Debian Codegraph @

addons/pos_restaurant/static/src/app/screens/payment_screen/payment_screen.xml

raw
1 <?xml version="1.0" encoding="UTF-8"?>
2 <templates id="template" xml:space="preserve">
3
4 <t t-name="pos_restaurant.PaymentScreenValidate" t-inherit="point_of_sale.PaymentScreenValidate" t-inherit-mode="extension">
5 <xpath expr="//button[hasclass('validation-button') and hasclass('next')]" position="attributes">
6 <attribute name="t-att-hidden">pos.config.set_tip_after_payment and !currentOrder.isPaid()</attribute>
7 </xpath>
8
9 <xpath expr="//button[hasclass('validation-button') and hasclass('next')]/span" position="replace">
10 <t t-if="pos.config.set_tip_after_payment and currentOrder.isPaid()">
11 <span class="back_text">Close Tab</span>
12 </t>
13 <t t-else="">$0</t>
14 </xpath>
15 </t>
16 <t t-name="pos_restaurant.PaymentScreenBack" t-inherit="point_of_sale.PaymentScreenBack" t-inherit-mode="extension">
17 <xpath expr="//button[hasclass('button') and hasclass('back')]/span[hasclass('back_text')]" position="replace">
18 <t t-if="pos.config.set_tip_after_payment and currentOrder.isPaid()">
19 <span class="back_text">Keep Open</span>
20 </t>
21 <t t-else="">$0</t>
22 </xpath>
23 </t>
24 <t t-name="pos_restaurant.PaymentScreenDue" t-inherit="point_of_sale.PaymentScreenDue" t-inherit-mode="extension">
25 <xpath expr="//section[hasclass('paymentlines-container')]" position="inside">
26 <div t-if="currentOrder.getCustomerCount() > 1" t-attf-class="message text-center {{ui.isSmall ? 'fs-2' : 'fs-1'}}" >
27 <PriceFormatter price="this.env.utils.formatCurrency(currentOrder.amountPerGuest())" /> / Guest
28 <button class="btn rounded-lg p" t-on-click="clickTableGuests" style="background-color: #ced4da;">
29 <span class="text-black fs-4 fw-bolder" t-esc="currentOrder?.getCustomerCount() || 0"/>
30 </button>
31 </div>
32 </xpath>
33 </t>
34
35 </templates>