7983-testToMaster_2438 #718
|
@ -116,14 +116,14 @@ const tableModes = [
|
|||
title: t('table view'),
|
||||
value: TABLE_MODE,
|
||||
disable: $props.disableOption?.table,
|
||||
visible: $props.disableOption?.table,
|
||||
// visible: $props.disableOption?.table,
|
||||
},
|
||||
{
|
||||
icon: 'grid_view',
|
||||
title: t('grid view'),
|
||||
value: CARD_MODE,
|
||||
disable: $props.disableOption?.card,
|
||||
visible: $props.disableOption?.card,
|
||||
// visible: $props.disableOption?.card,
|
||||
},
|
||||
];
|
||||
onBeforeMount(() => {
|
||||
|
@ -389,7 +389,7 @@ defineExpose({
|
|||
toggle-color="primary"
|
||||
class="bg-vn-section-color"
|
||||
dense
|
||||
:options="tableModes.filter((mode) => !mode.visible)"
|
||||
:options="tableModes.filter((mode) => !mode.disable)"
|
||||
/>
|
||||
<QBtn
|
||||
v-if="$props.rightSearch"
|
||||
|
|
|
@ -7,5 +7,5 @@ export function getDateQBadgeColor(date) {
|
|||
let comparation = today - timeTicket;
|
||||
|
||||
if (comparation == 0) return 'warning';
|
||||
if (comparation < 0) return 'negative';
|
||||
if (comparation < 0) return 'success';
|
||||
}
|
||||
|
|
|
@ -1100,11 +1100,11 @@ travel:
|
|||
id: Id
|
||||
ref: Referencia
|
||||
agency: Agencia
|
||||
shipped: Enviado
|
||||
landed: Llegada
|
||||
warehouseIn: Almacén de salida
|
||||
warehouseOut: Almacén de entrada
|
||||
totalEntries: Total de entradas
|
||||
shipped: F.envío
|
||||
landed: F.entrega
|
||||
warehouseIn: Alm.salida
|
||||
warehouseOut: Alm.entrada
|
||||
totalEntries: Ent.totales
|
||||
summary:
|
||||
confirmed: Confirmado
|
||||
entryId: Id entrada
|
||||
|
|
|
@ -100,7 +100,7 @@ const columns = computed(() => [
|
|||
name: 'tableActions',
|
||||
actions: [
|
||||
{
|
||||
title: t('View summary'),
|
||||
title: t('component.smartCard.viewSummary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row.id, ClaimSummary),
|
||||
},
|
||||
|
@ -155,7 +155,6 @@ es:
|
|||
You can search by claim id or customer name: Puedes buscar por id de la reclamación o nombre del cliente
|
||||
params:
|
||||
stateCode: Estado
|
||||
View summary: Ver resumen
|
||||
en:
|
||||
params:
|
||||
stateCode: State
|
||||
|
|
|
@ -357,7 +357,7 @@ const columns = computed(() => [
|
|||
isPrimary: true,
|
||||
},
|
||||
{
|
||||
title: t('View Summary'),
|
||||
title: t('component.smartCard.viewSummary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row.id, CustomerSummary),
|
||||
},
|
||||
|
@ -432,7 +432,6 @@ function handleLocation(data, location) {
|
|||
<i18n>
|
||||
es:
|
||||
Web user: Usuario Web
|
||||
View Summary: Ver resumen
|
||||
</i18n>
|
||||
<style lang="scss" scoped>
|
||||
.col-content {
|
||||
|
|
|
@ -7,11 +7,14 @@ import { useStateStore } from 'stores/useStateStore';
|
|||
import VnTable from 'components/VnTable/VnTable.vue';
|
||||
import RightMenu from 'src/components/common/RightMenu.vue';
|
||||
import { toDate } from 'src/filters';
|
||||
import { useSummaryDialog } from 'src/composables/useSummaryDialog';
|
||||
import EntrySummary from './Card/EntrySummary.vue';
|
||||
|
||||
const stateStore = useStateStore();
|
||||
const { t } = useI18n();
|
||||
const tableRef = ref();
|
||||
|
||||
const { viewSummary } = useSummaryDialog();
|
||||
const entryFilter = {
|
||||
include: [
|
||||
{
|
||||
|
@ -168,6 +171,18 @@ const columns = computed(() => [
|
|||
inWhere: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
align: 'right',
|
||||
name: 'tableActions',
|
||||
actions: [
|
||||
{
|
||||
title: t('component.smartCard.viewSummary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row.id, EntrySummary),
|
||||
isPrimary: true,
|
||||
},
|
||||
],
|
||||
},
|
||||
]);
|
||||
onMounted(async () => {
|
||||
stateStore.rightDrawer = true;
|
||||
|
|
|
@ -122,7 +122,7 @@ const columns = computed(() => [
|
|||
name: 'tableActions',
|
||||
actions: [
|
||||
{
|
||||
title: t('View Summary'),
|
||||
title: t('component.smartCard.viewSummary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row.id, InvoiceOutSummary),
|
||||
},
|
||||
|
@ -290,6 +290,5 @@ es:
|
|||
fileAllowed: Descarga exitosa de archivo CSV
|
||||
youCanSearchByInvoiceReference: Puedes buscar por referencia de la factura
|
||||
createInvoice: Crear factura
|
||||
View Summary: Ver resumen
|
||||
Create manual invoice: Crear factura manual
|
||||
</i18n>
|
||||
|
|
|
@ -185,7 +185,7 @@ const columns = computed(() => [
|
|||
action: (row) => openTicketsDialog(row?.id),
|
||||
},
|
||||
{
|
||||
title: t('View Summary'),
|
||||
title: t('component.smartCard.viewSummary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row?.id, RouteSummary),
|
||||
},
|
||||
|
@ -387,5 +387,4 @@ es:
|
|||
Route is not served: La ruta no está servida
|
||||
hourStarted: Hora de inicio
|
||||
hourFinished: Hora de fin
|
||||
View Summary: Ver resumen
|
||||
</i18n>
|
||||
|
|
|
@ -10,6 +10,7 @@ import { computed } from 'vue';
|
|||
import TravelSummary from './Card/TravelSummary.vue';
|
||||
import VnSearchbar from 'components/ui/VnSearchbar.vue';
|
||||
import { toDate } from 'src/filters';
|
||||
import { getDateQBadgeColor } from 'src/composables/getDateQBadgeColor.js';
|
||||
const { viewSummary } = useSummaryDialog();
|
||||
const router = useRouter();
|
||||
const { t } = useI18n();
|
||||
|
@ -46,14 +47,12 @@ const columns = computed(() => [
|
|||
name: 'id',
|
||||
label: t('travel.travelList.tableVisibleColumns.id'),
|
||||
isId: true,
|
||||
field: 'id',
|
||||
cardVisible: true,
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'ref',
|
||||
label: t('travel.travelList.tableVisibleColumns.ref'),
|
||||
field: 'ref',
|
||||
component: 'input',
|
||||
columnField: {
|
||||
component: null,
|
||||
|
@ -65,7 +64,6 @@ const columns = computed(() => [
|
|||
align: 'left',
|
||||
name: 'agencyModeFk',
|
||||
label: t('travel.travelList.tableVisibleColumns.agency'),
|
||||
field: 'agencyModeFk',
|
||||
component: 'select',
|
||||
attrs: {
|
||||
url: 'agencyModes',
|
||||
|
@ -78,37 +76,10 @@ const columns = computed(() => [
|
|||
cardVisible: true,
|
||||
create: true,
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'shipped',
|
||||
label: t('travel.travelList.tableVisibleColumns.shipped'),
|
||||
field: 'shipped',
|
||||
component: 'date',
|
||||
columnField: {
|
||||
component: null,
|
||||
},
|
||||
cardVisible: true,
|
||||
create: true,
|
||||
format: (row, dashIfEmpty) => dashIfEmpty(toDate(row.shipped)),
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'landed',
|
||||
label: t('travel.travelList.tableVisibleColumns.landed'),
|
||||
field: 'landed',
|
||||
component: 'date',
|
||||
columnField: {
|
||||
component: null,
|
||||
},
|
||||
cardVisible: true,
|
||||
create: true,
|
||||
format: (row, dashIfEmpty) => dashIfEmpty(toDate(row.landed)),
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'warehouseInFk',
|
||||
label: t('travel.travelList.tableVisibleColumns.warehouseIn'),
|
||||
field: 'warehouseInFk',
|
||||
component: 'select',
|
||||
attrs: {
|
||||
url: 'warehouses',
|
||||
|
@ -123,11 +94,22 @@ const columns = computed(() => [
|
|||
cardVisible: true,
|
||||
create: true,
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'shipped',
|
||||
label: t('travel.travelList.tableVisibleColumns.shipped'),
|
||||
component: 'date',
|
||||
columnField: {
|
||||
component: null,
|
||||
},
|
||||
cardVisible: true,
|
||||
create: true,
|
||||
format: (row, dashIfEmpty) => dashIfEmpty(toDate(row.shipped)),
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'warehouseOutFk',
|
||||
label: t('travel.travelList.tableVisibleColumns.warehouseOut'),
|
||||
field: 'warehouseOutFk',
|
||||
component: 'select',
|
||||
attrs: {
|
||||
url: 'warehouses',
|
||||
|
@ -140,11 +122,22 @@ const columns = computed(() => [
|
|||
cardVisible: true,
|
||||
create: true,
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'landed',
|
||||
label: t('travel.travelList.tableVisibleColumns.landed'),
|
||||
component: 'date',
|
||||
columnField: {
|
||||
component: null,
|
||||
},
|
||||
cardVisible: true,
|
||||
create: true,
|
||||
format: (row, dashIfEmpty) => dashIfEmpty(toDate(row.landed)),
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
name: 'totalEntries',
|
||||
label: t('travel.travelList.tableVisibleColumns.totalEntries'),
|
||||
field: 'totalEntries',
|
||||
component: 'input',
|
||||
columnField: {
|
||||
component: null,
|
||||
|
@ -167,11 +160,13 @@ const columns = computed(() => [
|
|||
title: t('Add entry'),
|
||||
icon: 'contact_support',
|
||||
action: redirectCreateEntryView,
|
||||
isPrimary: true,
|
||||
},
|
||||
{
|
||||
title: t('View Summary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row.id, TravelSummary),
|
||||
isPrimary: true,
|
||||
},
|
||||
],
|
||||
},
|
||||
|
@ -202,8 +197,39 @@ const columns = computed(() => [
|
|||
redirect="travel"
|
||||
:is-editable="false"
|
||||
:use-model="true"
|
||||
>
|
||||
<template #column-shipped="{ row }">
|
||||
<QBadge
|
||||
text-color="black"
|
||||
v-if="getDateQBadgeColor(row.shipped)"
|
||||
:color="getDateQBadgeColor(row.shipped)"
|
||||
>
|
||||
{{ toDate(row.shipped) }}
|
||||
</QBadge>
|
||||
<span v-else>{{ toDate(row.shipped) }}</span>
|
||||
<QIcon
|
||||
name="flight_takeoff"
|
||||
size="sm"
|
||||
:class="{ 'is-active': row.isDelivered }"
|
||||
/>
|
||||
</template>
|
||||
<template #column-landed="{ row }">
|
||||
<QBadge
|
||||
text-color="black"
|
||||
v-if="getDateQBadgeColor(row.landed)"
|
||||
:color="getDateQBadgeColor(row.landed)"
|
||||
>
|
||||
{{ toDate(row.landed) }}
|
||||
</QBadge>
|
||||
<span v-else>{{ toDate(row.landed) }}</span>
|
||||
<QIcon
|
||||
name="flight_land"
|
||||
size="sm"
|
||||
:class="{ 'is-active': row.isReceived }"
|
||||
/>
|
||||
</template>
|
||||
</VnTable>
|
||||
</template>
|
||||
|
||||
<i18n>
|
||||
en:
|
||||
|
@ -216,3 +242,9 @@ es:
|
|||
You can search by travel id or name: Buscar por envio por id o nombre
|
||||
Search travel: Buscar envio
|
||||
</i18n>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.is-active {
|
||||
color: green;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -77,7 +77,7 @@ const columns = computed(() => [
|
|||
name: 'tableActions',
|
||||
actions: [
|
||||
{
|
||||
title: t('View Summary'),
|
||||
title: t('component.smartCard.viewSummary'),
|
||||
icon: 'preview',
|
||||
action: (row) => viewSummary(row.id, WorkerSummary),
|
||||
},
|
||||
|
@ -342,5 +342,4 @@ async function autofillBic(worker) {
|
|||
es:
|
||||
Search worker: Buscar trabajador
|
||||
You can search by worker id or name: Puedes buscar por id o nombre del trabajador
|
||||
View Summary: Ver resumen
|
||||
</i18n>
|
||||
|
|
Loading…
Reference in New Issue