|
@@ -0,0 +1,373 @@
|
|
|
+<?xml version="1.0" encoding="utf-8"?>
|
|
|
+<openerp>
|
|
|
+<data>
|
|
|
+
|
|
|
+ <report id="factura_venta_rasil"
|
|
|
+ model="account.invoice"
|
|
|
+ string="Factura Legal"
|
|
|
+ report_type="qweb-html"
|
|
|
+ name="factura_venta_rasil.report_factura_rasil"
|
|
|
+ file="factura_venta_rasil.report_factura_rasil"
|
|
|
+ />
|
|
|
+
|
|
|
+ <template id="report_factura_rasil">
|
|
|
+ <t t-call="report.html_container">
|
|
|
+
|
|
|
+ <t t-foreach="[1,2,3]" t-as="i">
|
|
|
+ <div class="page">
|
|
|
+ <style type="text/css">
|
|
|
+ body{
|
|
|
+ font-size: 2.4mm;
|
|
|
+ font-family: Arial, Helvetica, sans-serif;
|
|
|
+ }
|
|
|
+ div{
|
|
|
+ padding: 0px;
|
|
|
+ }
|
|
|
+ .pagina{
|
|
|
+ width:19.3cm;
|
|
|
+ margin-right: 25px;
|
|
|
+ margin-left: 20px;
|
|
|
+ }
|
|
|
+ .logo{
|
|
|
+ height: 2.7cm;
|
|
|
+ width: 100%;
|
|
|
+ top: 0px;
|
|
|
+ }
|
|
|
+ .fecha_emision_data{
|
|
|
+ width: 13.9cm;
|
|
|
+ padding-left: 3.5cm;
|
|
|
+ float: left;
|
|
|
+
|
|
|
+ }
|
|
|
+ .contado_x{
|
|
|
+ width: 3.0cm;
|
|
|
+ float: left;
|
|
|
+ padding-left: 1.6cm;
|
|
|
+
|
|
|
+ }
|
|
|
+ .linea2{
|
|
|
+ position: relative;
|
|
|
+ top: 0.1cm;
|
|
|
+ min-height: 1.5cm;
|
|
|
+ }
|
|
|
+ .razon_data{
|
|
|
+ width: 11.1cm;
|
|
|
+ float: left;
|
|
|
+ padding-left: 4.5cm;
|
|
|
+
|
|
|
+ }
|
|
|
+ .ruc_data{
|
|
|
+ width: 5.5cm;
|
|
|
+ float: left;
|
|
|
+ padding-left: 3.3cm;
|
|
|
+
|
|
|
+ }
|
|
|
+ .linea3{
|
|
|
+ position: relative;
|
|
|
+ top: 0.05cm;
|
|
|
+ min-height: 0.9cm;
|
|
|
+ }
|
|
|
+ .direccion_data{
|
|
|
+ width: 14cm;
|
|
|
+ float: left;
|
|
|
+ padding-left: 3cm;
|
|
|
+
|
|
|
+ }
|
|
|
+ .telefono_data{
|
|
|
+ width: 6cm;
|
|
|
+ float: left;
|
|
|
+ padding-left: 1.9cm;
|
|
|
+ min-height: 0.4cm;
|
|
|
+ }
|
|
|
+ .divisoria1{
|
|
|
+ height: 0.8cm;
|
|
|
+ width: 100%;
|
|
|
+ top: 0px;
|
|
|
+ }
|
|
|
+ .cab-articulos{
|
|
|
+ height: 0.74cm;
|
|
|
+ clear: both;
|
|
|
+ padding-left: 1.5cm;
|
|
|
+ }
|
|
|
+ .borderless td, .borderless th {
|
|
|
+ border: none !important;
|
|
|
+ }
|
|
|
+ .table-condensed>tbody>tr>td {
|
|
|
+ padding: 1px !important; -->
|
|
|
+
|
|
|
+ }
|
|
|
+ .table-super-condensed>tbody>tr>td {
|
|
|
+ padding: 5px !important;
|
|
|
+ }
|
|
|
+ .logo1{
|
|
|
+ height: 1.55cm;
|
|
|
+ width: 100%;
|
|
|
+ top: 0px;
|
|
|
+ }
|
|
|
+ .logo2{
|
|
|
+ height: 1.80cm;
|
|
|
+ width: 100%;
|
|
|
+ top: 0px;
|
|
|
+ }
|
|
|
+
|
|
|
+ </style>
|
|
|
+ <t t-foreach="docs" t-as="o">
|
|
|
+
|
|
|
+ <div class="pagina">
|
|
|
+ <div class="logo"> </div>
|
|
|
+ <div class="linea1">
|
|
|
+ <div class="fecha_emision_data">San Lorenzo,<span t-field="o.date_invoice" t-field-options='{"format": "dd MMMM yyyy"}'/></div>
|
|
|
+ <div class="contado_x">
|
|
|
+ <t t-if="o.contado">Contado</t><t t-if="o.credito">Crédito</t>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+
|
|
|
+ <div class="linea2">
|
|
|
+ <div class="razon_data"><span t-field="o.partner_id.name"/></div>
|
|
|
+ <div class="ruc_data"><span t-field="o.partner_id.ruc"/></div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="linea3">
|
|
|
+ <div class="direccion_data">
|
|
|
+ <t t-f="o.partner_id.street"><span t-field="o.partner_id.street"/> <span t-field="o.partner_id.street2"/></t>
|
|
|
+ <t t-f="not o.partner_id.street"> </t>
|
|
|
+ <div class="telefono_data"><span t-field="o.partner_id.phone"/></div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+
|
|
|
+ <div class="cab-articulos"> </div>
|
|
|
+ <div style="height:2.24cm;">
|
|
|
+ <div style="font-family: Arial;">
|
|
|
+ <table class="table borderless table-condensed">
|
|
|
+ <t t-set="valor_exentas" t-value="0"/>
|
|
|
+ <t t-set="valor_5" t-value="0"/>
|
|
|
+ <t t-set="valor_10" t-value="0"/>
|
|
|
+ <tbody>
|
|
|
+ <tr t-foreach="o.invoice_line" t-as="l">
|
|
|
+ <!-- CODIGO DE PRODUCTO -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:1.0cm;overflow: auto; text-align: right;">
|
|
|
+ <span t-field="l.product_id.default_code"/>
|
|
|
+ </td>
|
|
|
+ <!-- CANTIDAD -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:1.6cm;overflow: auto; text-align: center;">
|
|
|
+ <span t-esc="'%.0f'%l.quantity"/>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <!-- NOMBRE DEL PRODUCTO -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:5.8cm;overflow: auto;">
|
|
|
+ <span t-field="l.name"/>
|
|
|
+ </td>
|
|
|
+ <!-- PRECIO UNITARIO -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:1.8cm;overflow: auto; text-align: right;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ </td>
|
|
|
+ <!-- EXENTAS -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:1.2cm;overflow: auto; text-align: right;">
|
|
|
+ <span t-if="'IVA 5% Venta' not in [ilt.name for ilt in l.invoice_line_tax_id] and 'IVA 10% Venta' not in [ilt.name for ilt in l.invoice_line_tax_id]">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(l.quantity * l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(l.quantity * l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-set="valor_exentas" t-value="valor_exentas+(l.quantity * l.price_unit)"/>
|
|
|
+ </span>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <!-- IVA 5% -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:1.5cm;overflow: auto; text-align: right;">
|
|
|
+ <span t-if="'IVA 5% Venta' in [ilt.name for ilt in l.invoice_line_tax_id] and 'IVA 10% Venta' not in [ilt.name for ilt in l.invoice_line_tax_id]">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(l.quantity * l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(l.quantity * l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-set="valor_5" t-value="valor_5+(l.quantity * l.price_unit)"/>
|
|
|
+ </span>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <!-- IVA 10% -->
|
|
|
+ <td style="font-size:9px;font-family: Arial;width:1.8cm;overflow: auto; text-align: right;">
|
|
|
+ <span t-if="'IVA 10% Venta' in [ilt.name for ilt in l.invoice_line_tax_id]">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(l.quantity * l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(l.quantity * l.price_unit)"/>
|
|
|
+ </t>
|
|
|
+ <t t-set="valor_10" t-value="valor_10+(l.quantity * l.price_unit)"/>
|
|
|
+ </span>
|
|
|
+ </td>
|
|
|
+ </tr>
|
|
|
+ </tbody>
|
|
|
+ </table>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div style="height:1.9cm;padding-left:1.7cm;">
|
|
|
+ <t t-set="total_exentas" t-value="0"/>
|
|
|
+ <t t-set="total_5" t-value="0"/>
|
|
|
+ <t t-set="total_10" t-value="0"/>
|
|
|
+ <t t-set="iva_5" t-value="0"/>
|
|
|
+ <t t-set="iva_10" t-value="0"/>
|
|
|
+ <t t-set="iva_exentas" t-value="0"/>
|
|
|
+ <table class="table borderless table-condensed">
|
|
|
+ <tbody>
|
|
|
+ <!-- LINEA DE SUBTOTALES -->
|
|
|
+ <tr>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:1.0cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:1.6cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:5.8cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:1.8cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:1.2cm;overflow: auto; text-align: right;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(valor_exentas)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(valor_exentas)"/>
|
|
|
+ </t>
|
|
|
+ <t t-set="iva_exentas" t-value="valor_exentas"/>
|
|
|
+ </td>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:1.5cm;overflow: auto; text-align: right;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(valor_5)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(valor_5)"/>
|
|
|
+ </t>
|
|
|
+ <t t-set="iva_5" t-value="valor_5/21" />
|
|
|
+ </td>
|
|
|
+ <td style="font-size:10px;font-family: Arial;width:1.8cm;overflow: auto; text-align: right;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(valor_10)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(valor_10)"/>
|
|
|
+ </t>
|
|
|
+ <t t-set="iva_10" t-value="(valor_10)/11" />
|
|
|
+ </td>
|
|
|
+ </tr>
|
|
|
+ <!-- LINEA TOTAL EN LETRAS Y TOTAL GENERAL -->
|
|
|
+ <tr>
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:1.0cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:1.0cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:6.5cm;overflow: auto; text-align: left;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <div><span t-esc="convertir(o.amount_total,o.currency_id.en_letras)"/></div>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <div><span t-esc="convertir(o.amount_total,o.currency_id.en_letras)"/></div>
|
|
|
+ </t>
|
|
|
+ </td>
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:1.8cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:1.2cm;overflow: auto; text-align: right;"></td>
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:1.5cm;overflow: auto; text-align: right;">
|
|
|
+
|
|
|
+ <td style="padding-top:1.35cm;font-size:10px;font-family: Arial;width:1.8cm;overflow: auto; text-align: right;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(o.amount_total)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <span t-esc="'{0:,.2f}'.format(o.amount_total)"/>
|
|
|
+ </t></td>
|
|
|
+ </td>
|
|
|
+ </tr>
|
|
|
+ <!-- TOTAL DE IVA -->
|
|
|
+ <div class="divisoria1"> </div>
|
|
|
+ <tr>
|
|
|
+ <td style="padding-top:1.8cm;font-size:10px;font-family: Arial;width:1.0cm;overflow: auto; text-align: center;"></td>
|
|
|
+ <td style="padding-top:1.8cm;font-size:10px;font-family: Arial;width:1.0cm;overflow: auto; text-align: center;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <div>
|
|
|
+ <t t-if="iva_5 != 0">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(iva_5)"/>
|
|
|
+ </t>
|
|
|
+ </div>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ <div>
|
|
|
+ <t t-if="iva_5 != 0">
|
|
|
+ <span t-esc="'{0:,.0f}'.format(iva_5)"/>
|
|
|
+ </t>
|
|
|
+ </div>
|
|
|
+ </t>
|
|
|
+ </td>
|
|
|
+ <td style="padding-top:1.8cm;font-size:10px;font-family: Arial;width:6.5cm;overflow: auto; text-align: left;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ <div>
|
|
|
+ <t t-if="iva_10 != 0">
|
|
|
+ &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n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1.8cm;overflow: auto; text-align: left;">
|
|
|
+
|
|
|
+ </td>
|
|
|
+ <td style="padding-top:1.8cm;font-size:10px;font-family: Arial;width:1.2cm;overflow: auto; text-align: right;">
|
|
|
+ <t t-if="o.currency_id.id == 166">
|
|
|
+ &nbsp;&nbsp;&nbsp;&nbsp;
|
|
|
+ <span t-esc="'{0:,.0f}'.format(iva_5+iva_10)"/>
|
|
|
+ </t>
|
|
|
+ <t t-if="o.currency_id.id != 166">
|
|
|
+ &nbsp;&nbsp;&nbsp;&nbsp;
|
|
|
+ <span t-esc="'{0:,.0f}'.format(iva_5+iva_10)"/>
|
|
|
+ </t>
|
|
|
+ </td>
|
|
|
+
|
|
|
+ <td style="padding-top:1.8cm;font-size:10px;font-family: Arial;width:1.5cm;overflow: auto; text-align: center;">
|
|
|
+
|
|
|
+ </td>
|
|
|
+ <td style="padding-top:1.8cm;font-size:10px;font-family: Arial;width:1.8cm;overflow: auto; text-align: right;">
|
|
|
+ </td>
|
|
|
+ </tr>
|
|
|
+ </tbody>
|
|
|
+ </table>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <t t-if="i == 1">
|
|
|
+ <div class="logo1"> </div>
|
|
|
+ </t>
|
|
|
+ <t t-if="i == 2">
|
|
|
+ <div class="logo2"> </div>
|
|
|
+ </t>
|
|
|
+
|
|
|
+ </t>
|
|
|
+ </div>
|
|
|
+ </t>
|
|
|
+
|
|
|
+ </t>
|
|
|
+ </template>
|
|
|
+
|
|
|
+</data>
|
|
|
+</openerp>
|