diff --git a/src/components/CrudModel.vue b/src/components/CrudModel.vue index de4724e55..000de4336 100644 --- a/src/components/CrudModel.vue +++ b/src/components/CrudModel.vue @@ -81,6 +81,7 @@ defineExpose({ hasChanges, saveChanges, getChanges, + formData, }); async function fetch(data) { diff --git a/src/components/common/VnSelect.vue b/src/components/common/VnSelect.vue index 05c74f00a..e8083dec2 100644 --- a/src/components/common/VnSelect.vue +++ b/src/components/common/VnSelect.vue @@ -57,7 +57,7 @@ const $props = defineProps({ }); const { t } = useI18n(); -const requiredFieldRule = (val) => !!val || t('globals.fieldRequired'); +const requiredFieldRule = (val) => val ?? t('globals.fieldRequired'); const { optionLabel, optionValue, options, modelValue } = toRefs($props); const myOptions = ref([]); @@ -167,6 +167,7 @@ watch(modelValue, (newValue) => { hide-selected fill-input ref="vnSelectRef" + lazy-rules :class="{ required: $attrs.required }" :rules="$attrs.required ? [requiredFieldRule] : null" virtual-scroll-slice-size="options.length" diff --git a/src/pages/Item/Card/ItemTags.vue b/src/pages/Item/Card/ItemTags.vue index 95f4380e4..b3cdfffb1 100644 --- a/src/pages/Item/Card/ItemTags.vue +++ b/src/pages/Item/Card/ItemTags.vue @@ -1 +1,191 @@ - + + + diff --git a/src/pages/Item/locale/en.yml b/src/pages/Item/locale/en.yml index 2c0131b4f..c08c71f48 100644 --- a/src/pages/Item/locale/en.yml +++ b/src/pages/Item/locale/en.yml @@ -72,3 +72,9 @@ lastEntries: package: Package freight: Freight comission: Comission +itemTags: + removeTag: Remove tag + addTag: Add tag + tag: Tag + value: Value + relevancy: Relevancy diff --git a/src/pages/Item/locale/es.yml b/src/pages/Item/locale/es.yml index a09a63249..9b6a51b8a 100644 --- a/src/pages/Item/locale/es.yml +++ b/src/pages/Item/locale/es.yml @@ -72,3 +72,9 @@ lastEntries: package: Embalaje freight: Porte comission: Comisión +itemTags: + removeTag: Quitar etiqueta + addTag: Añadir etiqueta + tag: Etiqueta + value: Valor + relevancy: Relevancia diff --git a/src/router/modules/item.js b/src/router/modules/item.js index 24919db39..6e8659747 100644 --- a/src/router/modules/item.js +++ b/src/router/modules/item.js @@ -28,6 +28,7 @@ export default { 'ItemBarcode', 'ItemShelving', 'ItemLastEntries', + 'ItemTags', ], }, children: [