diff --git a/src/components/ui/VnUsesMana.vue b/src/components/ui/VnUsesMana.vue index 1ad4a706e..cb066b235 100644 --- a/src/components/ui/VnUsesMana.vue +++ b/src/components/ui/VnUsesMana.vue @@ -53,3 +53,8 @@ const manaCode = ref(props.manaCode); /> + + es: + Promotion mana: Maná promoción + Claim mana: Maná reclamación + diff --git a/src/pages/Ticket/Card/TicketEditMana.vue b/src/pages/Ticket/Card/TicketEditMana.vue index 693875712..a55658a07 100644 --- a/src/pages/Ticket/Card/TicketEditMana.vue +++ b/src/pages/Ticket/Card/TicketEditMana.vue @@ -47,7 +47,10 @@ const cancel = () => {
Mana: {{ toCurrency(mana) }}
- + +
+ +
{{ t('New price') }} @@ -56,9 +59,6 @@ const cancel = () => {
-
- -
route.params.id, - () => tableRef.value.reload() + () => tableRef.value.reload(), ); const columns = computed(() => [ @@ -132,7 +132,7 @@ const columns = computed(() => [ align: 'left', label: t('globals.amount'), name: 'amount', - format: (row) => parseInt(row.amount * row.quantity), + format: (row) => toCurrency(getSaleTotal(row)), }, { align: 'left', @@ -199,7 +199,7 @@ const changeQuantity = async (sale) => { await updateQuantity(sale); } catch (e) { const { quantity } = tableRef.value.CrudModelRef.originalData.find( - (s) => s.id === sale.id + (s) => s.id === sale.id, ); sale.quantity = quantity; throw e; @@ -330,8 +330,7 @@ const updateDiscount = async (sales, newDiscount = null) => { }; await axios.post(`Tickets/${route.params.id}/updateDiscount`, params); notify('globals.dataSaved', 'positive'); - for (let sale of sales) sale.discount = _newDiscount; - edit.value = { ...DEFAULT_EDIT }; + tableRef.value.reload(); }; const getNewPrice = computed(() => { @@ -503,7 +502,7 @@ async function isSalePrepared(item) { componentProps: { title: t('Item prepared'), message: t( - 'This item is already prepared. Do you want to continue?' + 'This item is already prepared. Do you want to continue?', ), data: item, }, @@ -525,7 +524,7 @@ watch( if (newItemFk) { updateItem(newRow.value); } - } + }, ); @@ -595,7 +594,7 @@ watch( openConfirmationModal( t('Continue anyway?'), t('You are going to delete lines of the ticket'), - removeSales + removeSales, ) " > @@ -833,21 +832,24 @@ watch( :mana-code="manaCode" @save="changeDiscount(row)" > - -
- -
+ {{ toPercentage(row.discount / 100) }} -