refafctor: changed titles errors
gitea/salix-front/pipeline/pr-dev There was a failure building this commit
Details
gitea/salix-front/pipeline/pr-dev There was a failure building this commit
Details
This commit is contained in:
parent
a33ce5699e
commit
42c58296ac
|
@ -37,7 +37,6 @@ function getBreadcrumb(param) {
|
||||||
locale: t(`globals.pageTitles.${param.meta.title}`),
|
locale: t(`globals.pageTitles.${param.meta.title}`),
|
||||||
};
|
};
|
||||||
|
|
||||||
//TODO modificar para que funcione títulos de página
|
|
||||||
if (screen.gt.sm) {
|
if (screen.gt.sm) {
|
||||||
breadcrumb.name = param.name;
|
breadcrumb.name = param.name;
|
||||||
breadcrumb.title = useCamelCase(param.meta.title);
|
breadcrumb.title = useCamelCase(param.meta.title);
|
||||||
|
|
|
@ -100,8 +100,8 @@ globals:
|
||||||
modes: Modes
|
modes: Modes
|
||||||
zones: Zones
|
zones: Zones
|
||||||
zonesList: Zones
|
zonesList: Zones
|
||||||
deliveryList: Delivery days
|
deliveryDays: Delivery days
|
||||||
upcomingList: Upcoming deliveries
|
upcomingDeliveries: Upcoming deliveries
|
||||||
role: Role
|
role: Role
|
||||||
alias: Alias
|
alias: Alias
|
||||||
aliasUsers: Users
|
aliasUsers: Users
|
||||||
|
@ -220,6 +220,8 @@ globals:
|
||||||
lastEntries: Last entries
|
lastEntries: Last entries
|
||||||
itemType: Item type
|
itemType: Item type
|
||||||
monitors: Monitors
|
monitors: Monitors
|
||||||
|
dashboard: Dashboard
|
||||||
|
users: Users
|
||||||
created: Created
|
created: Created
|
||||||
worker: Worker
|
worker: Worker
|
||||||
now: Now
|
now: Now
|
||||||
|
@ -260,7 +262,7 @@ verifyEmail:
|
||||||
verifyEmail: Email verification
|
verifyEmail: Email verification
|
||||||
dashboard:
|
dashboard:
|
||||||
pageTitles:
|
pageTitles:
|
||||||
dashboard: Dashboard
|
|
||||||
customer:
|
customer:
|
||||||
list:
|
list:
|
||||||
phone: Phone
|
phone: Phone
|
||||||
|
|
|
@ -100,8 +100,8 @@ globals:
|
||||||
modes: Modos
|
modes: Modos
|
||||||
zones: Zonas
|
zones: Zonas
|
||||||
zonesList: Zonas
|
zonesList: Zonas
|
||||||
deliveryList: Días de entrega
|
deliveryDays: Días de entrega
|
||||||
upcomingList: Próximos repartos
|
upcomingDeliveries: Próximos repartos
|
||||||
role: Role
|
role: Role
|
||||||
alias: Alias
|
alias: Alias
|
||||||
aliasUsers: Usuarios
|
aliasUsers: Usuarios
|
||||||
|
@ -221,6 +221,8 @@ globals:
|
||||||
lastEntries: Últimas entradas
|
lastEntries: Últimas entradas
|
||||||
itemType: Familia
|
itemType: Familia
|
||||||
monitors: Monitores
|
monitors: Monitores
|
||||||
|
dashboard: Tablón
|
||||||
|
users: Usuarios
|
||||||
created: Fecha creación
|
created: Fecha creación
|
||||||
worker: Trabajador
|
worker: Trabajador
|
||||||
now: Ahora
|
now: Ahora
|
||||||
|
@ -259,7 +261,7 @@ verifyEmail:
|
||||||
verifyEmail: Verificación de correo
|
verifyEmail: Verificación de correo
|
||||||
dashboard:
|
dashboard:
|
||||||
pageTitles:
|
pageTitles:
|
||||||
dashboard: Tablón
|
|
||||||
customer:
|
customer:
|
||||||
list:
|
list:
|
||||||
phone: Teléfono
|
phone: Teléfono
|
||||||
|
|
|
@ -223,7 +223,7 @@ async function changeState(value) {
|
||||||
<QCard class="vn-one">
|
<QCard class="vn-one">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="`#/claim/${entityId}/basic-data`"
|
:url="`#/claim/${entityId}/basic-data`"
|
||||||
:text="t('claim.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('claim.summary.created')"
|
:label="t('claim.summary.created')"
|
||||||
|
|
|
@ -209,7 +209,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('invoiceIn.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<VnLv
|
<VnLv
|
||||||
|
@ -240,7 +240,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('invoiceIn.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<VnLv
|
<VnLv
|
||||||
|
@ -265,7 +265,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('invoiceIn.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<VnLv
|
<VnLv
|
||||||
|
@ -289,7 +289,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('invoiceIn.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
|
|
|
@ -49,7 +49,7 @@ const entriesTableColumns = computed(() => {
|
||||||
showValue: false,
|
showValue: false,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('supplier.pageTitles.supplier'),
|
label: t('globals.pageTitles.supplier'),
|
||||||
field: 'supplierName',
|
field: 'supplierName',
|
||||||
name: 'supplierName',
|
name: 'supplierName',
|
||||||
align: 'left',
|
align: 'left',
|
||||||
|
@ -247,7 +247,7 @@ const getLink = (param) => `#/travel/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('travel.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<VnLv :label="t('globals.shipped')" :value="toDate(travel.shipped)" />
|
<VnLv :label="t('globals.shipped')" :value="toDate(travel.shipped)" />
|
||||||
|
@ -265,7 +265,7 @@ const getLink = (param) => `#/travel/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('travel.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<VnLv :label="t('globals.landed')" :value="toDate(travel.landed)" />
|
<VnLv :label="t('globals.landed')" :value="toDate(travel.landed)" />
|
||||||
|
@ -283,7 +283,7 @@ const getLink = (param) => `#/travel/${entityId.value}/${param}`;
|
||||||
<QCardSection class="q-pa-none">
|
<QCardSection class="q-pa-none">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getLink('basic-data')"
|
:url="getLink('basic-data')"
|
||||||
:text="t('travel.pageTitles.basicData')"
|
:text="t('globals.pageTitles.basicData')"
|
||||||
/>
|
/>
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<VnLv :label="t('globals.agency')" :value="travel.agency?.name" />
|
<VnLv :label="t('globals.agency')" :value="travel.agency?.name" />
|
||||||
|
|
|
@ -132,7 +132,7 @@ const columns = computed(() => [
|
||||||
sortable: true,
|
sortable: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('supplier.pageTitles.supplier'),
|
label: t('globals.pageTitles.supplier'),
|
||||||
field: 'cargoSupplierNickname',
|
field: 'cargoSupplierNickname',
|
||||||
name: 'cargoSupplierNickname',
|
name: 'cargoSupplierNickname',
|
||||||
align: 'left',
|
align: 'left',
|
||||||
|
|
|
@ -182,7 +182,7 @@ const decrement = (paramsObj, key) => {
|
||||||
<QItem>
|
<QItem>
|
||||||
<QItemSection>
|
<QItemSection>
|
||||||
<VnSelect
|
<VnSelect
|
||||||
:label="t('supplier.pageTitles.supplier')"
|
:label="t('globals.pageTitles.supplier')"
|
||||||
v-model="params.cargoSupplierFk"
|
v-model="params.cargoSupplierFk"
|
||||||
@update:model-value="searchFn()"
|
@update:model-value="searchFn()"
|
||||||
:options="suppliersOptions"
|
:options="suppliersOptions"
|
||||||
|
|
|
@ -11,7 +11,6 @@ import { useState } from 'src/composables/useState';
|
||||||
import { useSession } from 'src/composables/useSession';
|
import { useSession } from 'src/composables/useSession';
|
||||||
import { useRole } from 'src/composables/useRole';
|
import { useRole } from 'src/composables/useRole';
|
||||||
import { useUserConfig } from 'src/composables/useUserConfig';
|
import { useUserConfig } from 'src/composables/useUserConfig';
|
||||||
import { toLowerCamel } from 'src/filters';
|
|
||||||
import { useTokenConfig } from 'src/composables/useTokenConfig';
|
import { useTokenConfig } from 'src/composables/useTokenConfig';
|
||||||
import { useAcl } from 'src/composables/useAcl';
|
import { useAcl } from 'src/composables/useAcl';
|
||||||
|
|
||||||
|
@ -79,13 +78,11 @@ export default route(function (/* { store, ssrContext } */) {
|
||||||
let title = t(`login.title`);
|
let title = t(`login.title`);
|
||||||
|
|
||||||
const matches = to.matched;
|
const matches = to.matched;
|
||||||
let moduleName;
|
|
||||||
if (matches && matches.length > 1) {
|
if (matches && matches.length > 1) {
|
||||||
const module = matches[1];
|
const module = matches[1];
|
||||||
const moduleTitle = module.meta && module.meta.title;
|
const moduleTitle = module.meta && module.meta.title;
|
||||||
moduleName = toLowerCamel(module.name);
|
|
||||||
if (moduleTitle) {
|
if (moduleTitle) {
|
||||||
title = t(`${moduleName}.pageTitles.${moduleTitle}`);
|
title = t(`globals.pageTitles.${moduleTitle}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -94,7 +91,7 @@ export default route(function (/* { store, ssrContext } */) {
|
||||||
if (childPageTitle && matches.length > 2) {
|
if (childPageTitle && matches.length > 2) {
|
||||||
if (title != '') title += ': ';
|
if (title != '') title += ': ';
|
||||||
|
|
||||||
const moduleLocale = `${moduleName}.pageTitles.${childPageTitle}`;
|
const moduleLocale = `globals.pageTitles.${childPageTitle}`;
|
||||||
const pageTitle = te(moduleLocale)
|
const pageTitle = te(moduleLocale)
|
||||||
? t(moduleLocale)
|
? t(moduleLocale)
|
||||||
: t(`globals.pageTitles.${childPageTitle}`);
|
: t(`globals.pageTitles.${childPageTitle}`);
|
||||||
|
|
|
@ -201,15 +201,6 @@ export default {
|
||||||
},
|
},
|
||||||
component: () => import('src/pages/Item/Card/ItemLog.vue'),
|
component: () => import('src/pages/Item/Card/ItemLog.vue'),
|
||||||
},
|
},
|
||||||
{
|
|
||||||
path: 'botanical',
|
|
||||||
name: 'ItemBotanical',
|
|
||||||
meta: {
|
|
||||||
title: 'botanical',
|
|
||||||
icon: 'vn:botanical',
|
|
||||||
},
|
|
||||||
component: () => import('src/pages/Item/Card/ItemBotanical.vue'),
|
|
||||||
},
|
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
|
@ -60,7 +60,7 @@ export const useNavigationStore = defineStore('navigationStore', () => {
|
||||||
menuChildren = menuChildren.map(({ name, title, icon }) => ({
|
menuChildren = menuChildren.map(({ name, title, icon }) => ({
|
||||||
name,
|
name,
|
||||||
icon,
|
icon,
|
||||||
title: `${module}.pageTitles.${title}`,
|
title: `globals.pageTitles.${title}`,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
if (meta && meta.roles && role.hasAny(meta.roles) === false) return;
|
if (meta && meta.roles && role.hasAny(meta.roles) === false) return;
|
||||||
|
@ -70,7 +70,7 @@ export const useNavigationStore = defineStore('navigationStore', () => {
|
||||||
children: menuChildren,
|
children: menuChildren,
|
||||||
};
|
};
|
||||||
if (meta) {
|
if (meta) {
|
||||||
item.title = `${module}.pageTitles.${meta.title}`;
|
item.title = `globals.pageTitles.${meta.title}`;
|
||||||
item.icon = meta.icon;
|
item.icon = meta.icon;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue