-
-
-
-
+
diff --git a/src/components/__tests__/Leftmenu.spec.js b/src/components/__tests__/Leftmenu.spec.js
index 4ab8b527fdf..0bcc587ac4c 100644
--- a/src/components/__tests__/Leftmenu.spec.js
+++ b/src/components/__tests__/Leftmenu.spec.js
@@ -15,10 +15,7 @@ vi.mock('src/router/modules', () => ({
meta: {
title: 'customers',
icon: 'vn:client',
- },
- menus: {
- main: ['CustomerList', 'CustomerCreate'],
- card: ['CustomerBasicData'],
+ menu: ['CustomerList', 'CustomerCreate'],
},
children: [
{
@@ -50,14 +47,6 @@ vi.mock('src/router/modules', () => ({
],
},
},
- {
- path: 'create',
- name: 'CustomerCreate',
- meta: {
- title: 'createCustomer',
- icon: 'vn:addperson',
- },
- },
],
},
],
@@ -98,7 +87,7 @@ vi.spyOn(vueRouter, 'useRoute').mockReturnValue({
icon: 'vn:client',
moduleName: 'Customer',
keyBinding: 'c',
- menu: 'customer',
+ menu: ['customer'],
},
},
],
@@ -260,15 +249,6 @@ describe('Leftmenu as main', () => {
});
});
- it('should handle a single matched route with a menu', () => {
- const route = {
- matched: [{ meta: { menu: 'customer' } }],
- };
-
- const result = vm.betaGetRoutes();
-
- expect(result.meta.menu).toEqual(route.matched[0].meta.menu);
- });
it('should get routes for main source', () => {
vm.props.source = 'main';
vm.getRoutes();
@@ -351,8 +331,9 @@ describe('addChildren', () => {
it('should handle routes with no meta menu', () => {
const route = {
- meta: {},
- menus: {},
+ meta: {
+ menu: [],
+ },
};
const parent = [];
diff --git a/src/components/common/VnCheckbox.vue b/src/components/common/VnCheckbox.vue
index 94e91328b6c..daaf891dce2 100644
--- a/src/components/common/VnCheckbox.vue
+++ b/src/components/common/VnCheckbox.vue
@@ -27,7 +27,11 @@ const checkboxModel = computed({
-
+
{{ t('globals.selectFile') }}
diff --git a/src/components/common/VnDmsList.vue b/src/components/common/VnDmsList.vue
index 424781a2695..aafa9f4babc 100644
--- a/src/components/common/VnDmsList.vue
+++ b/src/components/common/VnDmsList.vue
@@ -389,10 +389,7 @@ defineExpose({
-
+
{{ t('No data to display') }}
@@ -416,6 +413,7 @@ defineExpose({
v-shortcut
@click="showFormDialog()"
class="fill-icon"
+ data-cy="addButton"
>
{{ t('Upload file') }}
diff --git a/src/components/common/VnInputDate.vue b/src/components/common/VnInputDate.vue
index 1f4705faa15..343130f1d92 100644
--- a/src/components/common/VnInputDate.vue
+++ b/src/components/common/VnInputDate.vue
@@ -107,7 +107,7 @@ const manageDate = (date) => {
@click="isPopupOpen = !isPopupOpen"
@keydown="isPopupOpen = false"
hide-bottom-space
- :data-cy="$attrs.dataCy ?? $attrs.label + '_inputDate'"
+ :data-cy="($attrs['data-cy'] ?? $attrs.label) + '_inputDate'"
>
-
@@ -614,7 +615,11 @@ watch(
>
{{ prop.nameI18n }}:
-
+
+
-
→
-
-
+import { useDescriptorStore } from 'src/stores/useDescriptorStore';
+import VnJsonValue from './VnJsonValue.vue';
+import { computed } from 'vue';
+const descriptorStore = useDescriptorStore();
+
+const $props = defineProps({
+ name: { type: [String], default: undefined },
+});
+
+const descriptor = computed(() => descriptorStore.has($props.name));
+
+
+
+
+
+
diff --git a/src/components/common/VnSelect.vue b/src/components/common/VnSelect.vue
index 339f90e0ef8..6eda038919c 100644
--- a/src/components/common/VnSelect.vue
+++ b/src/components/common/VnSelect.vue
@@ -1,5 +1,5 @@
-