diff options
| author | Christophe Simonis <chs@odoo.com> | 2018-03-27 16:41:47 +0200 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2018-03-27 16:41:47 +0200 |
| commit | a9542240fce05cbeedbf8ec7f80ec5713a22da93 (patch) | |
| tree | ac96568e73b3e45b642646c72e222839d4af0b1b /addons | |
| parent | 3fce2b769e62bc9d11710f4a3fd550c493a55262 (diff) | |
| parent | ce5b4b651277694af1de5b48d21adce10efcf175 (diff) | |
[MERGE] forward port branch saas-14 up to ce5b4b65127
Diffstat (limited to 'addons')
| -rw-r--r-- | addons/mrp/models/mrp_production.py | 11 | ||||
| -rw-r--r-- | addons/payment_authorize/models/authorize_request.py | 2 | ||||
| -rw-r--r-- | addons/purchase/views/account_invoice_views.xml | 2 | ||||
| -rw-r--r-- | addons/website_sale/views/templates.xml | 2 |
4 files changed, 14 insertions, 3 deletions
diff --git a/addons/mrp/models/mrp_production.py b/addons/mrp/models/mrp_production.py index bfc48ef2072..914313b1def 100644 --- a/addons/mrp/models/mrp_production.py +++ b/addons/mrp/models/mrp_production.py @@ -263,6 +263,17 @@ class MrpProduction(models.Model): self.location_src_id = self.picking_type_id.default_location_src_id.id or location.id self.location_dest_id = self.picking_type_id.default_location_dest_id.id or location.id + @api.multi + def write (self, vals): + res = super(MrpProduction, self).write(vals) + if 'date_planned_start' in vals: + moves = (self.mapped('move_raw_ids') + self.mapped('move_finished_ids')).filtered( + lambda r: r.state not in ['done', 'cancel']) + moves.write({ + 'date_expected': vals['date_planned_start'], + }) + return res + @api.model def create(self, values): if not values.get('name', False) or values['name'] == _('New'): diff --git a/addons/payment_authorize/models/authorize_request.py b/addons/payment_authorize/models/authorize_request.py index f7aca95511d..fef82365b71 100644 --- a/addons/payment_authorize/models/authorize_request.py +++ b/addons/payment_authorize/models/authorize_request.py @@ -142,7 +142,7 @@ class AuthorizeAPI(): etree.SubElement(billTo, "address").text = (partner.street or '' + (partner.street2 if partner.street2 else '')) or None etree.SubElement(billTo, "city").text = partner.city etree.SubElement(billTo, "state").text = partner.state_id.name or None - etree.SubElement(billTo, "zip").text = partner.zip + etree.SubElement(billTo, "zip").text = partner.zip or '' etree.SubElement(billTo, "country").text = partner.country_id.name or None payment = etree.SubElement(payment_profile, "payment") creditCard = etree.SubElement(payment, "creditCard") diff --git a/addons/purchase/views/account_invoice_views.xml b/addons/purchase/views/account_invoice_views.xml index 583f2f40b56..5c028080315 100644 --- a/addons/purchase/views/account_invoice_views.xml +++ b/addons/purchase/views/account_invoice_views.xml @@ -75,7 +75,7 @@ <field name="inherit_id" ref="account.view_invoice_line_form"/> <field name="arch" type="xml"> <field name="account_id" position="before"> - <field name="purchase_id"/> + <field name="purchase_id" invisible="context.get('type') in ('out_invoice', 'out_refund')"/> </field> </field> </record> diff --git a/addons/website_sale/views/templates.xml b/addons/website_sale/views/templates.xml index 20cfc1728ca..bab625d08f0 100644 --- a/addons/website_sale/views/templates.xml +++ b/addons/website_sale/views/templates.xml @@ -166,7 +166,7 @@ <t t-set="additional_title">Shop</t> <div id="wrap" class="js_sale"> <div class="oe_structure" /> - <div t-attf-class="container oe_website_sale #{'oe_website_sale_search' if search else None}"> + <div class="container oe_website_sale"> <div class="products_pager"> <div class="row" style="width: 100%;"> <t t-call="website_sale.search"> |
