summaryrefslogtreecommitdiff
path: root/addons/account_edi/wizard
diff options
context:
space:
mode:
authorstephanchrst <stephanchrst@gmail.com>2022-05-10 21:51:50 +0700
committerstephanchrst <stephanchrst@gmail.com>2022-05-10 21:51:50 +0700
commit3751379f1e9a4c215fb6eb898b4ccc67659b9ace (patch)
treea44932296ef4a9b71d5f010906253d8c53727726 /addons/account_edi/wizard
parent0a15094050bfde69a06d6eff798e9a8ddf2b8c21 (diff)
initial commit 2
Diffstat (limited to 'addons/account_edi/wizard')
-rw-r--r--addons/account_edi/wizard/__init__.py1
-rw-r--r--addons/account_edi/wizard/account_invoice_send.py13
-rw-r--r--addons/account_edi/wizard/account_invoice_send_views.xml26
3 files changed, 40 insertions, 0 deletions
diff --git a/addons/account_edi/wizard/__init__.py b/addons/account_edi/wizard/__init__.py
new file mode 100644
index 00000000..edaf0442
--- /dev/null
+++ b/addons/account_edi/wizard/__init__.py
@@ -0,0 +1 @@
+from . import account_invoice_send
diff --git a/addons/account_edi/wizard/account_invoice_send.py b/addons/account_edi/wizard/account_invoice_send.py
new file mode 100644
index 00000000..3cf5e2ce
--- /dev/null
+++ b/addons/account_edi/wizard/account_invoice_send.py
@@ -0,0 +1,13 @@
+# -*- coding: utf-8 -*-
+# Part of Odoo. See LICENSE file for full copyright and licensing details.
+
+from odoo import api, fields, models, _
+from odoo.exceptions import UserError
+import base64
+
+
+class AccountInvoiceSend(models.TransientModel):
+ _inherit = 'account.invoice.send'
+ _description = 'Account Invoice Send'
+
+ edi_format_ids = fields.Many2many(related='invoice_ids.journal_id.edi_format_ids', string="Electronic invoicing")
diff --git a/addons/account_edi/wizard/account_invoice_send_views.xml b/addons/account_edi/wizard/account_invoice_send_views.xml
new file mode 100644
index 00000000..510cb7f5
--- /dev/null
+++ b/addons/account_edi/wizard/account_invoice_send_views.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<odoo>
+ <data>
+ <record model="ir.ui.view" id="account_invoice_send_inherit_account_wizard_form">
+ <!-- Deprecated, the field is now invisible. This view will be removed in future versions. -->
+ <field name="name">account.invoice.send.form.inherited.edi</field>
+ <field name="model">account.invoice.send</field>
+ <field name="inherit_id" ref="account.account_invoice_send_wizard_form"/>
+ <field name="arch" type="xml">
+ <xpath expr="//div[@name='mail_form']" position='before'>
+ <div name="edi_format_option" invisible='1'>
+ <group>
+ <label for="edi_format_ids"/>
+ <div class="oe_inline">
+ <field name="edi_format_ids"
+ nolabel="1"
+ widget="many2many_tags"
+ placeholder="You can set default electronic invoicing formats on the journal"/>
+ </div>
+ </group>
+ </div>
+ </xpath>
+ </field>
+ </record>
+ </data>
+</odoo>