mirror of
https://gitlab.com/hibou-io/hibou-odoo/suite.git
synced 2025-01-20 12:37:31 +02:00
Merge branch 'new/15.0/H11328_l10n_pe_sale_report__sale_pdf_template' into '15.0-test'
new/15.0/H11328_l10n_pe_sale_report__sale_pdf_template into 15.0-test See merge request hibou-io/hibou-odoo/suite!1607
This commit is contained in:
1
l10n_pe_sale_report/__init__.py
Normal file
1
l10n_pe_sale_report/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import models
|
||||
19
l10n_pe_sale_report/__manifest__.py
Normal file
19
l10n_pe_sale_report/__manifest__.py
Normal file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
'name': 'Peru - Quotation Report',
|
||||
'version': '15.0.1.0.0',
|
||||
'author': 'Hibou Corp. <hello@hibou.io>',
|
||||
'website': 'https://hibou.io/',
|
||||
'license': 'AGPL-3',
|
||||
'category': 'Sale',
|
||||
'complexity': 'easy',
|
||||
'description': """ """,
|
||||
'depends': [
|
||||
'sale',
|
||||
],
|
||||
'data': [
|
||||
'report/quotation_peru_reports.xml',
|
||||
'report/quotation_peru_templates.xml',
|
||||
],
|
||||
'installable': True,
|
||||
'auto_install': False,
|
||||
}
|
||||
1
l10n_pe_sale_report/models/__init__.py
Normal file
1
l10n_pe_sale_report/models/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import sale
|
||||
5
l10n_pe_sale_report/models/sale.py
Normal file
5
l10n_pe_sale_report/models/sale.py
Normal file
@@ -0,0 +1,5 @@
|
||||
from odoo import models
|
||||
|
||||
|
||||
class SaleOrder(models.Model):
|
||||
_inherit = 'sale.order'
|
||||
15
l10n_pe_sale_report/report/quotation_peru_reports.xml
Normal file
15
l10n_pe_sale_report/report/quotation_peru_reports.xml
Normal file
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<record id="action_peru_quotation" model="ir.actions.report">
|
||||
<field name="name">Peru Quotation</field>
|
||||
<field name="model">sale.order</field>
|
||||
<field name="report_type">qweb-pdf</field>
|
||||
<field name="report_name">l10n_pe_sale_report.peru_quotation_view</field>
|
||||
<field name="report_file">l10n_pe_sale_report.peru_quotation_view</field>
|
||||
<field name="print_report_name">(object._get_report_base_filename())</field>
|
||||
<field name="binding_model_id" ref="model_sale_order"/>
|
||||
<field name="binding_type">report</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
134
l10n_pe_sale_report/report/quotation_peru_templates.xml
Normal file
134
l10n_pe_sale_report/report/quotation_peru_templates.xml
Normal file
@@ -0,0 +1,134 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="peru_quotation_view">
|
||||
<t t-call="web.html_container">
|
||||
<t t-foreach="docs" t-as="o">
|
||||
<t t-call="web.external_layout">
|
||||
<div class="page">
|
||||
<div class="row" style="margin-bottom:10px;">
|
||||
<div class="col-8">
|
||||
<p>Sr(es): <span t-field="o.partner_id"/></p>
|
||||
</div>
|
||||
<div class="col-4" style="text-align:center;">
|
||||
<h4 t-field="o.name"/>
|
||||
<p>Cotización</p>
|
||||
<h6>Fecha: <span t-field="o.date_order" t-options="{'widget': 'date'}"/></h6>
|
||||
</div>
|
||||
</div>
|
||||
<table class="table table-sm table-bordered" border="0" cellpadding="0" cellspacing="0">
|
||||
<!-- <table border="0" cellpadding="0" cellspacing="0" width="590" style="min-width: 590px; background-color: white; padding: 0px 8px 0px 8px; border-collapse:separate;"> -->
|
||||
<thead>
|
||||
<tr style="background-color:#AAB7B8;">
|
||||
<td><strong>Detalle</strong></td>
|
||||
<td><strong>Cantidad</strong></td>
|
||||
<td><strong>P.Unitario</strong></td>
|
||||
<td><strong>Total/Mes</strong></td>
|
||||
<td><strong>Total/1er Año</strong></td>
|
||||
<td><strong>Total/2er Año</strong></td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<!-- TODO: use for by line of product -->
|
||||
<t t-foreach="o.order_line" t-as="line">
|
||||
<tr>
|
||||
<!-- <td><span t-field="o.fieldname"/></td> -->
|
||||
<td><span t-field="line.product_id"/></td>
|
||||
<td><span t-field="line.product_uom_qty"/></td>
|
||||
<td><span t-field="line.price_unit"/></td>
|
||||
<td><span t-field="line.price_subtotal"/></td>
|
||||
<!-- <t t-set="year" t-value="line.get_price_by_year()">
|
||||
<td><span t-esc="year"/></td>
|
||||
<td><span t-esc="year"/></td> -->
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</t>
|
||||
<tr style="background-color:#16A085;">
|
||||
<td colspan="4">
|
||||
<strong>Total (licencias/alojamiento)/Año</strong>
|
||||
</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4" style="background-color:#16A085;">
|
||||
<strong>Total Implementacion de modulos**</strong>
|
||||
</td>
|
||||
<td style="background-color:#16A085;"></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4">
|
||||
<strong>Sub total</strong>
|
||||
</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="4">
|
||||
<strong>IGV 18%</strong>
|
||||
</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr style="background-color:#FAD7A0;">
|
||||
<td colspan="4">
|
||||
<strong>Total/Año***</strong>
|
||||
</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
<tr/>
|
||||
<tr style="background-color:#AAB7B8;">
|
||||
<td><strong>Detalle</strong></td>
|
||||
<td><strong>Cantidad</strong></td>
|
||||
<td><strong>P.Unitario</strong></td>
|
||||
<td><strong>Total/Mes</strong></td>
|
||||
<td><strong>Total/1er Año</strong></td>
|
||||
<td><strong>Total/2er Año</strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<!-- <td><span t-field="o.fieldname"/></td> -->
|
||||
<td style="background-color:#FAD7A0;">Licencia de Odoo</td>
|
||||
<!-- TODO qty only of license -->
|
||||
<td style="background-color:#FAD7A0;"></td>
|
||||
<td style="background-color:#FAD7A0;">$10.90</td>
|
||||
<!-- TODO: qty * price unit -->
|
||||
<td style="background-color:#FAD7A0;"></td>
|
||||
<!-- TODO: price month * 12 -->
|
||||
<td style="background-color:#FAD7A0;"></td>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="5" style="background-color:#FAD7A0;">
|
||||
<p>Esto es un estimado. Las licencias de Odoo son contratadas directamente con Odoo.<br/>
|
||||
El precio se mantendrá fijo durante la vigencia del contrato.<br/>
|
||||
Los costos por el hosting de odoo.sh no estan incluidos.</p>
|
||||
</td>
|
||||
<td/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="5" style="background-color:#FAD7A0;">
|
||||
<p>Se incluye todos los módulos de Odoo sin configuración.<br/>
|
||||
Para visualizar la lista, por favor entre al siguiente enlace:<br/>
|
||||
<a href="https://www.odoo.com/es_ES/page/all-apps">https://www.odoo.com/es_ES/page/all-apps</a></p>
|
||||
</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>**Módulos implementados/configurados: Uso general de Odoo</p>
|
||||
<p>**Precios cambian de acuerdo a la implementación de nuevos módulos</p>
|
||||
<!-- TODO insert QR code -->
|
||||
<div name="footer_left_column" position="inside" style="text-align:right;">
|
||||
<!-- Example <img t-if="o.l10n_ar_afip_qr_code" t-att-src="'/report/barcode/?type=%s&value=%s&width=%s&height=%s' % ('QR', o.l10n_ar_afip_qr_code, 400, 400)" alt="QR Code" style="height:100px"/> -->
|
||||
<img t-att-src="'/report/barcode/?type=%s&value=%s&width=%s&height=%s' % ('QR', o.name, 400, 400)" alt="QR Code" style="height:100px"/>
|
||||
</div>
|
||||
</div>
|
||||
</t>
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
BIN
l10n_pe_sale_report/static/description/icon.png
Normal file
BIN
l10n_pe_sale_report/static/description/icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 8.0 KiB |
Reference in New Issue
Block a user