diff options
| author | stephanchrst <stephanchrst@gmail.com> | 2022-05-10 21:51:50 +0700 |
|---|---|---|
| committer | stephanchrst <stephanchrst@gmail.com> | 2022-05-10 21:51:50 +0700 |
| commit | 3751379f1e9a4c215fb6eb898b4ccc67659b9ace (patch) | |
| tree | a44932296ef4a9b71d5f010906253d8c53727726 /addons/account_check_printing/views | |
| parent | 0a15094050bfde69a06d6eff798e9a8ddf2b8c21 (diff) | |
initial commit 2
Diffstat (limited to 'addons/account_check_printing/views')
5 files changed, 145 insertions, 0 deletions
diff --git a/addons/account_check_printing/views/account_journal_views.xml b/addons/account_check_printing/views/account_journal_views.xml new file mode 100644 index 00000000..db8961ff --- /dev/null +++ b/addons/account_check_printing/views/account_journal_views.xml @@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="utf-8"?> +<odoo> + <record id="account_journal_dashboard_kanban_view_inherited" model="ir.ui.view"> + <field name="name">account.journal.dashboard.kanban.inherited</field> + <field name="model">account.journal</field> + <field name="inherit_id" ref="account.account_journal_dashboard_kanban_view" /> + <field name="arch" type="xml"> + <xpath expr="//t[@t-name='JournalBodyBankCash']//div[hasclass('o_kanban_primary_right')]" position="inside"> + <div t-if="journal_type == 'bank' and dashboard.num_checks_to_print != 0"> + <div class="row"> + <div class="col-12"> + <a type="object" name="action_checks_to_print"> + <t t-esc="dashboard.num_checks_to_print"/> + <t t-if="dashboard.num_checks_to_print == 1">Check to print</t> + <t t-if="dashboard.num_checks_to_print != 1">Checks to print</t> + </a> + </div> + </div> + </div> + </xpath> + </field> + </record> + + <record id="view_account_journal_form_inherited" model="ir.ui.view"> + <field name="name">account.journal.form.inherited</field> + <field name="model">account.journal</field> + <field name="inherit_id" ref="account.view_account_journal_form" /> + <field name="arch" type="xml"> + <xpath expr="//page[@name='journal_entries']//group[@name='outgoing_payment']" position="after"> + <group string="Check Printing" + attrs="{'invisible': ['|', ('type', '!=', 'bank'), ('check_printing_payment_method_selected', '=', False)]}"> + <field name="check_printing_payment_method_selected" invisible="1"/> + <field name="check_sequence_id" invisible="1"/> + <field name="check_manual_sequencing" + /> + <field name="check_next_number" + attrs="{'invisible': [('check_manual_sequencing', '=', False)]}"/> + </group> + </xpath> + </field> + </record> +</odoo> diff --git a/addons/account_check_printing/views/account_move_views.xml b/addons/account_check_printing/views/account_move_views.xml new file mode 100644 index 00000000..905a9da9 --- /dev/null +++ b/addons/account_check_printing/views/account_move_views.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="utf-8"?> +<odoo> + <record id="view_account_invoice_filter" model="ir.ui.view"> + <field name="name">account.invoice.select.account_check_printing</field> + <field name="model">account.move</field> + <field name="inherit_id" ref="account.view_account_invoice_filter"/> + <field name="arch" type="xml"> + <xpath expr="//search/group/filter[@name='status']" position="after"> + <filter name="preferred_payment_method" context="{'group_by': 'preferred_payment_method_id'}" groups="account.group_account_invoice,account.group_account_readonly"/> + </xpath> + </field> + </record> +</odoo> diff --git a/addons/account_check_printing/views/account_payment_views.xml b/addons/account_check_printing/views/account_payment_views.xml new file mode 100644 index 00000000..d8c52557 --- /dev/null +++ b/addons/account_check_printing/views/account_payment_views.xml @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="utf-8"?> +<odoo> + <record id="view_account_payment_form_inherited" model="ir.ui.view"> + <field name="name">account.payment.form.inherited</field> + <field name="model">account.payment</field> + <field name="inherit_id" ref="account.view_account_payment_form" /> + <field name="arch" type="xml"> + <xpath expr="//button[@name='action_post']" position="before"> + <button name="print_checks" class="oe_highlight" attrs="{'invisible': ['|', '|', ('payment_method_code', '!=', 'check_printing'), ('state', '!=', 'posted'), ('is_move_sent', '=', True)]}" string="Print Check" type="object"/> + <button name="action_unmark_sent" attrs="{'invisible': ['|', ('payment_method_code', '!=', 'check_printing'), ('is_move_sent', '=', False)]}" string="Unmark Sent" type="object"/> + <button name="action_void_check" attrs="{'invisible': ['|', '|', ('payment_method_code', '!=', 'check_printing'), ('state', '!=', 'posted'), ('is_move_sent', '=', False)]}" string="Void Check" type="object"/> + </xpath> + <xpath expr="//div[@name='amount_div']" position="after"> + <field name="check_amount_in_words" attrs="{'invisible': [('payment_method_code', '!=', 'check_printing')]}" groups="base.group_no_one"/> + </xpath> + <xpath expr="//field[@name='ref']" position="after"> + <field name="check_manual_sequencing" invisible="1"/> + <field name="check_number" attrs="{'invisible': ['|', ('payment_method_code', '!=', 'check_printing'), ('check_number', '=', False)]}"/> + </xpath> + <xpath expr="//field[@name='name']" position='before'> + <widget name="web_ribbon" title="Sent" attrs="{'invisible': [('is_move_sent', '!=', True)]}"/> + </xpath> + </field> + </record> + + <record id="view_payment_check_printing_search" model="ir.ui.view"> + <field name="name">account.payment.check.printing.search</field> + <field name="model">account.payment</field> + <field name="inherit_id" ref="account.view_account_payment_search"/> + <field name="arch" type="xml"> + <xpath expr="//filter[@name='activities_overdue']" position="before"> + <separator/> + <filter name="checks_to_send" string="Checks to Print" domain="[('payment_method_id.code', '=', 'check_printing'), ('state', '=', 'posted'), ('is_move_sent', '=', False)]"/> + <separator/> + </xpath> + </field> + </record> + +</odoo> diff --git a/addons/account_check_printing/views/res_config_settings_views.xml b/addons/account_check_printing/views/res_config_settings_views.xml new file mode 100644 index 00000000..969787a7 --- /dev/null +++ b/addons/account_check_printing/views/res_config_settings_views.xml @@ -0,0 +1,38 @@ +<?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.account.check.printing</field> + <field name="model">res.config.settings</field> + <field name="inherit_id" ref="account.res_config_settings_view_form"/> + <field name="arch" type="xml"> + <div id="print_bills_payment" position="after"> + <div class="content-group"> + <div class="row mt16"> + <label for="account_check_printing_layout" class="col-lg-4 o_light_label"/> + <field name="account_check_printing_layout" required="True"/> + </div> + <div class="row"> + <label for="account_check_printing_multi_stub" class="col-lg-4 o_light_label"/> + <field name="account_check_printing_multi_stub"/> + </div> + <div class="row"> + <label for="account_check_printing_margin_top" class="col-lg-4 o_light_label"/> + <field name="account_check_printing_margin_top"/> + </div> + <div class="row"> + <label for="account_check_printing_margin_left" class="col-lg-4 o_light_label"/> + <field name="account_check_printing_margin_left"/> + </div> + <div class="row" attrs="{'invisible': [('country_code', '!=', 'CA')]}"> + <label for="account_check_printing_margin_right" class="col-lg-4 o_light_label"/> + <field name="account_check_printing_margin_right"/> + </div> + <div class="row" attrs="{'invisible': [('country_code', '!=', 'CA')]}"> + <label for="account_check_printing_date_label" class="col-lg-4 o_light_label"/> + <field name="account_check_printing_date_label"/> + </div> + </div> + </div> + </field> + </record> +</odoo> diff --git a/addons/account_check_printing/views/res_partner_views.xml b/addons/account_check_printing/views/res_partner_views.xml new file mode 100644 index 00000000..cdd0fa56 --- /dev/null +++ b/addons/account_check_printing/views/res_partner_views.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="utf-8"?> +<odoo> + <record id="view_partner_property_form" model="ir.ui.view"> + <field name="name">res.partner.property.form.inherit</field> + <field name="model">res.partner</field> + <field name="inherit_id" ref="account.view_partner_property_form"/> + <field name="arch" type="xml"> + <field name="property_supplier_payment_term_id" position="after"> + <field name="property_payment_method_id" widget="selection" groups="account.group_account_invoice,account.group_account_readonly"/> + </field> + </field> + </record> +</odoo> |
