You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

239 lines
9.5 KiB

3 years ago
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <templates id="template" xml:space="preserve">
  3. <t t-extend="ConfirmationScreen">
  4. <t t-jquery='.pos-bottom-confirm' t-operation='replace'>
  5. <div class="pos-bottom pos-bottom-confirm">
  6. <div class="pos-confirm-screen">
  7. <p class="text-center">Merci.<br/>
  8. Vous pouvez passer en caisse</p>
  9. <div class='back-presentation'>
  10. <img class="logo-scan mb-3" src="/vracoop_pos_free_balance_v2/static/src/img/picto-confirm.png" />
  11. </div>
  12. <h1 class='product-name'><t t-esc="widget.get_product_name()" /></h1>
  13. <div class='product-price'>
  14. à <t t-esc="widget.format_currency(widget.get_product_price()) + '/' + widget.get_product_uom()" />
  15. </div>
  16. <div class="centered-content touch-scrollable">
  17. <div class="button print">
  18. <i class='fa fa-print'></i> Imprimer le ticket
  19. </div>
  20. <div class="pos-ticket-container">
  21. </div>
  22. </div>
  23. </div>
  24. </div>
  25. </t>
  26. </t>
  27. <t t-name="PosTicketBls">
  28. <div class="pos-sale-ticket" t-attf-style="width:#{width}">
  29. <div class="pos-center-align title-mag">Rayon vrac</div>
  30. <br />
  31. <div class="pos-center-align title-product"><t t-esc="transaction.name"/></div>
  32. <br />
  33. <br />
  34. <table class='ticket-info pos-center-align'>
  35. <tr class="title-info">
  36. <td>Prix Unitaire</td>
  37. <td>Poids Net</td>
  38. </tr>
  39. <tr>
  40. <td><span><t t-esc="transaction.price_product"/></span> €/kg</td>
  41. <td><span><t t-esc="transaction.weight_net"/></span> kg</td>
  42. </tr>
  43. </table>
  44. <br />
  45. <br />
  46. <table class='ticket-total pos-center-align'>
  47. <tr class="title-info">
  48. <td>Prix Total
  49. </td>
  50. </tr>
  51. <tr>
  52. <td><span><t t-esc="transaction.price_net"/></span>
  53. </td>
  54. </tr>
  55. </table>
  56. <br />
  57. <br />
  58. <table class='pos-center-align'>
  59. <tr class="title-info bloc-barcode">
  60. <td>
  61. <img t-att-src="'/report/barcode/EAN13/' + widget.get_barcode_data()" />
  62. <span class="caption"><t t-esc="num_ean13"/></span>
  63. </td>
  64. </tr>
  65. </table>
  66. </div>
  67. </t>
  68. <t t-name="XmlReceiptBls">
  69. <receipt align='center' width='40' value-thousands-separator='' >
  70. <t t-if='receipt.company.logo'>
  71. <img t-att-src='receipt.company.logo' alt="Logo"/>
  72. <br/>
  73. </t>
  74. <t t-if='!receipt.company.logo'>
  75. <h1><t t-esc='receipt.company.name' /></h1>
  76. <br/>
  77. </t>
  78. <div font='b'>
  79. <t t-if='receipt.company.contact_address'>
  80. <div><t t-esc='receipt.company.contact_address' /></div>
  81. </t>
  82. <t t-if='receipt.company.phone'>
  83. <div>Tel:<t t-esc='receipt.company.phone' /></div>
  84. </t>
  85. <t t-if='receipt.company.vat'>
  86. <div>VAT:<t t-esc='receipt.company.vat' /></div>
  87. </t>
  88. <t t-if='receipt.company.email'>
  89. <div><t t-esc='receipt.company.email' /></div>
  90. </t>
  91. <t t-if='receipt.company.website'>
  92. <div><t t-esc='receipt.company.website' /></div>
  93. </t>
  94. <t t-if='receipt.header_xml'>
  95. <t t-raw='receipt.header_xml' />
  96. </t>
  97. <t t-if='!receipt.header_xml and receipt.header'>
  98. <div><t t-esc='receipt.header' /></div>
  99. </t>
  100. <t t-if='receipt.cashier'>
  101. <div class='cashier'>
  102. <div>--------------------------------</div>
  103. <div>Served by <t t-esc='receipt.cashier' /></div>
  104. </div>
  105. </t>
  106. </div>
  107. <br /><br />
  108. <!-- Orderlines -->
  109. <div class='orderlines' line-ratio='0.6'>
  110. <t t-foreach='receipt.orderlines' t-as='line'>
  111. <t t-set='simple' t-value='line.discount === 0 and line.unit_name === "Unit(s)" and line.quantity === 1' />
  112. <t t-if='simple'>
  113. <line>
  114. <left><t t-esc='line.product_name_wrapped[0]' /></left>
  115. <right><value t-att-value-decimals='pos.currency.decimals'><t t-esc='line.price_display' /></value></right>
  116. </line>
  117. <t t-call="XmlReceiptWrappedProductNameLines"/>
  118. </t>
  119. <t t-if='!simple'>
  120. <line><left><t t-esc='line.product_name_wrapped[0]' /></left></line>
  121. <t t-call="XmlReceiptWrappedProductNameLines"/>
  122. <t t-if='line.discount !== 0'>
  123. <line indent='1'><left>Discount: <t t-esc='line.discount' />%</left></line>
  124. </t>
  125. <line indent='1'>
  126. <left>
  127. <value t-att-value-decimals='pos.dp["Product Unit of Measure"]' value-autoint='on'>
  128. <t t-esc='line.quantity' />
  129. </value>
  130. <t t-if='line.unit_name !== "Unit(s)"'>
  131. <t t-esc='line.unit_name' />
  132. </t>
  133. x
  134. <value t-att-value-decimals='pos.dp["Product Price"]'>
  135. <t t-esc='line.price' />
  136. </value>
  137. </left>
  138. <right>
  139. <value t-att-value-decimals='pos.currency.decimals'><t t-esc='line.price_display' /></value>
  140. </right>
  141. </line>
  142. </t>
  143. </t>
  144. </div>
  145. <!-- Subtotal -->
  146. <t t-set='taxincluded' t-value='Math.abs(receipt.subtotal - receipt.total_with_tax) &lt;= 0.000001' />
  147. <t t-if='!taxincluded'>
  148. <line><right>--------</right></line>
  149. <line><left>Subtotal</left><right><t t-esc="widget.format_currency(receipt.subtotal)" /></right></line>
  150. <t t-foreach='receipt.tax_details' t-as='tax'>
  151. <line>
  152. <left><t t-esc='tax.name' /></left>
  153. <right><t t-esc='tax.amount' /></right>
  154. </line>
  155. </t>
  156. </t>
  157. <!-- Total -->
  158. <line><right>--------</right></line>
  159. <line class='total' size='double-height'>
  160. <left><pre> TOTAL</pre></left>
  161. <right><t t-esc='widget.format_currency(receipt.total_with_tax)' /></right>
  162. </line>
  163. <br/><br/>
  164. <!-- Payment Lines -->
  165. <t t-foreach='paymentlines' t-as='line'>
  166. <line>
  167. <left><t t-esc='line.name' /></left>
  168. <right><value t-att-value-decimals='pos.currency.decimals'><t t-esc='line.get_amount()'/></value></right>
  169. </line>
  170. </t>
  171. <br/>
  172. <line size='double-height'>
  173. <left><pre> CHANGE</pre></left>
  174. <right><t t-esc='widget.format_currency(receipt.change)' /></right>
  175. </line>
  176. <br/>
  177. <!-- Extra Payment Info -->
  178. <t t-if='receipt.total_discount'>
  179. <line>
  180. <left>Discounts</left>
  181. <right><t t-esc='widget.format_currency(receipt.total_discount)'/></right>
  182. </line>
  183. </t>
  184. <t t-if='taxincluded'>
  185. <t t-foreach='receipt.tax_details' t-as='tax'>
  186. <line>
  187. <left><t t-esc='tax.name' /></left>
  188. <right><t t-esc='widget.format_currency(tax.amount)' /></right>
  189. </line>
  190. </t>
  191. <line>
  192. <left>Total Taxes</left>
  193. <right><t t-esc='widget.format_currency(receipt.total_tax)'/></right>
  194. </line>
  195. </t>
  196. <div class='before-footer' />
  197. <!-- Footer -->
  198. <t t-if='receipt.footer_xml'>
  199. <t t-raw='receipt.footer_xml' />
  200. </t>
  201. <t t-if='!receipt.footer_xml and receipt.footer'>
  202. <br/>
  203. <t t-esc='receipt.footer' />
  204. <br/>
  205. <br/>
  206. </t>
  207. <div class='after-footer' />
  208. <br/>
  209. <div font='b'>
  210. <div><t t-esc='receipt.name' /></div>
  211. <div><t t-esc='receipt.date.localestring' /></div>
  212. </div>
  213. </receipt>
  214. </t>
  215. </templates>