diff --git a/src/pages/Ecomerce/OrdersView.vue b/src/pages/Ecomerce/OrdersView.vue index 0c1ff6a5..1ee88978 100644 --- a/src/pages/Ecomerce/OrdersView.vue +++ b/src/pages/Ecomerce/OrdersView.vue @@ -32,17 +32,17 @@ const tpv = tpvStore(); onMounted(async () => { await tpv.check(route); - const myTickets = await api.post('applications/myTicket_list/execute-proc', new URLSearchParams({ + const myTickets = await api.post('applications/myTicket_list/execute-proc', { schema: 'hedera', - params: '[null, null]', - })); + params: [null, null], + }); orders.value = myTickets.data; }); -const getDebt = async (userId) => { +onUserId(async (userId) => { const myClientDebt = await api.get(`clients/${userId}/getDebt`); debt.value = -myClientDebt.data; -} +}); const onPayClick = async () => { showAmountToPayDialog.value = true; @@ -62,9 +62,6 @@ const onConfirmPay = async () => { amountToPay.value = parseFloat(amount); await tpv.pay(amountToPay.value); }; - -onUserId(getDebt); -