Hotfix: Redirect to Ticketsale when confirming an order #1245
|
@ -208,15 +208,28 @@ async function remove(item) {
|
|||
async function handleConfirm() {
|
||||
const result = await confirm(route.params.id);
|
||||
if (result) {
|
||||
const sale = await axios.get(`OrderRows`, {
|
||||
params: {
|
||||
filter: JSON.stringify({
|
||||
where: { orderFk: route.params.id },
|
||||
}),
|
||||
},
|
||||
});
|
||||
const ticket = await axios.get(`Sales`, {
|
||||
params: {
|
||||
filter: JSON.stringify({
|
||||
where: { id: sale.data[0].saleFk },
|
||||
}),
|
||||
},
|
||||
});
|
||||
quasar.notify({
|
||||
message: t('globals.dataSaved'),
|
||||
type: 'positive',
|
||||
});
|
||||
router.push({
|
||||
name: 'TicketSale',
|
||||
query: {
|
||||
table: JSON.stringify({ id: route.params.id }),
|
||||
},
|
||||
params: { id: ticket.data[0].ticketFk },
|
||||
query: { table: JSON.stringify({ filter: { limit: 20, skip: 0 } }) },
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue