This commit is contained in:
parent
5779d37bbd
commit
cc241c6a4e
|
@ -1,6 +1,6 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import { toRefs, ref } from 'vue';
|
import { toRefs, ref } from 'vue';
|
||||||
import TicketLackDialog from './TicketLackDialog.vue';
|
import TicketLackDetail from './TicketLackDetail.vue';
|
||||||
import { useSession } from 'src/composables/useSession';
|
import { useSession } from 'src/composables/useSession';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
|
|
||||||
|
@ -28,43 +28,38 @@ async function splitSelected() {
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<QDialog
|
<QCard class="q-pa-sm">
|
||||||
ref="dialogLackRef"
|
<QCardSection class="row items-center q-pb-none">
|
||||||
full-width
|
<QImg
|
||||||
@before-show="() => (hasRowsSelected = false)"
|
:src="`/api/Images/catalog/50x50/${ticket.itemFk}/download?access_token=${token}`"
|
||||||
>
|
spinner-color="primary"
|
||||||
<QCard class="q-pa-sm">
|
:ratio="1"
|
||||||
<QCardSection class="row items-center q-pb-none">
|
height="50px"
|
||||||
<QImg
|
width="50px"
|
||||||
:src="`/api/Images/catalog/50x50/${ticket.itemFk}/download?access_token=${token}`"
|
class="image remove-bg"
|
||||||
spinner-color="primary"
|
/>
|
||||||
:ratio="1"
|
|
||||||
height="50px"
|
|
||||||
width="50px"
|
|
||||||
class="image remove-bg"
|
|
||||||
/>
|
|
||||||
|
|
||||||
<span class="text-h6 text-grey">{{ ticket.longName }}</span>
|
<span class="text-h6 text-grey">{{ ticket.longName }}</span>
|
||||||
<QSpace />
|
<QSpace />
|
||||||
<QBtn
|
<QBtn
|
||||||
round
|
round
|
||||||
color="primary"
|
color="primary"
|
||||||
@click="splitSelected()"
|
@click="splitSelected()"
|
||||||
:disabled="!hasRowsSelected"
|
:disabled="!hasRowsSelected"
|
||||||
>
|
>
|
||||||
<QIcon name="call_split"></QIcon>
|
<QIcon name="call_split"></QIcon>
|
||||||
<QTooltip>
|
<QTooltip>
|
||||||
{{ t('globals.split') }}
|
{{ t('globals.split') }}
|
||||||
</QTooltip>
|
</QTooltip>
|
||||||
</QBtn>
|
</QBtn>
|
||||||
<QBtn icon="close" flat round dense v-close-popup />
|
<QBtn icon="close" flat round dense v-close-popup />
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<QCardSection class="row items-center">
|
<QCardSection class="row items-center">
|
||||||
<TicketLackDialog
|
<TicketLackDetail
|
||||||
ref="ticketRef"
|
ref="ticketRef"
|
||||||
:id="ticket.itemFk"
|
:id="ticket.itemFk"
|
||||||
@selection="(rows) => (hasRowsSelected = rows.length > 0)"
|
@selection="(rows) => (hasRowsSelected = rows.length > 0)"
|
||||||
/> </QCardSection></QCard
|
/> </QCardSection
|
||||||
></QDialog>
|
></QCard>
|
||||||
</template>
|
</template>
|
||||||
<i18n> </i18n>
|
<i18n> </i18n>
|
||||||
|
|
|
@ -4,7 +4,7 @@ import { useI18n } from 'vue-i18n';
|
||||||
import { useStateStore } from 'stores/useStateStore';
|
import { useStateStore } from 'stores/useStateStore';
|
||||||
import VnPaginate from 'components/ui/VnPaginate.vue';
|
import VnPaginate from 'components/ui/VnPaginate.vue';
|
||||||
import TicketLackFilter from 'pages/Ticket/Negative/TicketLackFilter.vue';
|
import TicketLackFilter from 'pages/Ticket/Negative/TicketLackFilter.vue';
|
||||||
import TicketLackDialogProxy from 'src/pages/Ticket/Negative/TicketLackDialogProxy.vue';
|
// import TicketLackDialogProxy from 'src/pages/Ticket/Negative/TicketLackDialogProxy.vue';
|
||||||
import NegativeOriginDialog from 'pages/Ticket/Negative/NegativeOriginDialog.vue';
|
import NegativeOriginDialog from 'pages/Ticket/Negative/NegativeOriginDialog.vue';
|
||||||
import TotalNegativeOriginDialog from 'pages/Ticket/Negative/TotalNegativeOriginDialog.vue';
|
import TotalNegativeOriginDialog from 'pages/Ticket/Negative/TotalNegativeOriginDialog.vue';
|
||||||
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
|
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
|
||||||
|
@ -19,10 +19,17 @@ const showNegativeOriginDialog = ref(false);
|
||||||
const showTotalNegativeOriginDialog = ref(false);
|
const showTotalNegativeOriginDialog = ref(false);
|
||||||
const currentRow = ref(null);
|
const currentRow = ref(null);
|
||||||
const { dialogRef, onDialogHide } = useDialogPluginComponent();
|
const { dialogRef, onDialogHide } = useDialogPluginComponent();
|
||||||
|
import { useRoute, useRouter } from 'vue-router';
|
||||||
|
|
||||||
const viewSummary = (value) => {
|
const route = useRoute();
|
||||||
showTicketDialog.value = true;
|
const router = useRouter();
|
||||||
currentRow.value = value;
|
const viewSummary = ({ itemFk: id }) => {
|
||||||
|
router.push({
|
||||||
|
name: 'TicketLackCard',
|
||||||
|
params: {
|
||||||
|
id: '1',
|
||||||
|
},
|
||||||
|
});
|
||||||
};
|
};
|
||||||
const originDialogRef = ref();
|
const originDialogRef = ref();
|
||||||
const totalNegativeDialogRef = ref();
|
const totalNegativeDialogRef = ref();
|
||||||
|
@ -199,12 +206,12 @@ const columns = computed(() => [
|
||||||
</template>
|
</template>
|
||||||
</VnPaginate>
|
</VnPaginate>
|
||||||
</div>
|
</div>
|
||||||
|
<!--
|
||||||
<TicketLackDialogProxy
|
<TicketLackDialogProxy
|
||||||
ref="dialogRef"
|
ref="dialogRef"
|
||||||
v-model="showTicketDialog"
|
v-model="showTicketDialog"
|
||||||
:ticket="currentRow"
|
:ticket="currentRow"
|
||||||
></TicketLackDialogProxy>
|
></TicketLackDialogProxy> -->
|
||||||
<TotalNegativeOriginDialog
|
<TotalNegativeOriginDialog
|
||||||
ref="totalNegativeDialogRef"
|
ref="totalNegativeDialogRef"
|
||||||
v-model="showTotalNegativeOriginDialog"
|
v-model="showTotalNegativeOriginDialog"
|
||||||
|
|
|
@ -39,6 +39,14 @@ export default {
|
||||||
},
|
},
|
||||||
component: () =>
|
component: () =>
|
||||||
import('src/pages/Ticket/Negative/TicketLackList.vue'),
|
import('src/pages/Ticket/Negative/TicketLackList.vue'),
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
name: 'TicketLackCard',
|
||||||
|
path: ':id/edit',
|
||||||
|
component: () =>
|
||||||
|
import('src/pages/Ticket/Negative/TicketLackDetail.vue'),
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'TicketCreate',
|
name: 'TicketCreate',
|
||||||
|
|
Loading…
Reference in New Issue