Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix-front into 8862-testIsolationFalse
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
This commit is contained in:
commit
4d9912e9b5
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "salix-front",
|
"name": "salix-front",
|
||||||
"version": "25.16.0",
|
"version": "25.18.0",
|
||||||
"description": "Salix frontend",
|
"description": "Salix frontend",
|
||||||
"productName": "Salix",
|
"productName": "Salix",
|
||||||
"author": "Verdnatura",
|
"author": "Verdnatura",
|
||||||
|
@ -89,4 +89,4 @@
|
||||||
"vite": "^6.0.11",
|
"vite": "^6.0.11",
|
||||||
"vitest": "^0.31.1"
|
"vitest": "^0.31.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -20,12 +20,12 @@ const autofillBic = async (iban) => {
|
||||||
|
|
||||||
if (ibanCountry != 'ES') return;
|
if (ibanCountry != 'ES') return;
|
||||||
|
|
||||||
const filter = { where: { id: bankEntityId.value } };
|
const filter = { where: { id: bankEntityId } };
|
||||||
const params = { filter: JSON.stringify(filter) };
|
const params = { filter: JSON.stringify(filter) };
|
||||||
|
|
||||||
const { data } = await axios.get(`BankEntities`, { params });
|
const { data } = await axios.get(`BankEntities`, { params });
|
||||||
|
|
||||||
emit('updateBic', data[0].id);
|
emit('updateBic', data[0]?.id);
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
|
|
|
@ -68,7 +68,6 @@ const filter = {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
where: { and: [{ originFk: route.params.id }] },
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const paginate = ref();
|
const paginate = ref();
|
||||||
|
@ -267,13 +266,6 @@ onMounted(() => {
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
stateStore.rightDrawer = false;
|
stateStore.rightDrawer = false;
|
||||||
});
|
});
|
||||||
|
|
||||||
watch(
|
|
||||||
() => router.currentRoute.value.params.id,
|
|
||||||
() => {
|
|
||||||
applyFilter();
|
|
||||||
},
|
|
||||||
);
|
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<VnPaginate
|
<VnPaginate
|
||||||
|
@ -281,6 +273,7 @@ watch(
|
||||||
:data-key
|
:data-key
|
||||||
:url="dataKey + 's'"
|
:url="dataKey + 's'"
|
||||||
:user-filter="filter"
|
:user-filter="filter"
|
||||||
|
:filter="{ where: { and: [{ originFk: route.params.id }] } }"
|
||||||
:skeleton="false"
|
:skeleton="false"
|
||||||
auto-load
|
auto-load
|
||||||
@on-fetch="setLogTree"
|
@on-fetch="setLogTree"
|
||||||
|
|
|
@ -39,7 +39,7 @@ const checkboxOptions = ref([
|
||||||
{ name: 'select', label: 'Accesses', selected: false },
|
{ name: 'select', label: 'Accesses', selected: false },
|
||||||
]);
|
]);
|
||||||
const columns = computed(() => [
|
const columns = computed(() => [
|
||||||
{ name: 'changedModelValue' },
|
{ name: 'changedModelValue', orderBy: 'id' },
|
||||||
{ name: 'changedModel' },
|
{ name: 'changedModel' },
|
||||||
{ name: 'userType', orderBy: false },
|
{ name: 'userType', orderBy: false },
|
||||||
{ name: 'userFk' },
|
{ name: 'userFk' },
|
||||||
|
|
|
@ -6,6 +6,7 @@ import { computed } from 'vue';
|
||||||
|
|
||||||
const $props = defineProps({
|
const $props = defineProps({
|
||||||
label: { type: String, default: null },
|
label: { type: String, default: null },
|
||||||
|
tooltip: { type: String, default: null },
|
||||||
value: {
|
value: {
|
||||||
type: [String, Boolean, Number],
|
type: [String, Boolean, Number],
|
||||||
default: null,
|
default: null,
|
||||||
|
@ -40,7 +41,10 @@ const val = computed(() => $props.value);
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<div v-if="label || $slots.label" class="label">
|
<div v-if="label || $slots.label" class="label">
|
||||||
<slot name="label">
|
<slot name="label">
|
||||||
<span style="color: var(--vn-label-color)">{{ label }}</span>
|
<QTooltip v-if="tooltip">{{ tooltip }}</QTooltip>
|
||||||
|
<span style="color: var(--vn-label-color)">
|
||||||
|
{{ label }}
|
||||||
|
</span>
|
||||||
</slot>
|
</slot>
|
||||||
</div>
|
</div>
|
||||||
<div class="value" v-if="value || $slots.value">
|
<div class="value" v-if="value || $slots.value">
|
||||||
|
|
|
@ -1,60 +0,0 @@
|
||||||
<script setup>
|
|
||||||
import { ref } from 'vue';
|
|
||||||
import { useI18n } from 'vue-i18n';
|
|
||||||
|
|
||||||
const { t } = useI18n();
|
|
||||||
const props = defineProps({
|
|
||||||
usesMana: {
|
|
||||||
type: Boolean,
|
|
||||||
required: true,
|
|
||||||
},
|
|
||||||
manaCode: {
|
|
||||||
type: String,
|
|
||||||
required: true,
|
|
||||||
},
|
|
||||||
manaVal: {
|
|
||||||
type: String,
|
|
||||||
default: 'mana',
|
|
||||||
},
|
|
||||||
manaLabel: {
|
|
||||||
type: String,
|
|
||||||
default: 'Promotion mana',
|
|
||||||
},
|
|
||||||
manaClaimVal: {
|
|
||||||
type: String,
|
|
||||||
default: 'manaClaim',
|
|
||||||
},
|
|
||||||
claimLabel: {
|
|
||||||
type: String,
|
|
||||||
default: 'Claim mana',
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
const manaCode = ref(props.manaCode);
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<template>
|
|
||||||
<div class="column q-gutter-y-sm q-mt-sm">
|
|
||||||
<QRadio
|
|
||||||
v-model="manaCode"
|
|
||||||
dense
|
|
||||||
:val="manaVal"
|
|
||||||
:label="t(manaLabel)"
|
|
||||||
:dark="true"
|
|
||||||
class="q-mb-sm"
|
|
||||||
/>
|
|
||||||
<QRadio
|
|
||||||
v-model="manaCode"
|
|
||||||
dense
|
|
||||||
:val="manaClaimVal"
|
|
||||||
:label="t(claimLabel)"
|
|
||||||
:dark="true"
|
|
||||||
class="q-mb-sm"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
<i18n>
|
|
||||||
es:
|
|
||||||
Promotion mana: Maná promoción
|
|
||||||
Claim mana: Maná reclamación
|
|
||||||
</i18n>
|
|
|
@ -340,17 +340,18 @@ function claimUrl(section) {
|
||||||
<template #body="props">
|
<template #body="props">
|
||||||
<QTr :props="props">
|
<QTr :props="props">
|
||||||
<QTd v-for="col in props.cols" :key="col.name" :props="props">
|
<QTd v-for="col in props.cols" :key="col.name" :props="props">
|
||||||
<span v-if="col.name != 'description'">{{
|
<template v-if="col.name === 'description'">
|
||||||
t(col.value)
|
<span class="link">{{
|
||||||
}}</span>
|
dashIfEmpty(col.field(props.row))
|
||||||
<span class="link" v-if="col.name === 'description'">{{
|
}}</span>
|
||||||
t(col.value)
|
<ItemDescriptorProxy
|
||||||
}}</span>
|
:id="props.row.sale.itemFk"
|
||||||
<ItemDescriptorProxy
|
:sale-fk="props.row.saleFk"
|
||||||
v-if="col.name == 'description'"
|
/>
|
||||||
:id="props.row.sale.itemFk"
|
</template>
|
||||||
:sale-fk="props.row.saleFk"
|
<template v-else>
|
||||||
></ItemDescriptorProxy>
|
{{ dashIfEmpty(col.field(props.row)) }}
|
||||||
|
</template>
|
||||||
</QTd>
|
</QTd>
|
||||||
</QTr>
|
</QTr>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -131,6 +131,7 @@ const columns = computed(() => [
|
||||||
name: 'isConciliate',
|
name: 'isConciliate',
|
||||||
label: t('Conciliated'),
|
label: t('Conciliated'),
|
||||||
cardVisible: true,
|
cardVisible: true,
|
||||||
|
component: 'checkbox',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
align: 'left',
|
align: 'left',
|
||||||
|
|
|
@ -18,7 +18,7 @@ import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
|
||||||
import VnSelect from 'components/common/VnSelect.vue';
|
import VnSelect from 'components/common/VnSelect.vue';
|
||||||
import VnInputDate from 'components/common/VnInputDate.vue';
|
import VnInputDate from 'components/common/VnInputDate.vue';
|
||||||
|
|
||||||
const arrayData = useArrayData('Client');
|
const arrayData = useArrayData('Customer');
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const campaignList = ref();
|
const campaignList = ref();
|
||||||
|
@ -260,7 +260,7 @@ const updateDateParams = (value, params) => {
|
||||||
:label="t('globals.campaign')"
|
:label="t('globals.campaign')"
|
||||||
:filled="true"
|
:filled="true"
|
||||||
class="q-px-sm q-pt-none fit"
|
class="q-px-sm q-pt-none fit"
|
||||||
:option-label="(opt) => t(opt.code)"
|
:option-label="(opt) => t(opt.code ?? '')"
|
||||||
:fields="['id', 'code', 'dated', 'scopeDays']"
|
:fields="['id', 'code', 'dated', 'scopeDays']"
|
||||||
@update:model-value="(data) => updateDateParams(data, params)"
|
@update:model-value="(data) => updateDateParams(data, params)"
|
||||||
dense
|
dense
|
||||||
|
|
|
@ -34,7 +34,7 @@ const columns = computed(() => [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
align: 'left',
|
align: 'left',
|
||||||
format: (row) => row.type.description,
|
format: (row) => row?.type?.description,
|
||||||
label: t('Description'),
|
label: t('Description'),
|
||||||
name: 'description',
|
name: 'description',
|
||||||
},
|
},
|
||||||
|
|
|
@ -185,7 +185,7 @@ const sumRisk = ({ clientRisks }) => {
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('customer.summary.payMethod')"
|
:label="t('customer.summary.payMethod')"
|
||||||
:value="entity.payMethod.name"
|
:value="entity.payMethod?.name"
|
||||||
/>
|
/>
|
||||||
<VnLv :label="t('customer.summary.bankAccount')" :value="entity.iban" />
|
<VnLv :label="t('customer.summary.bankAccount')" :value="entity.iban" />
|
||||||
<VnLv :label="t('customer.summary.dueDay')" :value="entity.dueDay" />
|
<VnLv :label="t('customer.summary.dueDay')" :value="entity.dueDay" />
|
||||||
|
@ -208,7 +208,8 @@ const sumRisk = ({ clientRisks }) => {
|
||||||
:text="t('customer.summary.consignee')"
|
:text="t('customer.summary.consignee')"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('customer.summary.addressName')"
|
:tooltip="t('customer.summary.addressName')"
|
||||||
|
:label="t('customer.summary.addressNameAbbr')"
|
||||||
:value="entity.defaultAddress.nickname"
|
:value="entity.defaultAddress.nickname"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
|
@ -252,7 +253,8 @@ const sumRisk = ({ clientRisks }) => {
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
v-if="entity.claimsRatio"
|
v-if="entity.claimsRatio"
|
||||||
:label="t('customer.summary.priceIncreasingRate')"
|
:tooltip="t('customer.summary.priceIncreasingRate')"
|
||||||
|
:label="t('customer.summary.priceIncreasingRateAbbr')"
|
||||||
:value="toPercentage(priceIncreasingRate)"
|
:value="toPercentage(priceIncreasingRate)"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
|
@ -261,7 +263,8 @@ const sumRisk = ({ clientRisks }) => {
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
v-if="entity.claimsRatio"
|
v-if="entity.claimsRatio"
|
||||||
:label="t('customer.summary.claimRate')"
|
:label="t('customer.summary.claimRateAbbr')"
|
||||||
|
:tooltip="t('customer.summary.claimRate')"
|
||||||
:value="toPercentage(claimRate)"
|
:value="toPercentage(claimRate)"
|
||||||
/>
|
/>
|
||||||
</QCard>
|
</QCard>
|
||||||
|
@ -318,8 +321,9 @@ const sumRisk = ({ clientRisks }) => {
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('customer.summary.recommendCredit')"
|
:label="t('customer.summary.recommendCreditAbbr')"
|
||||||
:value="entity.recommendedCredit"
|
:tooltip="t('customer.summary.recommendCredit')"
|
||||||
|
:value="toCurrency(entity.recommendedCredit)"
|
||||||
/>
|
/>
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard class="vn-max">
|
<QCard class="vn-max">
|
||||||
|
|
|
@ -111,14 +111,11 @@ const columns = computed(() => [
|
||||||
component: 'number',
|
component: 'number',
|
||||||
},
|
},
|
||||||
columnField: {
|
columnField: {
|
||||||
component: null,
|
component: markRaw(VnLinkPhone),
|
||||||
after: {
|
attrs: ({ model }) => {
|
||||||
component: markRaw(VnLinkPhone),
|
return {
|
||||||
attrs: ({ model }) => {
|
'phone-number': model,
|
||||||
return {
|
};
|
||||||
'phone-number': model,
|
|
||||||
};
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -42,14 +42,17 @@ customer:
|
||||||
hasCoreVnl: Has core VNL
|
hasCoreVnl: Has core VNL
|
||||||
hasB2BVnl: Has B2B VNL
|
hasB2BVnl: Has B2B VNL
|
||||||
addressName: Address name
|
addressName: Address name
|
||||||
|
addressNameAbbr: A. Name
|
||||||
addressCity: City
|
addressCity: City
|
||||||
username: Username
|
username: Username
|
||||||
webAccess: Web access
|
webAccess: Web access
|
||||||
totalGreuge: Total greuge
|
totalGreuge: Total greuge
|
||||||
mana: Mana
|
mana: Mana
|
||||||
priceIncreasingRate: Price increasing rate
|
priceIncreasingRate: Price increasing rate
|
||||||
|
priceIncreasingRateAbbr: Price inc. rate
|
||||||
averageInvoiced: Average invoiced
|
averageInvoiced: Average invoiced
|
||||||
claimRate: Claming rate
|
claimRate: Claming rate
|
||||||
|
claimRateAbbr: Claim. rate
|
||||||
payMethodFk: Billing data
|
payMethodFk: Billing data
|
||||||
risk: Risk
|
risk: Risk
|
||||||
maximumRisk: Solunion's maximum risk
|
maximumRisk: Solunion's maximum risk
|
||||||
|
@ -68,6 +71,7 @@ customer:
|
||||||
descriptorInfo: Invoices minus payments plus orders not yet
|
descriptorInfo: Invoices minus payments plus orders not yet
|
||||||
rating: Rating
|
rating: Rating
|
||||||
recommendCredit: Recommended credit
|
recommendCredit: Recommended credit
|
||||||
|
recommendCreditAbbr: Rec. credit
|
||||||
goToLines: Go to lines
|
goToLines: Go to lines
|
||||||
basicData:
|
basicData:
|
||||||
socialName: Fiscal name
|
socialName: Fiscal name
|
||||||
|
|
|
@ -42,14 +42,17 @@ customer:
|
||||||
hasCoreVnl: Recibido core VNL
|
hasCoreVnl: Recibido core VNL
|
||||||
hasB2BVnl: Recibido B2B VNL
|
hasB2BVnl: Recibido B2B VNL
|
||||||
addressName: Nombre de la dirección
|
addressName: Nombre de la dirección
|
||||||
|
addressNameAbbr: N. Dirección
|
||||||
addressCity: Ciudad
|
addressCity: Ciudad
|
||||||
username: Usuario
|
username: Usuario
|
||||||
webAccess: Acceso web
|
webAccess: Acceso web
|
||||||
totalGreuge: Greuge total
|
totalGreuge: Greuge total
|
||||||
mana: Maná
|
mana: Maná
|
||||||
priceIncreasingRate: Ratio de incremento de precio
|
priceIncreasingRate: Ratio de incremento de precio
|
||||||
|
priceIncreasingRateAbbr: R. Inc. Precio
|
||||||
averageInvoiced: Facturación media
|
averageInvoiced: Facturación media
|
||||||
claimRate: Ratio de reclamaciones
|
claimRate: Ratio de reclamaciones
|
||||||
|
claimRateAbbr: R. Reclamaciones
|
||||||
maximumRisk: Riesgo máximo asumido por Solunion
|
maximumRisk: Riesgo máximo asumido por Solunion
|
||||||
payMethodFk: Forma de pago
|
payMethodFk: Forma de pago
|
||||||
risk: Riesgo
|
risk: Riesgo
|
||||||
|
@ -68,6 +71,7 @@ customer:
|
||||||
descriptorInfo: Facturas menos recibos mas pedidos sin facturar
|
descriptorInfo: Facturas menos recibos mas pedidos sin facturar
|
||||||
rating: Clasificación
|
rating: Clasificación
|
||||||
recommendCredit: Crédito recomendado
|
recommendCredit: Crédito recomendado
|
||||||
|
recommendCreditAbbr: Cr. Recomendado
|
||||||
goToLines: Ir a líneas
|
goToLines: Ir a líneas
|
||||||
basicData:
|
basicData:
|
||||||
socialName: Nombre fiscal
|
socialName: Nombre fiscal
|
||||||
|
|
|
@ -141,7 +141,7 @@ const setOrderedPriority = async () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const sortRoutes = async () => {
|
const sortRoutes = async () => {
|
||||||
await axios.patch(`Routes/${route.params?.id}/guessPriority/`);
|
await axios.patch(`Routes/${route.params?.id}/optimizePriority`);
|
||||||
refreshKey.value++;
|
refreshKey.value++;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,6 @@ import { useI18n } from 'vue-i18n';
|
||||||
import { computed, ref } from 'vue';
|
import { computed, ref } from 'vue';
|
||||||
import { useRoute } from 'vue-router';
|
import { useRoute } from 'vue-router';
|
||||||
import { toCurrency } from 'src/filters';
|
import { toCurrency } from 'src/filters';
|
||||||
import VnUsesMana from 'components/ui/VnUsesMana.vue';
|
|
||||||
|
|
||||||
const $props = defineProps({
|
const $props = defineProps({
|
||||||
newPrice: {
|
newPrice: {
|
||||||
|
@ -15,23 +14,36 @@ const $props = defineProps({
|
||||||
type: Object,
|
type: Object,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
componentId: {
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const emit = defineEmits(['save', 'cancel', 'update:componentId']);
|
||||||
|
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const mana = ref(null);
|
const mana = ref(null);
|
||||||
const usesMana = ref(false);
|
const usesMana = ref([]);
|
||||||
|
|
||||||
const emit = defineEmits(['save', 'cancel']);
|
|
||||||
|
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const QPopupProxyRef = ref(null);
|
const QPopupProxyRef = ref(null);
|
||||||
const manaCode = ref($props.manaCode);
|
|
||||||
|
const componentId = computed({
|
||||||
|
get: () => $props.componentId,
|
||||||
|
set: (val) => emit('update:componentId', val),
|
||||||
|
});
|
||||||
|
|
||||||
const save = (sale = $props.sale) => {
|
const save = (sale = $props.sale) => {
|
||||||
emit('save', sale);
|
emit('save', sale);
|
||||||
QPopupProxyRef.value.hide();
|
QPopupProxyRef.value.hide();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const cancel = () => {
|
||||||
|
emit('cancel');
|
||||||
|
QPopupProxyRef.value.hide();
|
||||||
|
};
|
||||||
|
|
||||||
const getMana = async () => {
|
const getMana = async () => {
|
||||||
const { data } = await axios.get(`Tickets/${route.params.id}/getDepartmentMana`);
|
const { data } = await axios.get(`Tickets/${route.params.id}/getDepartmentMana`);
|
||||||
mana.value = data;
|
mana.value = data;
|
||||||
|
@ -39,15 +51,12 @@ const getMana = async () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const getUsesMana = async () => {
|
const getUsesMana = async () => {
|
||||||
const { data } = await axios.get('Sales/usesMana');
|
const { data } = await axios.get('Sales/getComponents');
|
||||||
usesMana.value = data;
|
usesMana.value = data;
|
||||||
};
|
};
|
||||||
|
|
||||||
const cancel = () => {
|
|
||||||
emit('cancel');
|
|
||||||
QPopupProxyRef.value.hide();
|
|
||||||
};
|
|
||||||
const hasMana = computed(() => typeof mana.value === 'number');
|
const hasMana = computed(() => typeof mana.value === 'number');
|
||||||
|
|
||||||
defineExpose({ save });
|
defineExpose({ save });
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -59,17 +68,29 @@ defineExpose({ save });
|
||||||
>
|
>
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="header">Mana: {{ toCurrency(mana) }}</div>
|
<div class="header">Mana: {{ toCurrency(mana) }}</div>
|
||||||
<QSpinner v-if="!hasMana" color="primary" size="md" />
|
|
||||||
|
<QSpinner v-if="!usesMana.length" color="primary" />
|
||||||
|
|
||||||
<div class="q-pa-md" v-else>
|
<div class="q-pa-md" v-else>
|
||||||
<slot :popup="QPopupProxyRef" />
|
<slot :popup="QPopupProxyRef" />
|
||||||
<div v-if="usesMana" class="column q-gutter-y-sm q-mt-sm">
|
|
||||||
<VnUsesMana :mana-code="manaCode" />
|
<div v-if="usesMana.length" class="column q-gutter-y-sm q-mt-sm">
|
||||||
|
<QRadio
|
||||||
|
v-for="(item, index) in usesMana"
|
||||||
|
:key="index"
|
||||||
|
v-model="componentId"
|
||||||
|
:val="item.id"
|
||||||
|
:label="item.name"
|
||||||
|
dense
|
||||||
|
:dark="true"
|
||||||
|
class="q-mb-sm"
|
||||||
|
:data-cy="`componentOption-${item.id}`"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="newPrice" class="column items-center q-mt-lg">
|
<div v-if="newPrice" class="column items-center q-mt-lg">
|
||||||
<span class="text-primary">{{ t('New price') }}</span>
|
<span class="text-primary">{{ t('New price') }}</span>
|
||||||
<span class="text-subtitle1">
|
<span class="text-subtitle1">{{ toCurrency(newPrice) }}</span>
|
||||||
{{ toCurrency($props.newPrice) }}
|
|
||||||
</span>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -77,7 +98,6 @@ defineExpose({ save });
|
||||||
<QBtn
|
<QBtn
|
||||||
color="primary"
|
color="primary"
|
||||||
class="no-border-radius"
|
class="no-border-radius"
|
||||||
dense
|
|
||||||
style="width: 50%"
|
style="width: 50%"
|
||||||
@click="cancel()"
|
@click="cancel()"
|
||||||
>
|
>
|
||||||
|
@ -86,7 +106,6 @@ defineExpose({ save });
|
||||||
<QBtn
|
<QBtn
|
||||||
color="primary"
|
color="primary"
|
||||||
class="no-border-radius"
|
class="no-border-radius"
|
||||||
dense
|
|
||||||
style="width: 50%"
|
style="width: 50%"
|
||||||
@click="save()"
|
@click="save()"
|
||||||
data-cy="saveManaBtn"
|
data-cy="saveManaBtn"
|
||||||
|
@ -116,8 +135,3 @@ defineExpose({ save });
|
||||||
min-width: 230px;
|
min-width: 230px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<i18n>
|
|
||||||
es:
|
|
||||||
New price: Nuevo precio
|
|
||||||
</i18n>
|
|
||||||
|
|
|
@ -38,7 +38,9 @@ function handleDelete(row) {
|
||||||
ticketNotesCrudRef.value.remove([row]);
|
ticketNotesCrudRef.value.remove([row]);
|
||||||
}
|
}
|
||||||
|
|
||||||
async function handleSave() {
|
async function handleSave(e) {
|
||||||
|
if (e.shiftKey && e.key === 'Enter') return;
|
||||||
|
e.preventDefault();
|
||||||
if (!isSaving.value) {
|
if (!isSaving.value) {
|
||||||
isSaving.value = true;
|
isSaving.value = true;
|
||||||
await ticketNotesCrudRef.value?.saveChanges();
|
await ticketNotesCrudRef.value?.saveChanges();
|
||||||
|
@ -70,7 +72,7 @@ async function handleSave() {
|
||||||
<div
|
<div
|
||||||
v-for="(row, index) in rows"
|
v-for="(row, index) in rows"
|
||||||
:key="index"
|
:key="index"
|
||||||
class="q-mb-md row items-center q-gutter-x-md"
|
class="q-mb-md row q-gutter-x-md"
|
||||||
>
|
>
|
||||||
<VnSelect
|
<VnSelect
|
||||||
:label="t('ticketNotes.observationType')"
|
:label="t('ticketNotes.observationType')"
|
||||||
|
@ -86,7 +88,8 @@ async function handleSave() {
|
||||||
:label="t('basicData.description')"
|
:label="t('basicData.description')"
|
||||||
v-model="row.description"
|
v-model="row.description"
|
||||||
class="col"
|
class="col"
|
||||||
@keyup.enter="handleSave"
|
@keydown.enter.stop="handleSave"
|
||||||
|
autogrow
|
||||||
data-cy="ticketNotesDescription"
|
data-cy="ticketNotesDescription"
|
||||||
/>
|
/>
|
||||||
<QIcon
|
<QIcon
|
||||||
|
|
|
@ -45,7 +45,7 @@ const isTicketEditable = ref(false);
|
||||||
const sales = ref([]);
|
const sales = ref([]);
|
||||||
const editableStatesOptions = ref([]);
|
const editableStatesOptions = ref([]);
|
||||||
const selectedSales = ref([]);
|
const selectedSales = ref([]);
|
||||||
const manaCode = ref('mana');
|
const componentId = ref(null);
|
||||||
const ticketState = computed(() => store.data?.ticketState?.state?.code);
|
const ticketState = computed(() => store.data?.ticketState?.state?.code);
|
||||||
const transfer = ref({
|
const transfer = ref({
|
||||||
lastActiveTickets: [],
|
lastActiveTickets: [],
|
||||||
|
@ -187,7 +187,7 @@ const getRowUpdateInputEvents = (sale) => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const resetChanges = async () => {
|
const resetChanges = async () => {
|
||||||
arrayData.fetch({ append: false });
|
await arrayData.fetch({ append: false });
|
||||||
tableRef.value.CrudModelRef.hasChanges = false;
|
tableRef.value.CrudModelRef.hasChanges = false;
|
||||||
await tableRef.value.reload();
|
await tableRef.value.reload();
|
||||||
|
|
||||||
|
@ -308,14 +308,15 @@ const changePrice = async (sale) => {
|
||||||
if (newPrice != null && newPrice != sale.price) {
|
if (newPrice != null && newPrice != sale.price) {
|
||||||
if (await isSalePrepared(sale)) {
|
if (await isSalePrepared(sale)) {
|
||||||
await confirmUpdate(() => updatePrice(sale, newPrice));
|
await confirmUpdate(() => updatePrice(sale, newPrice));
|
||||||
} else updatePrice(sale, newPrice);
|
} else await updatePrice(sale, newPrice);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const updatePrice = async (sale, newPrice) => {
|
const updatePrice = async (sale, newPrice) => {
|
||||||
try {
|
try {
|
||||||
await axios.post(`Sales/${sale.id}/updatePrice`, { newPrice });
|
await axios.post(`Sales/${sale.id}/updatePrice`, {
|
||||||
sale.price = newPrice;
|
newPrice: newPrice,
|
||||||
edit.value = { ...DEFAULT_EDIT };
|
componentId: componentId.value,
|
||||||
|
});
|
||||||
notify('globals.dataSaved', 'positive');
|
notify('globals.dataSaved', 'positive');
|
||||||
resetChanges();
|
resetChanges();
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
@ -327,28 +328,31 @@ const changeDiscount = async (sale) => {
|
||||||
const newDiscount = edit.value.discount;
|
const newDiscount = edit.value.discount;
|
||||||
if (newDiscount != null && newDiscount != sale.discount) {
|
if (newDiscount != null && newDiscount != sale.discount) {
|
||||||
if (await isSalePrepared(sale))
|
if (await isSalePrepared(sale))
|
||||||
await confirmUpdate(() => updateDiscount([sale], newDiscount));
|
await confirmUpdate(() =>
|
||||||
else await updateDiscount([sale], newDiscount);
|
updateDiscount([sale], newDiscount, componentId.value),
|
||||||
|
);
|
||||||
|
else await updateDiscount([sale], newDiscount, componentId.value);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const updateDiscounts = async (sales, newDiscount) => {
|
const updateDiscounts = async (sales, newDiscount, componentId) => {
|
||||||
const salesTracking = await fetchSalesTracking();
|
const salesTracking = await fetchSalesTracking();
|
||||||
|
|
||||||
const someSaleIsPrepared = salesTracking.some((sale) =>
|
const someSaleIsPrepared = salesTracking.some((sale) =>
|
||||||
matchSale(salesTracking, sale),
|
matchSale(salesTracking, sale),
|
||||||
);
|
);
|
||||||
if (someSaleIsPrepared) await confirmUpdate(() => updateDiscount(sales, newDiscount));
|
if (someSaleIsPrepared)
|
||||||
else updateDiscount(sales, newDiscount);
|
await confirmUpdate(() => updateDiscount(sales, newDiscount, componentId));
|
||||||
|
else updateDiscount(sales, newDiscount, componentId);
|
||||||
};
|
};
|
||||||
|
|
||||||
const updateDiscount = async (sales, newDiscount = 0) => {
|
const updateDiscount = async (sales, newDiscount, componentId) => {
|
||||||
try {
|
try {
|
||||||
const salesIds = sales.map(({ id }) => id);
|
const salesIds = sales.map(({ id }) => id);
|
||||||
const params = {
|
const params = {
|
||||||
salesIds,
|
salesIds,
|
||||||
newDiscount,
|
newDiscount: newDiscount ?? 0,
|
||||||
manaCode: manaCode.value,
|
componentId,
|
||||||
};
|
};
|
||||||
await axios.post(`Tickets/${route.params.id}/updateDiscount`, params);
|
await axios.post(`Tickets/${route.params.id}/updateDiscount`, params);
|
||||||
notify('globals.dataSaved', 'positive');
|
notify('globals.dataSaved', 'positive');
|
||||||
|
@ -821,10 +825,11 @@ watch(
|
||||||
ref="editPriceProxyRef"
|
ref="editPriceProxyRef"
|
||||||
:sale="row"
|
:sale="row"
|
||||||
:new-price="getNewPrice"
|
:new-price="getNewPrice"
|
||||||
|
v-model:component-id="componentId"
|
||||||
@save="changePrice"
|
@save="changePrice"
|
||||||
>
|
>
|
||||||
<VnInput
|
<VnInput
|
||||||
@keyup.enter.stop="() => editManaProxyRef.save(row)"
|
@keyup.enter.stop="() => editPriceProxyRef.save(row)"
|
||||||
v-model.number="edit.price"
|
v-model.number="edit.price"
|
||||||
:label="t('basicData.price')"
|
:label="t('basicData.price')"
|
||||||
type="number"
|
type="number"
|
||||||
|
@ -843,7 +848,7 @@ watch(
|
||||||
ref="editManaProxyRef"
|
ref="editManaProxyRef"
|
||||||
:sale="row"
|
:sale="row"
|
||||||
:new-price="getNewPrice"
|
:new-price="getNewPrice"
|
||||||
:mana-code="manaCode"
|
v-model:component-id="componentId"
|
||||||
@save="changeDiscount"
|
@save="changeDiscount"
|
||||||
>
|
>
|
||||||
<VnInput
|
<VnInput
|
||||||
|
|
|
@ -47,6 +47,7 @@ const { notify } = useNotify();
|
||||||
const acl = useAcl();
|
const acl = useAcl();
|
||||||
const btnDropdownRef = ref(null);
|
const btnDropdownRef = ref(null);
|
||||||
const editManaProxyRef = ref(null);
|
const editManaProxyRef = ref(null);
|
||||||
|
const componentId = ref(null);
|
||||||
const { openConfirmationModal } = useVnConfirm();
|
const { openConfirmationModal } = useVnConfirm();
|
||||||
|
|
||||||
const newDiscount = ref(null);
|
const newDiscount = ref(null);
|
||||||
|
@ -112,7 +113,7 @@ const changeMultipleDiscount = () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
if (newDiscount.value != null && hasChanges)
|
if (newDiscount.value != null && hasChanges)
|
||||||
emit('updateDiscounts', props.sales, newDiscount.value);
|
emit('updateDiscounts', props.sales, newDiscount.value, componentId.value);
|
||||||
btnDropdownRef.value.hide();
|
btnDropdownRef.value.hide();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -206,6 +207,7 @@ const createRefund = async (withWarehouse) => {
|
||||||
ref="editManaProxyRef"
|
ref="editManaProxyRef"
|
||||||
:sale="row"
|
:sale="row"
|
||||||
@save="changeMultipleDiscount"
|
@save="changeMultipleDiscount"
|
||||||
|
v-model:component-id="componentId"
|
||||||
>
|
>
|
||||||
<VnInput
|
<VnInput
|
||||||
autofocus
|
autofocus
|
||||||
|
|
|
@ -241,6 +241,7 @@ onMounted(async () => {
|
||||||
:value="`${entity.address?.nickname} #${entity.address?.id}`"
|
:value="`${entity.address?.nickname} #${entity.address?.id}`"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
|
class="white-space-normal"
|
||||||
:label="t('ticket.summary.consigneeStreet')"
|
:label="t('ticket.summary.consigneeStreet')"
|
||||||
:value="formattedAddress"
|
:value="formattedAddress"
|
||||||
/>
|
/>
|
||||||
|
@ -524,4 +525,7 @@ onMounted(async () => {
|
||||||
.grafana {
|
.grafana {
|
||||||
color: $primary-light;
|
color: $primary-light;
|
||||||
}
|
}
|
||||||
|
.white-space-normal :deep(.value span) {
|
||||||
|
white-space: normal;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -42,7 +42,11 @@ const groupedStates = ref([]);
|
||||||
auto-load
|
auto-load
|
||||||
/>
|
/>
|
||||||
<FetchData url="Warehouses" @on-fetch="(data) => (warehouses = data)" auto-load />
|
<FetchData url="Warehouses" @on-fetch="(data) => (warehouses = data)" auto-load />
|
||||||
<VnFilterPanel :data-key="props.dataKey" :search-button="true">
|
<VnFilterPanel
|
||||||
|
:data-key="props.dataKey"
|
||||||
|
:search-button="true"
|
||||||
|
:unremovableParams="['from', 'to']"
|
||||||
|
>
|
||||||
<template #tags="{ tag, formatFn }">
|
<template #tags="{ tag, formatFn }">
|
||||||
<div class="q-gutter-x-xs">
|
<div class="q-gutter-x-xs">
|
||||||
<strong>{{ t(`params.${tag.label}`) }}: </strong>
|
<strong>{{ t(`params.${tag.label}`) }}: </strong>
|
||||||
|
@ -273,6 +277,7 @@ en:
|
||||||
orderFk: Order
|
orderFk: Order
|
||||||
from: From
|
from: From
|
||||||
shipped: Shipped
|
shipped: Shipped
|
||||||
|
shippedDate: Shipped date
|
||||||
to: To
|
to: To
|
||||||
stateFk: State
|
stateFk: State
|
||||||
groupedStates: Grouped State
|
groupedStates: Grouped State
|
||||||
|
@ -300,6 +305,7 @@ es:
|
||||||
orderFk: Pedido
|
orderFk: Pedido
|
||||||
from: Desde
|
from: Desde
|
||||||
shipped: F. envío
|
shipped: F. envío
|
||||||
|
shippedDate: F. envío
|
||||||
to: Hasta
|
to: Hasta
|
||||||
stateFk: Estado
|
stateFk: Estado
|
||||||
groupedStates: Estado agrupado
|
groupedStates: Estado agrupado
|
||||||
|
|
|
@ -113,13 +113,13 @@ const columns = computed(() => [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
align: 'left',
|
align: 'left',
|
||||||
name: 'shippedDate',
|
name: 'shipped',
|
||||||
cardVisible: true,
|
cardVisible: true,
|
||||||
label: t('ticketList.shipped'),
|
label: t('ticketList.shipped'),
|
||||||
columnFilter: {
|
columnFilter: {
|
||||||
component: 'date',
|
component: 'date',
|
||||||
},
|
},
|
||||||
format: ({ shippedDate }) => toDate(shippedDate),
|
format: ({ shipped }) => toDate(shipped),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
align: 'left',
|
align: 'left',
|
||||||
|
@ -477,7 +477,7 @@ function setReference(data) {
|
||||||
prefix="card"
|
prefix="card"
|
||||||
:array-data-props="{
|
:array-data-props="{
|
||||||
url: 'Tickets/filter',
|
url: 'Tickets/filter',
|
||||||
order: ['shippedDate DESC', 'shippedHour ASC', 'zoneLanding ASC', 'id'],
|
order: ['shipped DESC', 'shippedHour ASC', 'zoneLanding ASC', 'id'],
|
||||||
exprBuilder,
|
exprBuilder,
|
||||||
}"
|
}"
|
||||||
>
|
>
|
||||||
|
@ -515,10 +515,10 @@ function setReference(data) {
|
||||||
<DepartmentDescriptorProxy :id="row.departmentFk" />
|
<DepartmentDescriptorProxy :id="row.departmentFk" />
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
<template #column-shippedDate="{ row }">
|
<template #column-shipped="{ row }">
|
||||||
<span v-if="getDateColor(row.shipped)">
|
<span v-if="getDateColor(row.shipped)">
|
||||||
<QChip :class="getDateColor(row.shipped)" dense square>
|
<QChip :class="getDateColor(row.shipped)" dense square>
|
||||||
{{ toDate(row.shippedDate) }}
|
{{ toDate(row.shipped) }}
|
||||||
</QChip>
|
</QChip>
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -68,7 +68,7 @@ const arrayData = useArrayData('ZoneEvents');
|
||||||
const exclusionGeoCreate = async () => {
|
const exclusionGeoCreate = async () => {
|
||||||
const params = {
|
const params = {
|
||||||
zoneFk: parseInt(route.params.id),
|
zoneFk: parseInt(route.params.id),
|
||||||
date: dated,
|
date: dated.value,
|
||||||
geoIds: tickedNodes.value,
|
geoIds: tickedNodes.value,
|
||||||
};
|
};
|
||||||
await axios.post('Zones/exclusionGeo', params);
|
await axios.post('Zones/exclusionGeo', params);
|
||||||
|
@ -101,9 +101,17 @@ const exclusionCreate = async () => {
|
||||||
const existsEvent = data.events.find(
|
const existsEvent = data.events.find(
|
||||||
(event) => toDateFormat(event.dated) === toDateFormat(dated.value),
|
(event) => toDateFormat(event.dated) === toDateFormat(dated.value),
|
||||||
);
|
);
|
||||||
|
const existsGeoEvent = data.geoExclusions.find(
|
||||||
|
(event) => toDateFormat(event.dated) === toDateFormat(dated.value),
|
||||||
|
);
|
||||||
if (existsEvent) {
|
if (existsEvent) {
|
||||||
await axios.delete(`Zones/${existsEvent?.zoneFk}/events/${existsEvent?.id}`);
|
await axios.delete(`Zones/${existsEvent?.zoneFk}/events/${existsEvent?.id}`);
|
||||||
}
|
}
|
||||||
|
if (existsGeoEvent) {
|
||||||
|
await axios.delete(
|
||||||
|
`Zones/${existsGeoEvent?.zoneFk}/exclusions/${existsGeoEvent?.zoneExclusionFk}`,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
if (isNew.value || props.event?.type) await axios.post(`${url}`, [body]);
|
if (isNew.value || props.event?.type) await axios.post(`${url}`, [body]);
|
||||||
else await axios.put(`${url}/${props.event?.id}`, body);
|
else await axios.put(`${url}/${props.event?.id}`, body);
|
||||||
|
|
|
@ -107,14 +107,27 @@ const createEvent = async () => {
|
||||||
`Zones/${existsExclusion?.zoneFk}/exclusions/${existsExclusion?.id}`,
|
`Zones/${existsExclusion?.zoneFk}/exclusions/${existsExclusion?.id}`,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
const {
|
||||||
|
dated: formDated,
|
||||||
|
started,
|
||||||
|
ended,
|
||||||
|
type,
|
||||||
|
weekDays,
|
||||||
|
wdays,
|
||||||
|
} = eventInclusionFormData.value;
|
||||||
|
|
||||||
if (isNew.value)
|
const payload = {
|
||||||
await axios.post(`Zones/${id}/events`, eventInclusionFormData.value);
|
dated: formDated,
|
||||||
else
|
started,
|
||||||
await axios.put(
|
ended,
|
||||||
`Zones/${id}/events/${props.event?.id}`,
|
type,
|
||||||
eventInclusionFormData.value,
|
weekDays,
|
||||||
);
|
wdays,
|
||||||
|
};
|
||||||
|
|
||||||
|
if (isNew.value || props.eventType === 'exclusion')
|
||||||
|
await axios.post(`Zones/${id}/events`, payload);
|
||||||
|
else await axios.put(`Zones/${id}/events/${props.event?.id}`, payload);
|
||||||
}
|
}
|
||||||
quasar.notify({
|
quasar.notify({
|
||||||
message: t('globals.dataSaved'),
|
message: t('globals.dataSaved'),
|
||||||
|
|
|
@ -113,7 +113,7 @@ const ticketCard = {
|
||||||
name: 'TicketExpedition',
|
name: 'TicketExpedition',
|
||||||
meta: {
|
meta: {
|
||||||
title: 'expedition',
|
title: 'expedition',
|
||||||
icon: 'vn:package',
|
icon: 'view_in_ar',
|
||||||
},
|
},
|
||||||
component: () => import('src/pages/Ticket/Card/TicketExpedition.vue'),
|
component: () => import('src/pages/Ticket/Card/TicketExpedition.vue'),
|
||||||
},
|
},
|
||||||
|
@ -168,7 +168,7 @@ const ticketCard = {
|
||||||
name: 'TicketBoxing',
|
name: 'TicketBoxing',
|
||||||
meta: {
|
meta: {
|
||||||
title: 'boxing',
|
title: 'boxing',
|
||||||
icon: 'view_in_ar',
|
icon: 'videocam',
|
||||||
},
|
},
|
||||||
component: () => import('src/pages/Ticket/Card/TicketBoxing.vue'),
|
component: () => import('src/pages/Ticket/Card/TicketBoxing.vue'),
|
||||||
},
|
},
|
||||||
|
|
|
@ -6,7 +6,6 @@ describe.skip('ClaimAction', () => {
|
||||||
const destinationRow = '.q-item__section > .q-field';
|
const destinationRow = '.q-item__section > .q-field';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/claim/${claimId}/action`);
|
cy.visit(`/#/claim/${claimId}/action`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -7,7 +7,6 @@ describe.skip('ClaimDevelopment', () => {
|
||||||
const newReason = 'Calor';
|
const newReason = 'Calor';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/claim/${claimId}/development`);
|
cy.visit(`/#/claim/${claimId}/development`);
|
||||||
cy.waitForElement('tbody');
|
cy.waitForElement('tbody');
|
||||||
|
|
|
@ -2,7 +2,6 @@ import '../commands.js';
|
||||||
|
|
||||||
describe('EntryBasicData', () => {
|
describe('EntryBasicData', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/list`);
|
cy.visit(`/#/entry/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import '../commands.js';
|
import '../commands.js';
|
||||||
describe('EntryDescriptor', () => {
|
describe('EntryDescriptor', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/list`);
|
cy.visit(`/#/entry/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import '../commands.js';
|
import '../commands.js';
|
||||||
describe('EntryDms', () => {
|
describe('EntryDms', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/list`);
|
cy.visit(`/#/entry/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import '../commands.js';
|
import '../commands.js';
|
||||||
describe('EntryLock', () => {
|
describe('EntryLock', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/list`);
|
cy.visit(`/#/entry/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -2,7 +2,6 @@ import '../commands.js';
|
||||||
|
|
||||||
describe('EntryNotes', () => {
|
describe('EntryNotes', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/list`);
|
cy.visit(`/#/entry/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -2,7 +2,6 @@ import './commands';
|
||||||
|
|
||||||
describe('EntryList', () => {
|
describe('EntryList', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/list`);
|
cy.visit(`/#/entry/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
describe('EntryStockBought', () => {
|
describe('EntryStockBought', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyer');
|
cy.login('buyer');
|
||||||
cy.visit(`/#/entry/stock-Bought`);
|
cy.visit(`/#/entry/stock-Bought`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
describe('EntrySupplier when is supplier', () => {
|
describe('EntrySupplier when is supplier', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('supplier');
|
cy.login('supplier');
|
||||||
cy.visit(`/#/entry/my`, {
|
cy.visit(`/#/entry/my`, {
|
||||||
onBeforeLoad(win) {
|
onBeforeLoad(win) {
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import './commands';
|
import './commands';
|
||||||
describe('EntryDms', () => {
|
describe('EntryDms', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('buyerBoss');
|
cy.login('buyerBoss');
|
||||||
cy.visit(`/#/entry/waste-recalc`);
|
cy.visit(`/#/entry/waste-recalc`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -28,7 +28,7 @@ describe('InvoiceOut list', () => {
|
||||||
cy.dataCy('InvoiceOutDownloadPdfBtn').click();
|
cy.dataCy('InvoiceOutDownloadPdfBtn').click();
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should open the invoice descriptor from table icon', () => {
|
it.skip('should open the invoice descriptor from table icon', () => {
|
||||||
cy.get(firstSummaryIcon).click();
|
cy.get(firstSummaryIcon).click();
|
||||||
cy.get('.cardSummary').should('be.visible');
|
cy.get('.cardSummary').should('be.visible');
|
||||||
cy.get('.summaryHeader > div').should('include.text', 'A1111111');
|
cy.get('.summaryHeader > div').should('include.text', 'A1111111');
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe.skip('InvoiceOut manual invoice', () => {
|
describe.skip('InvoiceOut manual invoice', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/ticket/list`);
|
cy.visit(`/#/ticket/list`);
|
||||||
cy.get('#searchbar input').type('{enter}');
|
cy.get('#searchbar input').type('{enter}');
|
||||||
|
|
|
@ -4,7 +4,6 @@ describe('InvoiceOut negative bases', () => {
|
||||||
`:nth-child(1) > [data-col-field="${opt}"] > .no-padding > .link`;
|
`:nth-child(1) > [data-col-field="${opt}"] > .no-padding > .link`;
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/invoice-out/negative-bases`);
|
cy.visit(`/#/invoice-out/negative-bases`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -15,7 +15,7 @@ describe('InvoiceOut summary', () => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/invoice-out/1/summary`);
|
cy.visit(`/#/invoice-out/1/summary`);
|
||||||
});
|
});
|
||||||
it('open the descriptors', () => {
|
it.skip('open the descriptors', () => {
|
||||||
cy.get(firstRowDescriptors(1)).click();
|
cy.get(firstRowDescriptors(1)).click();
|
||||||
cy.get('.descriptor').should('be.visible');
|
cy.get('.descriptor').should('be.visible');
|
||||||
cy.get('.q-item > .q-item__label').should('include.text', '1');
|
cy.get('.q-item > .q-item__label').should('include.text', '1');
|
||||||
|
@ -30,7 +30,7 @@ describe('InvoiceOut summary', () => {
|
||||||
cy.get('.q-item > .q-item__label').should('include.text', '1101');
|
cy.get('.q-item > .q-item__label').should('include.text', '1101');
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should open the ticket list', () => {
|
it.skip('should open the ticket list', () => {
|
||||||
cy.get(toTicketList).click();
|
cy.get(toTicketList).click();
|
||||||
cy.get('[data-col-field="stateFk"]').each(($el) => {
|
cy.get('[data-col-field="stateFk"]').each(($el) => {
|
||||||
cy.wrap($el).contains('T1111111');
|
cy.wrap($el).contains('T1111111');
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('InvoiceOut global invoicing', () => {
|
describe('InvoiceOut global invoicing', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('administrative');
|
cy.login('administrative');
|
||||||
cy.visit(`/#/invoice-out/global-invoicing`);
|
cy.visit(`/#/invoice-out/global-invoicing`);
|
||||||
});
|
});
|
||||||
|
@ -17,7 +16,7 @@ describe('InvoiceOut global invoicing', () => {
|
||||||
cy.dataCy('InvoiceOutGlobalPrinterSelect').type('printer1');
|
cy.dataCy('InvoiceOutGlobalPrinterSelect').type('printer1');
|
||||||
cy.get('.q-menu .q-item').contains('printer1').click();
|
cy.get('.q-menu .q-item').contains('printer1').click();
|
||||||
cy.get(
|
cy.get(
|
||||||
'[label="Invoice date"] > .q-field > .q-field__inner > .q-field__control'
|
'[label="Invoice date"] > .q-field > .q-field__inner > .q-field__control',
|
||||||
).click();
|
).click();
|
||||||
cy.get(':nth-child(5) > div > .q-btn > .q-btn__content > .block').click();
|
cy.get(':nth-child(5) > div > .q-btn > .q-btn__content > .block').click();
|
||||||
cy.get('.q-date__years-content > :nth-child(2) > .q-btn').click();
|
cy.get('.q-date__years-content > :nth-child(2) > .q-btn').click();
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('ItemBarcodes', () => {
|
describe('ItemBarcodes', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/1/barcode`);
|
cy.visit(`/#/item/1/barcode`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('Item botanical', () => {
|
describe('Item botanical', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/1/botanical`);
|
cy.visit(`/#/item/1/botanical`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
describe.skip('Item list', () => {
|
describe.skip('Item list', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/list`);
|
cy.visit(`/#/item/list`);
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('Item summary', () => {
|
describe('Item summary', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/1/summary`);
|
cy.visit(`/#/item/1/summary`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
describe('Item tag', () => {
|
describe('Item tag', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/1/tags`);
|
cy.visit(`/#/item/1/tags`);
|
||||||
cy.get('.q-page').should('be.visible');
|
cy.get('.q-page').should('be.visible');
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('Item tax', () => {
|
describe('Item tax', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/1/tax`);
|
cy.visit(`/#/item/1/tax`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -6,7 +6,6 @@ describe('Item type', () => {
|
||||||
const type = 'Flower';
|
const type = 'Flower';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/item/item-type`);
|
cy.visit(`/#/item/item-type`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -6,7 +6,6 @@ describe('OrderList', () => {
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/order/list');
|
cy.visit('/#/order/list');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,6 @@ describe('Agency modes', () => {
|
||||||
const name = 'inhouse pickup';
|
const name = 'inhouse pickup';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/agency/1/modes`);
|
cy.visit(`/#/route/agency/1/modes`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -13,7 +13,6 @@ describe('AgencyWorkCenter', () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/agency/11/workCenter`);
|
cy.visit(`/#/route/agency/11/workCenter`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -24,7 +24,6 @@ describe('Cmr list', { testIsolation: true }, () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit('/#/route/cmr');
|
cy.visit('/#/route/cmr');
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
|
|
|
@ -27,7 +27,6 @@ describe('RoadMap', () => {
|
||||||
const summaryUrl = '/summary';
|
const summaryUrl = '/summary';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/roadmap`);
|
cy.visit(`/#/route/roadmap`);
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
|
|
|
@ -32,7 +32,6 @@ describe.skip('RouteAutonomous', () => {
|
||||||
const dataSaved = 'Data saved';
|
const dataSaved = 'Data saved';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/agency-term`);
|
cy.visit(`/#/route/agency-term`);
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
|
|
|
@ -75,7 +75,6 @@ describe.skip('Route extended list', () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(url);
|
cy.visit(url);
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
|
|
|
@ -26,8 +26,8 @@ describe('Route', () => {
|
||||||
const summaryUrl = '/summary';
|
const summaryUrl = '/summary';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
|
cy.viewport(1920, 1080);
|
||||||
cy.visit(`/#/route/list`);
|
cy.visit(`/#/route/list`);
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
describe('Vehicle', () => {
|
describe('Vehicle', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('deliveryAssistant');
|
cy.login('deliveryAssistant');
|
||||||
cy.visit(`/#/route/vehicle/7/summary`);
|
cy.visit(`/#/route/vehicle/7/summary`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -21,7 +21,6 @@ describe('Vehicle list', () => {
|
||||||
const summaryUrl = '/summary';
|
const summaryUrl = '/summary';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/vehicle/list`);
|
cy.visit(`/#/route/vehicle/list`);
|
||||||
cy.typeSearchbar('{enter}');
|
cy.typeSearchbar('{enter}');
|
||||||
|
|
|
@ -10,7 +10,6 @@ describe('Vehicle Notes', () => {
|
||||||
const newNoteText = 'probando';
|
const newNoteText = 'probando';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/route/vehicle/1/notes`);
|
cy.visit(`/#/route/vehicle/1/notes`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -5,7 +5,6 @@ describe('ParkingList', () => {
|
||||||
const summaryHeader = '.header-link';
|
const summaryHeader = '.header-link';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/shelving/parking/list`);
|
cy.visit(`/#/shelving/parking/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -3,7 +3,6 @@ describe('ShelvingList', () => {
|
||||||
const parking =
|
const parking =
|
||||||
'.q-card > :nth-child(1) > .q-select > .q-field__inner > .q-field__control > .q-field__control-container';
|
'.q-card > :nth-child(1) > .q-select > .q-field__inner > .q-field__control > .q-field__control-container';
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/shelving/1/basic-data`);
|
cy.visit(`/#/shelving/1/basic-data`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('ShelvingList', () => {
|
describe('ShelvingList', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/shelving/list`);
|
cy.visit(`/#/shelving/list`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
describe('Supplier Balance', () => {
|
describe('Supplier Balance', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/supplier/1/balance`);
|
cy.visit(`/#/supplier/1/balance`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -9,7 +9,6 @@ describe('Ticket descriptor', () => {
|
||||||
const weightValue = '[data-cy="vnLvWeight"]';
|
const weightValue = '[data-cy="vnLvWeight"]';
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should clone the ticket without warehouse', () => {
|
it('should clone the ticket without warehouse', () => {
|
||||||
|
|
|
@ -5,7 +5,6 @@ describe('Ticket expedtion', () => {
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should change the state', () => {
|
it('should change the state', () => {
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
describe('TicketFilter', () => {
|
describe('TicketFilter', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/list');
|
cy.visit('/#/ticket/list');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
describe('TicketList', () => {
|
describe('TicketList', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/list', false);
|
cy.visit('/#/ticket/list', false);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
describe('TicketNotes', () => {
|
describe('TicketNotes', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/31/observation');
|
cy.visit('/#/ticket/31/observation');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
describe('TicketRequest', () => {
|
describe('TicketRequest', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/31/request');
|
cy.visit('/#/ticket/31/request');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -2,9 +2,9 @@
|
||||||
const firstRow = 'tbody > :nth-child(1)';
|
const firstRow = 'tbody > :nth-child(1)';
|
||||||
|
|
||||||
describe('TicketSale', () => {
|
describe('TicketSale', () => {
|
||||||
describe('#23', () => {
|
describe.skip('Ticket #23', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('salesBoss');
|
cy.login('claimManager');
|
||||||
cy.viewport(1920, 1080);
|
cy.viewport(1920, 1080);
|
||||||
cy.visit('/#/ticket/23/sale');
|
cy.visit('/#/ticket/23/sale');
|
||||||
});
|
});
|
||||||
|
@ -15,6 +15,8 @@ describe('TicketSale', () => {
|
||||||
cy.get('[data-col-field="price"]').find('.q-btn').click();
|
cy.get('[data-col-field="price"]').find('.q-btn').click();
|
||||||
cy.waitForElement('[data-cy="ticketEditManaProxy"]');
|
cy.waitForElement('[data-cy="ticketEditManaProxy"]');
|
||||||
cy.dataCy('ticketEditManaProxy').should('exist');
|
cy.dataCy('ticketEditManaProxy').should('exist');
|
||||||
|
cy.get('[data-cy="componentOption-37"]').click();
|
||||||
|
|
||||||
cy.waitForElement('[data-cy="Price_input"]');
|
cy.waitForElement('[data-cy="Price_input"]');
|
||||||
cy.dataCy('Price_input').clear().type(price);
|
cy.dataCy('Price_input').clear().type(price);
|
||||||
cy.intercept('POST', /\/api\/Sales\/\d+\/updatePrice/).as('updatePrice');
|
cy.intercept('POST', /\/api\/Sales\/\d+\/updatePrice/).as('updatePrice');
|
||||||
|
@ -33,6 +35,7 @@ describe('TicketSale', () => {
|
||||||
cy.get('[data-col-field="discount"]').find('.q-btn').click();
|
cy.get('[data-col-field="discount"]').find('.q-btn').click();
|
||||||
cy.waitForElement('[data-cy="ticketEditManaProxy"]');
|
cy.waitForElement('[data-cy="ticketEditManaProxy"]');
|
||||||
cy.dataCy('ticketEditManaProxy').should('exist');
|
cy.dataCy('ticketEditManaProxy').should('exist');
|
||||||
|
cy.get('[data-cy="componentOption-37"]').click();
|
||||||
cy.waitForElement('[data-cy="Disc_input"]');
|
cy.waitForElement('[data-cy="Disc_input"]');
|
||||||
cy.dataCy('Disc_input').clear().type(discount);
|
cy.dataCy('Disc_input').clear().type(discount);
|
||||||
cy.intercept('POST', /\/api\/Tickets\/\d+\/updateDiscount/).as(
|
cy.intercept('POST', /\/api\/Tickets\/\d+\/updateDiscount/).as(
|
||||||
|
@ -83,8 +86,7 @@ describe('TicketSale', () => {
|
||||||
});
|
});
|
||||||
describe('#24 add claim', () => {
|
describe('#24 add claim', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('salesPerson');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/24/sale');
|
cy.visit('/#/ticket/24/sale');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -102,8 +104,7 @@ describe('TicketSale', () => {
|
||||||
});
|
});
|
||||||
describe('#31 free ticket', () => {
|
describe('#31 free ticket', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('claimManager');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/31/sale');
|
cy.visit('/#/ticket/31/sale');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -139,14 +140,15 @@ describe('TicketSale', () => {
|
||||||
cy.dataCy('ticketSaleMoreActionsDropdown').should('be.disabled');
|
cy.dataCy('ticketSaleMoreActionsDropdown').should('be.disabled');
|
||||||
});
|
});
|
||||||
|
|
||||||
it.only('should update discount when "Update discount" is clicked', () => {
|
it('should update discount when "Update discount" is clicked', () => {
|
||||||
const discount = Number((Math.random() * 99 + 1).toFixed(2));
|
const discount = Number((Math.random() * 99 + 1).toFixed(2));
|
||||||
|
|
||||||
selectFirstRow();
|
selectFirstRow();
|
||||||
cy.dataCy('ticketSaleMoreActionsDropdown').click();
|
cy.dataCy('ticketSaleMoreActionsDropdown').click();
|
||||||
cy.waitForElement('[data-cy="updateDiscountItem"]');
|
cy.waitForElement('[data-cy="updateDiscountItem"]');
|
||||||
cy.dataCy('updateDiscountItem').should('exist');
|
|
||||||
cy.dataCy('updateDiscountItem').click();
|
cy.dataCy('updateDiscountItem').click();
|
||||||
|
cy.waitForElement('[data-cy="componentOption-37"]');
|
||||||
|
cy.get('[data-cy="componentOption-37"]').click();
|
||||||
cy.waitForElement('[data-cy="ticketSaleDiscountInput"]');
|
cy.waitForElement('[data-cy="ticketSaleDiscountInput"]');
|
||||||
cy.dataCy('ticketSaleDiscountInput').find('input').focus();
|
cy.dataCy('ticketSaleDiscountInput').find('input').focus();
|
||||||
cy.intercept('POST', /\/api\/Tickets\/\d+\/updateDiscount/).as(
|
cy.intercept('POST', /\/api\/Tickets\/\d+\/updateDiscount/).as(
|
||||||
|
@ -191,8 +193,7 @@ describe('TicketSale', () => {
|
||||||
});
|
});
|
||||||
describe('#32 transfer', () => {
|
describe('#32 transfer', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('salesPerson');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit('/#/ticket/32/sale');
|
cy.visit('/#/ticket/32/sale');
|
||||||
});
|
});
|
||||||
it('transfer sale to a new ticket', () => {
|
it('transfer sale to a new ticket', () => {
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
describe('VnBreadcrumbs', () => {
|
describe('VnBreadcrumbs', () => {
|
||||||
const lastBreadcrumb = '.q-breadcrumbs--last > .q-breadcrumbs__el';
|
const lastBreadcrumb = '.q-breadcrumbs--last > .q-breadcrumbs__el';
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit('/');
|
cy.visit('/');
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
describe('WagonTypeCreate', () => {
|
describe('WagonTypeCreate', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit('/#/wagon/type/list');
|
cy.visit('/#/wagon/type/list');
|
||||||
cy.waitForElement('.q-page', 6000);
|
cy.waitForElement('.q-page', 6000);
|
||||||
|
|
|
@ -2,7 +2,6 @@ describe('WagonTypeEdit', () => {
|
||||||
const trayColorRow =
|
const trayColorRow =
|
||||||
'.q-select > .q-field__inner > .q-field__control > .q-field__control-container';
|
'.q-select > .q-field__inner > .q-field__control > .q-field__control-container';
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit('/#/wagon/type/1/edit');
|
cy.visit('/#/wagon/type/1/edit');
|
||||||
});
|
});
|
||||||
|
|
|
@ -4,7 +4,6 @@ describe('WorkerPit', () => {
|
||||||
const savePIT = '#st-actions > .q-btn-group > .q-btn--standard';
|
const savePIT = '#st-actions > .q-btn-group > .q-btn--standard';
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.visit(`/#/worker/1107/pit`);
|
cy.visit(`/#/worker/1107/pit`);
|
||||||
});
|
});
|
||||||
|
|
|
@ -4,7 +4,6 @@ describe('ZoneDeliveryDays', () => {
|
||||||
const submitForm = '.q-form > .q-btn > .q-btn__content';
|
const submitForm = '.q-form > .q-btn > .q-btn__content';
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit(`/#/zone/delivery-days`);
|
cy.visit(`/#/zone/delivery-days`);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,6 @@ describe('ZoneUpcomingDeliveries', () => {
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.login('developer');
|
cy.login('developer');
|
||||||
cy.viewport(1920, 1080);
|
|
||||||
cy.visit(`/#/zone/upcoming-deliveries`);
|
cy.visit(`/#/zone/upcoming-deliveries`);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue