refs #6321 remove bad files

This commit is contained in:
Javier Segarra 2024-04-02 08:08:50 +02:00
parent 0c88efc291
commit c16cc78ce6
8 changed files with 2 additions and 795 deletions

4
.gitignore vendored
View File

@ -29,5 +29,5 @@ yarn-error.log*
*.sln
# Cypress directories and files
/tests/cypress/videos
/tests/cypress/screenshots
/test/cypress/videos
/test/cypress/screenshots

View File

@ -1,245 +0,0 @@
diff --git a/src/composables/useCardSize.js b/src/composables/useCardSize.js
new file mode 100644
index 00000000..7f562106
--- /dev/null
+++ b/src/composables/useCardSize.js
@@ -0,0 +1,8 @@
+import { useQuasar } from 'quasar';
+
+export default function() {
+ const quasar = useQuasar();
+ if (quasar.screen.gt.xs) return 'q-pa-md'
+ else return 'q-pa-xs';
+
+}
diff --git a/src/pages/Claim/Card/ClaimCard.vue b/src/pages/Claim/Card/ClaimCard.vue
index 249337c4..78eec9e8 100644
--- a/src/pages/Claim/Card/ClaimCard.vue
+++ b/src/pages/Claim/Card/ClaimCard.vue
@@ -5,6 +5,7 @@ import { useStateStore } from 'stores/useStateStore';
import { useI18n } from 'vue-i18n';
import ClaimDescriptor from './ClaimDescriptor.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -28,7 +29,7 @@ const { t } = useI18n();
<QPageContainer>
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Customer/Card/CustomerCard.vue b/src/pages/Customer/Card/CustomerCard.vue
index a3503628..9da9eb21 100644
--- a/src/pages/Customer/Card/CustomerCard.vue
+++ b/src/pages/Customer/Card/CustomerCard.vue
@@ -6,6 +6,7 @@ import CustomerDescriptor from './CustomerDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const route = useRoute();
@@ -30,7 +31,7 @@ const { t } = useI18n();
<QPageContainer>
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Entry/Card/EntryCard.vue b/src/pages/Entry/Card/EntryCard.vue
index eea0b3b6..5a2bef18 100644
--- a/src/pages/Entry/Card/EntryCard.vue
+++ b/src/pages/Entry/Card/EntryCard.vue
@@ -7,6 +7,7 @@ import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import EntryDescriptor from './EntryDescriptor.vue';
import { useStateStore } from 'stores/useStateStore';
+import useCardSize from 'src/composables/useCardSize';
const { t } = useI18n();
const stateStore = useStateStore();
@@ -33,7 +34,7 @@ const stateStore = useStateStore();
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/InvoiceIn/Card/InvoiceInCard.vue b/src/pages/InvoiceIn/Card/InvoiceInCard.vue
index c0e36e58..0de31c18 100644
--- a/src/pages/InvoiceIn/Card/InvoiceInCard.vue
+++ b/src/pages/InvoiceIn/Card/InvoiceInCard.vue
@@ -8,6 +8,7 @@ import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import { useArrayData } from 'src/composables/useArrayData';
import { onMounted, watch } from 'vue';
import { useRoute } from 'vue-router';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -74,7 +75,7 @@ watch(
<QPageContainer>
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/InvoiceOut/Card/InvoiceOutCard.vue b/src/pages/InvoiceOut/Card/InvoiceOutCard.vue
index fe6649fb..6844df2d 100644
--- a/src/pages/InvoiceOut/Card/InvoiceOutCard.vue
+++ b/src/pages/InvoiceOut/Card/InvoiceOutCard.vue
@@ -5,6 +5,7 @@ import InvoiceOutDescriptor from './InvoiceOutDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSearchbar from 'components/ui/VnSearchbar.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -28,7 +29,7 @@ const { t } = useI18n();
<QPageContainer>
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Item/Card/ItemCard.vue b/src/pages/Item/Card/ItemCard.vue
index 5ca20d6f..3b3750b2 100644
--- a/src/pages/Item/Card/ItemCard.vue
+++ b/src/pages/Item/Card/ItemCard.vue
@@ -4,6 +4,7 @@ import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import ItemDescriptor from './ItemDescriptor.vue';
import { useStateStore } from 'stores/useStateStore';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
</script>
@@ -19,7 +20,7 @@ const stateStore = useStateStore();
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Supplier/Card/SupplierCard.vue b/src/pages/Supplier/Card/SupplierCard.vue
index 74b2dfb4..fdf1d785 100644
--- a/src/pages/Supplier/Card/SupplierCard.vue
+++ b/src/pages/Supplier/Card/SupplierCard.vue
@@ -5,6 +5,7 @@ import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import LeftMenu from 'components/LeftMenu.vue';
import SupplierDescriptor from './SupplierDescriptor.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -30,7 +31,7 @@ const { t } = useI18n();
<QPageContainer>
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Ticket/Card/TicketCard.vue b/src/pages/Ticket/Card/TicketCard.vue
index 568cf644..0d5d3803 100644
--- a/src/pages/Ticket/Card/TicketCard.vue
+++ b/src/pages/Ticket/Card/TicketCard.vue
@@ -5,6 +5,7 @@ import TicketDescriptor from './TicketDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -29,7 +30,7 @@ const { t } = useI18n();
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Travel/Card/TravelCard.vue b/src/pages/Travel/Card/TravelCard.vue
index 76bf74c6..e6c7b7e2 100644
--- a/src/pages/Travel/Card/TravelCard.vue
+++ b/src/pages/Travel/Card/TravelCard.vue
@@ -3,6 +3,7 @@ import { useStateStore } from 'stores/useStateStore';
import TravelDescriptor from './TravelDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
</script>
@@ -17,7 +18,7 @@ const stateStore = useStateStore();
<QPageContainer>
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Wagon/Card/WagonCard.vue b/src/pages/Wagon/Card/WagonCard.vue
index ba451777..5ac18fb4 100644
--- a/src/pages/Wagon/Card/WagonCard.vue
+++ b/src/pages/Wagon/Card/WagonCard.vue
@@ -3,6 +3,7 @@ import { useI18n } from 'vue-i18n';
import { useStateStore } from 'stores/useStateStore';
import { useRoute } from 'vue-router';
import LeftMenu from 'components/LeftMenu.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const route = useRoute();
@@ -17,7 +18,7 @@ const { t } = useI18n();
</QDrawer>
<QPageContainer>
<QPage>
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>
diff --git a/src/pages/Worker/Card/WorkerCard.vue b/src/pages/Worker/Card/WorkerCard.vue
index 3b31f906..0d62dcfc 100644
--- a/src/pages/Worker/Card/WorkerCard.vue
+++ b/src/pages/Worker/Card/WorkerCard.vue
@@ -5,6 +5,7 @@ import WorkerDescriptor from './WorkerDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+import useCardSize from 'src/composables/useCardSize';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -29,7 +30,7 @@ const { t } = useI18n();
<QPage>
<VnSubToolbar />
- <div :class="$q.screen.gt.xs ? 'q-pa-md' : 'q-pa-xs'">
+ <div :class="useCardSize()">
<RouterView></RouterView>
</div>
</QPage>

View File

@ -1,30 +0,0 @@
diff --git a/src/components/FormModel.vue b/src/components/FormModel.vue
index 04b4b201..70c9369f 100644
--- a/src/components/FormModel.vue
+++ b/src/components/FormModel.vue
@@ -113,6 +113,8 @@ onUnmounted(() => {
state.unset($props.model);
});
+const formRef = ref();
+
const isLoading = ref(false);
// Si elegimos observar los cambios del form significa que inicialmente las actions estaran deshabilitadas
const isResetting = ref(false);
@@ -152,6 +154,8 @@ async function fetch() {
}
async function save() {
+ const isValid = await formRef.value.validate();
+ if (!isValid) return;
if ($props.observeFormChanges && !hasChanges.value) {
notify('globals.noChanges', 'negative');
return;
@@ -214,6 +218,7 @@ watch(formUrl, async () => {
<template>
<div class="column items-center full-width">
<QForm
+ ref="formRef"
v-if="formData"
@submit="save"
@reset="reset"

View File

@ -1,13 +0,0 @@
diff --git a/src/layouts/MainLayout.vue b/src/layouts/MainLayout.vue
index 021ee685..8ff625d5 100644
--- a/src/layouts/MainLayout.vue
+++ b/src/layouts/MainLayout.vue
@@ -5,7 +5,7 @@ const quasar = useQuasar();
</script>
<template>
- <QLayout view="hHh LpR fFf">
+ <QLayout view="hHh LspR fFf">
<Navbar />
<RouterView></RouterView>
<QFooter v-if="quasar.platform.is.mobile"></QFooter>

View File

@ -1,232 +0,0 @@
diff --git a/src/components/CreateBankEntityForm.vue b/src/components/CreateBankEntityForm.vue
index 0ad35490..20550255 100644
--- a/src/components/CreateBankEntityForm.vue
+++ b/src/components/CreateBankEntityForm.vue
@@ -60,6 +60,7 @@ const onDataSaved = (formData, requestResponse) => {
v-model="data.name"
:required="true"
:rules="validate('bankEntity.name')"
+ autofocus
/>
</div>
<div class="col">
diff --git a/src/components/ui/VnRow.vue b/src/components/ui/VnRow.vue
index f2d2b55d..a2f89ff3 100644
--- a/src/components/ui/VnRow.vue
+++ b/src/components/ui/VnRow.vue
@@ -1,17 +1,17 @@
<template>
- <div id="row" class="q-gutter-md q-mb-md">
+ <div class="vn-row q-gutter-md q-mb-md">
<slot></slot>
</div>
</template>
<style lang="scss" scopped>
-#row {
+.vn-row {
display: flex;
> * {
flex: 1;
}
}
@media screen and (max-width: 800px) {
- #row {
+ .vn-row {
flex-direction: column;
}
}
diff --git a/src/css/app.scss b/src/css/app.scss
index 4fec9db0..35a36797 100644
--- a/src/css/app.scss
+++ b/src/css/app.scss
@@ -89,3 +89,6 @@ input::-webkit-inner-spin-button {
-webkit-appearance: none;
-moz-appearance: none;
}
+.vn-row > .flex-0 {
+ flex: 0;
+}
diff --git a/src/pages/Supplier/Card/SupplierAccounts.vue b/src/pages/Supplier/Card/SupplierAccounts.vue
index 41df6adb..8600d421 100644
--- a/src/pages/Supplier/Card/SupplierAccounts.vue
+++ b/src/pages/Supplier/Card/SupplierAccounts.vue
@@ -102,64 +102,58 @@ onMounted(() => {
:key="index"
class="row q-gutter-md q-mb-md"
>
- <div class="col">
- <VnInput :label="t('supplier.accounts.iban')" v-model="row.iban">
- <template #append>
- <QIcon name="info" class="cursor-info">
- <QTooltip>{{
- t('components.iban_tooltip')
- }}</QTooltip>
- </QIcon>
- </template>
- </VnInput>
- </div>
- <div class="col">
- <VnSelectDialog
- :label="t('worker.create.bankEntity')"
- v-model="row.bankEntityFk"
- :options="bankEntitiesOptions"
- option-label="bic"
- option-value="id"
- hide-selected
- >
- <template #form>
- <CreateBankEntityForm
- @on-data-saved="
- (_, requestResponse) =>
- onBankEntityCreated(requestResponse, row)
- "
- :show-entity-field="false"
- />
- </template>
- <template #option="scope">
- <QItem v-bind="scope.itemProps">
- <QItemSection v-if="scope.opt">
- <QItemLabel
- >{{ scope.opt.bic }}
- {{ scope.opt.name }}</QItemLabel
- >
- </QItemSection>
- </QItem>
- </template>
- </VnSelectDialog>
- </div>
- <div class="col">
- <VnInput
- :label="t('supplier.accounts.beneficiary')"
- v-model="row.beneficiary"
- >
- <template #append>
- <QIcon name="info" class="cursor-pointer">
- <QTooltip>{{
- t(
- 'Name of the bank account holder if different from the provider'
- )
- }}</QTooltip>
- </QIcon>
- </template>
- </VnInput>
- </div>
- <div class="col-1 row justify-center items-center">
+ <VnInput :label="t('supplier.accounts.iban')" v-model="row.iban">
+ <template #append>
+ <QIcon name="info" class="cursor-info">
+ <QTooltip>{{ t('components.iban_tooltip') }}</QTooltip>
+ </QIcon>
+ </template>
+ </VnInput>
+
+ <VnSelectDialog
+ :label="t('worker.create.bankEntity')"
+ v-model="row.bankEntityFk"
+ :options="bankEntitiesOptions"
+ option-label="bic"
+ option-value="id"
+ hide-selected
+ >
+ <template #form>
+ <CreateBankEntityForm
+ @on-data-saved="
+ (_, requestResponse) =>
+ onBankEntityCreated(requestResponse, row)
+ "
+ :show-entity-field="false"
+ />
+ </template>
+ <template #option="scope">
+ <QItem v-bind="scope.itemProps">
+ <QItemSection v-if="scope.opt">
+ <QItemLabel
+ >{{ scope.opt.bic }}
+ {{ scope.opt.name }}</QItemLabel
+ >
+ </QItemSection>
+ </QItem>
+ </template>
+ </VnSelectDialog>
+
+ <VnInput
+ :label="t('supplier.accounts.beneficiary')"
+ v-model="row.beneficiary"
+ >
+ <template #append>
+ <QIcon name="info" class="cursor-pointer">
+ <QTooltip>{{
+ t(
+ 'Name of the bank account holder if different from the provider'
+ )
+ }}</QTooltip>
+ </QIcon>
+ </template>
+ </VnInput>
+ <div class="row justify-end items-center flex-0">
<QIcon
name="delete"
size="sm"
@@ -174,23 +168,24 @@ onMounted(() => {
</div>
</VnRow>
<VnRow>
- <QIcon
- name="add"
- size="sm"
- class="cursor-pointer"
- color="primary"
- @click="supplierAccountRef.insert()"
- >
- <QTooltip>
- {{ t('Add account') }}
- </QTooltip>
- </QIcon>
+ <div class="row items-center">
+ <QIcon
+ name="add"
+ size="sm"
+ class="cursor-pointer"
+ color="primary"
+ @click="supplierAccountRef.insert()"
+ >
+ <QTooltip>
+ {{ t('Add account') }}
+ </QTooltip>
+ </QIcon>
+ </div>
</VnRow>
</QCard>
</template>
</CrudModel>
</template>
-
<i18n>
es:
Do you want to change the pay method to wire transfer?: ¿Quieres modificar la forma de pago a transferencia?
diff --git a/src/pages/Supplier/Card/SupplierAgencyTerm.vue b/src/pages/Supplier/Card/SupplierAgencyTerm.vue
index 769ff4da..b53ace0a 100644
--- a/src/pages/Supplier/Card/SupplierAgencyTerm.vue
+++ b/src/pages/Supplier/Card/SupplierAgencyTerm.vue
@@ -108,7 +108,7 @@ onMounted(() => {
type="number"
/>
</div>
- <div class="col-1 row justify-center items-center">
+ <div class="flex-0 row justify-center items-center">
<QIcon
name="delete"
size="sm"
diff --git a/src/pages/Supplier/Card/SupplierContacts.vue b/src/pages/Supplier/Card/SupplierContacts.vue
index 3abe5a9c..5f1ecd83 100644
--- a/src/pages/Supplier/Card/SupplierContacts.vue
+++ b/src/pages/Supplier/Card/SupplierContacts.vue
@@ -81,7 +81,7 @@ onMounted(() => {
autogrow
/>
</div>
- <div class="col-1 row justify-center items-center">
+ <div class="flex-0 row justify-center items-center">
<QIcon
name="delete"
size="sm"

View File

@ -1,230 +0,0 @@
diff --git a/src/components/common/VnInput.vue b/src/components/common/VnInput.vue
index 8a01e0be..06654081 100644
--- a/src/components/common/VnInput.vue
+++ b/src/components/common/VnInput.vue
@@ -1,5 +1,5 @@
<script setup>
-import { computed } from 'vue';
+import { computed, ref } from 'vue';
import { useI18n } from 'vue-i18n';
const emit = defineEmits(['update:modelValue', 'update:options', 'keyup.enter']);
@@ -26,7 +26,7 @@ const value = computed({
emit('update:modelValue', value);
},
});
-
+const focus = ref(false);
const styleAttrs = computed(() => {
return $props.isOutlined
? {
@@ -43,20 +43,32 @@ const onEnterPress = () => {
</script>
<template>
- <QInput
- ref="vnInputRef"
- v-model="value"
- v-bind="{ ...$attrs, ...styleAttrs }"
- type="text"
- :class="{ required: $attrs.required }"
- @keyup.enter="onEnterPress()"
+ <div
+ @mouseover="focus = true"
+ @mouseleave="focus = false"
:rules="$attrs.required ? [requiredFieldRule] : null"
>
- <template v-if="$slots.prepend" #prepend>
- <slot name="prepend" />
- </template>
- <template v-if="$slots.append" #append>
- <slot name="append" />
- </template>
- </QInput>
+ <QInput
+ ref="vnInputRef"
+ v-model="value"
+ v-bind="{ ...$attrs, ...styleAttrs }"
+ :type="$attrs.type"
+ :class="{ required: $attrs.required }"
+ @keyup.enter="onEnterPress()"
+ >
+ <template v-if="$slots.prepend" #prepend>
+ <slot name="prepend" />
+ </template>
+
+ <template #append>
+ <slot name="append" v-if="$slots.append" />
+ <QIcon
+ name="close"
+ size="xs"
+ v-if="focus && value"
+ @click="value = null"
+ ></QIcon>
+ </template>
+ </QInput>
+ </div>
</template>
diff --git a/src/components/common/VnInputDate.vue b/src/components/common/VnInputDate.vue
index 8e0ef289..2f0863d0 100644
--- a/src/components/common/VnInputDate.vue
+++ b/src/components/common/VnInputDate.vue
@@ -16,6 +16,8 @@ const props = defineProps({
default: false,
},
});
+const focus = ref(false);
+
const emit = defineEmits(['update:modelValue']);
const value = computed({
get() {
@@ -53,30 +55,41 @@ const styleAttrs = computed(() => {
</script>
<template>
- <QInput
- class="vn-input-date"
- rounded
- readonly
- :model-value="toDate(value)"
- v-bind="{ ...$attrs, ...styleAttrs }"
- >
- <template #append>
- <QIcon name="event" class="cursor-pointer">
- <QPopupProxy
- v-model="isPopupOpen"
- cover
- transition-show="scale"
- transition-hide="scale"
- :no-parent-event="props.readonly"
- >
- <QDate
- :model-value="formatDate(value)"
- @update:model-value="onDateUpdate"
- />
- </QPopupProxy>
- </QIcon>
- </template>
- </QInput>
+ <div @mouseover="focus = true" @mouseleave="focus = false">
+ <QInput
+ class="vn-input-date"
+ rounded
+ readonly
+ :model-value="toDate(value)"
+ v-bind="{ ...$attrs, ...styleAttrs }"
+ @click="isPopupOpen = true"
+ >
+ <template #append>
+ <QIcon
+ name="close"
+ size="xs"
+ v-if="focus && value"
+ @click="onDateUpdate(null)"
+ ></QIcon>
+ <QIcon name="event" class="cursor-pointer">
+ <QPopupProxy
+ v-model="isPopupOpen"
+ cover
+ transition-show="scale"
+ transition-hide="scale"
+ :no-parent-event="props.readonly"
+ >
+ <QDate
+ :today-btn="true"
+ mask="YYYY-MM-DD"
+ :model-value="value"
+ @update:model-value="onDateUpdate"
+ />
+ </QPopupProxy>
+ </QIcon>
+ </template>
+ </QInput>
+ </div>
</template>
<style lang="scss">
diff --git a/test/cypress/integration/VnLocation.spec.js b/test/cypress/integration/VnLocation.spec.js
index 02b924e4..ab58395f 100644
--- a/test/cypress/integration/VnLocation.spec.js
+++ b/test/cypress/integration/VnLocation.spec.js
@@ -1,7 +1,7 @@
const locationOptions ='[role="listbox"] > div.q-virtual-scroll__content > .q-item'
describe('VnLocation', () => {
describe('Create',()=>{
- const inputLocation = ':nth-child(3) > :nth-child(1) > .q-field > .q-field__inner > .q-field__control';
+ const inputLocation = '.q-form .q-card> :nth-child(3) > :nth-child(1) > .q-field > .q-field__inner > .q-field__control';
beforeEach(() => {
cy.viewport(1280, 720);
cy.login('developer');
@@ -26,7 +26,7 @@ describe('VnLocation', () => {
cy.get(inputLocation).type('ecuador');
cy.get(locationOptions).should('have.length',1);
cy.get(`${locationOptions}:nth-child(1)`).click();
- cy.get(':nth-child(3) > :nth-child(1) > .q-field > .q-field__inner > .q-field__control > :nth-child(2) > .q-icon').click();
+ cy.get(inputLocation+'> :nth-child(2) > .q-icon').click();
});
});
diff --git a/test/cypress/integration/claim/claimDevelopment.spec.js b/test/cypress/integration/claim/claimDevelopment.spec.js
index 26c7ee19..903f58d4 100755
--- a/test/cypress/integration/claim/claimDevelopment.spec.js
+++ b/test/cypress/integration/claim/claimDevelopment.spec.js
@@ -8,6 +8,7 @@ describe('ClaimDevelopment', () => {
cy.viewport(1920, 1080);
cy.login('developer');
cy.visit(`/#/claim/${claimId}/development`);
+ cy.waitForElement('tbody');
});
it('should reset line', () => {
diff --git a/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js b/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js
index 20f137ae..fc989d6c 100644
--- a/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js
+++ b/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js
@@ -1,6 +1,6 @@
/// <reference types="cypress" />
describe('InvoiceInBasicData', () => {
- const selects = ':nth-child(1) > :nth-child(1) > .q-field';
+ const selects = '.q-form .q-card>:nth-child(1) > :nth-child(1) > .q-field';
const appendBtns = 'label button';
const dialogAppendBtns = '.q-dialog label button';
const dialogInputs = '.q-dialog input';
diff --git a/test/cypress/support/commands.js b/test/cypress/support/commands.js
index f075d500..70c6068e 100755
--- a/test/cypress/support/commands.js
+++ b/test/cypress/support/commands.js
@@ -70,6 +70,7 @@ Cypress.Commands.add('getValue', (selector) => {
// Fill Inputs
Cypress.Commands.add('selectOption', (selector, option) => {
+ cy.waitForElement(selector);
cy.get(selector).find('.q-select__dropdown-icon').click();
cy.get('.q-menu .q-item').contains(option).click();
});
@@ -181,11 +182,11 @@ Cypress.Commands.add('closeLeftMenu', (element) => {
Cypress.Commands.add('clearSearchbar', (element) => {
if (element) cy.waitForElement(element);
- cy.get('#searchbar > form > label > div:nth-child(1) input').clear();
+ cy.get('#searchbar > form > div:nth-child(1) > label > div:nth-child(1) input').clear();
});
Cypress.Commands.add('writeSearchbar', (value) => {
- cy.get('#searchbar > form > label > div:nth-child(1) input').type(value);
+ cy.get('#searchbar > form > div:nth-child(1) > label > div:nth-child(1) input').type(value);
});
Cypress.Commands.add('validateContent', (selector, expectedValue) => {
cy.get(selector).should('have.text', expectedValue);
diff --git a/src/pages/Entry/EntryLatestBuys.vue b/src/pages/Entry/EntryLatestBuys.vue
index 217a2587..438873a7 100644
--- a/src/pages/Entry/EntryLatestBuys.vue
+++ b/src/pages/Entry/EntryLatestBuys.vue
@@ -88,6 +88,7 @@ const getInputEvents = (col) => {
return col.columnFilter.type === 'select'
? { 'update:modelValue': () => applyColumnFilter(col) }
: {
+ 'update:modelValue': () => applyColumnFilter(col),
'keyup.enter': () => applyColumnFilter(col),
};
};

View File

@ -1,43 +0,0 @@
diff --git a/quasar.config.js b/quasar.config.js
index 755e96bd..7afe7da1 100644
--- a/quasar.config.js
+++ b/quasar.config.js
@@ -29,7 +29,7 @@ module.exports = configure(function (/* ctx */) {
// app boot file (/src/boot)
// --> boot files are part of "main.js"
// https://v2.quasar.dev/quasar-cli/boot-files
- boot: ['i18n', 'axios', 'vnDate', 'validations'],
+ boot: ['i18n', 'axios', 'vnDate', 'vn-custom', 'validations'],
// https://v2.quasar.dev/quasar-cli-vite/quasar-config-js#css
css: ['app.scss'],
@@ -67,7 +67,7 @@ module.exports = configure(function (/* ctx */) {
// analyze: true,
// env: {},
rawDefine: {
- 'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV)
+ 'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV),
},
// ignorePublicFolder: true,
// minify: false,
@@ -92,7 +92,7 @@ module.exports = configure(function (/* ctx */) {
vitePlugins: [
[
VueI18nPlugin({
- runtimeOnly: false
+ runtimeOnly: false,
}),
{
// if you want to use Vue I18n Legacy API, you need to set `compositionOnly: false`
diff --git a/src/pages/Ticket/TicketList.vue b/src/pages/Ticket/TicketList.vue
index 9186eb6a..c6266afb 100644
--- a/src/pages/Ticket/TicketList.vue
+++ b/src/pages/Ticket/TicketList.vue
@@ -70,6 +70,7 @@ function viewSummary(id) {
</template>
<QDrawer v-model="stateStore.rightDrawer" side="right" :width="256">
<QScrollArea class="fit text-grey-8">
+ <my-input-number label="Measure" :step="0.001" v-model.number="measure" />
<TicketFilter data-key="TicketList" />
</QScrollArea>
</QDrawer>

View File