Skip to content

Commit

Permalink
Create works
Browse files Browse the repository at this point in the history
  • Loading branch information
turulomio committed Aug 27, 2024
1 parent 9dcc8c2 commit b710b94
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/OpenFoodFactsSearch.vue
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@
this.product.ferrum= Number(item.nutriments.iron_100g )|| null
this.product.magnesium= Number(item.nutriments.magnesium_100g )|| null
this.product.phosphor= Number(item.nutriments.phosphor_100g )|| null
this.product.openfactsfood_id=item.id
this.product.openfoodfacts_id=item.id
this.key=this.key+1
this.dialog_products_crud=true
},
Expand Down
2 changes: 1 addition & 1 deletion src/components/ProductsCRUD.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<v-text-field data-test="ProductsCRUD_Phosphor" :readonly="mode=='D' || mode=='R'" v-model.number="newproduct.phosphor" :label="$t('Set product phosphor (mg)')" :placeholder="$t('Set product phosphor (mg)')" :rules="RulesFloatGEZ(10,false,3)" counter="10"/>
<v-text-field data-test="ProductsCRUD_Calcium" :readonly="mode=='D' || mode=='R'" v-model.number="newproduct.calcium" :label="$t('Set product calcium (mg)')" :placeholder="$t('Set product calcium (mg)')" :rules="RulesFloatGEZ(10,false,3)" counter="10"/>
<v-checkbox data-test="ProductsCRUD_GlutenFree" v-model="newproduct.glutenfree" :label="$t('Is gluten free?')"></v-checkbox>
<v-text-field :readonly="mode=='D' || mode=='R'" v-model="newproduct.openfactsfood_id" :label="$t('Set Open Facts Food Id')" :placeholder="$t('Set Open Facts Food Id')" :rules="RulesString(14,false)" counter="14"/>
<v-text-field :readonly="mode=='D' || mode=='R'" v-model="newproduct.openfoodfacts_id" :label="$t('Set Open Facts Food Id')" :placeholder="$t('Set Open Facts Food Id')" :rules="RulesString(14,false)" counter="14"/>

<AutocompleteProducts :readonly="mode=='D' || mode=='R'" :products="getArrayFromMap(useStore().products)" v-model="newproduct.products"/>
<v-text-field :readonly="mode=='D' || mode=='R'" v-model="newproduct.version_description" :label="$t('Set product version description')" :placeholder="$t('Set product version description')" :rules="RulesString(200,false)" counter="200"/>
Expand Down
2 changes: 1 addition & 1 deletion src/empty_objects.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export function empty_products(){
glutenfree:false,
calcium:null,
obsolete: false,
openfactsfood_id: null,
openfoodfacts_id: null,
elaborated_products:null,
food_types:null,
additives:[],
Expand Down

0 comments on commit b710b94

Please sign in to comment.