From 8a1a748c92f0bc884fcc7a4a3440e449379d898f Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Sat, 23 Nov 2024 00:51:33 +0100 Subject: [PATCH] test: add data-cy --- src/components/FormModel.vue | 3 +++ src/components/ui/VnNotes.vue | 1 + src/pages/Customer/Card/CustomerBasicData.vue | 7 ++++++- src/pages/Customer/Card/CustomerWebPayment.vue | 4 ++-- 4 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/components/FormModel.vue b/src/components/FormModel.vue index f44e9dadf..96b782e44 100644 --- a/src/components/FormModel.vue +++ b/src/components/FormModel.vue @@ -106,6 +106,7 @@ const originalData = ref({}); const formData = computed(() => state.get(modelValue)); const defaultButtons = computed(() => ({ save: { + dataCy: 'saveDefaultBtn', color: 'primary', icon: 'save', label: 'globals.save', @@ -113,6 +114,7 @@ const defaultButtons = computed(() => ({ type: 'submit', }, reset: { + dataCy: 'resetDefaultBtn', color: 'primary', icon: 'restart_alt', label: 'globals.reset', @@ -318,6 +320,7 @@ defineExpose({ :title="t(defaultButtons.reset.label)" /> { @click="insert" class="q-mb-xs" dense + data-cy="saveNote" /> diff --git a/src/pages/Customer/Card/CustomerBasicData.vue b/src/pages/Customer/Card/CustomerBasicData.vue index dd71edc0b..622044bbd 100644 --- a/src/pages/Customer/Card/CustomerBasicData.vue +++ b/src/pages/Customer/Card/CustomerBasicData.vue @@ -51,7 +51,12 @@ function onBeforeSave(formData, originalData) { @on-fetch="(data) => (businessTypes = data)" auto-load /> - +