Updated translations & upgraded quasar
gitea/salix-front/pipeline/head This commit looks good Details

This commit is contained in:
Joan Sanchez 2022-10-26 13:58:45 +02:00
parent 2af2a98b0d
commit 19dd262768
6 changed files with 707 additions and 607 deletions

1220
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -18,10 +18,10 @@
"test:e2e:ci": "cross-env E2E_TEST=true start-test \"quasar dev\" http-get://localhost:8080 \"cypress run\""
},
"dependencies": {
"@quasar/extras": "^1.14.0",
"@quasar/extras": "^1.15.5",
"axios": "^0.21.1",
"core-js": "^3.6.5",
"quasar": "^2.7.3",
"quasar": "^2.10.0",
"validator": "^13.7.0",
"vue": "^3.0.0",
"vue-i18n": "^9.0.0",
@ -30,8 +30,8 @@
"devDependencies": {
"@babel/eslint-parser": "^7.13.14",
"@intlify/vue-i18n-loader": "^4.1.0",
"@quasar/app-webpack": "^3.5.3",
"@quasar/quasar-app-extension-testing-e2e-cypress": "^4.1.2",
"@quasar/app-webpack": "^3.6.2",
"@quasar/quasar-app-extension-testing-e2e-cypress": "^4.2.2",
"@quasar/quasar-app-extension-testing-unit-jest": "^3.0.0-alpha.10",
"eslint": "^8.10.0",
"eslint-config-prettier": "^8.1.0",

View File

@ -219,14 +219,19 @@ export default {
attendedBy: 'Attended by',
created: 'Created',
state: 'State',
details: {
title: 'Details',
columns: {
item: 'Item',
landed: 'Delivered',
quantity: 'Quantity'
}
},
details: 'Details',
item: 'Item',
landed: 'Landed',
quantity: 'Quantity',
claimed: 'Claimed',
description: 'Description',
price: 'Price',
discount: 'Discount',
total: 'Total',
actions: 'Actions',
responsibility: 'Responsibility',
company: 'Company',
person: 'Employee/Customer'
},
basicData: {
customer: 'Customer',

View File

@ -218,14 +218,19 @@ export default {
attendedBy: 'Atendida por',
created: 'Creada',
state: 'Estado',
details: {
title: 'Detalles',
columns: {
item: 'Artículo2',
landed: 'Entregado',
quantity: 'Cantidad'
}
},
details: 'Detalles',
item: 'Artículo',
landed: 'Entregado',
quantity: 'Cantidad',
claimed: 'Reclamado',
description: 'Descripción',
price: 'Precio',
discount: 'Descuento',
total: 'Total',
actions: 'Acciones',
responsibility: 'Responsabilidad',
company: 'Empresa',
person: 'Comercial/Cliente'
},
basicData: {
customer: 'Cliente',

View File

@ -1,9 +1,9 @@
<script setup>
import { onMounted, defineProps, ref, computed } from 'vue';
import { onMounted, ref, computed } from 'vue';
import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import axios from 'axios';
import { toDate } from 'src/filters';
import { toDate, toCurrency } from 'src/filters';
import SkeletonSummary from 'src/components/SkeletonSummary';
onMounted(() => fetch());
@ -33,51 +33,51 @@ function fetch() {
const detailsColumns = ref([
{
name: 'item',
label: t('claim.summary.details.columns.item'),
label: 'claim.summary.item',
field: (row) => row.sale.itemFk,
sortable: true,
},
{
name: 'landed',
label: t('claim.summary.details.columns.landed'),
label: 'claim.summary.landed',
field: (row) => row.sale.ticket.landed,
format: (value) => toDate(value),
sortable: true,
},
{
name: 'quantity',
label: t('claim.summary.details.columns.quantity'),
label: 'claim.summary.quantity',
field: (row) => row.sale.quantity,
sortable: true,
},
{
name: 'claimed',
label: 'Claimed',
label: 'claim.summary.claimed',
field: (row) => row.quantity,
sortable: true,
},
{
name: 'description',
label: 'Description',
label: 'claim.summary.description',
field: (row) => row.sale.concept,
},
{
name: 'price',
label: 'Price',
label: 'claim.summary.price',
field: (row) => row.sale.price,
sortable: true,
},
{
name: 'discount',
label: 'Discount',
label: 'claim.summary.discount',
field: (row) => row.sale.discount,
format: (value) => `${value} %`,
sortable: true,
},
{
name: 'total',
label: 'Total',
field: ({ sale }) => sale.quantity * sale.price * ((100 - sale.discount) / 100),
label: 'claim.summary.total',
field: ({ sale }) => toCurrency(sale.quantity * sale.price * ((100 - sale.discount) / 100)),
sortable: true,
},
]);
@ -123,23 +123,31 @@ function stateColor(code) {
</q-item>
</q-list>
<q-card-section class="q-pa-md">
<h6>{{ t('claim.summary.details.title') }}</h6>
<q-table :columns="detailsColumns" :rows="salesClaimed" flat></q-table>
<h6>{{ t('claim.summary.details') }}</h6>
<q-table :columns="detailsColumns" :rows="salesClaimed" flat>
<template #header="props">
<q-tr :props="props">
<q-th v-for="col in props.cols" :key="col.name" :props="props">
{{ t(col.label) }}
</q-th>
</q-tr>
</template>
</q-table>
</q-card-section>
<q-card-section class="q-pa-md">
<h6>Action</h6>
<h6>{{ t('claim.summary.actions') }}</h6>
<q-separator />
<div id="slider-container">
<q-slider
v-model="claim.responsibility"
label
:label-value="'Responsibility'"
:label-value="t('claim.summary.responsibility')"
label-always
color="primary"
markers
:marker-labels="[
{ value: 1, label: 'Company' },
{ value: 5, label: 'Person' },
{ value: 1, label: t('claim.summary.company') },
{ value: 5, label: t('claim.summary.person') },
]"
:min="1"
:max="5"

View File

@ -1,5 +1,5 @@
<script setup>
import { onMounted, defineProps, ref, computed } from 'vue';
import { onMounted, ref, computed } from 'vue';
import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import axios from 'axios';