Added additional name filed to article.

This commit is contained in:
2026-02-25 15:49:42 +01:00
parent ba5ebc3524
commit 75a178cbf4
7 changed files with 46 additions and 5 deletions
@@ -176,6 +176,18 @@
</v-col>
<v-col cols="5" style="padding: 5px;">
<v-row no-gutters>
<v-text-field
v-model.trim="store.articleEdit.additional_name"
label="Siegel Text"
:placeholder="store.articleEdit.name"
:hint="store.articleEdit.name"
persistent-placeholder
:persistent-hint="store.articleEdit.additional_name != null"
:readonly="!edit"
:clearable="edit"
/>
</v-row>
<v-row no-gutters>
<v-text-field
v-model.trim="store.articleEdit.bio_info"
@@ -21,6 +21,7 @@
let allergens_text: Ref<string | null> = ref<string | null>(null);
let bio_info: Ref<string | null> = ref<string | null>(null);
let topm_id: Ref<string | null> = ref<string | null>(null);
let additional_name: Ref<string | null> = ref<string | null>(null);
async function create() {
if (name.value != null && name.value.trim().length > 0 &&
@@ -36,7 +37,7 @@
const article: Article = new Article(0, name.value, bio.value, origin.value, description.value,
ingredients.value, default_unit.value, [],
mhd.value, bio_origin.value, allergens_text.value, bio_info.value, topm_id.value);
mhd.value, bio_origin.value, allergens_text.value, bio_info.value, topm_id.value, additional_name.value);
await store.createArticle(article);
@@ -60,6 +61,7 @@
allergens_text.value = null;
bio_info.value = null;
topm_id.value = null;
additional_name.value = null;
loading.value = false;
}
@@ -108,6 +110,15 @@
autofocus
/>
<v-text-field
v-model.trim="additional_name"
label="Siegel Text"
:placeholder="name"
:hint="name"
persistent-placeholder
:persistent-hint="additional_name != null"
/>
<v-row>
<v-col cols="2">
<v-checkbox