factura_venta_detachi.xml 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <openerp>
  3. <data>
  4. <report id="factura_venta_detachi"
  5. model="account.invoice"
  6. string="Factura Legal"
  7. report_type="qweb-html"
  8. name="factura_venta_detachi.report_factura_detachi"
  9. file="factura_venta_detachi.report_factura_detachi"
  10. />
  11. <template id="report_header_custom" inherit_id="report.external_layout_header">
  12. <xpath expr="//div[@class='header']" position="replace">
  13. <div class ="header">
  14. </div>
  15. </xpath>
  16. </template>
  17. <template id="external_layout_footer" inherit_id="report.external_layout_footer">
  18. <xpath expr="//div[@class='footer']" position="replace">
  19. <div class ="footer">
  20. </div>
  21. </xpath>
  22. </template>
  23. <template id="report_factura_detachi">
  24. <t t-call="report.html_container">
  25. <t t-call="report.external_layout">
  26. <t t-foreach="[1,2,3]" t-as="i">
  27. <div class="page">
  28. <style type="text/css">
  29. body{
  30. font-size: 2.67mm;
  31. font-family: Arial, Helvetica, sans-serif;
  32. }
  33. div{
  34. padding: 0px;
  35. }
  36. .pagina{
  37. width:19.3cm;
  38. }
  39. .logo{
  40. height: 0.25cm;
  41. width: 100%;
  42. top: 0px;
  43. }
  44. .fecha_emision_data{
  45. width: 11cm;
  46. font-size: 2.4mm;
  47. padding-left: 9.4cm;
  48. float: left;
  49. min-height: 0.6cm;
  50. }
  51. .contado_x{
  52. width: 0.5cm;
  53. float: left;
  54. padding-left: 1.72cm;
  55. min-height: 0.6cm;
  56. }
  57. .credito_x{
  58. width: 0.5cm;
  59. float: left;
  60. padding-left: 1.0cm;
  61. min-height: 0.6cm;
  62. }
  63. .linea2{
  64. position: relative;
  65. top: -0.12cm;
  66. min-height: 0.4cm;
  67. }
  68. .razon_data{
  69. width: 14.8cm;
  70. float: left;
  71. padding-left: 10.5cm;
  72. min-height: 0.5cm;
  73. }
  74. .linea3{
  75. position: relative;
  76. top: -0.12cm;
  77. min-height: 0.4cm;
  78. }
  79. .direccion_data{
  80. width: 14.1cm;
  81. font-size: 2.4mm;
  82. font-family: Arial, Helvetica, sans-serif;
  83. float: left;
  84. padding-left: 10.2cm;
  85. min-height: 0.5cm;
  86. }
  87. .linea4{
  88. position: relative;
  89. top: -0.12cm;
  90. min-height: 0.4cm;
  91. }
  92. .ruc_data{
  93. width: 10.7cm;
  94. font-size: 2.4mm;
  95. font-family: Arial, Helvetica, sans-serif;
  96. float: left;
  97. padding-left: 9.3cm;
  98. min-height: 0.4cm;
  99. }
  100. .telefono_data{
  101. width: 6.8cm;
  102. font-size: 2.4mm;
  103. font-family: Arial, Helvetica, sans-serif;
  104. float: left;
  105. padding-left: 2.6cm;
  106. min-height: 0.5cm;
  107. }
  108. .linea5{
  109. position: relative;
  110. top: -0.12cm;
  111. min-height: 0.4cm;
  112. }
  113. .nota_remision_data{
  114. width: 8.3cm;
  115. float: left;
  116. padding-left: 2.5cm;
  117. min-height: 0.5cm;
  118. }
  119. .cab-articulos{
  120. height: 0.7cm;
  121. clear: both;
  122. }
  123. .articulos{
  124. height: 3.65cm;
  125. }
  126. .art-col1{
  127. width:1.3cm;
  128. text-align: center;
  129. }
  130. .art-col2{
  131. padding-left: 0.8cm;
  132. width:1cm;
  133. text-align: center;
  134. }
  135. .art-col3{
  136. padding-left: 0.6cm;
  137. width:9.1cm;
  138. }
  139. .art-col4{
  140. width:1.9cm;
  141. text-align: right;
  142. }
  143. .art-col5{
  144. width:2.2cm;
  145. text-align: right;
  146. }
  147. .art-col6{
  148. width:2.5cm;
  149. text-align: right;
  150. }
  151. .art-col7{
  152. width:1.9cm;
  153. text-align: right;
  154. }
  155. .logo1{
  156. height: 4.15cm;
  157. width: 100%;
  158. top: 0px;
  159. }
  160. .logo2{
  161. height: 4.10cm;
  162. width: 100%;
  163. top: 0px;
  164. }
  165. .subtotal_data{
  166. width: 6cm;
  167. float: left;
  168. padding-top: 0.002cm;
  169. padding-left: 2.3cm;
  170. min-height: 0.2cm;
  171. }
  172. .subtotal_excentas{
  173. width: 1.8cm;
  174. float: left;
  175. text-align: right;
  176. padding-left: 10cm;
  177. padding-top: 0.7cm;
  178. min-height: 0.2cm;
  179. }
  180. .subtotal_5{
  181. width: 1cm;
  182. float: left;
  183. padding-left: 1cm;
  184. text-align: right;
  185. padding-top: 0.7cm;
  186. min-height: 0.2cm;
  187. }
  188. .subtotal_10{
  189. width: 2.3cm;
  190. float: left;
  191. padding-left: 0.8cm;
  192. text-align: left;
  193. padding-top: 0.7cm;
  194. min-height: 0.2cm;
  195. }
  196. .total_pagar_data{
  197. width: 16.4cm;
  198. float: left;
  199. padding-top: 0.01mm;
  200. padding-left: 4.8cm;
  201. min-height: 0.3cm;
  202. }
  203. .total_pagar{
  204. width: 2.3cm;
  205. float: right;
  206. padding-top: 0.01mm;
  207. padding-left: 0.8cm;
  208. min-height: 0.3cm;
  209. }
  210. .iva_5_data{
  211. width: 5cm;
  212. float: left;
  213. padding-left: 4.7cm;
  214. min-height: 0.25cm;
  215. }
  216. .iva_10_data{
  217. width: 5.2cm;
  218. float: left;
  219. padding-left: 2.1cm;
  220. min-height: 0.25cm;
  221. }
  222. .iva_total_data{
  223. width: 7cm;
  224. float: left;
  225. padding-left: 3.6cm;
  226. min-height: 0.25cm;
  227. }
  228. </style>
  229. <t t-foreach="docs" t-as="o">
  230. <div class="pagina">
  231. <div class="logo"> </div>
  232. <div class="linea1">
  233. <div class="fecha_emision_data"><span t-field="o.date_invoice" t-field-options='{"format": "dd MMM yyyy"}'/></div>
  234. <div class="contado_x">
  235. <t t-if="o.contado == True">X</t>
  236. <t t-if="o.contado == False"></t>
  237. </div>
  238. <div class="credito_x">
  239. <t t-if="o.credito == True">X</t>
  240. <t t-if="o.credito == False"></t>
  241. </div>
  242. </div>
  243. <div class="linea2">
  244. <div class="razon_data"><span t-field="o.partner_id.name"/></div>
  245. </div>
  246. <div class="linea3">
  247. <div class="direccion_data">
  248. <t t-f="o.partner_id.street"><span t-field="o.partner_id.street"/> <span t-field="o.partner_id.street2"/></t>
  249. <t t-f="not o.partner_id.street"> </t>
  250. </div>
  251. </div>
  252. <div class="linea4">
  253. <div class="ruc_data"><span t-field="o.partner_id.ruc"/></div>
  254. <div class="telefono_data"><span t-field="o.partner_id.phone"/></div>
  255. </div>
  256. <div class="linea5">
  257. <div class="nota_remision_data"> </div>
  258. </div>
  259. <div class="cab-articulos"> </div>
  260. <div class="articulos">
  261. <table class="tab-articulos">
  262. <tr t-foreach="o.invoice_line" t-as="l">
  263. <td class="art-col1"><span t-field="l.product_id.default_code"/></td>
  264. <td class="art-col2"><span t-esc="'%.0f'%l.quantity"/></td>
  265. <td class="art-col3"><span t-field="l.product_id.name"/></td>
  266. <td class="art-col4"><span t-esc="'{0:,.0f}'.format(l.price_unit)"/></td>
  267. <td class="art-col5"> </td>
  268. <td class="art-col6"> </td>
  269. <td class="art-col7"><span t-esc="'{0:,.0f}'.format((l.quantity * l.price_unit))"/></td>
  270. </tr>
  271. </table>
  272. </div>
  273. <div class="subtotal_data"> </div>
  274. <div class="subtotal_excentas"> </div>
  275. <div class="subtotal_5"> </div>
  276. <td style="font-size:7.0px;">
  277. <div class="subtotal_10"><span t-esc="'{0:,.0f}'.format(o.amount_total)"/></div>
  278. </td>
  279. <div class="total_pagar_data">Gs.: <span t-esc="convertir(o.amount_total,o.currency_id.en_letras)"/></div>
  280. <div class="total_pagar"><span t-esc="'{0:,.0f}'.format(o.amount_total)"/></div>
  281. <div class="iva_5_data"> </div>
  282. <div class="iva_10_data"><span t-esc="'{0:,.0f}'.format(o.amount_tax)"/></div>
  283. <div class="iva_total_data"><span t-esc="'{0:,.0f}'.format(o.amount_tax)"/></div>
  284. </div>
  285. <t t-if="i == 1">
  286. <div class="logo1"> </div>
  287. </t>
  288. <t t-if="i == 2">
  289. <div class="logo2"> </div>
  290. </t>
  291. </t>
  292. </div>
  293. </t>
  294. </t>
  295. </t>
  296. </template>
  297. </data>
  298. </openerp>