[MERGE] forward port branch 9.0 up to f41690538d
This commit is contained in:
@@ -41,6 +41,13 @@ def migrate_tags_on_taxes(cr, registry):
|
||||
if len(tax_id.ids) == 1:
|
||||
tax_id.sudo().write({'tag_ids': [(6, 0, tax_template.tag_ids.ids)]})
|
||||
|
||||
def preserve_existing_tags_on_taxes(cr, registry, module):
|
||||
''' This is a utility function used to preserve existing previous tags during upgrade of the module.'''
|
||||
env = api.Environment(cr, SUPERUSER_ID, {})
|
||||
xml_records = env['ir.model.data'].search([('model', '=', 'account.account.tag'), ('module', 'like', module)])
|
||||
if xml_records:
|
||||
cr.execute("update ir_model_data set noupdate = 't' where id in %s", [tuple(xml_records.ids)])
|
||||
|
||||
# ---------------------------------------------------------------
|
||||
# Account Templates: Account, Tax, Tax Code and chart. + Wizard
|
||||
# ---------------------------------------------------------------
|
||||
|
||||
@@ -4,3 +4,8 @@
|
||||
# Copyright (c) 2008 JAILLET Simon - CrysaLEAD - www.crysalead.fr
|
||||
|
||||
import models
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_fr')
|
||||
|
||||
@@ -39,4 +39,5 @@ configuration of their taxes and fiscal positions manually.
|
||||
'data/account_reconcile_model_template.xml',
|
||||
'data/account_chart_template_data.yml',
|
||||
],
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -1,2 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_lu')
|
||||
|
||||
@@ -39,4 +39,5 @@ Notes:
|
||||
'data/account.chart.template.csv',
|
||||
'data/account_chart_template_data.yml',
|
||||
],
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -1,2 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_no')
|
||||
|
||||
@@ -15,4 +15,5 @@ Updated for Odoo 9 by Bringsvor Consulting AS <www.bringsvor.com>
|
||||
'data/account_tax_data.xml',
|
||||
'data/account_chart_template_data.yml'],
|
||||
"active": False,
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -1,2 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_pl')
|
||||
|
||||
@@ -28,4 +28,5 @@ Wewnętrzny numer wersji OpenGLOBE 1.02
|
||||
'data/res_country_state_data.xml',
|
||||
'data/account_chart_template_data.yml'
|
||||
],
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -2,3 +2,8 @@
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
# Copyright (C) 2014 Tech Receptives (<http://techreceptives.com>).
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_sg')
|
||||
|
||||
@@ -32,4 +32,5 @@ After installing this module, the Configuration wizard for accounting is launche
|
||||
'data/account_tax_data.xml',
|
||||
'data/account_chart_template_data.yml',
|
||||
],
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -1,2 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_th')
|
||||
|
||||
@@ -18,4 +18,5 @@ Thai accounting chart and localization.
|
||||
'data/l10n_th_chart_data.xml',
|
||||
'data/account_chart_template_data.yml',
|
||||
],
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -2,3 +2,8 @@
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
# This module is Copyright (c) 2009-2013 General Solutions (http://gscom.vn) All Rights Reserved.
|
||||
|
||||
|
||||
def _preserve_tag_on_taxes(cr, registry):
|
||||
from odoo.addons.account.models.chart_template import preserve_existing_tags_on_taxes
|
||||
preserve_existing_tags_on_taxes(cr, registry, 'l10n_vn')
|
||||
|
||||
@@ -28,5 +28,6 @@ with Chart of account under Circular No. 200/2014/TT-BTC
|
||||
'data/l10n_vn_chart_data.xml',
|
||||
'data/account_tax_data.xml',
|
||||
'data/account_chart_template_data.yml',
|
||||
]
|
||||
],
|
||||
'post_init_hook': '_preserve_tag_on_taxes',
|
||||
}
|
||||
|
||||
@@ -235,10 +235,12 @@ var PosDB = core.Class.extend({
|
||||
for(var i = 0, len = partners.length; i < len; i++){
|
||||
partner = partners[i];
|
||||
|
||||
if ( this.partner_write_date &&
|
||||
var local_partner_date = (this.partner_write_date || '').replace(/^(\d{4}-\d{2}-\d{2}) ((\d{2}:?){3})$/, '$1T$2Z');
|
||||
var dist_partner_date = (partner.write_date || '').replace(/^(\d{4}-\d{2}-\d{2}) ((\d{2}:?){3})$/, '$1T$2Z');
|
||||
if ( this.partner_write_date &&
|
||||
this.partner_by_id[partner.id] &&
|
||||
new Date(this.partner_write_date).getTime() + 1000 >=
|
||||
new Date(partner.write_date).getTime() ) {
|
||||
new Date(local_partner_date).getTime() + 1000 >=
|
||||
new Date(dist_partner_date).getTime() ) {
|
||||
// FIXME: The write_date is stored with milisec precision in the database
|
||||
// but the dates we get back are only precise to the second. This means when
|
||||
// you read partners modified strictly after time X, you get back partners that were
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
<!-- PDF Viewer Body : contains the canvas, the loader, or the image-->
|
||||
<div id="PDFSlideViewer" style="position:relative;"
|
||||
t-attf-data-slideid="#{slide.id}"
|
||||
t-attf-data-slideurl="/slides/slide/#{slide.id}/pdf_content"
|
||||
t-attf-data-slideurl="/slides/slide/#{slug(slide)}/pdf_content"
|
||||
t-attf-data-downloadable="#{slide.download_security}"
|
||||
t-att-data-defaultpage="page">
|
||||
<t t-if="is_embedded">
|
||||
@@ -133,7 +133,7 @@
|
||||
<div class="col-lg-4 col-md-4 col-sm-4 col-xs-4 text-center"></div>
|
||||
</div>
|
||||
<div class="col-lg-2 col-md-2 col-sm-2 col-xs-2 pull-right text-right">
|
||||
<a t-if="slide.download_security and not is_embedded" target="_top" t-attf-href="/slides/slide/#{slide.id}/download" title="Download" id="download">
|
||||
<a t-if="slide.download_security and not is_embedded" target="_top" t-attf-href="/slides/slide/#{slug(slide)}/download" title="Download" id="download">
|
||||
<i class="fa fa-download fa-2x"></i>
|
||||
</a>
|
||||
<span id="fullscreen" title="View fullscreen">
|
||||
|
||||
Reference in New Issue
Block a user