1
0
mirror of https://github.com/TandoorRecipes/recipes.git synced 2026-01-11 09:07:12 -05:00

fix get_facets_API

This commit is contained in:
smilerz
2021-12-16 08:13:10 -06:00
parent edc670e87d
commit d4553c05c2
4 changed files with 6 additions and 6 deletions

View File

@@ -220,7 +220,7 @@ export const ApiMixin = {
return {
Models: Models,
Actions: Actions,
FoodCreateDefault: function(form) {
FoodCreateDefault: function (form) {
form.inherit_ignore = getUserPreference("food_ignore_default")
form.inherit = form.supermarket_category.length > 0
return form
@@ -538,7 +538,7 @@ const specialCases = {
}
export const formFunctions = {
FoodCreateDefault: function(form) {
FoodCreateDefault: function (form) {
form.fields.filter((x) => x.field === "ignore_inherit")[0].value = getUserPreference("food_ignore_default")
form.fields.filter((x) => x.field === "inherit")[0].value = getUserPreference("food_ignore_default").length > 0
return form