forked from verdnatura/salix-front
Merge branch 'dev' into 6280_vnLocation
This commit is contained in:
commit
b0083544f0
|
@ -37,6 +37,7 @@ const marker_labels = [
|
||||||
{ value: DEFAULT_MIN_RESPONSABILITY, label: t('claim.summary.company') },
|
{ value: DEFAULT_MIN_RESPONSABILITY, label: t('claim.summary.company') },
|
||||||
{ value: DEFAULT_MAX_RESPONSABILITY, label: t('claim.summary.person') },
|
{ value: DEFAULT_MAX_RESPONSABILITY, label: t('claim.summary.person') },
|
||||||
];
|
];
|
||||||
|
const multiplicatorValue = ref();
|
||||||
|
|
||||||
const columns = computed(() => [
|
const columns = computed(() => [
|
||||||
{
|
{
|
||||||
|
@ -134,17 +135,7 @@ async function regularizeClaim() {
|
||||||
message: t('globals.dataSaved'),
|
message: t('globals.dataSaved'),
|
||||||
type: 'positive',
|
type: 'positive',
|
||||||
});
|
});
|
||||||
if (claim.value.responsibility >= Math.ceil(DEFAULT_MAX_RESPONSABILITY) / 2) {
|
await onUpdateGreugeAccept();
|
||||||
quasar
|
|
||||||
.dialog({
|
|
||||||
component: VnConfirm,
|
|
||||||
componentProps: {
|
|
||||||
title: t('confirmGreuges'),
|
|
||||||
message: t('confirmGreugesMessage'),
|
|
||||||
},
|
|
||||||
})
|
|
||||||
.onOk(async () => await onUpdateGreugeAccept());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async function onUpdateGreugeAccept() {
|
async function onUpdateGreugeAccept() {
|
||||||
|
@ -153,9 +144,9 @@ async function onUpdateGreugeAccept() {
|
||||||
filter: { where: { code: 'freightPickUp' } },
|
filter: { where: { code: 'freightPickUp' } },
|
||||||
})
|
})
|
||||||
).data.id;
|
).data.id;
|
||||||
const freightPickUpPrice = (await axios.get(`GreugeConfigs/findOne`)).data
|
const freightPickUpPrice =
|
||||||
.freightPickUpPrice;
|
(await axios.get(`GreugeConfigs/findOne`)).data.freightPickUpPrice *
|
||||||
|
multiplicatorValue.value;
|
||||||
await axios.post(`Greuges`, {
|
await axios.post(`Greuges`, {
|
||||||
clientFk: claim.value.clientFk,
|
clientFk: claim.value.clientFk,
|
||||||
description: `${t('ClaimGreugeDescription')} ${claimId}`.toUpperCase(),
|
description: `${t('ClaimGreugeDescription')} ${claimId}`.toUpperCase(),
|
||||||
|
@ -226,10 +217,10 @@ async function importToNewRefundTicket() {
|
||||||
show-if-above
|
show-if-above
|
||||||
v-if="claim"
|
v-if="claim"
|
||||||
>
|
>
|
||||||
<QCard class="totalClaim vn-card q-my-md q-pa-sm">
|
<QCard class="totalClaim q-my-md q-pa-sm no-box-shadow">
|
||||||
{{ `${t('Total claimed')}: ${toCurrency(totalClaimed)}` }}
|
{{ `${t('Total claimed')}: ${toCurrency(totalClaimed)}` }}
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard class="vn-card q-mb-md q-pa-sm">
|
<QCard class="q-mb-md q-pa-sm no-box-shadow">
|
||||||
<QItem class="justify-between">
|
<QItem class="justify-between">
|
||||||
<QItemLabel class="slider-container">
|
<QItemLabel class="slider-container">
|
||||||
<p class="text-primary">
|
<p class="text-primary">
|
||||||
|
@ -250,6 +241,7 @@ async function importToNewRefundTicket() {
|
||||||
</QItemLabel>
|
</QItemLabel>
|
||||||
</QItem>
|
</QItem>
|
||||||
</QCard>
|
</QCard>
|
||||||
|
<QCard class="q-mb-md q-pa-sm no-box-shadow" style="margin-bottom: 1em">
|
||||||
<QItemLabel class="mana q-mb-md">
|
<QItemLabel class="mana q-mb-md">
|
||||||
<QCheckbox
|
<QCheckbox
|
||||||
v-model="claim.isChargedToMana"
|
v-model="claim.isChargedToMana"
|
||||||
|
@ -257,6 +249,23 @@ async function importToNewRefundTicket() {
|
||||||
/>
|
/>
|
||||||
<span>{{ t('mana') }}</span>
|
<span>{{ t('mana') }}</span>
|
||||||
</QItemLabel>
|
</QItemLabel>
|
||||||
|
</QCard>
|
||||||
|
<QCard class="q-mb-md q-pa-sm no-box-shadow" style="position: static">
|
||||||
|
<QInput
|
||||||
|
:disable="
|
||||||
|
!(claim.responsibility >= Math.ceil(DEFAULT_MAX_RESPONSABILITY) / 2)
|
||||||
|
"
|
||||||
|
:label="t('confirmGreuges')"
|
||||||
|
class="q-field__native text-grey-2"
|
||||||
|
type="number"
|
||||||
|
placeholder="0"
|
||||||
|
id="multiplicatorValue"
|
||||||
|
name="multiplicatorValue"
|
||||||
|
min="0"
|
||||||
|
max="50"
|
||||||
|
v-model="multiplicatorValue"
|
||||||
|
/>
|
||||||
|
</QCard>
|
||||||
</QDrawer>
|
</QDrawer>
|
||||||
<Teleport to="#st-data" v-if="stateStore.isSubToolbarShown()"> </Teleport>
|
<Teleport to="#st-data" v-if="stateStore.isSubToolbarShown()"> </Teleport>
|
||||||
<CrudModel
|
<CrudModel
|
||||||
|
@ -494,4 +503,5 @@ es:
|
||||||
Id item: Id artículo
|
Id item: Id artículo
|
||||||
confirmGreuges: ¿Desea insertar greuges?
|
confirmGreuges: ¿Desea insertar greuges?
|
||||||
confirmGreugesMessage: Insertar greuges en la ficha del cliente
|
confirmGreugesMessage: Insertar greuges en la ficha del cliente
|
||||||
|
Apply Greuges: Aplicar Greuges
|
||||||
</i18n>
|
</i18n>
|
||||||
|
|
|
@ -31,7 +31,6 @@ describe('ClaimAction', () => {
|
||||||
|
|
||||||
it('should regularize', () => {
|
it('should regularize', () => {
|
||||||
cy.get('[title="Regularize"]').click();
|
cy.get('[title="Regularize"]').click();
|
||||||
cy.clickConfirm();
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should remove the line', () => {
|
it('should remove the line', () => {
|
||||||
|
|
Loading…
Reference in New Issue