[IMP] account: show send by email button on invoice for pro-forma stage too
- when we send invoice by email, the template shows `False` at invoice number, we will show `pro-forma` invoice instead of `False`
This commit is contained in:
committed by
Yannick Tivisse
parent
018144b8ac
commit
78b2aa4ce5
@@ -25,7 +25,12 @@
|
||||
(<i>${object.partner_id.parent_id.name}</i>)
|
||||
% endif
|
||||
,</p>
|
||||
<p>Here is your invoice <strong>${object.number}</strong>
|
||||
<p>Here is your
|
||||
% if object.number:
|
||||
invoice <strong>${object.number}</strong>
|
||||
% else:
|
||||
pro-forma invoice
|
||||
% endif
|
||||
% if object.origin:
|
||||
(with reference: ${object.origin} )
|
||||
% endif
|
||||
|
||||
@@ -347,9 +347,9 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Invoice">
|
||||
<header>
|
||||
<button name="action_invoice_sent" type="object" string="Send by Email" attrs="{'invisible':['|',('sent','=',True), ('state', '!=', 'open')]}" class="oe_highlight" groups="base.group_user"/>
|
||||
<button name="action_invoice_sent" type="object" string="Send by Email" attrs="{'invisible':['|',('sent','=',True), ('state', 'not in', ('open', 'proforma', 'proforma2'))]}" class="oe_highlight" groups="base.group_user"/>
|
||||
<button name="invoice_print" string="Print" type="object" attrs="{'invisible':['|',('sent','=',True), ('state', '!=', 'open')]}" class="oe_highlight" groups="base.group_user"/>
|
||||
<button name="action_invoice_sent" type="object" string="Send by Email" attrs="{'invisible':['|',('sent','=',False), ('state', '!=', 'open')]}" groups="base.group_user"/>
|
||||
<button name="action_invoice_sent" type="object" string="Send by Email" attrs="{'invisible':['|',('sent','=',False), ('state', 'not in', ('open', 'proforma', 'proforma2'))]}" groups="base.group_user"/>
|
||||
<button name="invoice_print" string="Print Invoice" type="object" attrs="{'invisible':['|',('sent','=',False), ('state', '!=', 'open')]}" groups="base.group_user"/>
|
||||
<button name="%(action_account_invoice_payment)d" type="action" states="open" string="Register Payment" groups="account.group_account_invoice" class="oe_highlight"/>
|
||||
<button name="action_invoice_open" type="object" states="draft" string="Validate" class="oe_highlight" groups="account.group_account_invoice"/>
|
||||
|
||||
Reference in New Issue
Block a user