refactor: refs #8197 rename VnSectionMain to VnModule and VnCardMain to VnSection
gitea/salix-front/pipeline/pr-beta This commit looks good Details

This commit is contained in:
Alex Moreno 2024-12-18 13:42:57 +01:00
parent 8c3c318099
commit fccca9ea47
24 changed files with 98 additions and 98 deletions

View File

@ -5,6 +5,8 @@ import { useArrayData } from 'src/composables/useArrayData';
import { useStateStore } from 'stores/useStateStore';
import useCardSize from 'src/composables/useCardSize';
import LeftMenu from 'components/LeftMenu.vue';
import VnSubToolbar from '../ui/VnSubToolbar.vue';
const props = defineProps({
dataKey: { type: String, required: true },
baseUrl: { type: String, default: undefined },

View File

@ -9,7 +9,7 @@ import VnTable from 'components/VnTable/VnTable.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
import FetchData from 'src/components/FetchData.vue';
import { useValidator } from 'src/composables/useValidator';
import VnCardMain from 'src/components/common/VnCardMain.vue';
import VnSection from 'src/components/common/VnSection.vue';
defineProps({
id: {
@ -138,7 +138,7 @@ const deleteAcl = async ({ id }) => {
auto-load
@on-fetch="(data) => (roles = data)"
/>
<VnCardMain
<VnSection
:data-key="dataKey"
:columns="columns"
prefix="acls"
@ -166,7 +166,7 @@ const deleteAcl = async ({ id }) => {
:use-model="true"
/>
</template>
</VnCardMain>
</VnSection>
</template>
<i18n>

View File

@ -2,7 +2,7 @@
import { useI18n } from 'vue-i18n';
import { ref, computed } from 'vue';
import VnTable from 'components/VnTable/VnTable.vue';
import VnCardMain from 'src/components/common/VnCardMain.vue';
import VnSection from 'src/components/common/VnSection.vue';
const tableRef = ref();
const { t } = useI18n();
@ -43,7 +43,7 @@ const exprBuilder = (param, value) => {
</script>
<template>
<VnCardMain
<VnSection
:data-key="dataKey"
:columns="columns"
prefix="mailAlias"
@ -68,7 +68,7 @@ const exprBuilder = (param, value) => {
:right-search="false"
/>
</template>
</VnCardMain>
</VnSection>
</template>
<i18n>
es:

View File

@ -4,7 +4,7 @@ import { computed } from 'vue';
import VnTable from 'components/VnTable/VnTable.vue';
import AccountSummary from './Card/AccountSummary.vue';
import { useSummaryDialog } from 'src/composables/useSummaryDialog';
import VnCardMain from 'src/components/common/VnCardMain.vue';
import VnSection from 'src/components/common/VnSection.vue';
const { t } = useI18n();
const { viewSummary } = useSummaryDialog();
@ -103,7 +103,7 @@ function exprBuilder(param, value) {
</script>
<template>
<VnCardMain
<VnSection
:data-key="dataKey"
:columns="columns"
prefix="account"
@ -124,7 +124,7 @@ function exprBuilder(param, value) {
:right-search="false"
/>
</template>
</VnCardMain>
</VnSection>
</template>
<i18n>

View File

@ -5,7 +5,7 @@ import VnTable from 'components/VnTable/VnTable.vue';
import { useRoute } from 'vue-router';
import { useSummaryDialog } from 'src/composables/useSummaryDialog';
import RoleSummary from './Card/RoleSummary.vue';
import VnCardMain from 'src/components/common/VnCardMain.vue';
import VnSection from 'src/components/common/VnSection.vue';
const route = useRoute();
const { t } = useI18n();
@ -85,7 +85,7 @@ const exprBuilder = (param, value) => {
</script>
<template>
<VnCardMain
<VnSection
:data-key="dataKey"
:columns="columns"
prefix="role"
@ -110,7 +110,7 @@ const exprBuilder = (param, value) => {
:right-search="false"
/>
</template>
</VnCardMain>
</VnSection>
</template>
<i18n>

View File

@ -1,15 +1,18 @@
<script setup>
import axios from 'axios';
import { date, useQuasar } from 'quasar';
import { computed, onMounted, reactive, ref } from 'vue';
import { computed, onMounted, onUnmounted, reactive, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
import { useStateStore } from 'stores/useStateStore';
const router = useRouter();
const stateStore = useStateStore();
const { t } = useI18n();
const quasar = useQuasar();
onMounted(async () => {
stateStore.rightDrawer = true;
await fetch();
});
@ -84,74 +87,69 @@ async function getVideoList(expeditionId, timed) {
</script>
<template>
<QDrawer show-if-above side="right">
<QScrollArea class="fit">
<QList bordered separator style="max-width: 318px">
<QItem v-if="lastExpedition && videoList.length">
<QItemSection>
<QItemLabel class="text-h6">
{{ t('ticket.boxing.selectTime') }} ({{ time.min }}-{{
time.max
}})
</QItemLabel>
<QRange
v-model="time"
@change="getVideoList(lastExpedition, time)"
:min="0"
:max="24"
:step="1"
:left-label-value="time.min + ':00'"
:right-label-value="time.max + ':00'"
label
markers
snap
color="primary"
/>
</QItemSection>
</QItem>
<QItem v-if="lastExpedition && videoList.length">
<QItemSection>
<QSelect
color="primary"
v-model="slide"
:options="videoList"
:label="t('ticket.boxing.selectVideo')"
emit-value
map-options
>
<template #prepend>
<QIcon name="schedule" />
</template>
</QSelect>
</QItemSection>
</QItem>
<QItem
v-for="expedition in expeditions"
:key="expedition.id"
@click="getVideoList(expedition.id)"
clickable
v-ripple
>
<QItemSection>
<QItemLabel class="text-h6">#{{ expedition.id }}</QItemLabel>
</QItemSection>
<QItemSection>
<QItemLabel caption>{{ t('globals.created') }}</QItemLabel>
<QItemLabel>
{{
date.formatDate(expedition.created, 'YYYY-MM-DD HH:mm:ss')
}}
</QItemLabel>
<QItemLabel caption>{{ t('globals.item') }}</QItemLabel>
<QItemLabel>{{ expedition.packagingItemFk }}</QItemLabel>
<QItemLabel caption>{{ t('ticket.boxing.worker') }}</QItemLabel>
<QItemLabel>{{ expedition.userName }}</QItemLabel>
</QItemSection>
</QItem>
</QList>
</QScrollArea>
</QDrawer>
<Teleport to="#right-panel" v-if="stateStore.isHeaderMounted()">
<QList bordered separator style="max-width: 318px">
<QItem v-if="lastExpedition && videoList.length">
<QItemSection>
<QItemLabel class="text-h6">
{{ t('ticket.boxing.selectTime') }} ({{ time.min }}-{{
time.max
}})
</QItemLabel>
<QRange
v-model="time"
@change="getVideoList(lastExpedition, time)"
:min="0"
:max="24"
:step="1"
:left-label-value="time.min + ':00'"
:right-label-value="time.max + ':00'"
label
markers
snap
color="primary"
/>
</QItemSection>
</QItem>
<QItem v-if="lastExpedition && videoList.length">
<QItemSection>
<QSelect
color="primary"
v-model="slide"
:options="videoList"
:label="t('ticket.boxing.selectVideo')"
emit-value
map-options
>
<template #prepend>
<QIcon name="schedule" />
</template>
</QSelect>
</QItemSection>
</QItem>
<QItem
v-for="expedition in expeditions"
:key="expedition.id"
@click="getVideoList(expedition.id)"
clickable
v-ripple
>
<QItemSection>
<QItemLabel class="text-h6">#{{ expedition.id }}</QItemLabel>
</QItemSection>
<QItemSection>
<QItemLabel caption>{{ t('globals.created') }}</QItemLabel>
<QItemLabel>
{{ date.formatDate(expedition.created, 'YYYY-MM-DD HH:mm:ss') }}
</QItemLabel>
<QItemLabel caption>{{ t('globals.item') }}</QItemLabel>
<QItemLabel>{{ expedition.packagingItemFk }}</QItemLabel>
<QItemLabel caption>{{ t('ticket.boxing.worker') }}</QItemLabel>
<QItemLabel>{{ expedition.userName }}</QItemLabel>
</QItemSection>
</QItem>
</QList>
</Teleport>
<QCard>
<QCarousel animated v-model="slide" height="max-content">
<QCarouselSlide

View File

@ -28,7 +28,7 @@ export default {
{
path: '',
name: 'AccountMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'AccountIndexMain' },
children: [
{

View File

@ -27,7 +27,7 @@ export default {
{
name: 'ClaimMain',
path: '',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'ClaimList' },
children: [
{

View File

@ -39,7 +39,7 @@ export default {
{
path: '',
name: 'CustomerMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'CustomerList' },
children: [
{

View File

@ -25,7 +25,7 @@ export default {
{
path: '',
name: 'EntryMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'EntryList' },
children: [
{

View File

@ -25,7 +25,7 @@ export default {
{
path: '',
name: 'InvoiceInMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'InvoiceInList' },
children: [
{

View File

@ -18,7 +18,7 @@ export default {
{
path: '',
name: 'InvoiceOutMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'InvoiceOutList' },
children: [
{

View File

@ -36,7 +36,7 @@ export default {
{
path: '',
name: 'ItemMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'ItemList' },
children: [
{

View File

@ -19,7 +19,7 @@ export default {
{
path: '',
name: 'MonitorMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
props: (route) => ({ leftDrawer: route.name === 'MonitorClientsActions' }),
redirect: { name: 'MonitorTickets' },
children: [

View File

@ -19,7 +19,7 @@ export default {
{
path: '',
name: 'OrderMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'OrderList' },
children: [
{

View File

@ -25,7 +25,7 @@ export default {
{
path: '/route',
name: 'RouteMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'RouteList' },
children: [
{

View File

@ -18,7 +18,7 @@ export default {
{
path: '',
name: 'ShelvingMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'ShelvingList' },
children: [
{

View File

@ -30,7 +30,7 @@ export default {
{
path: '',
name: 'SupplierMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'SupplierList' },
children: [
{

View File

@ -18,7 +18,7 @@ export default {
{
path: '',
name: 'TravelMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'TravelList' },
children: [
{

View File

@ -18,7 +18,7 @@ export default {
{
path: '/wagon',
name: 'WagonMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'WagonList' },
children: [
{
@ -62,7 +62,7 @@ export default {
{
path: '/wagon/type',
name: 'WagonTypeMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'WagonTypeList' },
children: [
{

View File

@ -35,7 +35,7 @@ export default {
{
path: '',
name: 'WorkerMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'WorkerList' },
children: [
{

View File

@ -30,7 +30,7 @@ export default {
{
path: '/zone',
name: 'ZoneMain',
component: () => import('src/components/common/VnSectionMain.vue'),
component: () => import('src/components/common/VnModule.vue'),
redirect: { name: 'ZoneList' },
children: [
{