Skip to content
Snippets Groups Projects
Commit 93ed20d7 authored by Benjamin - Le Filament's avatar Benjamin - Le Filament
Browse files

[init] module init

parents
No related branches found
No related tags found
No related merge requests found
.*
*.pyc
!.gitignore
This diff is collapsed.
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:target: http://www.gnu.org/licenses/agpl
:alt: License: AGPL-3
==================
Legicoop - Account
==================
Hérite le module **account** et ajoute les fonctions suivantes :
* ajout d'un champ sur la facture pour afficher ou nom le détail du tableau
* modifie le template pour afficher ou non les colonnes
Credits
=======
Contributors
------------
* Juliana Poudou <juliana@le-filament.com>
* Benjamin Rivier <benjamin@le-filament.com>
Maintainer
----------
.. image:: https://le-filament.com/images/logo-lefilament.png
:alt: Le Filament
:target: https://le-filament.com
This module is maintained by Le Filament
# Copyright 2020 Le Filament (<http://www.le-filament.com>)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import models
\ No newline at end of file
{
'name': "LEGICOOP - Account",
'summary': "Gestion des factures - LEGICOOP",
'author': "Le Filament",
'website': "https://www.le-filament.com",
'version': '12.0.1.0.1',
'license': "AGPL-3",
'depends': ['account'],
'data': [
'views/account_invoice_views.xml',
'templates/account_invoice_templates.xml',
],
}
\ No newline at end of file
# Copyright 2022 Le Filament (<http://www.le-filament.com>)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import account_invoice
# Copyright 2022 Le Filament (<http://www.le-filament.com>)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from odoo import models, fields
class AccountInvoice(models.Model):
_inherit = 'account.invoice'
with_detail = fields.Boolean("Facture avec détail", default=False)
static/description/icon.png

8.95 KiB

<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<data>
<!-- Invoice report -->
<template id="report_invoice_document" inherit_id="account.report_invoice_document">
<!-- Hide Header Qty, PU, Tax if not with detail -->
<xpath expr="//table/thead/tr/th[3]" position="attributes">
<attribute name="t-if">o.with_detail</attribute>
</xpath>
<xpath expr="//table/thead/tr/th[4]" position="attributes">
<attribute name="t-if">o.with_detail</attribute>
</xpath>
<xpath expr="//table/thead/tr/th[6]" position="attributes">
<attribute name="t-if">o.with_detail</attribute>
</xpath>
<!-- Hide body Qty, PU, Tax if not with detail -->
<xpath expr="//table/tbody/t/tr/t/td[3]" position="attributes">
<attribute name="t-if">o.with_detail</attribute>
</xpath>
<xpath expr="//table/tbody/t/tr/t/td[4]" position="attributes">
<attribute name="t-if">o.with_detail</attribute>
</xpath>
<xpath expr="//table/tbody/t/tr/t/td[6]" position="attributes">
<attribute name="t-if">o.with_detail</attribute>
</xpath>
</template>
</data>
</odoo>
\ No newline at end of file
<?xml version="1.0"?>
<!-- Copyright 2022 Le Filament
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -->
<odoo>
<data>
<record id="legicoop_invoice_form" model="ir.ui.view">
<field name="name">legicoop.account.invoice.form</field>
<field name="model">account.invoice</field>
<field name="inherit_id" ref="account.invoice_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='payment_term_id']" position="after">
<field name="with_detail"/>
</xpath>
</field>
</record>
</data>
</odoo>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment