diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c575299fc05d609e25260193f2b663be50d0fd31..da24b78433b8fc6aa9df342b506c26ad1db61260 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -58,6 +58,7 @@ repos: rev: v2.7.1 hooks: - id: prettier + exclude: ^templates/ name: prettier (with plugin-xml) additional_dependencies: - "prettier@2.7.1" @@ -101,14 +102,14 @@ repos: - id: pyupgrade args: ["--keep-percent-format"] - repo: https://github.com/PyCQA/isort - rev: 5.10.1 + rev: 5.12.0 hooks: - id: isort name: isort except __init__.py args: - --settings=. exclude: /__init__\.py$ - - repo: https://gitlab.com/PyCQA/flake8 + - repo: https://github.com/PyCQA/flake8 rev: 3.9.2 hooks: - id: flake8 diff --git a/__manifest__.py b/__manifest__.py index a5ce9a6aa89e966a7aa6720a3357f151a44c5a07..e492baabc074e3c4a6c02760b45fe742030dbdb5 100644 --- a/__manifest__.py +++ b/__manifest__.py @@ -10,20 +10,31 @@ ], "website": "https://le-filament.com", "data": [ - "data/ir_module_category.xml", + # security "security/training_security.xml", "security/ir.model.access.csv", + # datas + "data/ir_module_category.xml", "data/training_data.xml", + "data/training_type_data.xml", + # templates + "templates/report_config_settings.xml", + "templates/report_agreement.xml", + "templates/report_attestation.xml", + "templates/report_attendance_sheet.xml", + "templates/report_convocation.xml", + "templates/report_program.xml", + # views "views/account_move_view.xml", - "views/partner_view.xml", + "views/res_company_view.xml", + "views/res_config_settings_view.xml", + "views/res_partner_view.xml", "views/sale_order_view.xml", "views/training_course_view.xml", "views/training_training_view.xml", "views/training_session_view.xml", - "report/report_agreement.xml", - "report/report_attestation.xml", - "report/report_attendance_sheet.xml", - "report/report_program.xml", + "views/training_type_view.xml", + "views/menus.xml", ], "assets": { "web.report_assets_common": [ diff --git a/data/training_type_data.xml b/data/training_type_data.xml new file mode 100644 index 0000000000000000000000000000000000000000..db75cc2f58bafbf9bc0d04700e044700bc029c4c --- /dev/null +++ b/data/training_type_data.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8"?> +<odoo> + <data> + <record id="training_type_present" model="training.type"> + <field name="name">Présentiel</field> + </record> + <record id="training_type_remote" model="training.type"> + <field name="name">Distanciel</field> + </record> + <record id="training_type_blended" model="training.type"> + <field name="name">Blended</field> + </record> + + </data> +</odoo> diff --git a/models/__init__.py b/models/__init__.py index 9af0c3dbaad804f5306896ad797d04c7410561ec..4047d81f329b60338860f9f9e85a1fc456439379 100644 --- a/models/__init__.py +++ b/models/__init__.py @@ -1,7 +1,11 @@ from . import account_move -from . import partner +from . import res_partner +from . import res_company +from . import res_company_training_logo +from . import res_config_settings from . import sale_order from . import training_course from . import training_session from . import training_student from . import training_training +from . import training_type diff --git a/models/res_company.py b/models/res_company.py new file mode 100644 index 0000000000000000000000000000000000000000..4c40b56fbd9239ed21a92c01ab0950ae9ca9ee8b --- /dev/null +++ b/models/res_company.py @@ -0,0 +1,45 @@ +# © 2023 Le Filament (<http://www.le-filament.com>) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from odoo import fields, models + + +class ResCompany(models.Model): + _inherit = "res.company" + + training_number = fields.Char("N° Organisme de formation") + agreement_special_condition = fields.Html("Conditions spéciales de la convention") + title_color = fields.Char("Couleur du titre", default="#ffffff") + title_bg_color = fields.Char("Couleur arrière plan du titre", default="#00b495") + title_font = fields.Selection( + [ + ("Lato", "Lato"), + ("Roboto", "Roboto"), + ("Open_Sans", "Open Sans"), + ("Montserrat", "Montserrat"), + ("Oswald", "Oswald"), + ("Raleway", "Raleway"), + ], + string="Police des titres", + default="Lato", + required=True, + ) + subtitle_color = fields.Char("Couleur sous-titre", default="#1c2f82") + text_font = fields.Selection( + [ + ("Lato", "Lato"), + ("Roboto", "Roboto"), + ("Open_Sans", "Open Sans"), + ("Montserrat", "Montserrat"), + ("Oswald", "Oswald"), + ("Raleway", "Raleway"), + ], + string="Police du texte", + default="Lato", + required=True, + ) + logo_ids = fields.One2many( + comodel_name="res.company.training.logo", + inverse_name="company_id", + string="Logos", + ) diff --git a/models/res_company_training_logo.py b/models/res_company_training_logo.py new file mode 100644 index 0000000000000000000000000000000000000000..eda5a94cb4abb27a0cc303322809461a091602e6 --- /dev/null +++ b/models/res_company_training_logo.py @@ -0,0 +1,19 @@ +# © 2023 Le Filament (<http://www.le-filament.com>) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from odoo import fields, models + + +class ResCompanyTrainingLogo(models.Model): + _name = "res.company.training.logo" + _description = "Logos à afficher sur les documents de formation" + + logo = fields.Binary(required=True) + name = fields.Char("Nom du logo") + company_id = fields.Many2one( + comodel_name="res.company", + string="Company", + required=True, + default=lambda self: self.env["res.company"]._company_default_get(), + ondelete="cascade", + ) diff --git a/models/res_config_settings.py b/models/res_config_settings.py new file mode 100644 index 0000000000000000000000000000000000000000..6d3b6497c03d3ffc73badff8494087b60cf85b08 --- /dev/null +++ b/models/res_config_settings.py @@ -0,0 +1,19 @@ +# © 2023 Le Filament (<http://www.le-filament.com>) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from odoo import fields, models + + +class ResConfigSettings(models.TransientModel): + _inherit = "res.config.settings" + + training_number = fields.Char(related="company_id.training_number", readonly=False) + agreement_special_condition = fields.Html( + related="company_id.agreement_special_condition", readonly=False + ) + title_color = fields.Char(related="company_id.title_color", readonly=False) + title_bg_color = fields.Char(related="company_id.title_bg_color", readonly=False) + title_font = fields.Selection(related="company_id.title_font", readonly=False) + subtitle_color = fields.Char(related="company_id.subtitle_color", readonly=False) + text_font = fields.Selection(related="company_id.text_font", readonly=False) + logo_ids = fields.One2many(related="company_id.logo_ids", readonly=False) diff --git a/models/partner.py b/models/res_partner.py similarity index 100% rename from models/partner.py rename to models/res_partner.py diff --git a/models/training_course.py b/models/training_course.py index a04890b220498d5ef4df993ea555a414e73dd757..4dc10db37fb63a97b3edaeeb853e7771aceb82e5 100644 --- a/models/training_course.py +++ b/models/training_course.py @@ -22,6 +22,7 @@ class TrainingProgram(models.Model): nature = fields.Text(string="Nature de l'action") acquis = fields.Text(string="Acquis de la formation") students_profile = fields.Text(string="Profil des stagiaires") + prerequisites = fields.Text(string="Pré-requis") session_ids = fields.Many2many( comodel_name="training.course.session", relation="program_course_rel", diff --git a/models/training_training.py b/models/training_training.py index 2dbccb2dc398290caa31081eccc0ec9420fb661b..f57d694b55b11917c317da1aefed1c3097948936 100644 --- a/models/training_training.py +++ b/models/training_training.py @@ -47,9 +47,25 @@ class Training(models.Model): date_end = fields.Date(string="Fin de la formation") session_hours = fields.Char(string="Horaires") students_nb_prev = fields.Char(string="Nb Stagiaires Prévisionnel") - convention = fields.Binary() + convention = fields.Binary(attachment=True) + signin_person = fields.Char( + string="Signataire", help="Signataire de la convention et des attestations" + ) + signin_function = fields.Char( + string="Fonction Signataire", + help="Fonction du signataire de la convention et des attestations", + ) + date_convocation = fields.Date() date_convention = fields.Date() + place_convention = fields.Char( + "Lieu signature convention", + default=lambda self: self.env["res.company"]._company_default_get().city, + ) date_attestation = fields.Date() + place_attestation = fields.Char( + "Lieu signature attestation", + default=lambda self: self.env["res.company"]._company_default_get().city, + ) hours = fields.Integer(string="Durée (h)", compute="_compute_sessions", store=True) hours_total = fields.Integer( string="Nombre d'heures", compute="_compute_hours_total", store=True @@ -89,7 +105,8 @@ class Training(models.Model): selection=[("draft", "Brouillon"), ("current", "Accepté"), ("done", "Réalisé")], default="draft", ) - place = fields.Text(string="Lieu de la formation") + place = fields.Char(string="Lieu de la formation") + place_detail = fields.Text(string="Détails du lieu") company_id = fields.Many2one( comodel_name="res.company", string="Company", @@ -98,8 +115,22 @@ class Training(models.Model): readonly=True, default=lambda self: self.env["res.company"]._company_default_get(), ) - file_number = fields.Char(string="N° Dossier") - plan = fields.Char(string="Dispositif") + file_number = fields.Char(string="N° Dossier OPCO") + plan = fields.Char(string="Dispositif OPCO") + meanings = fields.Text("Dispositif formation") + is_vat = fields.Boolean("TVA 20% applicable", default=True) + training_type_id = fields.Many2one( + comodel_name="training.type", + string="Type de formation", + ) + payment_term_id = fields.Many2one( + comodel_name="account.payment.term", + string="Condition de règlement", + check_company=True, + domain="['|', ('company_id', '=', False), ('company_id', '=', company_id)]", + ) + email_contact = fields.Char("Email contact formation") + equipment = fields.Text(string="Équipement/éléments nécessaires pour la formation") # ------------------------------------------------------ # Override ORM diff --git a/models/training_type.py b/models/training_type.py new file mode 100644 index 0000000000000000000000000000000000000000..ac5478a5b7812ac2dcff9993a511c25bb26ab631 --- /dev/null +++ b/models/training_type.py @@ -0,0 +1,11 @@ +# Copyright 2019-2022 Le Filament (<https://le-filament.com>) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from odoo import fields, models + + +class TrainingType(models.Model): + _name = "training.type" + _description = "Training Type" + + name = fields.Char("Nom", required=True) diff --git a/report/report_agreement.xml b/report/report_agreement.xml deleted file mode 100644 index f045dca52e26dba7dcabc756699468ce6aeb374c..0000000000000000000000000000000000000000 --- a/report/report_agreement.xml +++ /dev/null @@ -1,228 +0,0 @@ -<?xml version="1.0" encoding="utf-8" ?> -<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) - License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> -<odoo> - <template id="qweb_agreement_pdf"> - <t t-call="web.html_container"> - <t t-foreach="docs" t-as="doc"> - <t t-call="web.external_layout"> - <div class="page"> - <div class="convention"> - <div class="col-12 text-center"> - <h1>CONVENTION DE FORMATION PROFESSIONNELLE N°<span - t-field="doc.agreement_number" - /></h1> - <h2><span t-field="doc.course_id.name" /></h2> - <hr /> - </div> - <div class="col-12"> - <p>ENTRE :</p> - <p> - <strong - >LE FILAMENT</strong> – Déclaration d’activité enregistrée sous le numéro 73310810731 auprès de la Préfecture de la région Occitanie – dont le siège est situé 32 Rue Riquet – 31000 TOULOUSE. - Représenté par Monsieur Benjamin RIVIER, Gérant - </p> - <p>ET</p> - <p> - <strong><span - t-field="doc.customer_id.name" - /></strong> - <span - t-field="doc.customer_id.street" - /> - <span t-field="doc.customer_id.zip" /> <span - t-field="doc.customer_id.city" - />. - </p> - <p - >Il est établi la présente convention de formation en application des dispositions de la sixième partie du Code du Travail (article L6353-1 à 2 et R6353-1) portant organisation de la formation professionnelle continue tout au long de la vie.</p> - - <div class="subblock"> - <h3 - >ARTICLE 1 - OBJET ET CARACTERISTIQUES DE LA FORMATION</h3> - <p - >En exécution de la présente convention, l’organisme LE FILAMENT s’engage à organiser l’action de formation intitulée : <span - t-field="doc.course_id.name" - /></p> - <p - >L’objet, le programme, les méthodes pédagogiques, l’évaluation de cette formation relèvent de l’acquisition, de l’entretien ou du perfectionnement des connaissances (article L6313-1 du Code du Travail).</p> - <p> - Objectif de formation : <br /> - <span t-field="doc.course_id.objective" /> - </p> - </div> - <div class="subblock"> - <h3>ARTICLE 2 – LIEU ET DATE DE LA FORMATION</h3> - <table - class="table table-borderless table-sm" - style="border: 0px; border-color: transparent;" - > - <tbody style="border: 0px;"> - <tr style="border: 0px;"> - <td - style="width: 160px; border: 0px;" - >Lieu :</td> - <td style="border: 0px;"><span - t-field="doc.place" - /></td> - </tr> - <tr> - <td - style="width: 160px; border: 0px;" - >Dates :</td> - <td style="border: 0px;">Du <span - t-field="doc.date_begin" - /> au <span - t-field="doc.date_end" - /></td> - </tr> - <tr style="border: 0px;"> - <td - style="width: 160px; border: 0px;" - >Durée :</td> - <td style="border: 0px;"><span - t-esc="doc.hours" - />h</td> - </tr> - </tbody> - </table> - </div> - <div class="subblock"> - <h3 - >ARTICLE 3 – STAGIAIRES BENEFICIAIRES DE L’ACTION</h3> - <p - >L’entreprise signataire inscrit à cette formation les personnes suivantes :</p> - <t t-foreach="doc.student_ids" t-as="student"> - <strong><span - t-field="student.student_id.lastname" - /> <span - t-field="student.student_id.firstname" - /></strong><br /> - </t> - <p>Nombre d'inscrit(s) : <strong><span - t-esc="doc.students_count" - /></strong></p> - </div> - <div class="subblock"> - <h3>ARTICLE 4 – MODALITES FINANCIERES</h3> - <p - >Le coût de la formation, objet de la présente convention, s’élève à : </p> - <table class="table table-borderless table-sm"> - <thead> - <tr> - <th>Intitulé</th> - <th>Prix HT</th> - <th>TVA</th> - <th>Prix TTC</th> - </tr> - </thead> - <tbody> - <tr> - <td><span - t-field="doc.course_id.name" - /></td> - <td><span t-esc="doc.cost" /> €</td> - <td><span - t-esc="doc.cost * 0.2" - /> €</td> - <td><span - t-esc="doc.cost * 1.2" - /> €</td> - </tr> - </tbody> - </table> - <p - >Cette somme couvre l’intégralité des frais engagés par l’organisme de formation pour cette session.</p> - </div> - <div class="subblock"> - <h3 - >ARTICLE 5 – MOYENS PEDAGOGIQUES ET TECHNIQUES MIS EN OEUVRE</h3> - <p><span t-field="doc.course_id.means" /></p> - </div> - <div class="subblock"> - <h3 - >ARTICLE 6 – MOYENS PERMETTANT D’APPRECIER LES RESULTATS DE L’ACTION</h3> - <p><span t-field="doc.course_id.evaluation" /></p> - </div> - <div class="subblock"> - <h3 - >ARTICLE 7 – MOYENS PERMETTANT DE SUIVRE L’EXECUTION DE L’ACTION</h3> - <p><span t-field="doc.course_id.control" /></p> - </div> - <div class="subblock"> - <h3>ARTICLE 8 – SANCTION DE LA FORMATION</h3> - <p - >En application de l’article L6353-1 du Code du Travail, une attestation mentionnant les objectifs, la nature et la durée de l’action, les résultats de l’évaluation des acquis de la formation sera transmise aux stagiaires à l’issue de la formation.</p> - </div> - <div class="subblock"> - <h3 - >ARTICLE 9 – DELAI DE RETRACTATION ET CONDITIONS D’ANNULATION</h3> - <p - >Conformément à la législation en vigueur (cf. Partie 6 du Code du Travail), l’entreprise signataire dispose d'un délai de 10 jours à compter de la signature de la présente convention pour se rétracter, par lettre recommandée avec accusé de réception.</p> - <p - >Si, en cas de force majeure dûment reconnue, l’entreprise signataire est empêchée de suivre le programme de formation objet de la présente convention, elle pourra résilier ce contrat. Dans ce cas, seules les prestations effectivement dispensées seront dues prorata temporis de leur valeur prévue au contrat.</p> - <p - >En cas de renoncement par LE FILAMENT à l’exécution de la présente convention, aucun règlement n’est dû et les sommes perçues sont remboursées.</p> - </div> - <div class="subblock"> - <h3>ARTICLE 10 – DROIT APPLICABLE</h3> - <p - >Le présent contrat est régi par le droit français.</p> - <p - >En cas de litige résultant de l'interprétation du présent contrat, de son exécution, ou en cas de rupture du lien contractuel, la juridiction compétente sera le tribunal de Toulouse.</p> - - <p class="mt32 mb32"> - Fait à Toulouse, le <span - t-field="doc.date_convention" - /> - </p> - <table - class="table table-borderless" - style="border: 0px; border-color: transparent;" - > - <tr> - <td style="border-color: #eee;"> - Pour <span - t-field="doc.customer_id.name" - /> <br /> - (Cachet et signature) - </td> - <td style="border: 0;"> - Pour LE FILAMENT <br /> - Benjamin RIVIER, Gérant<br /> - (Cachet et signature) - </td> - </tr> - </table> - </div> - </div> - </div> - </div> - </t> - </t> - </t> - </template> - - <record id="paperformat_a4_training" model="report.paperformat"> - <field name="name">A4 Formation</field> - <field name="default" eval="True" /> - <field name="format">A4</field> - <field name="orientation">Portrait</field> - <field name="margin_top">35</field> - <field name="margin_bottom">30</field> - <field name="margin_left">10</field> - <field name="margin_right">10</field> - <field name="header_line" eval="False" /> - <field name="header_spacing">30</field> - <field name="dpi">90</field> - </record> - - <record id="report_agreement_pdf" model="ir.actions.report"> - <field name="name">Formation - Convention</field> - <field name="model">training.training</field> - <field name="report_type">qweb-pdf</field> - <field name="report_name">lefilament_training.qweb_agreement_pdf</field> - <field name="binding_model_id" ref="model_training_training" /> - <field name="binding_type">report</field> - <field name="paperformat_id" ref="paperformat_a4_training" /> - </record> - -</odoo> diff --git a/report/report_attestation.xml b/report/report_attestation.xml deleted file mode 100644 index 80290a2034347c0a6f2ccd36417d3941a86803a2..0000000000000000000000000000000000000000 --- a/report/report_attestation.xml +++ /dev/null @@ -1,118 +0,0 @@ -<?xml version="1.0" encoding="utf-8" ?> -<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) - License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> -<odoo> - <template id="qweb_attestation_pdf"> - <t t-call="web.html_container"> - <t t-foreach="docs" t-as="doc"> - <t t-foreach="doc.student_ids" t-as="student"> - <t t-call="web.external_layout"> - <div class="page"> - <div class="row convention"> - <div class="col-12"> - <div class="col-12 text-center"> - <h1>ATTESTATION DE FIN DE FORMATION</h1> - </div> - <div class="col-12" style="margin-top: 20px;"> - <p - >Je soussigné, Benjamin RIVIER, agissant en qualité de gérant au sein de l’organisme de formation Le Filament, enregistré sous le numéro 73310810731, atteste que :</p> - <p><strong><span - t-field="student.student_id.name" - /></strong></p> - <p>Salarié(e) de la société <strong><span - t-field="doc.customer_id.name" - /></strong>, située au <span - t-field="doc.customer_id.street" - />, <span - t-field="doc.customer_id.zip" - /> <span - t-field="doc.customer_id.city" - />,</p> - <p>A suivi la formation suivante :</p> - <h2 class="text-center"><span - t-field="doc.course_id.name" - /></h2> - - <h3>OBJECTIFS DE LA FORMATION</h3> - <p t-field="doc.course_id.objective" /> - - <h3>NATURE DE L’ACTION DE FORMATION</h3> - <p t-field="doc.course_id.nature" /> - - <h3>MODALITÉS DE LA FORMATION</h3> - <table class="table table-striped"> - <tbody> - <tr> - <td style="width: 120px;"><strong - >Dates</strong></td> - <td>Du <span - t-field="doc.date_begin" - /> au <span - t-field="doc.date_end" - /></td> - <td style="width: 120px;"><strong - >Lieu</strong></td> - <td><span - t-field="doc.place" - /></td> - </tr> - <tr> - <td style="width: 120px;"><strong - >Durée</strong></td> - <td><span - t-esc="doc.hours" - /> heures</td> - <td style="width: 120px;"><strong - >Intervenant(s)</strong></td> - <td> - <t - t-set="trainers" - t-value="doc._get_trainers()" - /> - <t - t-foreach="trainers" - t-as="trainer" - > - <span - t-field="trainer.lastname" - /> <span - t-field="trainer.firstname" - />, - </t> - </td> - </tr> - </tbody> - </table> - - <h3>ACQUIS DE LA FORMATION</h3> - <p t-field="doc.course_id.acquis" /> - </div> - <div - class="col-offset-8 col-4" - style="margin-top: 20px;" - > - Pour valoir ce que de droit <br /> - Fait à Toulouse, le <span - t-field="doc.date_attestation" - /> - </div> - </div> - </div> - </div> - </t> - </t> - </t> - </t> - </template> - - <record id="report_attestation_pdf" model="ir.actions.report"> - <field name="name">Formation - Attestations</field> - <field name="model">training.training</field> - <field name="report_type">qweb-pdf</field> - <field name="report_name">lefilament_training.qweb_attestation_pdf</field> - <field name="binding_model_id" ref="model_training_training" /> - <field name="binding_type">report</field> - <field name="paperformat_id" ref="paperformat_a4_training" /> - </record> - -</odoo> diff --git a/report/report_program.xml b/report/report_program.xml deleted file mode 100644 index 66fc9f84818c1273b42a52d4fe7e6b435abb847f..0000000000000000000000000000000000000000 --- a/report/report_program.xml +++ /dev/null @@ -1,117 +0,0 @@ -<?xml version="1.0" encoding="utf-8" ?> -<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) - License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> -<odoo> - <template id="qweb_program_pdf"> - <t t-call="web.html_container"> - <t t-foreach="docs" t-as="doc"> - <t t-call="web.external_layout"> - <div class="page"> - <div class="row convention"> - <div class="col-12"> - <div class="text-center"> - <h1><span t-field="doc.course_id.name" /></h1> - <h2>Programme de formation</h2> - </div> - <div class="subblock"> - <h3>1. DESCRIPTION</h3> - <p t-field="doc.course_id.description" /> - </div> - <div class="subblock"> - <h3>2. OBJECTIFS / COMPÉTENCES VISÉES</h3> - <p t-field="doc.course_id.objective" /> - </div> - <div class=""> - <h3>3. PROGRAMME DE LA FORMATION</h3> - <t t-foreach="doc.session_ids" t-as="session"> - <div class="subblock"> - <h4 style="margin-left: 40px;">3.<span - t-esc="'%01d' % (session_index+1)" - /> <span - t-field="session.session_id.name" - /></h4> - <p style="margin-bottom: 40px;"><span - t-field="session.session_id.description" - /></p> - </div> - </t> - </div> - <div class="subblock"> - <h3>4. MÉTHODOLOGIE ET SUPPORTS PÉDAGOGIQUES</h3> - <span t-field="doc.course_id.method" /> - </div> - <div class="subblock"> - <h3>5. MOYENS PÉDAGOGIQUES D'ENCADREMENT</h3> - <span t-field="doc.course_id.means" /> - </div> - <div class="subblock"> - <h3>6. SUIVI DE L’EXÉCUTION</h3> - <span t-field="doc.course_id.control" /> - </div> - <div class="subblock"> - <h3>7. MODALITÉS D'ÉVALUATION</h3> - <span t-field="doc.course_id.evaluation" /> - </div> - <div class="subblock"> - <h3>8. MODALITÉS ET DURÉE DE LA FORMATION</h3> - <p - >Formation dispensée en intra-entreprise par groupes de <span - t-field="doc.students_nb_prev" - /> personnes, et par session de demi-journées, afin de s’adapter aux contraintes de disponibilité de l’entreprise.</p> - <p>Horaires : <strong><span - t-field="doc.session_hours" - /></strong></p> - <p><strong><span - t-field="doc.session_count" - /> sessions</strong> de formation, soit <strong - ><span - t-field="doc.hours" - /> heures par personne</strong></p> - </div> - <div class="subblock"> - <h3>9. LIEU ET DÉLAIS DE LA FORMATION</h3> - <p t-field="doc.place" /> - <p>Du <span t-field="doc.date_begin" /> au <span - t-field="doc.date_end" - /></p> - </div> - <div class="subblock"> - <h3>10. COÛT DE LA FORMATION</h3> - <p> - <span - t-field="doc.cost" - /> € HT en formation INTRA de <span - t-field="doc.students_nb_prev" - /> personnes. - </p> - </div> - <div class="subblock"> - <h3>11. LES STAGIAIRES</h3> - <span t-field="doc.course_id.students_profile" /> - </div> - <div class="text-center"> - <img - src="/lefilament_training/static/src/img/logo-datadock.jpg" - style="max-width: 80px;" - class="mt64" - /> - </div> - </div> - </div> - </div> - </t> - </t> - </t> - </template> - - <record id="report_program_pdf" model="ir.actions.report"> - <field name="name">Formation - Programme</field> - <field name="model">training.training</field> - <field name="report_type">qweb-pdf</field> - <field name="report_name">lefilament_training.qweb_program_pdf</field> - <field name="binding_model_id" ref="model_training_training" /> - <field name="binding_type">report</field> - <field name="paperformat_id" ref="paperformat_a4_training" /> - </record> - -</odoo> diff --git a/security/ir.model.access.csv b/security/ir.model.access.csv index e66679b8c513e197eb2356c204214c791fec8635..ace35a224513d5a8cffbef6bf6ba8141aeff11c6 100644 --- a/security/ir.model.access.csv +++ b/security/ir.model.access.csv @@ -4,3 +4,7 @@ access_training_session_group_user,training.session,model_training_session,group access_training_student_group_user,training.student,model_training_student,group_training,1,1,1,1 access_training_course_group_user,training.course,model_training_course,group_training,1,1,1,1 access_training_course_session_group_user,training.course.session,model_training_course_session,group_training,1,1,1,1 +admin_res_company_training_logo,admin_res_company_training_logo,model_res_company_training_logo,group_training,1,1,1,1 +access_res_company_training_logo,access_res_company_training_logo,model_res_company_training_logo,base.group_user,1,0,0,0 +access_training_type,access_training_type,model_training_type,base.group_user,1,0,0,0 +admin_training_type,admin_training_type,model_training_type,group_training,1,1,1,1 \ No newline at end of file diff --git a/static/description/icon.png b/static/description/icon.png index 82ef47760a441cf229b5009f0a18ccf3842fbfa5..9c3e608f69181d3991017570740811080c71b5e3 100644 Binary files a/static/description/icon.png and b/static/description/icon.png differ diff --git a/static/description/training.png b/static/description/training.png deleted file mode 100644 index 9c3e608f69181d3991017570740811080c71b5e3..0000000000000000000000000000000000000000 Binary files a/static/description/training.png and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-Black.ttf b/static/src/fonts/Lato/Lato-Black.ttf deleted file mode 100644 index 421164c2bb442f2671673532c360a04f763dbb75..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-Black.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-BlackItalic.ttf b/static/src/fonts/Lato/Lato-BlackItalic.ttf deleted file mode 100644 index f367ad43809bf1ea933e36b2e17b1e05adc3edc4..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-BlackItalic.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-Bold.ttf b/static/src/fonts/Lato/Lato-Bold.ttf deleted file mode 100644 index 620c85e3af02de7010306e0c7b8f516ef8ddcee8..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-Bold.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-BoldItalic.ttf b/static/src/fonts/Lato/Lato-BoldItalic.ttf deleted file mode 100644 index 4c9cd1905bf0b457e93a97edbb5edce61ff0a5cd..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-BoldItalic.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-Hairline.ttf b/static/src/fonts/Lato/Lato-Hairline.ttf deleted file mode 100644 index 94da2dcbb65e7033fb7b9330dc18b9959b04f918..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-Hairline.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-HairlineItalic.ttf b/static/src/fonts/Lato/Lato-HairlineItalic.ttf deleted file mode 100644 index d2236cae0141ccc350745655daeb8fe4afbe1bc1..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-HairlineItalic.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-Italic.ttf b/static/src/fonts/Lato/Lato-Italic.ttf deleted file mode 100644 index bc2a62245e1b7dc36913c7d9d079d5bd07717d96..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-Italic.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-Light.ttf b/static/src/fonts/Lato/Lato-Light.ttf deleted file mode 100644 index 1d023d7d6fa69ad417e931ea7e5f6f572d805359..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-Light.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-LightItalic.ttf b/static/src/fonts/Lato/Lato-LightItalic.ttf deleted file mode 100644 index b28954b89c48581125930c4702316442a1898445..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-LightItalic.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/Lato-Regular.ttf b/static/src/fonts/Lato/Lato-Regular.ttf deleted file mode 100644 index ade05beafec4be6edaa51517bab2fd838ab39049..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lato/Lato-Regular.ttf and /dev/null differ diff --git a/static/src/fonts/Lato/OFL.txt b/static/src/fonts/Lato/OFL.txt deleted file mode 100644 index 4d308fb87e4c7d4237c37a099268045b99b5246e..0000000000000000000000000000000000000000 --- a/static/src/fonts/Lato/OFL.txt +++ /dev/null @@ -1,93 +0,0 @@ -Copyright (c) 2010-2014 by tyPoland Lukasz Dziedzic (team@latofonts.com) with Reserved Font Name "Lato" - -This Font Software is licensed under the SIL Open Font License, Version 1.1. -This license is copied below, and is also available with a FAQ at: -http://scripts.sil.org/OFL - - ------------------------------------------------------------ -SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 ------------------------------------------------------------ - -PREAMBLE -The goals of the Open Font License (OFL) are to stimulate worldwide -development of collaborative font projects, to support the font creation -efforts of academic and linguistic communities, and to provide a free and -open framework in which fonts may be shared and improved in partnership -with others. - -The OFL allows the licensed fonts to be used, studied, modified and -redistributed freely as long as they are not sold by themselves. The -fonts, including any derivative works, can be bundled, embedded, -redistributed and/or sold with any software provided that any reserved -names are not used by derivative works. The fonts and derivatives, -however, cannot be released under any other type of license. The -requirement for fonts to remain under this license does not apply -to any document created using the fonts or their derivatives. - -DEFINITIONS -"Font Software" refers to the set of files released by the Copyright -Holder(s) under this license and clearly marked as such. This may -include source files, build scripts and documentation. - -"Reserved Font Name" refers to any names specified as such after the -copyright statement(s). - -"Original Version" refers to the collection of Font Software components as -distributed by the Copyright Holder(s). - -"Modified Version" refers to any derivative made by adding to, deleting, -or substituting -- in part or in whole -- any of the components of the -Original Version, by changing formats or by porting the Font Software to a -new environment. - -"Author" refers to any designer, engineer, programmer, technical -writer or other person who contributed to the Font Software. - -PERMISSION & CONDITIONS -Permission is hereby granted, free of charge, to any person obtaining -a copy of the Font Software, to use, study, copy, merge, embed, modify, -redistribute, and sell modified and unmodified copies of the Font -Software, subject to the following conditions: - -1) Neither the Font Software nor any of its individual components, -in Original or Modified Versions, may be sold by itself. - -2) Original or Modified Versions of the Font Software may be bundled, -redistributed and/or sold with any software, provided that each copy -contains the above copyright notice and this license. These can be -included either as stand-alone text files, human-readable headers or -in the appropriate machine-readable metadata fields within text or -binary files as long as those fields can be easily viewed by the user. - -3) No Modified Version of the Font Software may use the Reserved Font -Name(s) unless explicit written permission is granted by the corresponding -Copyright Holder. This restriction only applies to the primary font name as -presented to the users. - -4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font -Software shall not be used to promote, endorse or advertise any -Modified Version, except to acknowledge the contribution(s) of the -Copyright Holder(s) and the Author(s) or with their explicit written -permission. - -5) The Font Software, modified or unmodified, in part or in whole, -must be distributed entirely under this license, and must not be -distributed under any other license. The requirement for fonts to -remain under this license does not apply to any document created -using the Font Software. - -TERMINATION -This license becomes null and void if any of the above conditions are -not met. - -DISCLAIMER -THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT -OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE -COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, -INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL -DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM -OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/static/src/fonts/Lekton/Lekton-Bold.ttf b/static/src/fonts/Lekton/Lekton-Bold.ttf deleted file mode 100644 index fbbb3139aa287e89ec938471222db766259e1dc9..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lekton/Lekton-Bold.ttf and /dev/null differ diff --git a/static/src/fonts/Lekton/Lekton-Italic.ttf b/static/src/fonts/Lekton/Lekton-Italic.ttf deleted file mode 100644 index 4f7afcebd3ffaa39a609c3f2d45552aa201d05db..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lekton/Lekton-Italic.ttf and /dev/null differ diff --git a/static/src/fonts/Lekton/Lekton-Regular.ttf b/static/src/fonts/Lekton/Lekton-Regular.ttf deleted file mode 100644 index 7021e3fb1a478e00377a18e7f540b0339b01b5bc..0000000000000000000000000000000000000000 Binary files a/static/src/fonts/Lekton/Lekton-Regular.ttf and /dev/null differ diff --git a/static/src/fonts/Lekton/OFL.txt b/static/src/fonts/Lekton/OFL.txt deleted file mode 100644 index b34b58d54939a4ee92229f8999ec0d1ccf59572b..0000000000000000000000000000000000000000 --- a/static/src/fonts/Lekton/OFL.txt +++ /dev/null @@ -1,93 +0,0 @@ -Copyright (c) 2008-2010, Isia Urbino (http://www.isiaurbino.net) - -This Font Software is licensed under the SIL Open Font License, Version 1.1. -This license is copied below, and is also available with a FAQ at: -http://scripts.sil.org/OFL - - ------------------------------------------------------------ -SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 ------------------------------------------------------------ - -PREAMBLE -The goals of the Open Font License (OFL) are to stimulate worldwide -development of collaborative font projects, to support the font creation -efforts of academic and linguistic communities, and to provide a free and -open framework in which fonts may be shared and improved in partnership -with others. - -The OFL allows the licensed fonts to be used, studied, modified and -redistributed freely as long as they are not sold by themselves. The -fonts, including any derivative works, can be bundled, embedded, -redistributed and/or sold with any software provided that any reserved -names are not used by derivative works. The fonts and derivatives, -however, cannot be released under any other type of license. The -requirement for fonts to remain under this license does not apply -to any document created using the fonts or their derivatives. - -DEFINITIONS -"Font Software" refers to the set of files released by the Copyright -Holder(s) under this license and clearly marked as such. This may -include source files, build scripts and documentation. - -"Reserved Font Name" refers to any names specified as such after the -copyright statement(s). - -"Original Version" refers to the collection of Font Software components as -distributed by the Copyright Holder(s). - -"Modified Version" refers to any derivative made by adding to, deleting, -or substituting -- in part or in whole -- any of the components of the -Original Version, by changing formats or by porting the Font Software to a -new environment. - -"Author" refers to any designer, engineer, programmer, technical -writer or other person who contributed to the Font Software. - -PERMISSION & CONDITIONS -Permission is hereby granted, free of charge, to any person obtaining -a copy of the Font Software, to use, study, copy, merge, embed, modify, -redistribute, and sell modified and unmodified copies of the Font -Software, subject to the following conditions: - -1) Neither the Font Software nor any of its individual components, -in Original or Modified Versions, may be sold by itself. - -2) Original or Modified Versions of the Font Software may be bundled, -redistributed and/or sold with any software, provided that each copy -contains the above copyright notice and this license. These can be -included either as stand-alone text files, human-readable headers or -in the appropriate machine-readable metadata fields within text or -binary files as long as those fields can be easily viewed by the user. - -3) No Modified Version of the Font Software may use the Reserved Font -Name(s) unless explicit written permission is granted by the corresponding -Copyright Holder. This restriction only applies to the primary font name as -presented to the users. - -4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font -Software shall not be used to promote, endorse or advertise any -Modified Version, except to acknowledge the contribution(s) of the -Copyright Holder(s) and the Author(s) or with their explicit written -permission. - -5) The Font Software, modified or unmodified, in part or in whole, -must be distributed entirely under this license, and must not be -distributed under any other license. The requirement for fonts to -remain under this license does not apply to any document created -using the Font Software. - -TERMINATION -This license becomes null and void if any of the above conditions are -not met. - -DISCLAIMER -THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT -OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE -COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, -INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL -DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM -OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/static/src/img/logo-datadock.jpg b/static/src/img/logo-datadock.jpg deleted file mode 100644 index 354fb24bc9924caf2507ee1319511b0adad7d746..0000000000000000000000000000000000000000 Binary files a/static/src/img/logo-datadock.jpg and /dev/null differ diff --git a/static/src/img/logo-lefilament.png b/static/src/img/logo-lefilament.png deleted file mode 100644 index 0d0eac612a05955114444dc1c531f3aba9de421d..0000000000000000000000000000000000000000 Binary files a/static/src/img/logo-lefilament.png and /dev/null differ diff --git a/static/src/scss/style.scss b/static/src/scss/style.scss index 85d02e5845cf37fa7de0a3bc9618f3ee46e7ac39..1b989dd7446a5f63ee98e8f331f4795f4c2bc0e7 100644 --- a/static/src/scss/style.scss +++ b/static/src/scss/style.scss @@ -1,55 +1,8 @@ -/*************************** -/** Fonts -***************************/ -@font-face { - font-family: "Lato"; - src: url(../fonts/Lato/Lato-Regular.ttf); - font-weight: normal; - font-style: normal; -} -@font-face { - font-family: "Lato"; - src: url(../fonts/Lato/Lato-Light.ttf); - font-weight: 300; - font-style: normal; -} -@font-face { - font-family: "Lato"; - src: url(../fonts/Lato/Lato-Bold.ttf); - font-weight: bold; - font-style: normal; -} -@font-face { - font-family: "Lekton"; - src: url(../fonts/Lekton/Lekton-Regular.ttf); - font-weight: normal; - font-style: normal; -} -@font-face { - font-family: "Lekton"; - src: url(../fonts/Lekton/Lekton-Bold.ttf); - font-weight: bold; - font-style: normal; -} - -/*************************** -/** Variables -***************************/ -$typo_body: "Lato", sans-serif; -$typo_1: "Lekton", sans-serif; - -$color1: #1c2f82; -$color2: rgb(0, 180, 149); - /*************************** /** Global ***************************/ -body, -table, -td, -span, -div { - font-family: inherit; +.training_layout .bg-white { + background-color: #fff !important; } .attendance { @@ -63,15 +16,13 @@ div { .attendance td, .convention, .convention td { - font-family: $typo_body; font-weight: 300; + background-color: #fff; } - .training-footer { border-top: 1px solid #eee; padding-top: 10px; font-size: 11px; - font-family: $typo_1; text-align: center; color: #333; } @@ -80,32 +31,23 @@ div { /** Attendance ***************************/ .attendance h1 { - color: $color2; font-size: 26px; - font-family: $typo_1; text-transform: uppercase; } .attendance h2 { - color: $color1; font-size: 22px; - font-family: $typo_1; } /*************************** /** Convention ***************************/ .convention h1 { - background-color: $color2; - color: #fff; padding: 5px 0; font-size: 26px; - font-family: $typo_1; text-transform: uppercase; } .convention h2 { - color: $color1; font-size: 22px; - font-family: $typo_1; text-transform: uppercase; } .convention h3 { diff --git a/templates/report_agreement.xml b/templates/report_agreement.xml new file mode 100644 index 0000000000000000000000000000000000000000..43ecdbb48bb096acf274d38185f5024b2e2ad574 --- /dev/null +++ b/templates/report_agreement.xml @@ -0,0 +1,268 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + <template id="qweb_agreement_pdf"> + <t t-call="web.html_container"> + <t t-foreach="docs" t-as="doc"> + <t t-call="web.external_layout"> + <!-- Call CSS config --> + <t t-call="lefilament_training.training_styles_company"> + <t t-set="company" t-value="doc.company_id" /> + </t> + + <div class="page"> + <div class="convention training_layout"> + <div class="col-12 text-center"> + <h1> + CONVENTION DE FORMATION PROFESSIONNELLE N°<t t-out="doc.agreement_number" /> + </h1> + <h2 t-field="doc.course_id.name" /> + <hr /> + </div> + <div class="col-12"> + <p>ENTRE :</p> + <p> + <strong><t t-out="doc.company_id.name" /></strong> – Déclaration d’activité enregistrée sous le numéro <t t-out="doc.company_id.training_number" /> - dont le siège est situé <t t-out="doc.company_id.partner_id._display_address(without_company=True)" />. + <br /> + Représenté par <t t-out="doc.signin_person" />, <t t-out="doc.signin_function" /> + </p> + <p>ET</p> + <p> + <strong><t t-out="doc.customer_id.name" /></strong> - <t t-out="doc.customer_id._display_address(without_company=True)" />. + </p> + <p> + Il est établi la présente convention de formation en application des dispositions de la sixième partie du Code du Travail (article L6353-1 à 2 et R6353-1) portant organisation de la formation professionnelle continue tout au long de la vie. + </p> + + <div class="subblock"> + <h3>ARTICLE 1 - OBJET ET CARACTERISTIQUES DE LA FORMATION</h3> + <p> + En exécution de la présente convention, l’organisme LE FILAMENT s’engage à organiser l’action de formation intitulée : <strong><t t-out="doc.course_id.name" /></strong> + </p> + <p> + <span class="text-decoration-underline">Nature de l’action au sens de l’article L.6313-1 du code du travail</span> :<br /> + Développement des compétences et de la qualification professionnelle + </p> + <p> + <span class="text-decoration-underline">Compétences visées</span> : <br /> + À l’issue de la formation l'apprenant sera en mesure de :<br /> + <span t-field="doc.course_id.objective" /> + </p> + <p> + <span class="text-decoration-underline">Prérequis</span> : <br /> + <t t-out="doc.course_id.prerequisites" /> + </p> + <p> + <span class="text-decoration-underline">Profil des stagiaires</span> : <br /> + <t t-out="doc.course_id.students_profile" /> + </p> + <p> + <span class="text-decoration-underline">Formateur(s)</span> : <br /> + <t t-set="trainers" t-value="doc._get_trainers()" /> + <t t-foreach="trainers" t-as="trainer"> + <t t-out="trainer.name" /><br /> + </t> + </p> + <p> + <span class="text-decoration-underline">Modalités et délais d'accès</span> : <br /> + Nous avoir renvoyé la convention signée au plus tard 24h avant la formation + </p> + </div> + + <div class="subblock"> + <h3>ARTICLE 2 – LIEU ET DATE DE LA FORMATION</h3> + <table + class="table table-borderless table-sm" + style="border: 0px; border-color: transparent;" + > + <tbody style="border: 0px;"> + <tr style="border: 0px;"> + <td style="width: 160px; border: 0px;"> + Lieu : + </td> + <td style="border: 0px;"> + <span t-field="doc.place" /> + </td> + </tr> + <tr> + <td style="width: 160px; border: 0px;"> + Dates : + </td> + <td style="border: 0px;"> + Du <span t-field="doc.date_begin" /> au <span t-field="doc.date_end" /> + </td> + </tr> + <tr style="border: 0px;"> + <td style="width: 160px; border: 0px;"> + Durée : + </td> + <td style="border: 0px;"> + <span t-out="doc.hours" />h + </td> + </tr> + <tr style="border: 0px;" t-if="doc.meanings"> + <td style="width: 160px; border: 0px;"> + Dispositif : + </td> + <td style="border: 0px;"> + <t t-out="doc.meanings" /> + </td> + </tr> + </tbody> + </table> + </div> + <div class="subblock"> + <h3>ARTICLE 3 – STAGIAIRES BENEFICIAIRES DE L’ACTION</h3> + <p>L’entreprise signataire inscrit à cette formation les personnes suivantes :</p> + <t t-foreach="doc.student_ids" t-as="student"> + <strong><span t-field="student.student_id.lastname" /> <span t-field="student.student_id.firstname" /></strong><br /> + </t> + <p> + Nombre d'inscrit(s) : <strong><span t-esc="doc.students_count" /></strong> + </p> + </div> + <div class="subblock"> + <h3>ARTICLE 4 – MODALITES FINANCIERES</h3> + <p>Le coût de la formation, objet de la présente convention, s’élève à : </p> + <table class="table table-borderless table-sm"> + <thead> + <tr> + <th>Intitulé</th> + <th>Prix HT</th> + <th>TVA</th> + <th>Prix TTC</th> + </tr> + </thead> + <tbody> + <tr> + <td><span t-field="doc.course_id.name" /></td> + <td + t-out="doc.cost" + class="text-end" + t-options="{'widget': 'monetary', 'display_currency': doc.company_id.currency_id}" + /> + <td + t-out="doc.cost * 0.2 if doc.is_vat else 0" + class="text-end" + t-options="{'widget': 'monetary', 'display_currency': doc.company_id.currency_id}" + /> + <td + t-out="doc.cost * 1.2 if doc.is_vat else doc.cost" + class="text-end" + t-options="{'widget': 'monetary', 'display_currency': doc.company_id.currency_id}" + /> + </tr> + </tbody> + </table> + <p> + Cette somme couvre l’intégralité des frais engagés par l’organisme de formation pour cette session. + </p> + <p t-if="doc.payment_term_id" t-out="doc.payment_term_id.note" /> + </div> + <div class="subblock"> + <h3>ARTICLE 5 – MOYENS PEDAGOGIQUES ET TECHNIQUES MIS EN OEUVRE</h3> + <p><span t-field="doc.course_id.means" /></p> + </div> + <div class="subblock"> + <h3>ARTICLE 6 – MOYENS PERMETTANT D’APPRECIER LES RESULTATS DE L’ACTION</h3> + <p><span t-field="doc.course_id.evaluation" /></p> + </div> + <div class="subblock"> + <h3>ARTICLE 7 – MOYENS PERMETTANT DE SUIVRE L’EXECUTION DE L’ACTION</h3> + <p><span t-field="doc.course_id.control" /></p> + </div> + <div class="subblock"> + <h3>ARTICLE 8 – SANCTION DE LA FORMATION</h3> + <p> + En application de l’article L6353-1 du Code du Travail, une attestation mentionnant les objectifs, la nature et la durée de l’action, les résultats de l’évaluation des acquis de la formation sera transmise aux stagiaires à l’issue de la formation. + </p> + </div> + <div class="subblock"> + <h3>ARTICLE 9 – DELAI DE RETRACTATION ET CONDITIONS D’ANNULATION</h3> + <p> + Conformément à la législation en vigueur (cf. Partie 6 du Code du Travail), l’entreprise signataire dispose d'un délai de 10 jours à compter de la signature de la présente convention pour se rétracter, par lettre recommandée avec accusé de réception. + </p> + <p> + Si, en cas de force majeure dûment reconnue, l’entreprise signataire est empêchée de suivre le programme de formation objet de la présente convention, elle pourra résilier ce contrat. Dans ce cas, seules les prestations effectivement dispensées seront dues prorata temporis de leur valeur prévue au contrat. + </p> + <p> + Pour toute annulation faite par le client moins de 10 jours avant le début du stage, <t t-out="doc.company_id.name" /> facturera un dédit de 50% des frais de stage, montant non imputable par l’entreprise à la contribution financière obligatoire de formation. En cas d’absence ou d’abandon en cours de stage d’un stagiaire, la formation reste payable en totalité. + </p> + <p> + Dans le cas de force majeure dûment reconnue, ou de la cessation anticipée du fait de l’organisme de formation, de nouvelles dates seront convenues. + </p> + <p class="fw-bold">Substitution</p> + <p> + Jusqu’à 24 h avant le début de la session de formation, le Client peut, sans aucun frais supplémentaire, substituer une personne inscrite par ses soins par tout autre personne de son choix en respectant les pré-requis et à condition d’en informer par écrit. Cependant, l’alternance d’un stagiaire par un autre en cours de module de formation n’est pas acceptée. + </p> + <p> + Annulation-report du fait de <t t-out="doc.company_id.name" /> : <t t-out="doc.company_id.name" /> se réserve la possibilité de reporter ou d’annuler une formation. <t t-out="doc.company_id.name" /> en informe alors le Client dans les plus brefs délais. En cas de report, il incombe alors au Client de confirmer sa participation à la nouvelle session qui lui sera proposée. Aucune indemnité ne sera versée au Client en raison d’un report ou d’une annulation du fait de <t t-out="doc.company_id.name" />. + </p> + <p> + En cas de renoncement par <t t-out="doc.company_id.name" /> à l’exécution de la présente convention, aucun règlement n’est dû et les sommes perçues sont remboursées. + </p> + </div> + + <div class="subblock"> + <h3>ARTICLE 10 – DROIT APPLICABLE</h3> + <p>Le présent contrat est régi par le droit français.</p> + <p>En cas de litige résultant de l'interprétation du présent contrat, de son exécution, ou en cas de rupture du lien contractuel, la juridiction compétente sera le tribunal de Toulouse.</p> + <p t-if="doc.company_id.agreement_special_condition" t-out="doc.company_id.agreement_special_condition" class="mt-3" /> + <p class="mt-3 mb-33"> + Fait à <span t-field="doc.place_convention" />, le <span t-field="doc.date_convention" /> + </p> + <table + class="table table-borderless" + style="border: 0px; border-color: transparent;" + > + <tr> + <td style="border-color: #eee;"> + Pour <span t-field="doc.customer_id.name"/> <br /> + (Cachet et signature) + </td> + <td style="border: 0;"> + Pour <t t-out="doc.company_id.name" class="text-uppercase" /><br /> + <t t-if="doc.signin_person"> + <t t-out="doc.signin_person" /> + <t t-if="doc.signin_function">, <t t-out="doc.signin_function" /></t> + <br /> + </t> + (Cachet et signature) + </td> + </tr> + </table> + </div> + </div> + </div> + </div> + </t> + </t> + </t> + </template> + + <record id="paperformat_a4_training" model="report.paperformat"> + <field name="name">A4 Formation</field> + <field name="default" eval="True" /> + <field name="format">A4</field> + <field name="orientation">Portrait</field> + <field name="margin_top">35</field> + <field name="margin_bottom">30</field> + <field name="margin_left">10</field> + <field name="margin_right">10</field> + <field name="header_line" eval="False" /> + <field name="header_spacing">30</field> + <field name="dpi">90</field> + </record> + + <record id="report_agreement_pdf" model="ir.actions.report"> + <field name="name">Formation - Convention</field> + <field name="model">training.training</field> + <field name="report_type">qweb-pdf</field> + <field name="report_name">lefilament_training.qweb_agreement_pdf</field> + <field name="binding_model_id" ref="model_training_training" /> + <field name="binding_type">report</field> + <field name="paperformat_id" ref="paperformat_a4_training" /> + </record> + +</odoo> diff --git a/report/report_attendance_sheet.xml b/templates/report_attendance_sheet.xml similarity index 55% rename from report/report_attendance_sheet.xml rename to templates/report_attendance_sheet.xml index 7405954e70e0d13969a6f3a91226056167855b7f..9353282a87cb826c462ccffa48a7547297812835 100644 --- a/report/report_attendance_sheet.xml +++ b/templates/report_attendance_sheet.xml @@ -6,31 +6,32 @@ <t t-call="web.html_container"> <t t-foreach="docs" t-as="doc"> <t t-call="web.external_layout"> - <!-- gestion du nombre de sessions par page = 8 --> <t t-set="nb_case" t-value="8" /> <t t-set="nb_page" t-value="int(len(doc.session_ids)/nb_case) + 1" /> - - <div class="page"> + <t t-call="lefilament_training.training_styles_company"> + <t t-set="company" t-value="doc.company_id" /> + </t> + <div class="page"> <t t-foreach="nb_page" t-as="page"> - <div class="row attendance"> - <div class="col-12 content-pdf"> - + <div class="attendance training_layout"> + <div class="row"> <div class="col-12 text-center"> <h1> FORMATION : <span t-field="doc.course_id.name" /> </h1> - <hr /> <h2> Feuille d'émargement </h2> </div> - <div class="col-6"> + </div> + <div class="row"> + <div class="col-6 mt-4"> <strong>Lieu : </strong><span t-field="doc.place" /><br /> @@ -39,9 +40,12 @@ /> au <span t-field="doc.date_end" /><br /> <strong>Durée : </strong><span t-field="doc.hours" - />h + />h<br /> + <strong>Client : </strong><span + t-field="doc.customer_id.name" + /> </div> - <div class="col-6"> + <div class="col-6 mt-4"> <t t-if="doc.file_number"> <strong>N° Dossier : </strong><span t-field="doc.file_number" @@ -53,106 +57,72 @@ /> </t> </div> - <div class="col-12 mt16 mb16"> + </div> + <div class="row"> + <div class="col-12 my-4"> <table class="table table-bordered"> <thead> <tr> - <th - scope="col" - style="vertical-align: middle; width: 100px;" - >Nom</th> - <th - scope="col" - style="vertical-align: middle; width: 100px;" - >Prénom</th> + <th scope="col" style="vertical-align: middle; width: 100px;"> + Nom + </th> + <th scope="col" style="vertical-align: middle; width: 100px;"> + Prénom + </th> <t t-foreach="doc.session_ids[nb_case * page_index:nb_case * (page_index + 1)]" t-as="session" > - <th - scope="row" - style="vertical-align: middle; width: 100px;" - > - <span - t-field="session.date" - t-options='{"format": "dd/MM/yyyy"}' - /><br /> - Début : <span - t-field="session.date" - t-options='{"format": "HH:mm"}' - /><br /> - Durée : <span - t-esc="session.date_delay" - />h + <th scope="row" style="vertical-align: middle; width: 100px;"> + <span t-field="session.date" t-options='{"format": "dd/MM/yyyy"}' /><br /> + Début : <span t-field="session.date" t-options='{"format": "HH:mm"}' /><br /> + Durée : <span t-esc="session.date_delay" />h </th> </t> </tr> </thead> <tbody> - <t - t-set="length" - t-value="nb_case + 2" - /> + <t t-set="length" t-value="nb_case + 2" /> <tr style="background-color: #eee;"> - <td - t-att-colspan="length" - >Stagiaires</td> + <td t-att-colspan="length"> + Stagiaires + </td> </tr> - <t - t-foreach="doc.student_ids" - t-as="student" - > + <t t-foreach="doc.student_ids" t-as="student"> <tr style="height: 60px;"> - <th - scope="col" - style="vertical-align: middle;" - ><span - t-field="student.student_id.lastname" - /></th> - <th - scope="col" - style="vertical-align: middle;" - ><span - t-field="student.student_id.firstname" - /></th> + <th scope="col" style="vertical-align: middle;"> + <span t-field="student.student_id.lastname" /> + </th> + <th scope="col" style="vertical-align: middle;"> + <span t-field="student.student_id.firstname" /> + </th> <t t-foreach="doc.session_ids[nb_case * page_index:nb_case * (page_index + 1)]" t-as="session" > - <td> - </td> + <td class="bg-white" /> </t> </tr> </t> - <t - t-set="trainers" - t-value="doc._get_trainers()" - /> + <t t-set="trainers" t-value="doc._get_trainers()" /> <tr style="background-color: #eee;"> - <td - t-att-colspan="length" - >Formateur(s)</td> + <td t-att-colspan="length"> + Formateur(s) + </td> </tr> <t t-foreach="trainers" t-as="trainer"> <tr style="height: 60px;"> - <th - scope="col" - style="vertical-align: middle;" - ><span - t-field="trainer.lastname" - /></th> - <th - scope="col" - style="vertical-align: middle;" - ><span - t-field="trainer.firstname" - /></th> + <th scope="col" style="vertical-align: middle;"> + <span t-field="trainer.lastname" /> + </th> + <th scope="col" style="vertical-align: middle;"> + <span t-field="trainer.firstname" /> + </th> <t t-foreach="doc.session_ids[nb_case * page_index:nb_case * (page_index + 1)]" t-as="session" > - <td> - </td> + <td class="bg-white" /> </t> </tr> </t> @@ -162,8 +132,7 @@ </div> </div> </t> - </div> - + </div> </t> </t> </t> diff --git a/templates/report_attestation.xml b/templates/report_attestation.xml new file mode 100644 index 0000000000000000000000000000000000000000..ca3cf5ebcbee20c93fb5a88e6fbc16ef6fefed91 --- /dev/null +++ b/templates/report_attestation.xml @@ -0,0 +1,106 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + <template id="qweb_attestation_pdf"> + <t t-call="web.html_container"> + <t t-foreach="docs" t-as="doc"> + <t t-foreach="doc.student_ids" t-as="student"> + <t t-call="web.external_layout"> + <!-- Call CSS config --> + <t t-call="lefilament_training.training_styles_company"> + <t t-set="company" t-value="doc.company_id" /> + </t> + + <div class="page"> + <div class="row convention training_layout"> + <div class="col-12"> + <div class="col-12 text-center"> + <h1>ATTESTATION DE FIN DE FORMATION</h1> + </div> + + <div class="col-12" style="margin-top: 20px;"> + <p> + Je soussigné, <t t-out="doc.signin_person" />, agissant en qualité de <t t-out="doc.signin_function" /> au sein de l’organisme de formation <t t-out="doc.company_id.name" />, enregistré sous le numéro <t t-out="doc.company_id.training_number" />, atteste que : + </p> + <p> + <strong><t t-out="student.student_id.name" /></strong> + </p> + <p> + Salarié(e) de la société <strong><t t-out="doc.customer_id.name" /></strong>, située au <t t-out="doc.customer_id._display_address(without_company=True)" />, + </p> + <p> + A suivi la formation suivante : + </p> + <h2 class="text-center" t-out="doc.course_id.name"/> + + <h3>OBJECTIFS DE LA FORMATION</h3> + <p t-field="doc.course_id.objective" /> + + <h3>NATURE DE L’ACTION DE FORMATION</h3> + <p t-field="doc.course_id.nature" /> + + <h3>MODALITÉS DE LA FORMATION</h3> + <table class="table table-striped"> + <tbody> + <tr> + <td style="width: 120px;"> + <strong>Dates</strong> + </td> + <td> + Du <span t-field="doc.date_begin" /> au <span t-field="doc.date_end" /> + </td> + <td style="width: 120px;"> + <strong>Lieu</strong> + </td> + <td> + <span t-field="doc.place" /> + </td> + </tr> + <tr> + <td style="width: 120px;"> + <strong>Durée</strong> + </td> + <td> + <span t-out="doc.hours" /> heures + </td> + <td style="width: 120px;"> + <strong>Intervenant(s)</strong> + </td> + <td> + <t t-set="trainers" t-value="doc._get_trainers()" /> + <t t-foreach="trainers" t-as="trainer"> + <span t-field="trainer.lastname" /> <span t-field="trainer.firstname" />, + </t> + </td> + </tr> + </tbody> + </table> + + <h3>ACQUIS DE LA FORMATION</h3> + <p t-field="doc.course_id.acquis" /> + </div> + <div class="col-offset-8 col-4" style="margin-top: 20px;"> + Pour valoir ce que de droit <br /> + Fait à <span t-field="doc.place_attestation" />, le <span t-field="doc.date_attestation" /> + </div> + </div> + </div> + </div> + </t> + </t> + </t> + </t> + </template> + + <record id="report_attestation_pdf" model="ir.actions.report"> + <field name="name">Formation - Attestations</field> + <field name="model">training.training</field> + <field name="report_type">qweb-pdf</field> + <field name="report_name">lefilament_training.qweb_attestation_pdf</field> + <field name="binding_model_id" ref="model_training_training" /> + <field name="binding_type">report</field> + <field name="paperformat_id" ref="paperformat_a4_training" /> + </record> + +</odoo> diff --git a/templates/report_config_settings.xml b/templates/report_config_settings.xml new file mode 100644 index 0000000000000000000000000000000000000000..13b7b2f514bbb4cf555e275e421d3ffb00d6793c --- /dev/null +++ b/templates/report_config_settings.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + <template id="training_styles_company"> + <style type="text/css"> + .training_layout body, + .training_layout table, + .training_layout td, + .training_layout span, + .training_layout div { + font-family: <t t-out="company.text_font" />; + } + .training_layout h1 { + color: <t t-out='company.title_color'/>; + background-color: <t t-out='company.title_bg_color'/>; + font-family: <t t-out="company.title_font" />; + } + .training_layout h2 { + color: <t t-out='company.subtitle_color'/> !important; + font-family: <t t-out="company.title_font" />; + } + </style> + </template> +</odoo> diff --git a/templates/report_convocation.xml b/templates/report_convocation.xml new file mode 100644 index 0000000000000000000000000000000000000000..50943d94d2b81d7cf7d4aba267ac53adcce38dfe --- /dev/null +++ b/templates/report_convocation.xml @@ -0,0 +1,102 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + <template id="qweb_convocation_pdf"> + <t t-call="web.html_container"> + <t t-foreach="docs" t-as="doc"> + <t t-foreach="doc.student_ids" t-as="student"> + <t t-call="web.external_layout"> + <!-- Call CSS config --> + <t t-call="lefilament_training.training_styles_company"> + <t t-set="company" t-value="doc.company_id" /> + </t> + + <div class="page"> + <div class="convention training_layout"> + <div class="row mb-4"> + <div class="offset-8 col-4"> + <p> + À <t t-if="student.student_id.title"><t t-out="student.student_id.title.name" /> </t><t t-out="student.student_id.lastname" class="text-uppercase" /> <t t-out="student.student_id.firstname"/> + <br /> + <t t-out="doc.company_id.city" />, le <t t-out="doc.date_convocation" t-options="{'widget': 'date', 'format': 'dd/MM/yyyy'}" /> + </p> + </div> + </div> + + <div class="row mb-4"> + <div class="col-12 text-center"> + <h1 class="text-uppercase">Convocation à une formation</h1> + </div> + </div> + + <div class="row"> + <div class="col-12"> + <p t-if="student.student_id.title" class="mb-2"> + <t t-out="student.student_id.title.name" />, + </p> + <p> + Nous avons le plaisir de vous convier à la formation : + </p> + <h2 class="text-center" t-out="doc.course_id.name"/> + <p> + dont l'objectif est de vous permettre de : <br /> + <span t-field="doc.course_id.objective" /> + </p> + <p> + Le programme détaillé de cette formation est joint en annexe.<br /> + Pour toute demande d’information concernant cette formation, vous pouvez vous adresser à : <a t-attf-href="mailto:{{doc.email_contact}}"><t t-out="doc.email_contact" /></a> + </p> + <p> + Cette formation se déroulera : + <ul> + <li t-if="doc.training_type_id">au format suivant : <span t-out="doc.training_type_id.name" class="fw-bold text-decoration-underline" /><br /></li> + <li> + aux dates suivantes : + <ul> + <li t-foreach="doc.session_ids" t-as="session"> + <t t-out="session.date" t-options="{'widget': 'datetime', 'format': 'dd/MM/yyyy'}" /> de <t t-out="session.date" t-options="{'widget': 'datetime', 'format': 'HH:mm'}" /> à <t t-out="session.date + relativedelta(hours=session.date_delay)" t-options="{'widget': 'datetime', 'format': 'HH:mm'}" /> + </li> + </ul> + </li> + </ul> + </p> + <p> + Lieu : <span t-out="doc.place" class="fw-bold" /> + <t t-if="doc.place_detail"> + <br/><span t-field="doc.place_detail" class="fst-italic" /> + </t> + </p> + <p t-if="doc.equipment"> + Nous vous prions pour le bon déroulé de la formation d'apporter les éléments suivants : <br/> + <span t-field="doc.equipment" /> + </p> + <p> + <span class="fw-bold">Situations particulières</span><br/> + Pour toute difficulté ou handicap, veuillez contacter <a t-attf-href="mailto:{{doc.email_contact}}"><t t-out="doc.email_contact" /></a> pour voir les éventuelles adaptations à prévoir. + </p> + <p> + Nous vous prions d’agréer, <t t-if="student.student_id.title"><t t-out="student.student_id.title.name" />, </t>l’expression de nos cordiales salutations. <br /> + Fait à <span t-field="doc.company_id.city" />, le <span t-field="doc.date_convocation" /> + </p> + </div> + </div> + </div> + </div> + </t> + </t> + </t> + </t> + </template> + + <record id="report_convocation_pdf" model="ir.actions.report"> + <field name="name">Formation - Convocation</field> + <field name="model">training.training</field> + <field name="report_type">qweb-pdf</field> + <field name="report_name">lefilament_training.qweb_convocation_pdf</field> + <field name="binding_model_id" ref="model_training_training" /> + <field name="binding_type">report</field> + <field name="paperformat_id" ref="paperformat_a4_training" /> + </record> + +</odoo> diff --git a/templates/report_program.xml b/templates/report_program.xml new file mode 100644 index 0000000000000000000000000000000000000000..27505581e4edddd671fafd62d833c223b511d0a3 --- /dev/null +++ b/templates/report_program.xml @@ -0,0 +1,142 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + <template id="qweb_program_pdf"> + <t t-call="web.html_container"> + <t t-foreach="docs" t-as="doc"> + <t t-call="web.external_layout"> + <!-- Call CSS config --> + <t t-call="lefilament_training.training_styles_company"> + <t t-set="company" t-value="doc.company_id" /> + </t> + + <div class="page"> + <div class="row convention training_layout"> + <div class="col-12"> + <div class="text-center"> + <h1 t-field="doc.course_id.name" /> + <h2>Programme de formation</h2> + </div> + + <t t-set="chapter" t-value="1" /> + <div class="subblock" t-if="doc.course_id.description"> + <h3><t t-out="chapter" />. DESCRIPTION</h3> + <p t-field="doc.course_id.description" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.course_id.objective"> + <h3><t t-out="chapter" />. OBJECTIFS / COMPÉTENCES VISÉES</h3> + <p t-field="doc.course_id.objective" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="" t-if="doc.course_id.session_ids"> + <h3><t t-out="chapter" />. PROGRAMME DE LA FORMATION</h3> + <t t-foreach="doc.session_ids" t-as="session"> + <div class="subblock"> + <h4 style="margin-left: 40px;"> + <t t-out="chapter" />. <t t-out="'%01d' % (session_index+1)" /> <t t-out="session.session_id.name" /> + </h4> + <p style="margin-bottom: 40px;"> + <span t-field="session.session_id.description" /> + </p> + </div> + </t> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.course_id.method"> + <h3><t t-out="chapter" />. MÉTHODOLOGIE ET SUPPORTS PÉDAGOGIQUES</h3> + <span t-field="doc.course_id.method" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + <div class="subblock" t-if="doc.course_id.means"> + <h3><t t-out="chapter" />. MOYENS PÉDAGOGIQUES D'ENCADREMENT</h3> + <span t-field="doc.course_id.means" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.course_id.control"> + <h3><t t-out="chapter" />. SUIVI DE L’EXÉCUTION</h3> + <span t-field="doc.course_id.control" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.course_id.evaluation"> + <h3><t t-out="chapter" />. MODALITÉS D'ÉVALUATION</h3> + <span t-field="doc.course_id.evaluation" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.session_hours"> + <h3><t t-out="chapter" />. MODALITÉS ET DURÉE DE LA FORMATION</h3> + <p> + Formation dispensée en intra-entreprise par groupes de <t t-out="doc.students_nb_prev" /> personnes, et par session de demi-journées, afin de s’adapter aux contraintes de disponibilité de l’entreprise. + </p> + <p> + Horaires : <strong><t t-out="doc.session_hours" /></strong> + </p> + <p> + <strong><t t-out="doc.session_count"/> sessions</strong> de formation, soit <strong><t t-out="doc.hours" /> heures par personne</strong> + </p> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.date_begin"> + <h3><t t-out="chapter" />. LIEU ET DÉLAIS DE LA FORMATION</h3> + <p t-field="doc.place" /> + <p> + Du <t t-out="doc.date_begin" /> au <t t-out="doc.date_end" /> + </p> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + <div class="subblock" t-if="doc.cost"> + <h3><t t-out="chapter" />. COÛT DE LA FORMATION</h3> + <p> + <t t-out="doc.cost" /> € HT en formation INTRA de <t t-out="doc.students_nb_prev"/> personnes. + </p> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock" t-if="doc.course_id.students_profile"> + <h3><t t-out="chapter" />. LES STAGIAIRES</h3> + <span t-field="doc.course_id.students_profile" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="subblock mb-4" t-if="doc.course_id.prerequisites"> + <h3><t t-out="chapter" />. PRÉ-REQUIS</h3> + <span t-field="doc.course_id.prerequisites" /> + <t t-set="chapter" t-value="chapter + 1" /> + </div> + + <div class="text-center mt-4"> + <t t-foreach="doc.company_id.logo_ids" t-as="logo"> + <img + t-att-src="image_data_uri(logo.logo)" + style="height: 80px;" + class="img-fluid mx-3" + /> + </t> + </div> + </div> + </div> + </div> + </t> + </t> + </t> + </template> + + <record id="report_program_pdf" model="ir.actions.report"> + <field name="name">Formation - Programme</field> + <field name="model">training.training</field> + <field name="report_type">qweb-pdf</field> + <field name="report_name">lefilament_training.qweb_program_pdf</field> + <field name="binding_model_id" ref="model_training_training" /> + <field name="binding_type">report</field> + <field name="paperformat_id" ref="paperformat_a4_training" /> + </record> + +</odoo> diff --git a/views/menus.xml b/views/menus.xml new file mode 100644 index 0000000000000000000000000000000000000000..509a032d90623f6eae8a59b2991ce7e5eb0002e7 --- /dev/null +++ b/views/menus.xml @@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="utf-8" ?> +<odoo> + <!-- MENU --> + <menuitem + id="menu_training" + name="Formation" + sequence="160" + web_icon="lefilament_training,static/description/icon.png" + /> + + <menuitem + id="menu_training_training" + name="Gestion des Formations" + sequence="1" + parent="menu_training" + action="action_training_training" + /> + + <menuitem + id="menu_training_course" + name="Catalogue" + sequence="20" + parent="menu_training" + /> + <menuitem + id="menu_training_course_list" + name="Programmes" + sequence="10" + parent="menu_training_course" + action="action_training_course" + /> + <menuitem + id="menu_training_course_session" + name="Modules" + sequence="20" + parent="menu_training_course" + action="action_training_course_session" + /> + + <menuitem + id="menu_training_session" + name="Analyse des sessions" + sequence="50" + parent="menu_training" + action="action_training_session" + /> + + <menuitem + id="menu_training_config" + name="Configuration" + sequence="100" + parent="menu_training" + /> + <menuitem + id="menu_training_settings" + name="Paramètres" + sequence="10" + parent="menu_training_config" + action="action_training_config" + /> + <menuitem + id="menu_training_type" + name="Types de formation" + sequence="20" + parent="menu_training_config" + action="action_training_type" + /> +</odoo> diff --git a/views/res_company_view.xml b/views/res_company_view.xml new file mode 100644 index 0000000000000000000000000000000000000000..ff16ad91b370f869c3f2db6d773972b468940c33 --- /dev/null +++ b/views/res_company_view.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + + <!-- Form View --> + <record id="view_company_form_form_view" model="ir.ui.view"> + <field name="name">res.company.form.training</field> + <field name="model">res.company</field> + <field name="inherit_id" ref="base.view_company_form" /> + <field name="arch" type="xml"> + <xpath expr="//field[@name='company_registry']" position="after"> + <field name="training_number" /> + </xpath> + </field> + </record> + +</odoo> diff --git a/views/res_config_settings_view.xml b/views/res_config_settings_view.xml new file mode 100644 index 0000000000000000000000000000000000000000..99b32c1cf765c9e2e58a5c71280236b7c5c351d9 --- /dev/null +++ b/views/res_config_settings_view.xml @@ -0,0 +1,160 @@ +<?xml version="1.0" encoding="utf-8" ?> +<odoo> + <record id="res_config_settings_view_form" model="ir.ui.view"> + <field name="name">res.config.settings.view.form.inherit.training</field> + <field name="model">res.config.settings</field> + <field name="priority" eval="40" /> + <field name="inherit_id" ref="base.res_config_settings_view_form" /> + <field name="arch" type="xml"> + <xpath expr="//div[hasclass('settings')]" position="inside"> + <field + name="country_code" + invisible="1" + groups="account.group_account_manager" + /> + <div + class="app_settings_block" + data-string="Formation" + string="Formation" + data-key="lefilament_training" + groups="lefilament_training.group_training" + > + <h2>Infos Légales</h2> + <div + class="row mt16 o_settings_container" + name="title_report_settings" + > + <div class="col-12 o_setting_box"> + <div class="o_setting_left_pane" /> + <div class="o_setting_right_pane"> + <div class="content-group"> + <div class="row mt16"> + <label + for="training_number" + class="col-lg-6" + /> + <field name="training_number" /> + </div> + <div class="row mt16"> + <div class="col-12 fw-bold"> + Conditions spéciales à ajouter en fin de convention + </div> + <div class="col-12"> + <field + name="agreement_special_condition" + class="w-100" + widget="html" + /> + </div> + </div> + </div> + </div> + </div> + </div> + <h2>Configuration des PDF</h2> + <div + class="row mt16 o_settings_container" + name="title_report_settings" + > + <div class="col-12 col-lg-6 o_setting_box"> + <div class="o_setting_left_pane" /> + <div class="o_setting_right_pane"> + <span class="o_form_label">Titres</span> + <div class="content-group"> + <div class="row mt16"> + <label + for="title_color" + class="col-lg-6 o_light_label" + /> + <field name="title_color" widget="color" /> + </div> + <div class="row"> + <label + for="title_bg_color" + class="col-lg-6 o_light_label" + /> + <field name="title_bg_color" widget="color" /> + </div> + <div class="row"> + <label + for="subtitle_color" + class="col-lg-6 o_light_label" + /> + <field name="subtitle_color" widget="color" /> + </div> + <div class="row"> + <label + for="title_font" + class="col-lg-6 o_light_label" + /> + <field name="title_font" /> + </div> + </div> + </div> + </div> + <div class="col-12 col-lg-6 o_setting_box" id="rounding_method"> + <div class="o_setting_left_pane" /> + <div class="o_setting_right_pane"> + <span class="o_form_label">Texte</span> + <div class="content-group"> + <div class="row mt16"> + <label + for="text_font" + class="col-lg-6 o_light_label" + /> + <field name="text_font" /> + </div> + <div class="row mt16"> + <div class="col-lg-6"> + <label for="logo_ids" /> + <p class="text-muted"> + Les logos sont affichés à la fin de la page de programme + </p> + </div> + <field name="logo_ids" mode="kanban"> + <kanban delete="1"> + <field name="name" /> + <field name="company_id" /> + <field name="logo" /> + <templates> + <t t-name="kanban-box"> + <div + class="oe_kanban_global_click" + > + <field + name="logo" + preview_image="logo" + widget="image" + options="{'zoom': true, 'zoom_delay': 1000}" + /> + </div> + </t> + </templates> + </kanban> + <form string="Logos"> + <field name="logo" filename="name" /> + <field + name="company_id" + invisible="1" + /> + </form> + </field> + </div> + </div> + </div> + </div> + </div> + </div> + </xpath> + </field> + </record> + + <record id="action_training_config" model="ir.actions.act_window"> + <field name="name">Settings</field> + <field name="type">ir.actions.act_window</field> + <field name="res_model">res.config.settings</field> + <field name="view_mode">form</field> + <field name="target">inline</field> + <field name="context">{'module' : 'lefilament_training', 'bin_size': False}</field> + </record> +</odoo> diff --git a/views/partner_view.xml b/views/res_partner_view.xml similarity index 100% rename from views/partner_view.xml rename to views/res_partner_view.xml diff --git a/views/training_course_view.xml b/views/training_course_view.xml index 4db709e494a9164c711afa96d4b6a4596ecf49d5..c00b711026b2f476e8b6e74ad33cc88972658db3 100644 --- a/views/training_course_view.xml +++ b/views/training_course_view.xml @@ -2,20 +2,77 @@ <!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> <odoo> + <!-- Form View Programs --> <record id="training_course_form" model="ir.ui.view"> <field name="name">Training Course Form View</field> <field name="model">training.course</field> <field name="arch" type="xml"> <form string="Formation"> <sheet> + <label for="name" /> + <h1><field name="name" /></h1> <group> - <field name="name" /> - <field name="description" /> - <field name="objective" /> <field name="duration_total" /> </group> <notebook> - <page name="sessions" string="Sessions"> + <!-- Informations générales --> + <page name="general_info" string="Informations générales"> + <label for="description" class="mb-2" /> + <field name="description" class="mb-4" /> + + <label for="objective" class="mb-2" /> + <field name="objective" class="mb-4" /> + + <label for="method" class="mb-2" /> + <div class="text-muted"> + La méthodologie est décrite dans le programme de formation + </div> + <field name="method" class="mb-4" /> + + <label for="means" class="mb-2" /> + <div class="text-muted"> + Apparaît dans le programme et la convention + </div> + <field name="means" class="mb-4" /> + + <label for="control" class="mb-2" /> + <div class="text-muted"> + Apparaît dans le programme et la convention + </div> + <field name="control" class="mb-4" /> + + <label for="evaluation" class="mb-2" /> + <div class="text-muted"> + Apparaît dans le programme et la convention + </div> + <field name="evaluation" class="mb-4" /> + + <label for="students_profile" class="mb-2" /> + <div class="text-muted"> + Apparaît dans le programme et la convention + </div> + <field name="students_profile" class="mb-4" /> + + <label for="prerequisites" class="mb-2" /> + <div class="text-muted"> + Apparaît dans le programme et la convention + </div> + <field name="prerequisites" class="mb-4" /> + + <label for="nature" class="mb-2" /> + <div class="text-muted"> + Apparaît dans la convention et l'attestation de fin de formation + </div> + <field name="nature" class="mb-4" /> + + <label for="acquis" class="mb-2" /> + <div class="text-muted"> + Apparaît dans la convention et l'attestation de fin de formation + </div> + <field name="acquis" class="mb-4" /> + </page> + <!-- Sessions / Modules --> + <page name="sessions" string="Sessions/Modules"> <field name="session_ids" context="{'default_course_id': active_id,}" @@ -27,17 +84,6 @@ </tree> </field> </page> - <page name="detail" string="Détail"> - <group> - <field name="method" /> - <field name="means" /> - <field name="control" /> - <field name="evaluation" /> - <field name="students_profile" /> - <field name="nature" /> - <field name="acquis" /> - </group> - </page> </notebook> </sheet> <div class="oe_chatter"> @@ -54,15 +100,15 @@ <field name="name">Training Course Tree View</field> <field name="model">training.course</field> <field name="arch" type="xml"> - <tree decoration-danger="duration_total == 0"> - <field name="name" /> - <field name="duration_total" /> - <field name="session_count" /> - </tree> - </field> + <tree decoration-danger="duration_total == 0"> + <field name="name" /> + <field name="duration_total" /> + <field name="session_count" /> + </tree> + </field> </record> - <!-- Filtres et Champ de Recherche --> + <!-- Search view --> <record id="training_course_search" model="ir.ui.view"> <field name="name">Training Course Search View</field> <field name="model">training.course</field> @@ -83,11 +129,12 @@ </field> </record> + <!-- Form View --> <record id="training_course_session_form" model="ir.ui.view"> <field name="name">Training Course Session Form View</field> <field name="model">training.course.session</field> <field name="arch" type="xml"> - <form string="Fomration"> + <form string="Formation"> <sheet> <group> <field name="name" /> @@ -126,32 +173,4 @@ <field name="res_model">training.course.session</field> <field name="view_mode">tree,form,pivot,graph</field> </record> - - <!-- MENU --> - <menuitem - id="menu_training" - name="Formation" - sequence="160" - web_icon="lefilament_training,static/description/training.png" - /> - <menuitem - id="menu_training_course" - name="Catalogue" - sequence="40" - parent="menu_training" - /> - <menuitem - id="menu_training_course_list" - name="Programmes" - sequence="10" - parent="menu_training_course" - action="action_training_course" - /> - <menuitem - id="menu_training_course_session" - name="Modules" - sequence="20" - parent="menu_training_course" - action="action_training_course_session" - /> </odoo> diff --git a/views/training_session_view.xml b/views/training_session_view.xml index 78369e523adf1f479e94523c7c3787ea4f90cfc2..71cc7030443ec4651b29b4cb836afd0ddb99461b 100644 --- a/views/training_session_view.xml +++ b/views/training_session_view.xml @@ -79,13 +79,4 @@ <field name="view_mode">tree,form,calendar,pivot,graph</field> </record> - <!-- MENU --> - <menuitem - id="menu_training_session" - name="Sessions" - sequence="20" - parent="menu_training_training_parent" - action="action_training_session" - /> - </odoo> diff --git a/views/training_training_view.xml b/views/training_training_view.xml index 1ddf06b9867c26ec6437db6af144a7bd6a47310c..9f16a0cf81fb69e779cbe5af608f9f7a70e7539f 100644 --- a/views/training_training_view.xml +++ b/views/training_training_view.xml @@ -3,246 +3,252 @@ License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> <odoo> <record id="training_training_form" model="ir.ui.view"> - <field name="name">Training Form View</field> - <field name="model">training.training</field> - <field name="arch" type="xml"> - <form string="Contrat"> - <header> - <button + <field name="name">Training Form View</field> + <field name="model">training.training</field> + <field name="arch" type="xml"> + <form string="Contrat"> + <header> + <button name="action_valid" states="draft" string="Valider" class="btn-primary" type="object" /> - <button + <button name="action_done" states="current" string="Formation Terminée" class="btn-primary" type="object" /> - <button + <button name="action_draft" states="current,done" string="Remettre en brouillon" class="" type="object" /> - <field + <field name="state" widget="statusbar" nolabel="1" statusbar_visible="draft,current,done" /> - </header> - <sheet> - <group> - <group string="Formation"> - <field name="customer_id" required="1" /> - <field name="course_id" required="1" /> - <field name="date_begin" widget="date" required="1" /> - <field name="date_end" widget="date" required="1" /> - <field name="students_nb_prev" required="1" placeholder="ex : 4, 4 à 6" /> - <field + </header> + <sheet> + <group string="Formation"> + <group> + <field name="customer_id" required="1" /> + <field name="course_id" required="1" /> + <field name="training_type_id" options="{'no_create': 1}" /> + <field name="date_begin" widget="date" required="1" /> + <field name="date_end" widget="date" required="1" /> + <field + name="students_nb_prev" + required="1" + placeholder="ex : 4, 4 à 6" + /> + <field name="session_hours" required="1" placeholder="ex : 9h-12h ou 14h-17h" /> - </group> - <group string="OPCO"> - <field name="opco_id" /> - <field name="type" /> - <field name="payment" /> - <field name="file_number" /> - <field name="plan" /> - </group> - </group> - <group string="Infos Financières"> - <group> - <field name="cost" required="1" /> - <field name="rate" /> - <field name="amount" /> - <field name="invoiced" /> - </group> - <group> - <field name="students_count" /> - <field name="hours" /> - <field name="hours_total" /> - <field name="session_count" /> - </group> - </group> - <group> - <field name="place" required="1" /> - </group> - <notebook> - <page name="students" string="Stagiaires"> - <field + </group> + <group> + <field name="date_convocation" /> + <field name="email_contact" required="1" /> + <field name="signin_person" required="1" /> + <field name="signin_function" required="1" /> + <field name="place" required="1" /> + <field name="place_detail" /> + <field name="meanings" /> + <field name="equipment" /> + </group> + </group> + <group string="Infos Financières"> + <group> + <field name="company_id" invisible="1" /> + <field name="cost" required="1" /> + <field name="is_vat" /> + <field name="payment_term_id" /> + <field name="rate" /> + <field name="amount" /> + <field name="invoiced" /> + </group> + <group> + <field name="students_count" /> + <field name="hours" /> + <field name="hours_total" /> + <field name="session_count" /> + </group> + </group> + <notebook> + <page name="students" string="Stagiaires"> + <field name="student_ids" context="{'default_parent_id': customer_id, 'default_training_id': active_id}" > - <tree> - <field name="student_id" domain="[('parent_id', '=', parent_id), ]" /> - <field name="parent_id" /> - <field name="certificate" /> - </tree> - </field> - </page> - <page name="sessions" string="Sessions"> - <field name="session_ids"> - <tree editable="bottom"> - <field name="sequence" widget="handle" /> - <field name="session_id" /> - <field name="date" /> - <field name="user_id" /> - <field name="date_delay" /> - </tree> - </field> - </page> - <page name="convention" string="Convention"> - <group> - <field name="agreement_number" /> - <field name="date_convention" /> - <field name="convention" /> - </group> - </page> - <page name="attestation" string="Attestation"> - <group> - <field name="date_attestation" /> - </group> - </page> - <page name="orders" string="Commandes"> - <field name="order_ids" readonly="1" /> - </page> - <page name="invoices" string="Factures"> - <field name="invoice_ids" readonly="1" /> - </page> - </notebook> - </sheet> - <div class="oe_chatter"> - <field name="message_follower_ids" widget="mail_followers" /> - <field name="message_ids" widget="mail_thread" /> - </div> - </form> - </field> + <tree> + <field + name="student_id" + domain="[('parent_id', '=', parent_id), ]" + /> + <field name="parent_id" /> + <field name="certificate" /> + </tree> + </field> + </page> + <page name="sessions" string="Sessions"> + <field name="session_ids"> + <tree editable="bottom"> + <field name="sequence" widget="handle" /> + <field name="session_id" /> + <field name="date" /> + <field name="user_id" /> + <field name="date_delay" /> + </tree> + </field> + </page> + <page name="opco" string="OPCO"> + <group> + <field name="opco_id" /> + <field name="type" /> + <field name="payment" /> + <field name="file_number" /> + <field name="plan" /> + </group> + </page> + <page name="convention" string="Convention"> + <group> + <field name="agreement_number" /> + <field name="place_convention" /> + <field name="date_convention" /> + <field name="convention" /> + </group> + </page> + <page name="attestation" string="Attestation"> + <group> + <field name="place_attestation" /> + <field name="date_attestation" /> + </group> + </page> + <page name="orders" string="Commandes"> + <field name="order_ids" readonly="1" /> + </page> + <page name="invoices" string="Factures"> + <field name="invoice_ids" readonly="1" /> + </page> + </notebook> + </sheet> + <div class="oe_chatter"> + <field name="message_follower_ids" widget="mail_followers" /> + <field name="message_ids" widget="mail_thread" /> + </div> + </form> + </field> </record> - - <!-- Tree View Projects --> + <!-- Tree View --> <record id="training_training_tree" model="ir.ui.view"> - <field name="name">Training Tree View</field> - <field name="model">training.training</field> - <field name="arch" type="xml"> - <tree> - <field name="customer_id" /> - <field name="opco_id" /> - <field name="course_id" /> - <field name="date_begin" widget="date" /> - <field name="date_end" widget="date" /> - <field name="type" /> - <field name="amount" /> - <field name="invoiced" /> - <field name="payment" /> - <field name="state" /> - </tree> - </field> + <field name="name">Training Tree View</field> + <field name="model">training.training</field> + <field name="arch" type="xml"> + <tree> + <field name="customer_id" /> + <field name="opco_id" /> + <field name="course_id" /> + <field name="date_begin" widget="date" /> + <field name="date_end" widget="date" /> + <field name="type" /> + <field name="amount" /> + <field name="invoiced" /> + <field name="payment" /> + <field name="state" /> + </tree> + </field> </record> - <!-- Filtres et Champ de Recherche --> + <!-- Search view --> <record id="training_training_search" model="ir.ui.view"> <field name="name">Training Search View</field> <field name="model">training.training</field> <field name="arch" type="xml"> <search> - <!-- Champs de recherche --> - <field name="customer_id" /> - <field name="opco_id" /> - <field name="course_id" /> - <!-- Filtres --> - <filter + <!-- Champs de recherche --> + <field name="customer_id" /> + <field name="opco_id" /> + <field name="course_id" /> + <!-- Filtres --> + <filter string="Brouillon" name="filter_draft" domain="[('state','=','draft')]" /> - <filter + <filter string="En cours" name="filter_current" domain="[('state','=','current')]" /> - <filter + <filter string="Réalisé" name="filter_done" domain="[('state','=','done')]" /> - <separator /> - <filter + <separator /> + <filter string="INTRA" name="filter_intra" domain="[('type','=','intra')]" /> - <filter + <filter string="INTER" name="filter_inter" domain="[('type','=','inter')]" /> - <!-- Groupes --> - <group expand="0" name="group_by" string="Group By"> - <filter + <!-- Groupes --> + <group expand="0" name="group_by" string="Group By"> + <filter string="Client" name="group_customer" domain="[]" context="{'group_by' : 'customer_id'}" /> - <filter + <filter string="OPCO" name="group_opco" domain="[]" context="{'group_by' : 'opco_id'}" /> - <filter + <filter string="Formation" name="group_course" domain="[]" context="{'group_by' : 'course_id'}" /> - <separator /> - <filter + <separator /> + <filter string="Date Début" name="group_start" domain="[]" context="{'group_by' : 'date_begin'}" /> - <filter + <filter string="Date Fin" name="group_end" domain="[]" context="{'group_by' : 'date_end'}" /> - </group> + </group> </search> </field> </record> <!-- ACTIONS --> <record model="ir.actions.act_window" id="action_training_training"> - <field name="name">Formations</field> - <field name="res_model">training.training</field> - <field name="view_mode">tree,form,pivot,graph</field> - </record> - - <!-- MENU --> - <menuitem - id="menu_training_training_parent" - name="Gestion" - sequence="1" - parent="menu_training" - /> - <menuitem - id="menu_training_training" - name="Formations" - sequence="1" - parent="menu_training_training_parent" - action="action_training_training" - /> + <field name="name">Formations</field> + <field name="res_model">training.training</field> + <field name="view_mode">tree,form,pivot,graph</field> + </record> </odoo> diff --git a/views/training_type_view.xml b/views/training_type_view.xml new file mode 100644 index 0000000000000000000000000000000000000000..88ac84593f5f09530109cab981586a0f4faf3949 --- /dev/null +++ b/views/training_type_view.xml @@ -0,0 +1,36 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- Copyright 2019-2022 Le Filament (<https://le-filament.com>) + License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> +<odoo> + + <!-- Tree View --> + <record id="training_type_tree" model="ir.ui.view"> + <field name="name">Training Type Tree View</field> + <field name="model">training.type</field> + <field name="arch" type="xml"> + <tree editable="bottom"> + <field name="name" /> + </tree> + </field> + </record> + + <!-- Search view --> + <record id="training_type_search" model="ir.ui.view"> + <field name="name">Training Type Search View</field> + <field name="model">training.type</field> + <field name="arch" type="xml"> + <search> + <!-- Champs de recherche --> + <field name="name" /> + </search> + </field> + </record> + + <!-- ACTIONS --> + <record model="ir.actions.act_window" id="action_training_type"> + <field name="name">Types de Formations</field> + <field name="res_model">training.type</field> + <field name="view_mode">tree</field> + </record> + +</odoo>