[MERGE] forward port branch 10.0 up to ea42f6c176
This commit is contained in:
@@ -1418,6 +1418,7 @@ class AccountInvoiceTax(models.Model):
|
||||
base = fields.Monetary(string='Base', compute='_compute_base_amount', store=True)
|
||||
|
||||
# DO NOT FORWARD-PORT!!! ONLY FOR v10
|
||||
@api.model
|
||||
def create(self, vals):
|
||||
inv_tax = super(AccountInvoiceTax, self).create(vals)
|
||||
# Workaround to make sure the tax amount is rounded to the currency precision since the ORM
|
||||
|
||||
@@ -220,7 +220,8 @@ class rml_parse(object):
|
||||
date = datetime(*value.timetuple()[:6])
|
||||
if date_time:
|
||||
# Convert datetime values to the expected client/context timezone
|
||||
record = self.env['base'].with_context(self.localcontext)
|
||||
env = odoo.api.Environment(self.cr, self.uid, {})
|
||||
record = env['base'].with_context(self.localcontext)
|
||||
date = fields.Datetime.context_timestamp(record, date)
|
||||
return date.strftime(date_format.encode('utf-8'))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user