Debian Codegraph @

addons/point_of_sale/views/pos_session_sales_details.xml

raw symbols SCIP
1 <?xml version="1.0" encoding="utf-8"?>
2 <odoo>
3 <data>
4 <template id="pos_session_sales_details">
5 <div class="page">
6 <div class="bg-secondary p-3" id="header">
7 <div class="row">
8 <div class="col-3 d-flex flex-column justify-content-center">
9 <br/>
10 <br/>
11 <div class="text-start" style="font-size:0.85rem;">
12 <span t-esc="company.name"/>
13 <address class="mb-0 text-muted" t-field="env.company.partner_id" t-options='{"widget": "contact", "fields": ["address"], "no_marker": True}'/>
14 </div>
15 </div>
16 <div class="col-6 text-center">
17 <h2 t-if="state == 'closed' or state == 'opened'" id="daily_report_title">Daily Sales Report
18 <t t-if="state == 'closed'">Z</t>
19 <t t-else="">X</t>
20 </h2>
21 <t t-if="session_name">
22 Session ID: <span t-out="session_name">987657</span>
23 </t>
24 </div>
25 </div>
26 </div>
27 <div class="row">
28 <div class="col-12 text-end mt-2">
29 <span class="badge bg-light text-dark border border-dark p-2">
30 <t t-set="date_format" t-value="env['res.lang']._get_data(code=env.user.lang).date_format"/>
31 <strong> As of <span t-esc="context_timestamp(datetime.datetime.now()).strftime(date_format)"/>
32 </strong>
33 </span>
34 </div>
35 </div>
36 <div class="text-center" style="break-inside: avoid;">
37 <t t-if="state == 'multiple'">
38 <h2>Sales Details</h2>
39 <div class="oe_structure"></div>
40 <t t-if="config_names">
41 <strong>Config names</strong>
42 <t t-foreach="config_names" t-as="name">
43 <span t-out="name">Sample Config Name</span>,
44 </t>
45 </t>
46 </t>
47 <t t-if="date_start and date_stop">
48 <span t-out="date_start" t-options="{'widget': 'datetime'}">2-03-2000 9:00 AM</span> - <span t-out="date_stop" t-options="{'widget': 'datetime'}">Demo 3-03-2000 5:00 PM</span>
49 </t>
50 </div>
51 <br/>
52 <br/>
53 <div class="oe_structure"></div>
54 <!-- Orderlines -->
55 <div t-if="products" id="sales">
56 <h6 class="bg-secondary p-1 fw-bold">Sales</h6>
57 <div class="oe_structure"></div>
58 <table class="table table-sm table-borderless" >
59 <tbody>
60 <tr t-foreach="products" t-as="category" class="border-bottom border-secondary">
61 <td class="ps-2 fw-bold"><span t-out="category['name']">Technical Stuffs</span></td>
62 <td class="fw-bold"/>
63 <td class="fw-bold"/>
64 <td class="text-end fw-bold" ><span t-out="category['qty']">5</span></td>
65 <td class="text-end fw-bold">
66 <t t-if="currency['position']">
67 <span t-out="category['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">10000.00</span><span t-out='currency["symbol"]'>$</span>
68 </t>
69 <t t-else="" >
70 <span t-out='currency["symbol"]'>$</span><span t-out="category['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">10000.00</span>
71 </t>
72 </td>
73 <tr t-foreach="category['products']" t-as="line" class="border-bottom border-secondary">
74 <td class="ps-5"><span t-out="line['product_name']">Laptop model x</span><span t-if="line['combo_products_label']" t-out="line['combo_products_label']"/></td>
75 <td/>
76 <td class="text-end">
77 <t t-if="line['barcode']">
78 <img t-att-src="'/report/barcode/Code128/'+line['barcode']" style="width:230px; height:23px" alt="Barcode"/>
79 </t>
80 </td>
81 <td class="text-end">
82 <span t-out="line['quantity']">5</span>
83 <t t-if='line["uom"] != "Units"'>
84 <span t-out='line["uom"]'>Unit</span>
85 </t>
86 </td>
87 <td class="text-end">
88 <t t-if="currency['position']">
89 <span t-out='line["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">567789</span><span t-out='currency["symbol"]'>$</span>
90 </t>
91 <t t-else="" >
92 <span t-out='currency["symbol"]'>$</span><span t-out='line["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">567789</span>
93 </t>
94
95 <t t-if='line["discount"] != 0'>
96 Disc: <span t-out='line["discount"]'>45</span>%
97 </t>
98 </td>
99 </tr>
100 </tr>
101 <tr>
102 <td><strong>Total</strong></td>
103 <td/>
104 <td/>
105 <td class="text-end"><strong><span t-out="products_info['qty']">5</span></strong></td>
106 <td class="text-end">
107 <t t-if="currency['position']">
108 <strong><span t-out='products_info["total"]' t-options="{'widget': 'float', 'precision': currency['precision']}">10000</span><span t-out='currency["symbol"]'>$</span></strong>
109 </t>
110 <t t-else="" >
111 <strong><span t-out='currency["symbol"]'>$</span><span t-out='products_info["total"]' t-options="{'widget': 'float', 'precision': currency['precision']}">1000</span></strong>
112 </t>
113 </td>
114 </tr>
115 </tbody>
116 </table>
117 </div>
118 <div class="oe_structure"></div>
119 <div t-if="taxes" id="taxe_sales" style="page-break-inside: avoid;">
120 <h6 class="bg-secondary p-1 fw-bold w-50 ms-auto">Taxes on sales</h6>
121 <table class="table table-sm table-borderless w-50 ms-auto" >
122 <tbody>
123 <tr t-foreach='taxes' t-as='tax' class="border-bottom border-secondary">
124 <td class="ps-2 fw-bold"><span t-out="tax['name']">Demo Name</span></td>
125 <td class="text-end">
126 <t t-if="currency['position']">
127 <span t-out="tax['tax_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span>
128 </t>
129 <t t-else="" >
130 <span t-out='currency["symbol"]'>$</span><span t-out="tax['tax_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span>
131 </t>
132
133 </td>
134 <td class="text-end">
135 <t t-if="currency['position']">
136 <span t-out="tax['base_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span>
137 </t>
138 <t t-else="" >
139 <span t-out='currency["symbol"]'>$</span><span t-out="tax['base_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span>
140 </t>
141 </td>
142 </tr>
143 <tr>
144 <td><strong>Total</strong></td>
145 <td class="text-end">
146 <t t-if="currency['position']">
147 <strong><span t-out='taxes_info["tax_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span></strong>
148 </t>
149 <t t-else="" >
150 <strong><span t-out='currency["symbol"]'>$</span><span t-out='taxes_info["tax_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span></strong>
151 </t>
152 </td>
153 <td class="text-end">
154 <t t-if="currency['position']">
155 <strong><span t-out='taxes_info["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span></strong>
156 </t>
157 <t t-else="" >
158 <strong><span t-out='currency["symbol"]'>$</span><span t-out='taxes_info["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span></strong>
159 </t>
160 </td>
161 </tr>
162 </tbody>
163 </table>
164 <div class="oe_structure"></div>
165 </div>
166 <div t-if="refund_products" id="refunds">
167 <h6 class="bg-secondary p-1 fw-bold">Refunds</h6>
168 <table class="table table-sm table-borderless" >
169 <tbody>
170 <tr t-foreach="refund_products" t-as="category" class="border-bottom border-secondary">
171 <td class="ps-2 fw-bold"><span t-out="category['name']">Technical Stuff</span></td>
172 <td class="fw-bold"/>
173 <td class="fw-bold"/>
174 <td class="text-end fw-bold">
175 <span t-out="category['qty']">0</span>
176 </td>
177 <td class="text-end fw-bold">
178 <t t-if="currency['position']">
179 <span t-out="category['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span>
180 </t>
181 <t t-else="" >
182 <span t-out='currency["symbol"]'>$</span><span t-out="category['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span>
183 </t>
184 </td>
185 <tr t-foreach="category['products']" t-as="line" class="border-bottom border-secondary">
186 <td class="ps-5"><span t-out="line['product_name']">Laptop</span><span t-if="line['combo_products_label']" t-out="line['combo_products_label']"/></td>
187 <td/>
188 <td class="text-end">
189 <t t-if="line['barcode']">
190 <img t-att-src="'/report/barcode/Code128/'+line['barcode']" style="width:230px; height:23px" alt="Barcode"/>
191 </t>
192 </td>
193 <td class="text-end">
194 <span t-out="line['quantity']">0</span>
195 <t t-if='line["uom"] != "Units"'>
196 <span t-out='line["uom"]'>Unit</span>
197 </t>
198 </td>
199 <td class="text-end">
200 <t t-if="currency['position']">
201 <span t-out='line["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span>
202 </t>
203 <t t-else="" >
204 <span t-out='currency["symbol"]'>$</span><span t-out='line["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span>
205 </t>
206 <t t-if='line["discount"] != 0'>
207 Disc: <span t-out='line["discount"]'>0</span>%
208 </t>
209 </td>
210 </tr>
211 </tr>
212 <tr>
213 <td><strong>Total</strong></td>
214 <td/>
215 <td/>
216 <td class="text-end">
217 <strong><span t-out="refund_info['qty']">0</span></strong>
218 </td>
219 <td class="text-end">
220 <t t-if="currency['position']">
221 <strong><span t-out='refund_info["total"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span><span t-out='currency["symbol"]'>$</span></strong>
222 </t>
223 <t t-else="" >
224 <strong><span t-out='currency["symbol"]'>$</span><span t-out='refund_info["total"]' t-options="{'widget': 'float', 'precision': currency['precision']}">0.00</span></strong>
225 </t>
226 </td>
227 </tr>
228 </tbody>
229 </table>
230 <div class="oe_structure"></div>
231 </div>
232
233 <div t-if="refund_taxes" id="taxe_refunds" style="page-break-inside: avoid;">
234 <h6 class="bg-secondary p-1 fw-bold w-50 ms-auto">Taxes on refunds</h6>
235 <table class="table table-sm table-borderless w-50 ms-auto" >
236 <tbody>
237 <tr t-foreach='refund_taxes' t-as='tax' class="border-bottom border-secondary">
238 <td class="ps-2 fw-bold"><span t-out="tax['name']">Tax Name</span></td>
239 <td class="text-end">
240 <span t-if="currency['position']">
241 <span t-out="tax['tax_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span>
242 </span>
243 <span t-else="">
244 <span t-out='currency["symbol"]'>$</span><span t-out="tax['tax_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span>
245 </span>
246 </td>
247 <td class="text-end">
248 <span t-if="currency['position']">
249 <span t-out="tax['base_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span>
250 </span>
251 <span t-else="">
252 <span t-out='currency["symbol"]'>$</span><span t-out="tax['base_amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span>
253 </span>
254 </td>
255 </tr>
256 <tr>
257 <td><strong>Total</strong></td>
258 <td class="text-end">
259 <span t-if="currency['position']">
260 <strong><span t-out='refund_taxes_info["tax_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span></strong>
261 </span>
262 <span t-else="">
263 <strong><span t-out='currency["symbol"]'>$</span><span t-out='refund_taxes_info["tax_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span></strong>
264 </span>
265 </td>
266 <td class="text-end">
267 <span t-if="currency['position']">
268 <strong><span t-out='refund_taxes_info["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span></strong>
269 </span>
270 <span t-else="">
271 <strong><span t-out='currency["symbol"]'>$</span><span t-out='refund_taxes_info["base_amount"]' t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span></strong>
272 </span>
273 </td>
274 </tr>
275 </tbody>
276 </table>
277 <div class="oe_structure"></div>
278 </div>
279 <div class="oe_structure"></div>
280 <div t-if="payments" id="payments" style="page-break-inside: avoid;">
281 <t t-if="payments" id="other_payments">
282 <h6 class="bg-secondary p-1 fw-bold w-50 ms-auto">Payments</h6>
283 <table class="table table-sm table-borderless w-50 ms-auto" >
284 <tbody>
285 <tr t-foreach='payments' t-as='payment'>
286 <td class="ps-2 fw-bold" ><span t-out="payment['name']">Payment Name Demo</span></td>
287 <td class="text-end">
288 <span t-if="currency['position']">
289 <span t-out="payment['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span>
290 </span>
291 <span t-else="">
292 <span t-out='currency["symbol"]'>$</span><span t-out="payment['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span>
293 </span>
294 </td>
295 </tr>
296 </tbody>
297 </table>
298 <table class="table table-sm table-borderless w-50 ms-auto border-top">
299 <tr class="fs-5">
300 <th class="ps-2 fw-bolder">Total</th>
301 <th class="text-end fw-bolder">
302 <t t-if="currency['position']">
303 <span t-out="currency['total_paid']" t-options="{'widget': 'float', 'precision': currency['precision']}">11.11</span><span t-out="currency['symbol']">$</span>
304 </t>
305 <t t-else="">
306 <span t-out="currency['symbol']">$</span><span t-out="currency['total_paid']" t-options="{'widget': 'float', 'precision': currency['precision']}">11.11</span>
307 </t>
308 </th>
309 </tr>
310 <tr t-if="show_payment_per_method" t-foreach="payments_per_method" t-as="ppm">
311 <td class="ps-2 fw-bold" ><t t-out="ppm['name']"/></td>
312 <td class="text-end">
313 <t t-if="currency['position']">
314 <span t-out="ppm['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">38.83</span><span t-out="currency['symbol']">$</span>
315 </t>
316 <t t-else="">
317 <span t-out="currency['symbol']">$</span><span t-out="ppm['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">38.83</span>
318 </t>
319 </td>
320 </tr>
321 </table>
322 <div class="oe_structure"></div>
323 </t>
324 </div>
325 <div id="discounts" style="break-inside: avoid; page-break-inside: avoid;">
326 <h6 class="bg-secondary p-1 fw-bold">Discounts</h6>
327 <div class="row">
328 <div class="col-12">
329 <strong>Number of discounts</strong>: <span t-out="discount_number">5</span>
330 </div>
331 </div>
332 <div class="row">
333 <div class="col-12">
334 <strong>Amount of discounts</strong>:
335 <span t-if="currency['position']">
336 <span t-out="discount_amount" t-options="{'widget': 'float', 'precision': currency['precision']}">50.00</span>
337 <span t-out='currency["symbol"]'>$</span>
338 </span>
339 <span t-else="">
340 <span t-out='currency["symbol"]'>$</span>
341 <span t-out="discount_amount" t-options="{'widget': 'float', 'precision': currency['precision']}">50.00</span>
342 </span>
343 </div>
344 </div>
345 <br/>
346 </div>
347 <div class="oe_structure"></div>
348
349
350 <div t-if="invoiceTotal" id="invoices">
351 <br/>
352 <h6 class="bg-secondary p-1 fw-bold">Invoices</h6>
353 <table class="table table-sm table-borderless" >
354 <tbody>
355 <t t-foreach="invoiceList" t-as="invoiceSession" class="border-bottom border-secondary">
356 <t t-if="invoiceSession['invoices']">
357 <tr t-foreach='invoiceSession["invoices"]' t-as='invoice'>
358 <td class="ps-2 fw-bold"><span t-out="invoice['name']">Invoice Name</span></td>
359 <td><span t-out="invoice['order_ref']">Order Ref</span></td>
360 <td class="text-end">
361 <span t-if="currency['position']">
362 <span t-out="invoice['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span>
363 </span>
364 <span t-else="">
365 <span t-out='currency["symbol"]'>$</span><span t-out="invoice['total']" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span>
366 </span>
367 </td>
368 </tr>
369 </t>
370 </t>
371 <tr>
372 <td><strong>Total</strong></td>
373 <td/>
374 <td class="text-end"><strong>
375 <span t-if="currency['position']">
376 <span t-out="invoiceTotal" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span><span t-out='currency["symbol"]'>$</span>
377 </span>
378 <span t-else="">
379 <span t-out='currency["symbol"]'>$</span><span t-out="invoiceTotal" t-options="{'widget': 'float', 'precision': currency['precision']}">123.45</span>
380 </span>
381 </strong></td>
382 </tr>
383 </tbody>
384 </table>
385 </div>
386 <div class="oe_structure"></div>
387 <t id="closing_session">
388 <h6 class="bg-secondary p-1 fw-bold">Session Control</h6>
389 <div class="oe_structure"></div>
390 <div style="break-inside: avoid;">
391 <strong>Total:
392 <span t-if="currency['position']">
393 <span t-out='currency["total_paid"]' t-options="{'widget': 'float', 'precision': currency['precision']}">99.99</span><span t-out='currency["symbol"]'>$</span>
394 </span>
395 <span t-else="">
396 <span t-out='currency["symbol"]'>$</span><span t-out='currency["total_paid"]' t-options="{'widget': 'float', 'precision': currency['precision']}">99.99</span>
397 </span>
398 </strong>
399 <br/>
400 <strong>Number of transactions: <span t-out="nbr_orders">10</span></strong>
401 </div>
402 <br/>
403 <div class="oe_structure"></div>
404 <table class="table table-sm table-borderless" >
405 <thead><tr>
406 <th class="text-start">Name</th>
407 <th/>
408 <th class="text-end">Expected</th>
409 <th t-if="(state == 'closed' or state == 'multiple') and payments" class="text-end">Counted</th>
410 <th t-if="(state == 'closed' or state == 'multiple') and payments" class="text-end">Difference</th>
411 </tr></thead>
412 <tbody>
413 <t t-foreach="payments" t-as="method">
414 <t t-if="method['count']">
415 <tr>
416 <td><strong><span t-out="method['name']">Cash</span></strong></td>
417 <td/>
418 <td class="text-end">
419 <span t-if="currency['position']">
420 <span t-out="method['final_count']" t-options="{'widget': 'float', 'precision': currency['precision']}">100.00</span><span t-out='currency["symbol"]'>$</span>
421 </span>
422 <span t-else="">
423 <span t-out='currency["symbol"]'>$</span><span t-out="method['final_count']" t-options="{'widget': 'float', 'precision': currency['precision']}">100.00</span>
424 </span>
425 </td>
426 <td t-if="(state == 'closed' or state == 'multiple') and payments" class="text-end">
427 <span t-if="currency['position']">
428 <span t-out="method['money_counted']" t-options="{'widget': 'float', 'precision': currency['precision']}">95.00</span><span t-out='currency["symbol"]'>$</span>
429 </span>
430 <span t-else="">
431 <span t-out='currency["symbol"]'>$</span><span t-out="method['money_counted']" t-options="{'widget': 'float', 'precision': currency['precision']}">95.00</span>
432 </span>
433 </td>
434 <td t-if="(state == 'closed' or state == 'multiple') and payments" class="text-end">
435 <span t-if="currency['position']">
436 <span t-out="method['money_difference']" t-options="{'widget': 'float', 'precision': currency['precision']}">5.00</span><span t-out='currency["symbol"]'>$</span>
437 </span>
438 <span t-else="">
439 <span t-out='currency["symbol"]'>$</span><span t-out="method['money_difference']" t-options="{'widget': 'float', 'precision': currency['precision']}">5.00</span>
440 </span>
441 </td>
442 </tr>
443 <tr t-if="(state == 'closed' or state == 'multiple') and payments" t-foreach="method['cash_moves']" t-as="move">
444 <td/>
445 <td><span t-out="move['name']">Cash Move 1</span></td>
446 <td class="text-end">
447 <span t-if="currency['position']">
448 <span t-out="move['amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">50.00</span><span t-out='currency["symbol"]'>$</span>
449 </span>
450 <span t-else="">
451 <span t-out='currency["symbol"]'>$</span><span t-out="move['amount']" t-options="{'widget': 'float', 'precision': currency['precision']}">50.00</span>
452 </span>
453 </td>
454 <td></td>
455 <td></td>
456 </tr>
457 </t>
458 </t>
459 </tbody>
460 </table>
461 <div class="oe_structure"></div>
462 <div t-if="opening_note or closing_note" style="break-inside: avoid;">
463 <br/>
464 <br/>
465 <span t-if="opening_note" id="opening_note">
466 <strong>Opening of session note:</strong>
467 <span t-out="opening_note" t-options="{'widget': 'text'}">Sample Opening Note</span>
468 </span>
469 <br/>
470 <span t-if="closing_note" id="closing_note">
471 <strong>End of session note:</strong>
472 <span t-out="closing_note" t-options="{'widget': 'text'}">Sample Closing Note</span>
473 </span>
474 </div>
475 </t>
476 <div id="end_report" style="page-break-after: always;"/>
477 </div>
478 </template>
479 </data>
480 </odoo>