From e4a21fbd7b1e2a1f5343f89ccdbd186aa1bb8bb1 Mon Sep 17 00:00:00 2001 From: "Ferdinand,mtr(OpenERP)" <> Date: Thu, 16 Jun 2011 15:00:21 +0530 Subject: [PATCH 001/163] [FIX] account: calculates the correct level lp bug: https://launchpad.net/bugs/783670 fixed bzr revid: mtr@mtr-20110616093021-n7ihs56l7v08ntwq --- addons/account/account.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/addons/account/account.py b/addons/account/account.py index f6dd36c01fc..b3b6016fc74 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -340,9 +340,11 @@ class account_account(osv.osv): accounts = self.browse(cr, uid, ids, context=context) for account in accounts: level = 0 - if account.parent_id: - obj = self.browse(cr, uid, account.parent_id.id) - level = obj.level + 1 + parent_id = account.parent_id + while parent_id: + obj = self.browse(cr, uid, parent_id.id) + level += 1 + parent_id = obj.parent_id res[account.id] = level return res @@ -390,7 +392,10 @@ class account_account(osv.osv): 'manage this. So if you import from another software system you may have to use the rate at date. ' \ 'Incoming transactions always use the rate at date.', \ required=True), - 'level': fields.function(_get_level, string='Level', method=True, store=True, type='integer'), + 'level': fields.function(_get_level, string='Level', method=True, type='integer', + store={ + 'account.account': (lambda self, cr, uid, ids, c={}: ids, ['parent_id'], 10), + }), } _defaults = { From ef278ffae6da5a72eabe6ea026a2cc8c3ae97561 Mon Sep 17 00:00:00 2001 From: mtr Date: Tue, 5 Jul 2011 17:56:39 +0530 Subject: [PATCH 002/163] [IMP] account: improved store dictionary of function field 'level' bzr revid: mtr@mtr-20110705122639-nq3yqkebakr4vig7 --- addons/account/account.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/account/account.py b/addons/account/account.py index b3b6016fc74..24b04ea6ae7 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -332,9 +332,9 @@ class account_account(osv.osv): for acc in record.child_consol_ids: if acc.id not in result[record.id]: result[record.id].append(acc.id) - + return result - + def _get_level(self, cr, uid, ids, field_name, arg, context=None): res = {} accounts = self.browse(cr, uid, ids, context=context) @@ -344,7 +344,7 @@ class account_account(osv.osv): while parent_id: obj = self.browse(cr, uid, parent_id.id) level += 1 - parent_id = obj.parent_id + parent_id = obj.parent_id res[account.id] = level return res @@ -394,7 +394,7 @@ class account_account(osv.osv): required=True), 'level': fields.function(_get_level, string='Level', method=True, type='integer', store={ - 'account.account': (lambda self, cr, uid, ids, c={}: ids, ['parent_id'], 10), + 'account.account': (_get_children_and_consol, [], 10), }), } From 8bdaefd12e5d6e7f774662cdfeb756d822f0f27b Mon Sep 17 00:00:00 2001 From: Date: Wed, 6 Jul 2011 09:47:31 +0200 Subject: [PATCH 003/163] [IMP] hr_timesheet_sheet: sign-in and sign-out buttons on the sheet use the same attendances wizard which asks for the last sign-in/sign-out if it is missing instead of raising an error bzr revid: guewen.baconnier@camptocamp.com-20110706074731-8v14k99lcgmipm4y --- .../hr_timesheet_sheet/hr_timesheet_sheet.py | 24 ++++++++++++------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py index cf4351112a4..0cc0fbc11f7 100644 --- a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py +++ b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py @@ -245,23 +245,29 @@ class hr_timesheet_sheet(osv.osv): self.write(cr, uid, [sheet.id], {'date_current': sheet.date_to,}, context=context) return True - def sign(self, cr, uid, ids, typ, context=None): - emp_obj = self.pool.get('hr.employee') + def check_sign(self, cr, uid, ids, typ, context=None): sheet = self.browse(cr, uid, ids, context=context)[0] - if context is None: - context = {} if not sheet.date_current == time.strftime('%Y-%m-%d'): raise osv.except_osv(_('Error !'), _('You cannot sign in/sign out from an other date than today')) - emp_id = sheet.employee_id.id - context['sheet_id']=ids[0] - emp_obj.attendance_action_change(cr, uid, [emp_id], type=typ, context=context,) return True + def sign(self, cr, uid, ids, typ, context=None): + self.check_sign(cr, uid, ids, typ, context=context) + sign_obj = self.pool.get('hr.sign.in.out') + sign_id = sign_obj.create(cr, uid, {}, context=context) + methods = {'sign_in': sign_obj.si_check, + 'sign_out': sign_obj.so_check} + wizard_result = methods[typ](cr, uid, [sign_id], context=context) + if wizard_result.get('type', False) == 'ir.actions.act_window_close': + return True # ensure we do not close the main window ! + wizard_result['nodestroy'] = True # do not destroy the main window ! + return wizard_result + def sign_in(self, cr, uid, ids, context=None): - return self.sign(cr,uid,ids,'sign_in',context=None) + return self.sign(cr, uid, ids, 'sign_in', context=context) def sign_out(self, cr, uid, ids, context=None): - return self.sign(cr,uid,ids,'sign_out',context=None) + return self.sign(cr, uid, ids, 'sign_out', context=context) _columns = { 'name': fields.char('Description', size=64, select=1, From 95a2d179308a2c9b5c86ec4bc8601434a880890e Mon Sep 17 00:00:00 2001 From: Date: Thu, 7 Jul 2011 14:27:59 +0200 Subject: [PATCH 004/163] [FIX] of last commit: allow to sign in / sign out on the sheet of an other employee bzr revid: guewen.baconnier@camptocamp.com-20110707122759-3919twq9v9sznuo4 --- .../wizard/hr_attendance_sign_in_out.py | 17 ++++++++++++++--- addons/hr_timesheet_sheet/hr_timesheet_sheet.py | 2 ++ 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/addons/hr_attendance/wizard/hr_attendance_sign_in_out.py b/addons/hr_attendance/wizard/hr_attendance_sign_in_out.py index 7a51c2b9e1e..89ca5148bbb 100644 --- a/addons/hr_attendance/wizard/hr_attendance_sign_in_out.py +++ b/addons/hr_attendance/wizard/hr_attendance_sign_in_out.py @@ -33,14 +33,20 @@ class hr_si_so_ask(osv.osv_memory): } def _get_empname(self, cr, uid, context=None): - emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context) + if context.get('emp_id', False): + emp_id = context['emp_id'] + else: + emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context) if emp_id: employee = self.pool.get('hr.employee').browse(cr, uid, emp_id, context=context)[0].name return employee return '' def _get_empid(self, cr, uid, context=None): - emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context) + if context.get('emp_id', False): + emp_id = context['emp_id'] + else: + emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context) if emp_id: return emp_id[0] return False @@ -72,7 +78,10 @@ class hr_sign_in_out(osv.osv_memory): } def _get_empid(self, cr, uid, context=None): - emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context) + if context.get('emp_id', False): + emp_id = context['emp_id'] + else: + emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context) if emp_id: employee = self.pool.get('hr.employee').browse(cr, uid, emp_id, context=context)[0] return {'name': employee.name, 'state': employee.state, 'emp_id': emp_id[0]} @@ -106,6 +115,7 @@ class hr_sign_in_out(osv.osv_memory): 'res_model': 'hr.sign.in.out.ask', 'views': [(resource_id,'form')], 'type': 'ir.actions.act_window', + 'context': context, 'target': 'new', } @@ -128,6 +138,7 @@ class hr_sign_in_out(osv.osv_memory): 'res_model': 'hr.sign.in.out', 'views': [(resource_id,'form')], 'type': 'ir.actions.act_window', + 'context': context, 'target': 'new', } diff --git a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py index 0cc0fbc11f7..7ba824814cf 100644 --- a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py +++ b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py @@ -254,6 +254,8 @@ class hr_timesheet_sheet(osv.osv): def sign(self, cr, uid, ids, typ, context=None): self.check_sign(cr, uid, ids, typ, context=context) sign_obj = self.pool.get('hr.sign.in.out') + sheet = self.browse(cr, uid, ids, context=context)[0] + context['emp_id'] = [sheet.employee_id.id] sign_id = sign_obj.create(cr, uid, {}, context=context) methods = {'sign_in': sign_obj.si_check, 'sign_out': sign_obj.so_check} From 4ee5b4bedae693d4c9e338b0f9a53b540cff9441 Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Wed, 24 Aug 2011 13:31:51 +0530 Subject: [PATCH 005/163] [FIX] mrp_repair:Hardcoded stock name location in mrp_repair are removed lp bug: https://launchpad.net/bugs/831543 fixed bzr revid: aag@tinyerp.com-20110824080151-3hnce2cgz6600gy8 --- addons/mrp_repair/mrp_repair.py | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 3a538590d10..548c95ffa1c 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -699,7 +699,7 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): } } - product_id = self.pool.get('stock.location').search(cr, uid, [('name','=','Production')])[0] + product_id = self.pool.get('stock.location').search(cr, uid, [('usage','=','production')])[0] if type != 'add': return {'value': { 'to_invoice': False, @@ -707,15 +707,16 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): 'location_dest_id': False } } - - stock_id = self.pool.get('stock.location').search(cr, uid, [('name','=','Stock')])[0] - to_invoice = (guarantee_limit and - datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) - return {'value': { - 'to_invoice': to_invoice, - 'location_id': stock_id, - 'location_dest_id': product_id - } + + if ids: + stock_id = self.browse(cr, uid, ids[0]).repair_id.company_id.partner_id.property_stock_customer.id + to_invoice = (guarantee_limit and + datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) + return {'value': { + 'to_invoice': to_invoice, + 'location_id': stock_id, + 'location_dest_id': product_id + } } mrp_repair_line() From 873b0b206ecdcda9fdc4b06ea137597989992251 Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Mon, 29 Aug 2011 15:03:08 +0530 Subject: [PATCH 006/163] [FIX] mrp_repair:Hardcoded stock name location in mrp_repair are removed lp bug: https://launchpad.net/bugs/831543 fixed bzr revid: aag@tinyerp.com-20110829093308-zy30ntoek58l1oyl --- addons/mrp_repair/mrp_repair.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 548c95ffa1c..ad7d1f993c5 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -692,6 +692,7 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): @param guarantee_limit: Guarantee limit of current record. @return: Dictionary of values. """ + wrehouse_obj = self.pool.get('stock.warehouse') if not type: return {'value': { 'location_id': False, @@ -709,7 +710,8 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): } if ids: - stock_id = self.browse(cr, uid, ids[0]).repair_id.company_id.partner_id.property_stock_customer.id + company_id = self.browse(cr, uid, ids[0]).repair_id.company_id.id + stock_id = wrehouse_obj.browse(cr, uid, company_id).lot_input_id.id to_invoice = (guarantee_limit and datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) return {'value': { From fd04c0d7fcdb7e6ab6336d336452fc09b9424362 Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Tue, 30 Aug 2011 10:35:19 +0530 Subject: [PATCH 007/163] [IMP] mrp_repair:Rename stock.warehouse object name bzr revid: aag@tinyerp.com-20110830050519-zlmhksehjub57qto --- addons/mrp_repair/mrp_repair.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index ad7d1f993c5..6f326a0a483 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -692,7 +692,7 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): @param guarantee_limit: Guarantee limit of current record. @return: Dictionary of values. """ - wrehouse_obj = self.pool.get('stock.warehouse') + warehouse_obj = self.pool.get('stock.warehouse') if not type: return {'value': { 'location_id': False, @@ -711,7 +711,7 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): if ids: company_id = self.browse(cr, uid, ids[0]).repair_id.company_id.id - stock_id = wrehouse_obj.browse(cr, uid, company_id).lot_input_id.id + stock_id = warehouse_obj.browse(cr, uid, company_id).lot_input_id.id to_invoice = (guarantee_limit and datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) return {'value': { From f6f09e06edb881812ef42eed8007503efa70761c Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Tue, 30 Aug 2011 10:40:58 +0530 Subject: [PATCH 008/163] [IMP] mrp_repair:ADD context in browse method bzr revid: aag@tinyerp.com-20110830051058-4klmhdcsdkucf0aj --- addons/mrp_repair/mrp_repair.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 6f326a0a483..0c8334421da 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -710,8 +710,8 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): } if ids: - company_id = self.browse(cr, uid, ids[0]).repair_id.company_id.id - stock_id = warehouse_obj.browse(cr, uid, company_id).lot_input_id.id + company_id = self.browse(cr, uid, ids[0], context=context).repair_id.company_id.id + stock_id = warehouse_obj.browse(cr, uid, company_id, context=context).lot_input_id.id to_invoice = (guarantee_limit and datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) return {'value': { From c6fe5c3502e50592dd83290c68431e4f45f3517b Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Tue, 30 Aug 2011 10:43:56 +0530 Subject: [PATCH 009/163] [IMP] mrp_repair:ADD context in method bzr revid: aag@tinyerp.com-20110830051356-vi5icqt04n99mf98 --- addons/mrp_repair/mrp_repair.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 0c8334421da..c23f868f370 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -685,13 +685,15 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): 'product_uom_qty': lambda *a: 1, } - def onchange_operation_type(self, cr, uid, ids, type, guarantee_limit): + def onchange_operation_type(self, cr, uid, ids, type, guarantee_limit, context = None): """ On change of operation type it sets source location, destination location and to invoice field. @param product: Changed operation type. @param guarantee_limit: Guarantee limit of current record. @return: Dictionary of values. """ + if context is None: + context = {} warehouse_obj = self.pool.get('stock.warehouse') if not type: return {'value': { @@ -700,7 +702,7 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): } } - product_id = self.pool.get('stock.location').search(cr, uid, [('usage','=','production')])[0] + product_id = self.pool.get('stock.location').search(cr, uid, [('usage','=','production')], context=context)[0] if type != 'add': return {'value': { 'to_invoice': False, From cf21a70172907eee6adbbfcbfc04526f9f38039c Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Tue, 30 Aug 2011 12:03:50 +0530 Subject: [PATCH 010/163] [IMP] mrp_repair:Find production location company wise bzr revid: aag@tinyerp.com-20110830063350-94xgxlg2znm2lu29 --- addons/mrp_repair/mrp_repair.py | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index c23f868f370..153f36c32bd 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -695,31 +695,33 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): if context is None: context = {} warehouse_obj = self.pool.get('stock.warehouse') + location_obj = self.pool.get('stock.location') if not type: return {'value': { 'location_id': False, 'location_dest_id': False } } - - product_id = self.pool.get('stock.location').search(cr, uid, [('usage','=','production')], context=context)[0] - if type != 'add': - return {'value': { - 'to_invoice': False, - 'location_id': product_id, - 'location_dest_id': False - } - } if ids: company_id = self.browse(cr, uid, ids[0], context=context).repair_id.company_id.id + product_id = location_obj.search(cr, uid, [('usage','=','production'), ('company_id','=',company_id)], context=context) + if not product_id: + product_id = location_obj.search(cr, uid, [('usage','=','production')], context=context) + if type != 'add': + return {'value': { + 'to_invoice': False, + 'location_id': product_id[0], + 'location_dest_id': False + } + } stock_id = warehouse_obj.browse(cr, uid, company_id, context=context).lot_input_id.id to_invoice = (guarantee_limit and datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) return {'value': { 'to_invoice': to_invoice, 'location_id': stock_id, - 'location_dest_id': product_id + 'location_dest_id': product_id[0] } } From 3ff689c76375d8d4fa71b70bd0589f66268e3d73 Mon Sep 17 00:00:00 2001 From: "Meera Trambadia (OpenERP)" Date: Fri, 2 Sep 2011 14:57:42 +0530 Subject: [PATCH 011/163] [IMP] hr_payroll: improved data.xml to change the sequence in the display of salary rule categories. bzr revid: mtr@tinyerp.com-20110902092742-cyj58sya4krdu3al --- addons/hr_payroll/hr_payroll_data.xml | 28 +++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/addons/hr_payroll/hr_payroll_data.xml b/addons/hr_payroll/hr_payroll_data.xml index d5618fab3a0..c752a2ca3a4 100644 --- a/addons/hr_payroll/hr_payroll_data.xml +++ b/addons/hr_payroll/hr_payroll_data.xml @@ -1,37 +1,37 @@ - + Basic BASIC - + Allowance ALW - - - Deduction - DED - - + Gross GROSS - + + + Deduction + DED + + Net NET - + Company Contribution COMP - + Basic @@ -71,13 +71,13 @@ - + - + Payroll 2 - + From cc5c8a71330993540d43385dff74e2ce40c6d36f Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Mon, 5 Sep 2011 14:56:44 +0530 Subject: [PATCH 012/163] [IMP] mrp_repair:optimize code bzr revid: aag@tinyerp.com-20110905092644-86ph50nywnv1eoev --- addons/mrp_repair/mrp_repair.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 153f36c32bd..026ceb51104 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -706,12 +706,15 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): if ids: company_id = self.browse(cr, uid, ids[0], context=context).repair_id.company_id.id product_id = location_obj.search(cr, uid, [('usage','=','production'), ('company_id','=',company_id)], context=context) - if not product_id: - product_id = location_obj.search(cr, uid, [('usage','=','production')], context=context) + if product_id: + product_id = product_id[0] + else: + product_id = False + if type != 'add': return {'value': { 'to_invoice': False, - 'location_id': product_id[0], + 'location_id': product_id, 'location_dest_id': False } } @@ -721,7 +724,7 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): return {'value': { 'to_invoice': to_invoice, 'location_id': stock_id, - 'location_dest_id': product_id[0] + 'location_dest_id': product_id } } From a0b42c1f74b1ad36f625f1d6845050843a41137b Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Fri, 9 Sep 2011 12:49:27 +0200 Subject: [PATCH 013/163] [IMP] report available in header and foot in report_webkit bzr revid: nicolas.bessi@camptocamp.com-20110909104927-xy9mcytpteiwi02w --- addons/report_webkit/webkit_report.py | 35 ++++++++------------------- 1 file changed, 10 insertions(+), 25 deletions(-) diff --git a/addons/report_webkit/webkit_report.py b/addons/report_webkit/webkit_report.py index 406013cef12..23d0b44507c 100644 --- a/addons/report_webkit/webkit_report.py +++ b/addons/report_webkit/webkit_report.py @@ -306,16 +306,11 @@ class WebKitParser(report_sxw): raise except_osv(_('Webkit render'), msg) head_mako_tpl = mako_template(header) try : - head = head_mako_tpl.render( - company=company, - time=time, - helper=helper, + head = head_mako_tpl.render(helper=helper, css=css, - formatLang=self.formatLang, - setLang=self.setLang, _=self.translate_call, - _debug=False - ) + _debug=False, + **self.parser_instance.localcontext) except Exception, e: raise except_osv(_('Webkit render'), exceptions.text_error_template().render()) @@ -323,31 +318,21 @@ class WebKitParser(report_sxw): if footer : foot_mako_tpl = mako_template(footer) try : - foot = foot_mako_tpl.render( - company=company, - time=time, - helper=helper, + foot = foot_mako_tpl.render(helper=helper, css=css, - formatLang=self.formatLang, - setLang=self.setLang, _=self.translate_call, - ) + **self.parser_instance.localcontext) except: msg = exceptions.text_error_template().render() netsvc.Logger().notifyChannel('Webkit render', netsvc.LOG_ERROR, msg) raise except_osv(_('Webkit render'), msg) if report_xml.webkit_debug : try : - deb = head_mako_tpl.render( - company=company, - time=time, - helper=helper, - css=css, - _debug=tools.ustr(html), - formatLang=self.formatLang, - setLang=self.setLang, - _=self.translate_call, - ) + deb = head_mako_tpl.render(helper=helper, + css=css, + _debug=tools.ustr(html), + _=self.translate_call, + **self.parser_instance.localcontext) except Exception, e: msg = exceptions.text_error_template().render() netsvc.Logger().notifyChannel('Webkit render', netsvc.LOG_ERROR, msg) From 92b3106212de2a109a769d3442b1a9700c3e1cbd Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Fri, 9 Sep 2011 12:59:01 +0200 Subject: [PATCH 014/163] [IMP] Layer of report webkit bzr revid: nicolas.bessi@camptocamp.com-20110909105901-9odsx3p030znn6qc --- addons/report_webkit/header_view.xml | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/addons/report_webkit/header_view.xml b/addons/report_webkit/header_view.xml index d3e9363acd7..bc643a0a28c 100644 --- a/addons/report_webkit/header_view.xml +++ b/addons/report_webkit/header_view.xml @@ -24,13 +24,8 @@ - - - - - - - + + @@ -38,6 +33,15 @@ + + + + + + + + + From e133c408cb2e79e65c3d58cabeb5ea75c6c29f9c Mon Sep 17 00:00:00 2001 From: "Rucha (Open ERP)" Date: Wed, 21 Sep 2011 11:09:53 +0530 Subject: [PATCH 015/163] [FIX, REF]: mrp_repair: Improvement in code and logic of onchange type of repair line to fix the problem of hard coded location name in search bzr revid: rpa@tinyerp.com-20110921053953-gwcq1k72bln0ue7s --- addons/mrp_repair/mrp_repair.py | 53 +++++++++++++++------------------ 1 file changed, 24 insertions(+), 29 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 026ceb51104..32ea609fd14 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -685,48 +685,43 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): 'product_uom_qty': lambda *a: 1, } - def onchange_operation_type(self, cr, uid, ids, type, guarantee_limit, context = None): + def onchange_operation_type(self, cr, uid, ids, type, guarantee_limit, context=None): """ On change of operation type it sets source location, destination location and to invoice field. @param product: Changed operation type. @param guarantee_limit: Guarantee limit of current record. @return: Dictionary of values. """ - if context is None: - context = {} - warehouse_obj = self.pool.get('stock.warehouse') - location_obj = self.pool.get('stock.location') if not type: return {'value': { 'location_id': False, 'location_dest_id': False - } - } - - if ids: - company_id = self.browse(cr, uid, ids[0], context=context).repair_id.company_id.id - product_id = location_obj.search(cr, uid, [('usage','=','production'), ('company_id','=',company_id)], context=context) - if product_id: - product_id = product_id[0] - else: - product_id = False - - if type != 'add': - return {'value': { - 'to_invoice': False, - 'location_id': product_id, - 'location_dest_id': False - } - } - stock_id = warehouse_obj.browse(cr, uid, company_id, context=context).lot_input_id.id - to_invoice = (guarantee_limit and - datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) + }} + + warehouse_obj = self.pool.get('stock.warehouse') + location_id = self.pool.get('stock.location').search(cr, uid, [('usage','=','production')], context=context) + location_id = location_id and location_id[0] or False + + if type == 'add': + # TOCHECK: Find stock location for user's company warehouse or + # repair order's company's warehouse (company_id field is added in fix of lp:831583) + company_id = self.pool.get('res.company')._company_default_get(cr, uid, 'mrp.repair', context=context) + warehouse_ids = warehouse_obj.search(cr, uid, [], context=context) + if warehouse_ids: + stock_id = warehouse_obj.browse(cr, uid, warehouse_ids[0], context=context).lot_stock_id.id + to_invoice = (guarantee_limit and datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) + return {'value': { 'to_invoice': to_invoice, 'location_id': stock_id, - 'location_dest_id': product_id - } - } + 'location_dest_id': location_id + }} + + return {'value': { + 'to_invoice': False, + 'location_id': location_id, + 'location_dest_id': False + }} mrp_repair_line() From 4d26cf1cf0a77ef240fc8113868102c563d099c6 Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Wed, 21 Sep 2011 09:49:42 +0200 Subject: [PATCH 016/163] =?UTF-8?q?[IMP]=C2=A0support=20precise=20mode=20+?= =?UTF-8?q?=20get=20ride=20of=20notify=20channel=20+=20small=20refactoring?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bzr revid: nicolas.bessi@camptocamp.com-20110921074942-9zukri77gv8eeofd --- addons/report_webkit/ir_report.py | 3 + addons/report_webkit/ir_report_view.xml | 1 + .../security/ir.model.access.csv | 4 +- addons/report_webkit/webkit_report.py | 99 +++++++++---------- 4 files changed, 53 insertions(+), 54 deletions(-) diff --git a/addons/report_webkit/ir_report.py b/addons/report_webkit/ir_report.py index e6f4a81f9e7..e5b4156a348 100644 --- a/addons/report_webkit/ir_report.py +++ b/addons/report_webkit/ir_report.py @@ -130,6 +130,9 @@ class ReportXML(osv.osv): ), 'webkit_debug' : fields.boolean('Webkit debug', help="Enable the webkit engine debugger"), 'report_webkit_data': fields.text('Webkit Template', help="This template will be used if the main report file is not found"), + 'precise_mode':fields.boolean('Precise Mode', help='This mode allow more precise element \ + position as each object is printed on a separate HTML.\ + but memory and disk usage is wider') } ReportXML() diff --git a/addons/report_webkit/ir_report_view.xml b/addons/report_webkit/ir_report_view.xml index e92c5a5345b..1d60f6a873d 100644 --- a/addons/report_webkit/ir_report_view.xml +++ b/addons/report_webkit/ir_report_view.xml @@ -10,6 +10,7 @@ + diff --git a/addons/report_webkit/security/ir.model.access.csv b/addons/report_webkit/security/ir.model.access.csv index 850a202512e..6c626f9873e 100644 --- a/addons/report_webkit/security/ir.model.access.csv +++ b/addons/report_webkit/security/ir.model.access.csv @@ -1,3 +1,3 @@ "id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink" -"access_ir_header_webkit","ir.header_webkit","model_ir_header_webkit",,1,,, -"access_ir_header_img","ir.header_img","model_ir_header_img",,,,, +"access_ir_header_webkit","ir.header_webkit","model_ir_header_webkit",,1,,1, +"access_ir_header_img","ir.header_img","model_ir_header_img",,1,,1, \ No newline at end of file diff --git a/addons/report_webkit/webkit_report.py b/addons/report_webkit/webkit_report.py index 23d0b44507c..e72984ac96f 100644 --- a/addons/report_webkit/webkit_report.py +++ b/addons/report_webkit/webkit_report.py @@ -35,8 +35,11 @@ import os import report import tempfile import time +import logging + from mako.template import Template from mako import exceptions + import netsvc import pooler from report_helper import WebKitHelper @@ -46,6 +49,7 @@ import tools from tools.translate import _ from osv.osv import except_osv +logger = logging.getLogger('report_webkit') def mako_template(text): """Build a Mako template. @@ -186,7 +190,8 @@ class WebKitParser(report_sxw): def translate_call(self, src): """Translate String.""" ir_translation = self.pool.get('ir.translation') - res = ir_translation._get_source(self.parser_instance.cr, self.parser_instance.uid, self.name, 'report', self.localcontext.get('lang', 'en_US'), src) + res = ir_translation._get_source(self.parser_instance.cr, self.parser_instance.uid, + self.name, 'report', self.localcontext.get('lang', 'en_US'), src) if not res : return src return res @@ -222,22 +227,20 @@ class WebKitParser(report_sxw): return lang_obj.format('%.' + str(digits) + 'f', value, grouping=grouping, monetary=monetary) - # override needed to keep the attachments' storing procedure + # override needed to keep the attachments storing procedure def create_single_pdf(self, cursor, uid, ids, data, report_xml, context=None): """generate the PDF""" if context is None: context={} - + htmls = [] if report_xml.report_type != 'webkit': return super(WebKitParser,self).create_single_pdf(cursor, uid, ids, data, report_xml, context=context) - self.parser_instance = self.parser( - cursor, - uid, - self.name2, - context=context - ) + self.parser_instance = self.parser(cursor, + uid, + self.name2, + context=context) self.pool = pooler.get_pool(cursor.dbname) objs = self.getObjects(cursor, uid, ids, context) @@ -261,30 +264,10 @@ class WebKitParser(report_sxw): _('Please set a header in company settings') ) if not report_xml.header : - #I know it could be cleaner ... - header = u""" - - - - - - - - -""" + header = '' + defaut_head = addons.get_module_resource('report_webkit', 'default_header.html') + with open(defaut_head,'r') as f: + header = f.read() css = report_xml.webkit_header.css if not css : css = '' @@ -294,16 +277,30 @@ class WebKitParser(report_sxw): #default_filters=['unicode', 'entity'] can be used to set global filter body_mako_tpl = mako_template(template) helper = WebKitHelper(cursor, uid, report_xml.id, context) - try : - html = body_mako_tpl.render( helper=helper, - css=css, - _=self.translate_call, - **self.parser_instance.localcontext - ) - except Exception, e: - msg = exceptions.text_error_template().render() - netsvc.Logger().notifyChannel('Webkit render', netsvc.LOG_ERROR, msg) - raise except_osv(_('Webkit render'), msg) + if report_xml.precise_mode: + for obj in objs: + self.parser_instance.localcontext['objects'] = [obj] + try : + html = body_mako_tpl.render(helper=helper, + css=css, + _=self.translate_call, + **self.parser_instance.localcontext) + htmls.append(html) + except Exception, e: + msg = exceptions.text_error_template().render() + logger.error(msg) + raise except_osv(_('Webkit render'), msg) + else: + try : + html = body_mako_tpl.render(helper=helper, + css=css, + _=self.translate_call, + **self.parser_instance.localcontext) + htmls.append(html) + except Exception, e: + msg = exceptions.text_error_template().render() + logger.error(msg) + raise except_osv(_('Webkit render'), msg) head_mako_tpl = mako_template(header) try : head = head_mako_tpl.render(helper=helper, @@ -324,7 +321,7 @@ class WebKitParser(report_sxw): **self.parser_instance.localcontext) except: msg = exceptions.text_error_template().render() - netsvc.Logger().notifyChannel('Webkit render', netsvc.LOG_ERROR, msg) + logger.error(msg) raise except_osv(_('Webkit render'), msg) if report_xml.webkit_debug : try : @@ -335,11 +332,11 @@ class WebKitParser(report_sxw): **self.parser_instance.localcontext) except Exception, e: msg = exceptions.text_error_template().render() - netsvc.Logger().notifyChannel('Webkit render', netsvc.LOG_ERROR, msg) + logger.error(msg) raise except_osv(_('Webkit render'), msg) return (deb, 'html') bin = self.get_lib(cursor, uid, company.id) - pdf = self.generate_pdf(bin, report_xml, head, foot, [html]) + pdf = self.generate_pdf(bin, report_xml, head, foot, htmls) return (pdf, 'pdf') @@ -352,12 +349,10 @@ class WebKitParser(report_sxw): [('report_name', '=', self.name[7:])], context=context) if report_xml_ids: - report_xml = ir_obj.browse( - cursor, - uid, - report_xml_ids[0], - context=context - ) + report_xml = ir_obj.browse(cursor, + uid, + report_xml_ids[0], + context=context) report_xml.report_rml = None report_xml.report_rml_content = None report_xml.report_sxw_content_data = None From 73adeb660c18890105d7747d2b54360016698eee Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Wed, 21 Sep 2011 10:14:51 +0200 Subject: [PATCH 017/163] [IMP] trailing spaces bzr revid: nicolas.bessi@camptocamp.com-20110921081451-9bdq6wvtjvxbqv3l --- addons/report_webkit/webkit_report.py | 50 +++++++++++++-------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/addons/report_webkit/webkit_report.py b/addons/report_webkit/webkit_report.py index e72984ac96f..d91b8451075 100644 --- a/addons/report_webkit/webkit_report.py +++ b/addons/report_webkit/webkit_report.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- ############################################################################## # -# Copyright (c) 2010 Camptocamp SA (http://www.camptocamp.com) +# Copyright (c) 2010 Camptocamp SA (http://www.camptocamp.com) # All Right Reserved # # Author : Nicolas Bessi (Camptocamp) @@ -64,12 +64,12 @@ class WebKitParser(report_sxw): """Custom class that use webkit to render HTML reports Code partially taken from report openoffice. Thanks guys :) """ - - def __init__(self, name, table, rml=False, parser=False, + + def __init__(self, name, table, rml=False, parser=False, header=True, store=False): self.parser_instance = False self.localcontext={} - report_sxw.__init__(self, name, table, rml, parser, + report_sxw.__init__(self, name, table, rml, parser, header, store) def get_lib(self, cursor, uid, company) : @@ -85,7 +85,7 @@ class WebKitParser(report_sxw): ' http://code.google.com/p/wkhtmltopdf/downloads/list and set the'+ ' path to the executable on the Company form.'+ 'Minimal version is 0.9.9') - ) + ) if os.path.isabs(path) : if (os.path.exists(path) and os.access(path, os.X_OK)\ and os.path.basename(path).startswith('wkhtmltopdf')): @@ -122,7 +122,7 @@ class WebKitParser(report_sxw): head_file = file( os.path.join( tmp_dir, str(time.time()) + '.head.html' - ), + ), 'w' ) head_file.write(header) @@ -133,14 +133,14 @@ class WebKitParser(report_sxw): foot_file = file( os.path.join( tmp_dir, str(time.time()) + '.foot.html' - ), + ), 'w' ) foot_file.write(footer) foot_file.close() file_to_del.append(foot_file.name) command.extend(['--footer-html', foot_file.name]) - + if webkit_header.margin_top : command.extend(['--margin-top', str(webkit_header.margin_top).replace(',', '.')]) if webkit_header.margin_bottom : @@ -167,7 +167,7 @@ class WebKitParser(report_sxw): status = subprocess.call(command, stderr=subprocess.PIPE) # ignore stderr if status : raise except_osv( - _('Webkit raise an error' ), + _('Webkit raise an error' ), status ) except Exception: @@ -180,8 +180,8 @@ class WebKitParser(report_sxw): os.unlink(out) return pdf - - + + def setLang(self, lang): if not lang: lang = 'en_US' @@ -194,8 +194,8 @@ class WebKitParser(report_sxw): self.name, 'report', self.localcontext.get('lang', 'en_US'), src) if not res : return src - return res - + return res + def formatLang(self, value, digits=None, date=False, date_time=False, grouping=True, monetary=False): """format using the know cursor, language from localcontext""" if digits is None: @@ -204,7 +204,7 @@ class WebKitParser(report_sxw): return '' pool_lang = self.pool.get('res.lang') lang = self.localcontext['lang'] - + lang_ids = pool_lang.search(self.parser_instance.cr, self.parser_instance.uid, [('code','=',lang)])[0] lang_obj = pool_lang.browse(self.parser_instance.cr, self.parser_instance.uid, lang_ids) @@ -230,7 +230,7 @@ class WebKitParser(report_sxw): # override needed to keep the attachments storing procedure def create_single_pdf(self, cursor, uid, ids, data, report_xml, context=None): """generate the PDF""" - + if context is None: context={} htmls = [] @@ -259,10 +259,10 @@ class WebKitParser(report_sxw): header = report_xml.webkit_header.html footer = report_xml.webkit_header.footer_html if not header and report_xml.header: - raise except_osv( - _('No header defined for this Webkit report!'), - _('Please set a header in company settings') - ) + raise except_osv( + _('No header defined for this Webkit report!'), + _('Please set a header in company settings') + ) if not report_xml.header : header = '' defaut_head = addons.get_module_resource('report_webkit', 'default_header.html') @@ -273,7 +273,7 @@ class WebKitParser(report_sxw): css = '' user = self.pool.get('res.users').browse(cursor, uid, uid) company= user.company_id - + #default_filters=['unicode', 'entity'] can be used to set global filter body_mako_tpl = mako_template(template) helper = WebKitHelper(cursor, uid, report_xml.id, context) @@ -327,7 +327,7 @@ class WebKitParser(report_sxw): try : deb = head_mako_tpl.render(helper=helper, css=css, - _debug=tools.ustr(html), + _debug=tools.ustr("\n".join(htmls)), _=self.translate_call, **self.parser_instance.localcontext) except Exception, e: @@ -348,10 +348,10 @@ class WebKitParser(report_sxw): report_xml_ids = ir_obj.search(cursor, uid, [('report_name', '=', self.name[7:])], context=context) if report_xml_ids: - - report_xml = ir_obj.browse(cursor, - uid, - report_xml_ids[0], + + report_xml = ir_obj.browse(cursor, + uid, + report_xml_ids[0], context=context) report_xml.report_rml = None report_xml.report_rml_content = None From 97892fb72d21938cefe58b8095ece3e1962ef1aa Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Wed, 21 Sep 2011 10:15:46 +0200 Subject: [PATCH 018/163] [FIX] typo bzr revid: nicolas.bessi@camptocamp.com-20110921081546-uwwc9nx71pr6u742 --- addons/report_webkit/webkit_report.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/report_webkit/webkit_report.py b/addons/report_webkit/webkit_report.py index d91b8451075..bda6c193af2 100644 --- a/addons/report_webkit/webkit_report.py +++ b/addons/report_webkit/webkit_report.py @@ -265,8 +265,8 @@ class WebKitParser(report_sxw): ) if not report_xml.header : header = '' - defaut_head = addons.get_module_resource('report_webkit', 'default_header.html') - with open(defaut_head,'r') as f: + default_head = addons.get_module_resource('report_webkit', 'default_header.html') + with open(default_head,'r') as f: header = f.read() css = report_xml.webkit_header.css if not css : From 31204f5247dedabd572e798ee44aa8d1c61e4f12 Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Wed, 21 Sep 2011 10:16:11 +0200 Subject: [PATCH 019/163] =?UTF-8?q?[ADD]=C2=A0default=20header.html?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bzr revid: nicolas.bessi@camptocamp.com-20110921081611-3p75ty254t88xcg9 --- addons/report_webkit/default_header.html | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 addons/report_webkit/default_header.html diff --git a/addons/report_webkit/default_header.html b/addons/report_webkit/default_header.html new file mode 100644 index 00000000000..0798209a5b7 --- /dev/null +++ b/addons/report_webkit/default_header.html @@ -0,0 +1,22 @@ + + + + + + + + + \ No newline at end of file From 4772d465fd7c5df58ec7244deddd634426698477 Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Wed, 21 Sep 2011 10:44:13 +0200 Subject: [PATCH 020/163] =?UTF-8?q?[FIX]=C2=A0author?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bzr revid: nicolas.bessi@camptocamp.com-20110921084413-6cdm16i96ufwoelx --- addons/report_webkit/__openerp__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/report_webkit/__openerp__.py b/addons/report_webkit/__openerp__.py index e593791f826..1e0e780786d 100644 --- a/addons/report_webkit/__openerp__.py +++ b/addons/report_webkit/__openerp__.py @@ -73,7 +73,7 @@ Web client WYSIWYG """, "version" : "0.9", "depends" : ["base"], - "author" : "Camptocamp SA - NBessi", + "author" : "Camptocamp", "category": "Tools", "url": "http://http://www.camptocamp.com/", "data": [ "security/ir.model.access.csv", From 74cb5782aa6b8ed6bc8b2210664dc682d045707d Mon Sep 17 00:00:00 2001 From: "Vaibhav (OpenERP)" Date: Fri, 23 Sep 2011 12:22:51 +0530 Subject: [PATCH 021/163] [FIX] Gantview contextmenu Action should affects to record. lp bug: https://launchpad.net/bugs/855346 fixed bzr revid: vda@tinyerp.com-20110923065251-uj5ywar45xyj2y64 --- addons/web/static/src/js/views.js | 3 +- addons/web_gantt/static/src/js/gantt.js | 115 ++++++++++++++---------- 2 files changed, 72 insertions(+), 46 deletions(-) diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index 88db848118f..e8068fb90d0 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -424,7 +424,8 @@ db.web.ViewManagerAction = db.web.ViewManager.extend(/** @lends oepnerp.web.View return $.when( this._super(view_type), this.shortcut_check(this.views[view_type])).then(function () { - var view_id = self.views[self.active_view].controller.fields_view.view_id; + var active_controller = self.views[self.active_view].controller; + var view_id = active_controller.fields_view ? active_controller.fields_view.view_id : active_controller.view_id; self.$element.find('.oe_get_xml_view span').text(view_id); }); }, diff --git a/addons/web_gantt/static/src/js/gantt.js b/addons/web_gantt/static/src/js/gantt.js index a045bae64e1..378951b2a4f 100644 --- a/addons/web_gantt/static/src/js/gantt.js +++ b/addons/web_gantt/static/src/js/gantt.js @@ -43,7 +43,7 @@ init: function(parent, dataset, view_id) { this.name = this.fields_view.arch.attrs.string; this.view_id = this.fields_view.view_id; - + this.date_start = this.fields_view.arch.attrs.date_start; this.date_delay = this.fields_view.arch.attrs.date_delay; this.date_stop = this.fields_view.arch.attrs.date_stop; @@ -228,7 +228,7 @@ init: function(parent, dataset, view_id) { var evt_date = ""; var evt_duration = ""; var evt_end_date = ""; - + var project_tree_field = []; for (var i in final_events){ evt_id = final_events[i]; evt_date = all_events[evt_id]['evt'][2]; @@ -254,7 +254,7 @@ init: function(parent, dataset, view_id) { self.render_events(all_events, 0); } - for (var i in final_events){ + for (var i in final_events) { evt_id = final_events[i]; res = all_events[evt_id]; task=new GanttTaskInfo(res['evt'][0], res['evt'][1], res['evt'][2], res['evt'][3], res['evt'][4], "",res['evt'][6]); @@ -278,8 +278,9 @@ init: function(parent, dataset, view_id) { ganttChartControl.attachEvent("onTaskStartDrag", function(task) {self.on_drag_start(task);}); ganttChartControl.attachEvent("onTaskEndResize", function(task) {self.on_resize_drag_end(task, "resize");}); ganttChartControl.attachEvent("onTaskEndDrag", function(task) {self.on_resize_drag_end(task, "drag");}); + ganttChartControl.attachEvent("onTaskDblClick", function(task) {self.open_popup(task);}); - + var taskdiv = jQuery("div.taskPanel").parent(); taskdiv.addClass('ganttTaskPanel'); taskdiv.prev().addClass('ganttDayPanel'); @@ -293,7 +294,7 @@ init: function(parent, dataset, view_id) { self.set_width(); }); - jQuery(window).bind('resize',function(){ + jQuery(window).bind('resize',function() { window.clearTimeout(ganttChartControl._resize_timer); ganttChartControl._resize_timer = window.setTimeout(function(){ self.reload_gantt(); @@ -301,6 +302,37 @@ init: function(parent, dataset, view_id) { }); jQuery("div #_1, div #_1 + div").hide(); + + //Custom events + var context_menu = ganttChartControl.contextMenu, + buttons = [], + values = {}; + + _.each(context_menu.arrTabs, function(tab, tab_index) { + buttons.push(_.filter(tab.arrItems,function(b) { + return b.control.type == "button"; + })[0]); + }); + _.each(buttons, function(b, index) { + $(b.control).click(function() { + if(!context_menu.arrTabs[index].object.parentTask) + return false; + var task_info = context_menu.arrTabs[index].object.TaskInfo; + project_id = task_info.Id;; + switch(index) { + case 0: + values[self.text] = task_info.Name; + return self.dataset.write(project_id, values); + case 1: + return self.dataset.unlink([project_id]); + case 3: + if(self.date_delay) { + values[self.date_delay] = task_info.Duration; + return self.dataset.write(project_id, values); + } + } + }) + }); }, set_width: function() { @@ -385,53 +417,46 @@ init: function(parent, dataset, view_id) { }, open_popup : function(task) { + var self = this; var event_id = task.getId(); if(event_id.toString().search("_") != -1) return; if(event_id) event_id = parseInt(event_id, 10); + + var action_manager = new openerp.web.ActionManager(this); + + var dialog = new openerp.web.Dialog(this, { + width: 800, + height: 600, + buttons : { + Cancel : function() { + $(this).dialog('destroy'); + }, + Save : function() { + var form_view = action_manager.inner_viewmanager.views.form.controller; - var action = { - "res_model": this.dataset.model, - "res_id": event_id, - "views":[[false,"form"]], - "type":"ir.actions.act_window", - "view_type":"form", - "view_mode":"form" - }; - - action.flags = { - search_view: false, - sidebar : false, - views_switcher : false, - pager: false - }; - var element_id = _.uniqueId("act_window_dialog"); - var dialog = jQuery('
', { - 'id': element_id - }).dialog({ - modal: true, - width: 'auto', - height: 'auto', - buttons: { - Cancel: function() { - $(this).dialog("destroy"); - }, - Save: function() { - var view_manager = action_manager.viewmanager; - var _dialog = this; - view_manager.views[view_manager.active_view].controller.do_save(function(r) { - $(_dialog).dialog("destroy"); - self.reload_gantt(); - }) - } + form_view.do_save(function() { + self.get_events(); + }); + $(this).dialog('destroy'); } + } + }).start().open(); + action_manager.appendTo(dialog.$element); + action_manager.do_action({ + res_model : this.dataset.model, + res_id: event_id, + views : [[false, 'form']], + type : 'ir.actions.act_window', + auto_search : false, + flags : { + search_view: false, + sidebar : false, + views_switcher : false, + action_buttons : false, + pager: false + } }); - var action_manager = new openerp.web.ActionManager(this, element_id); - action_manager.start(); - action_manager.do_action(action); - - //Default_get - if(!event_id) action_manager.viewmanager.dataset.index = null; }, on_drag_start : function(task){ From 2b36bfc4cc6f73bea64e97c107dd1b5a1765c35f Mon Sep 17 00:00:00 2001 From: "renatonlima@gmail.com" <> Date: Mon, 3 Oct 2011 10:32:03 -0300 Subject: [PATCH 022/163] brazilian localization module merge bzr revid: renatonlima@gmail.com-20111003133203-10qix7vprmwifru6 --- addons/l10n_br/__init__.py | 5 +- addons/l10n_br/__openerp__.py | 40 +- addons/l10n_br/account.py | 177 ++++ addons/l10n_br/account_view.xml | 114 ++ .../l10n_br/data/account.account.template.csv | 412 ++++---- addons/l10n_br/data/account.account.type.csv | 4 +- .../data/account.tax.code.template.csv | 23 +- addons/l10n_br/data/account_tax_template.xml | 994 ++++++++++-------- .../data/l10n_br_account_chart_template.xml | 13 +- addons/l10n_br/data/l10n_br_data.xml | 673 ++++++++++++ addons/l10n_br/l10n_br.py | 84 ++ addons/l10n_br/l10n_br_view.xml | 80 ++ addons/l10n_br/security/ir.model.access.csv | 3 + 13 files changed, 1970 insertions(+), 652 deletions(-) create mode 100644 addons/l10n_br/account.py create mode 100644 addons/l10n_br/account_view.xml create mode 100644 addons/l10n_br/data/l10n_br_data.xml create mode 100644 addons/l10n_br/l10n_br.py create mode 100644 addons/l10n_br/l10n_br_view.xml create mode 100644 addons/l10n_br/security/ir.model.access.csv diff --git a/addons/l10n_br/__init__.py b/addons/l10n_br/__init__.py index efb54d8e4c1..ad29d242d37 100644 --- a/addons/l10n_br/__init__.py +++ b/addons/l10n_br/__init__.py @@ -4,7 +4,7 @@ # Copyright (C) 2009 Renato Lima - Akretion # # # #This program is free software: you can redistribute it and/or modify # -#it under the terms of the GNU General Public License as published by # +#it under the terms of the GNU Affero General Public License as published by # #the Free Software Foundation, either version 3 of the License, or # #(at your option) any later version. # # # @@ -17,5 +17,8 @@ #along with this program. If not, see . # ################################################################################# +import account +import l10n_br + # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_br/__openerp__.py b/addons/l10n_br/__openerp__.py index 578978599a0..be7fddc15db 100644 --- a/addons/l10n_br/__openerp__.py +++ b/addons/l10n_br/__openerp__.py @@ -4,7 +4,7 @@ # Copyright (C) 2009 Renato Lima - Akretion # # This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by +# it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # @@ -20,29 +20,43 @@ { 'name': 'Brazilian Localization', - 'description': 'Brazilian Localization', - 'category': 'Finance', - 'description': """ -This is the base module to manage the accounting chart for Brazil in OpenERP. -============================================================================= + 'description': """Brazilian Localization. This module consists in: +- Generic Brazilian chart of accounts +- Brazilian taxes such as: + - IPI + - ICMS + - PIS + - COFINS + - ISS + - IR + - IRPJ + - CSLL +- Tax Situation Code (CST) required for the electronic fiscal invoicing (NFe) -Brazilian accounting chart and localization. - """, - 'author': 'OpenERP Brasil', +The field tax_discount has also been added in the account.tax.template and account.tax objects to allow the proper computation of some Brazilian VATs such as ICMS. The chart of account creation wizard has been extended to propagate those new data properly. + +It's important to note however that this module lack many implementations to use OpenERP properly in Brazil. Those implementations (such as the electronic fiscal Invoicing which is already operational) are brought by more than 15 additional modules of the Brazilian Launchpad localization project https://launchpad.net/openerp.pt-br-localiz and their dependencies in the extra addons branch. Those modules aim at not breaking with the remarkable OpenERP modularity, this is why they are numerous but small. One of the reasons for maintaining those modules apart is that Brazilian Localization leaders need commit rights agility to complete the localization as companies fund the remaining legal requirements (such as soon fiscal ledgers, accounting SPED, fiscal SPED and PAF ECF that are still missing as September 2011). Those modules are also strictly licensed under AGPL V3 and today don't come with any additional paid permission for online use of 'private modules'.""", + 'category': 'Localisation/Account Charts', + 'license': 'AGPL-3', + 'author': 'Akretion, OpenERP Brasil', 'website': 'http://openerpbrasil.org', 'version': '0.6', 'depends': ['account','account_chart'], - 'init_xml': [], - 'update_xml': [ + 'init_xml': [ 'data/account.account.type.csv', 'data/account.tax.code.template.csv', 'data/account.account.template.csv', 'data/l10n_br_account_chart_template.xml', - 'data/account_tax_template.xml' + 'data/account_tax_template.xml', + 'data/l10n_br_data.xml', + 'security/ir.model.access.csv', + ], + 'update_xml': [ + 'account_view.xml', + 'l10n_br_view.xml', ], 'installable': True, 'certificate' : '001280994939126801405', - 'images': ['images/1_config_chart_l10n_br.jpeg','images/2_l10n_br_chart.jpeg'], } # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_br/account.py b/addons/l10n_br/account.py new file mode 100644 index 00000000000..965ff500829 --- /dev/null +++ b/addons/l10n_br/account.py @@ -0,0 +1,177 @@ +# -*- encoding: utf-8 -*- +################################################################################# +# # +# Copyright (C) 2009 Renato Lima - Akretion # +# # +#This program is free software: you can redistribute it and/or modify # +#it under the terms of the GNU Affero General Public License as published by # +#the Free Software Foundation, either version 3 of the License, or # +#(at your option) any later version. # +# # +#This program is distributed in the hope that it will be useful, # +#but WITHOUT ANY WARRANTY; without even the implied warranty of # +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +#GNU General Public License for more details. # +# # +#You should have received a copy of the GNU General Public License # +#along with this program. If not, see . # +################################################################################# + +import time +from datetime import datetime, timedelta +from dateutil.relativedelta import relativedelta +from operator import itemgetter + +import netsvc +import pooler +from osv import fields, osv +import decimal_precision as dp +from tools.misc import currency +from tools.translate import _ +from tools import config + +class account_tax_code_template(osv.osv): + + _inherit = 'account.tax.code.template' + _columns = { + 'domain':fields.char('Domain', size=32, help="This field is only used if you develop your own module allowing developers to create specific taxes in a custom domain."), + 'tax_discount': fields.boolean('Discount this Tax in Prince', help="Mark it for (ICMS, PIS e etc.)."), + } +account_tax_code_template() + +class account_tax_code(osv.osv): + + _inherit = 'account.tax.code' + _columns = { + 'domain':fields.char('Domain', size=32, help="This field is only used if you develop your own module allowing developers to create specific taxes in a custom domain."), + 'tax_discount': fields.boolean('Discount this Tax in Prince', help="Mark it for (ICMS, PIS e etc.)."), + } +account_tax_code() + +class account_tax_template(osv.osv): + _inherit = 'account.tax.template' + + def get_precision_tax(): + def change_digit_tax(cr): + res = pooler.get_pool(cr.dbname).get('decimal.precision').precision_get(cr, 1, 'Account') + return (16, res+2) + return change_digit_tax + + _columns = { + 'tax_discount': fields.boolean('Discount this Tax in Prince', help="Mark it for (ICMS, PIS e etc.)."), + 'base_reduction': fields.float('Redution', required=True, digits_compute=get_precision_tax(), help="For taxes of type percentage, enter % ratio between 0-1."), + 'amount_mva': fields.float('MVA Percent', required=True, digits_compute=get_precision_tax(), help="For taxes of type percentage, enter % ratio between 0-1."), + 'type': fields.selection( [('percent','Percentage'), ('fixed','Fixed Amount'), ('none','None'), ('code','Python Code'), ('balance','Balance'), ('quantity','Quantity')], 'Tax Type', required=True, + help="The computation method for the tax amount."), + } + _defaults = { + 'base_reduction': 0, + 'amount_mva': 0, + } + + def onchange_tax_code_id(self, cr, uid, ids, tax_code_id, context=None): + + result = {'value': {}} + + if not tax_code_id: + return result + + obj_tax_code = self.pool.get('account.tax.code.template').browse(cr, uid, tax_code_id) + + if obj_tax_code: + result['value']['tax_discount'] = obj_tax_code.tax_discount + result['value']['domain'] = obj_tax_code.domain + + return result + +account_tax_template() + +class account_tax(osv.osv): + _inherit = 'account.tax' + + def get_precision_tax(): + def change_digit_tax(cr): + res = pooler.get_pool(cr.dbname).get('decimal.precision').precision_get(cr, 1, 'Account') + return (16, res+2) + return change_digit_tax + + _columns = { + 'tax_discount': fields.boolean('Discount this Tax in Prince', help="Mark it for (ICMS, PIS e etc.)."), + 'base_reduction': fields.float('Redution', required=True, digits_compute=get_precision_tax(), help="Um percentual decimal em % entre 0-1."), + 'amount_mva': fields.float('MVA Percent', required=True, digits_compute=get_precision_tax(), help="Um percentual decimal em % entre 0-1."), + 'type': fields.selection( [('percent','Percentage'), ('fixed','Fixed Amount'), ('none','None'), ('code','Python Code'), ('balance','Balance'), ('quantity','Quantity')], 'Tax Type', required=True, + help="The computation method for the tax amount."), + } + _defaults = { + 'base_reduction': 0, + 'amount_mva': 0, + } + + def onchange_tax_code_id(self, cr, uid, ids, tax_code_id, context=None): + + result = {'value': {}} + + if not tax_code_id: + return result + + obj_tax_code = self.pool.get('account.tax.code').browse(cr, uid, tax_code_id) + + if obj_tax_code: + result['value']['tax_discount'] = obj_tax_code.tax_discount + result['value']['domain'] = obj_tax_code.domain + + return result + +account_tax() + +class account_journal(osv.osv): + _inherit = "account.journal" + + _columns = { + 'internal_sequence': fields.many2one('ir.sequence', 'Internal Sequence'), + } + +account_journal() + +class wizard_multi_charts_accounts(osv.osv_memory): + + _inherit = 'wizard.multi.charts.accounts' + + def execute(self, cr, uid, ids, context=None): + + super(wizard_multi_charts_accounts, self).execute(cr, uid, ids, context) + + obj_multi = self.browse(cr, uid, ids[0]) + obj_acc_tax = self.pool.get('account.tax') + obj_acc_tax_tmp = self.pool.get('account.tax.template') + obj_acc_cst = self.pool.get('l10n_br_account.cst') + obj_acc_cst_tmp = self.pool.get('l10n_br_account.cst.template') + obj_tax_code = self.pool.get('account.tax.code') + obj_tax_code_tmp = self.pool.get('account.tax.code.template') + + # Creating Account + obj_acc_root = obj_multi.chart_template_id.account_root_id + tax_code_root_id = obj_multi.chart_template_id.tax_code_root_id.id + company_id = obj_multi.company_id.id + + children_tax_code_template = self.pool.get('account.tax.code.template').search(cr, uid, [('parent_id','child_of',[tax_code_root_id])], order='id') + children_tax_code_template.sort() + for tax_code_template in self.pool.get('account.tax.code.template').browse(cr, uid, children_tax_code_template, context=context): + tax_code_id = self.pool.get('account.tax.code').search(cr, uid, [('code','=',tax_code_template.code),('company_id','=',company_id)]) + if tax_code_id: + obj_tax_code.write(cr, uid, tax_code_id, {'domain': tax_code_template.domain,'tax_discount': tax_code_template.tax_discount}) + + cst_tmp_ids = self.pool.get('l10n_br_account.cst.template').search(cr, uid, [('tax_code_template_id','=',tax_code_template.id)], order='id') + for cst_tmp in self.pool.get('l10n_br_account.cst.template').browse(cr, uid, cst_tmp_ids, context=context): + obj_acc_cst.create(cr, uid, { + 'code': cst_tmp.code, + 'name': cst_tmp.name, + 'tax_code_id': tax_code_id[0], + }) + + tax_ids = self.pool.get('account.tax').search(cr, uid, [('company_id','=',company_id)]) + for tax in self.pool.get('account.tax').browse(cr, uid, tax_ids, context=context): + if tax.tax_code_id: + obj_acc_tax.write(cr, uid, tax.id, {'domain': tax.tax_code_id.domain,'tax_discount': tax.tax_code_id.tax_discount}) + +wizard_multi_charts_accounts() \ No newline at end of file diff --git a/addons/l10n_br/account_view.xml b/addons/l10n_br/account_view.xml new file mode 100644 index 00000000000..da2ab84d4ab --- /dev/null +++ b/addons/l10n_br/account_view.xml @@ -0,0 +1,114 @@ + + + + + + + l10n_br_account.tax.code.form + account.tax.code + + + + + + + + + + + l10n_br_account.tax.code.template.form + account.tax.code.template + + + + + + + + + + + + l10n_br_account.tax.template.form + account.tax.template + + + + + + + + + + l10n_br_account.tax.form + account.tax + + + + + + + + + + l10n_br_account.tax.template.form1 + account.tax.template + + + + + + + + + + + l10n_br_account.tax.form1 + account.tax + + + + + + + + + + + l10n_br_account.tax.form2 + account.tax + + + + + + + + + + l10n_br_account.tax.template.form2 + account.tax.template + + + + + + + + + + l10n_br.journal.form.inherit + account.journal + form + + + + + + + + + + + + diff --git a/addons/l10n_br/data/account.account.template.csv b/addons/l10n_br/data/account.account.template.csv index d0468c68995..6b466b6e7ab 100644 --- a/addons/l10n_br/data/account.account.template.csv +++ b/addons/l10n_br/data/account.account.template.csv @@ -1,17 +1,17 @@ "id","code","name","parent_id:id","type","user_type:id","reconcile" -"account_template_1","0","Plano de Contas Padrão","","view","ativo","True" +"account_template_1","0","Plano de Contas Padrão",,"view","ativo","True" "account_template_2","1","ATIVO","account_template_1","view","ativo","True" "account_template_3","1.1","CIRCULANTE","account_template_2","view","ativo","True" "account_template_4","1.1.01","DISPONIBILIDADES","account_template_3","view","ativo","True" "account_template_5","1.1.01.01","CAIXA","account_template_4","view","ativo","True" -"account_template_6","1.1.01.01.0001","Caixa Geral","account_template_5","receivable","ativo","True" -"account_template_7","1.1.01.01.0002","Fundo Fixo","account_template_5","receivable","ativo","True" +"account_template_6","1.1.01.01.0001","Caixa Geral","account_template_5","other","ativo","True" +"account_template_7","1.1.01.01.0002","Fundo Fixo","account_template_5","other","ativo","True" "account_template_8","1.1.01.02","BANCOS ","account_template_4","view","ativo","True" -"account_template_9","1.1.01.02.0001","Banco C/ Movimento","account_template_8","receivable","ativo","True" +"account_template_9","1.1.01.02.0001","Banco C/ Movimento","account_template_8","other","ativo","True" "account_template_10","1.1.01.03","VALORES MOBILIÁRIOS-MERC.CAP.INTERNOS","account_template_4","view","ativo","True" -"account_template_11","1.1.01.03.0001","Aplicações Nacionais","account_template_10","receivable","ativo","True" +"account_template_11","1.1.01.03.0001","Aplicações Nacionais","account_template_10","other","ativo","True" "account_template_12","1.1.01.04","TITULOS DE CAPITALIZAÇÃO","account_template_4","view","ativo","True" -"account_template_13","1.1.01.04.0001","Banco Título de Capitalização","account_template_12","receivable","ativo","True" +"account_template_13","1.1.01.04.0001","Banco Título de Capitalização","account_template_12","other","ativo","True" "account_template_14","1.1.02","CRÉDITOS","account_template_3","view","ativo","True" "account_template_15","1.1.02.01","CLIENTES NACIONAIS","account_template_14","view","ativo","True" "account_template_16","1.1.02.01.0001","Clientes Nacionais","account_template_15","receivable","ativo","True" @@ -20,186 +20,186 @@ "account_template_19","1.1.02.03","OUTROS VALORES A RECEBER","account_template_14","view","ativo","True" "account_template_20","1.1.02.03.0001","Outras Contas a Receber","account_template_19","receivable","ativo","True" "account_template_21","1.1.02.04","DUPLICATAS CONTA VINCULADA","account_template_14","view","ativo","True" -"account_template_22","1.1.02.04.0001","Banco Conta Garantida","account_template_21","receivable","ativo","True" +"account_template_22","1.1.02.04.0001","Banco Conta Garantida","account_template_21","other","ativo","True" "account_template_23","1.1.02.05","DUPLICATAS CAUCIONADAS","account_template_14","view","ativo","True" -"account_template_24","1.1.02.05.0001","Banco Conta Caucionada","account_template_23","receivable","ativo","True" +"account_template_24","1.1.02.05.0001","Banco Conta Caucionada","account_template_23","other","ativo","True" "account_template_25","1.1.02.06","CHEQUES DEVOLVIDOS","account_template_14","view","ativo","True" -"account_template_26","1.1.02.06.0001","Cheques Devolvidos","account_template_25","receivable","ativo","True" +"account_template_26","1.1.02.06.0001","Cheques Devolvidos","account_template_25","other","ativo","True" "account_template_27","1.1.02.07","ADIANTAMENTOS","account_template_14","view","ativo","True" -"account_template_28","1.1.02.07.0002","Adiantamento de Salários","account_template_27","receivable","ativo","True" -"account_template_29","1.1.02.07.0003","Adiantamento Despesa de Viagem","account_template_27","receivable","ativo","True" -"account_template_30","1.1.02.07.0004","Adiantamento de Férias","account_template_27","receivable","ativo","True" -"account_template_31","1.1.02.07.0005","Adiantamento 13º Salário","account_template_27","receivable","ativo","True" -"account_template_32","1.1.02.07.0006","Adiantamento de Pro-Labore a Diretores","account_template_27","receivable","ativo","True" -"account_template_33","1.1.02.07.0001","Adiantamento de PIS a Empregados","account_template_27","receivable","ativo","True" +"account_template_28","1.1.02.07.0002","Adiantamento de Salários","account_template_27","other","ativo","True" +"account_template_29","1.1.02.07.0003","Adiantamento Despesa de Viagem","account_template_27","other","ativo","True" +"account_template_30","1.1.02.07.0004","Adiantamento de Férias","account_template_27","other","ativo","True" +"account_template_31","1.1.02.07.0005","Adiantamento 13º Salário","account_template_27","other","ativo","True" +"account_template_32","1.1.02.07.0006","Adiantamento de Pro-Labore a Diretores","account_template_27","other","ativo","True" +"account_template_33","1.1.02.07.0001","Adiantamento de PIS a Empregados","account_template_27","other","ativo","True" "account_template_34","1.1.02.08","ADIANTAMENTO A FORNECEDORES","account_template_14","view","ativo","True" -"account_template_35","1.1.02.08.0001","Adiantamento a Fornecedor","account_template_34","receivable","ativo","True" +"account_template_35","1.1.02.08.0001","Adiantamento a Fornecedor","account_template_34","other","ativo","True" "account_template_36","1.1.02.09","IMPOSTOS E CONTRIBUIÇÕES A RECUPERAR","account_template_14","view","ativo","True" -"account_template_37","1.1.02.09.0001","CSLL a Recuperar/Compensar","account_template_36","receivable","ativo","True" -"account_template_38","1.1.02.09.0002","CSLL a Compensar Lei 10.833/03","account_template_36","receivable","ativo","True" -"account_template_39","1.1.02.09.0003","COFINS a Recuperar/Compensar","account_template_36","receivable","ativo","True" -"account_template_40","1.1.02.09.0004","COFINS a Compensar Lei 10.833/03","account_template_36","receivable","ativo","True" -"account_template_41","1.1.02.09.0008","Crédito COFINS Não-Cumulativo","account_template_36","receivable","ativo","True" -"account_template_42","1.1.02.09.0009","ICMS a Recuperar","account_template_36","receivable","ativo","True" -"account_template_43","1.1.02.09.0010","ICMS a Recup. s/Ativo Imobilizado","account_template_36","receivable","ativo","True" -"account_template_44","1.1.02.09.0012","IPI a Recuperar/Compensar","account_template_36","receivable","ativo","True" -"account_template_45","1.1.02.09.0013","IPI a Compensar Pedido Restituição","account_template_36","receivable","ativo","True" -"account_template_46","1.1.02.09.0015","IRF s/Aplicações Financeiras","account_template_36","receivable","ativo","True" -"account_template_47","1.1.02.09.0016","IRRF a Recuperar/Compensar","account_template_36","receivable","ativo","True" -"account_template_48","1.1.02.09.0017","IRPJ a Recuperar/Compensar","account_template_36","receivable","ativo","True" -"account_template_49","1.1.02.09.0019","PIS a Recuperar/Compensar","account_template_36","receivable","ativo","True" -"account_template_50","1.1.02.09.0020","PIS a Compensar Lei 10.833/03","account_template_36","receivable","ativo","True" -"account_template_51","1.1.02.09.0022","PIS/COFINS/CSLL a Recuperar","account_template_36","receivable","ativo","True" -"account_template_52","1.1.02.09.0007","Crédito de PIS Não-Cumulativo","account_template_36","receivable","ativo","True" +"account_template_37","1.1.02.09.0001","CSLL a Recuperar/Compensar","account_template_36","other","ativo","True" +"account_template_38","1.1.02.09.0002","CSLL a Compensar Lei 10.833/03","account_template_36","other","ativo","True" +"account_template_39","1.1.02.09.0003","COFINS a Recuperar/Compensar","account_template_36","other","ativo","True" +"account_template_40","1.1.02.09.0004","COFINS a Compensar Lei 10.833/03","account_template_36","other","ativo","True" +"account_template_41","1.1.02.09.0008","Crédito COFINS Não-Cumulativo","account_template_36","other","ativo","True" +"account_template_42","1.1.02.09.0009","ICMS a Recuperar","account_template_36","other","ativo","True" +"account_template_43","1.1.02.09.0010","ICMS a Recup. s/Ativo Imobilizado","account_template_36","other","ativo","True" +"account_template_44","1.1.02.09.0012","IPI a Recuperar/Compensar","account_template_36","other","ativo","True" +"account_template_45","1.1.02.09.0013","IPI a Compensar Pedido Restituição","account_template_36","other","ativo","True" +"account_template_46","1.1.02.09.0015","IRF s/Aplicações Financeiras","account_template_36","other","ativo","True" +"account_template_47","1.1.02.09.0016","IRRF a Recuperar/Compensar","account_template_36","other","ativo","True" +"account_template_48","1.1.02.09.0017","IRPJ a Recuperar/Compensar","account_template_36","other","ativo","True" +"account_template_49","1.1.02.09.0019","PIS a Recuperar/Compensar","account_template_36","other","ativo","True" +"account_template_50","1.1.02.09.0020","PIS a Compensar Lei 10.833/03","account_template_36","other","ativo","True" +"account_template_51","1.1.02.09.0022","PIS/COFINS/CSLL a Recuperar","account_template_36","other","ativo","True" +"account_template_52","1.1.02.09.0007","Crédito de PIS Não-Cumulativo","account_template_36","other","ativo","True" "account_template_53","1.1.02.10","CRÉDITOS FISCAIS CSLL BASE CALC.NEGATIVA","account_template_14","view","ativo","True" -"account_template_54","1.1.02.10.0001","Base Negativa CSLL - Exerc. Anteriores","account_template_53","receivable","ativo","True" +"account_template_54","1.1.02.10.0001","Base Negativa CSLL - Exerc. Anteriores","account_template_53","other","ativo","True" "account_template_55","1.1.02.11","CRÉDITOS FISCAIS IRPJ-BASE CALC.NEGATIVA","account_template_14","view","ativo","True" -"account_template_56","1.1.02.11.0001","Base Negativa IRPJ - Exerc. Anteriores","account_template_55","receivable","ativo","True" +"account_template_56","1.1.02.11.0001","Base Negativa IRPJ - Exerc. Anteriores","account_template_55","other","ativo","True" "account_template_57","1.1.03","ESTOQUES","account_template_3","view","ativo","True" "account_template_58","1.1.03.01","ESTOQUE DE MERCADORIAS","account_template_57","view","ativo","True" -"account_template_59","1.1.03.01.0001","Insumos (Materiais Diretos)","account_template_58","receivable","ativo","True" -"account_template_60","1.1.03.01.0002","Material de Consumo-Almoxarifado","account_template_58","receivable","ativo","True" -"account_template_61","1.1.03.01.0003","Mercadorias para Revenda","account_template_58","receivable","ativo","True" -"account_template_62","1.1.03.01.0004","Produtos Acabados","account_template_58","receivable","ativo","True" -"account_template_63","1.1.03.01.0005","Produtos em Elaboração","account_template_58","receivable","ativo","True" +"account_template_59","1.1.03.01.0001","Insumos (Materiais Diretos)","account_template_58","other","ativo","True" +"account_template_60","1.1.03.01.0002","Material de Consumo-Almoxarifado","account_template_58","other","ativo","True" +"account_template_61","1.1.03.01.0003","Mercadorias para Revenda","account_template_58","other","ativo","True" +"account_template_62","1.1.03.01.0004","Produtos Acabados","account_template_58","other","ativo","True" +"account_template_63","1.1.03.01.0005","Produtos em Elaboração","account_template_58","other","ativo","True" "account_template_64","1.1.03.02","(-) DEVOLUÇÕES DE COMPRAS","account_template_57","view","ativo","True" -"account_template_65","1.1.03.02.0001","Devoluções de Compras","account_template_64","receivable","ativo","True" +"account_template_65","1.1.03.02.0001","Devoluções de Compras","account_template_64","other","ativo","True" "account_template_66","1.1.03.03","TRANSFERÊNCIA DE MERCADORIAS","account_template_57","view","ativo","True" -"account_template_67","1.1.03.03.0001","Transferência de Mercadorias","account_template_66","receivable","ativo","True" +"account_template_67","1.1.03.03.0001","Transferência de Mercadorias","account_template_66","other","ativo","True" "account_template_68","1.1.03.04","ESTOQUE DE TERCEIROS EM NOSSO PODER","account_template_57","view","ativo","True" -"account_template_69","1.1.03.04.0001","Estoque de Terceiros em N/Poder","account_template_68","receivable","ativo","True" -"account_template_70","1.1.03.04.0002","Entrada P/Industrialização","account_template_68","receivable","ativo","True" -"account_template_71","1.1.03.04.0003","Entrada P/Conserto","account_template_68","receivable","ativo","True" -"account_template_72","1.1.03.04.0004","Entrada P/Demonstração","account_template_68","receivable","ativo","True" -"account_template_73","1.1.03.04.0005","Entrada P/Empréstimo","account_template_68","receivable","ativo","True" -"account_template_74","1.1.03.04.0006","Entrada em Consignação","account_template_68","receivable","ativo","True" -"account_template_75","1.1.03.04.0007","Entrada p/ Garantia","account_template_68","receivable","ativo","True" -"account_template_76","1.1.03.04.0008","Entrada p/ Locação","account_template_68","receivable","ativo","True" -"account_template_77","1.1.03.04.0009","Entrada em Comodato","account_template_68","receivable","ativo","True" +"account_template_69","1.1.03.04.0001","Estoque de Terceiros em N/Poder","account_template_68","other","ativo","True" +"account_template_70","1.1.03.04.0002","Entrada P/Industrialização","account_template_68","other","ativo","True" +"account_template_71","1.1.03.04.0003","Entrada P/Conserto","account_template_68","other","ativo","True" +"account_template_72","1.1.03.04.0004","Entrada P/Demonstração","account_template_68","other","ativo","True" +"account_template_73","1.1.03.04.0005","Entrada P/Empréstimo","account_template_68","other","ativo","True" +"account_template_74","1.1.03.04.0006","Entrada em Consignação","account_template_68","other","ativo","True" +"account_template_75","1.1.03.04.0007","Entrada p/ Garantia","account_template_68","other","ativo","True" +"account_template_76","1.1.03.04.0008","Entrada p/ Locação","account_template_68","other","ativo","True" +"account_template_77","1.1.03.04.0009","Entrada em Comodato","account_template_68","other","ativo","True" "account_template_78","1.1.03.05","NOSSO ESTOQUE EM PODER DE TERCEIROS","account_template_57","view","ativo","True" -"account_template_79","1.1.03.05.0001","N/Estoque em Poder de Terceiros","account_template_78","receivable","ativo","True" -"account_template_80","1.1.03.05.0002","Remessa P/Industrialização","account_template_78","receivable","ativo","True" -"account_template_81","1.1.03.05.0003","Remessa P/Conserto","account_template_78","receivable","ativo","True" -"account_template_82","1.1.03.05.0004","Remessa P/Demonstração","account_template_78","receivable","ativo","True" -"account_template_83","1.1.03.05.0005","Remessa P/Exposição","account_template_78","receivable","ativo","True" -"account_template_84","1.1.03.05.0006","Remessa P/Empréstimo","account_template_78","receivable","ativo","True" -"account_template_85","1.1.03.05.0007","Remessa em Consignação","account_template_78","receivable","ativo","True" -"account_template_86","1.1.03.05.0008","Remessa P/Locação","account_template_78","receivable","ativo","True" -"account_template_87","1.1.03.05.0009","Remessa em Garantia","account_template_78","receivable","ativo","True" +"account_template_79","1.1.03.05.0001","N/Estoque em Poder de Terceiros","account_template_78","other","ativo","True" +"account_template_80","1.1.03.05.0002","Remessa P/Industrialização","account_template_78","other","ativo","True" +"account_template_81","1.1.03.05.0003","Remessa P/Conserto","account_template_78","other","ativo","True" +"account_template_82","1.1.03.05.0004","Remessa P/Demonstração","account_template_78","other","ativo","True" +"account_template_83","1.1.03.05.0005","Remessa P/Exposição","account_template_78","other","ativo","True" +"account_template_84","1.1.03.05.0006","Remessa P/Empréstimo","account_template_78","other","ativo","True" +"account_template_85","1.1.03.05.0007","Remessa em Consignação","account_template_78","other","ativo","True" +"account_template_86","1.1.03.05.0008","Remessa P/Locação","account_template_78","other","ativo","True" +"account_template_87","1.1.03.05.0009","Remessa em Garantia","account_template_78","other","ativo","True" "account_template_88","1.1.03.06","(-) IMPOSTOS S/ESTOQUE DE TERCEIROS","account_template_57","view","ativo","True" -"account_template_89","1.1.03.06.0001","(-) ICMS s/Estoque de Terceiros","account_template_88","receivable","ativo","True" -"account_template_90","1.1.03.06.0002","(-) IPI s/Estoque de Terceiros","account_template_88","receivable","ativo","True" +"account_template_89","1.1.03.06.0001","(-) ICMS s/Estoque de Terceiros","account_template_88","other","ativo","True" +"account_template_90","1.1.03.06.0002","(-) IPI s/Estoque de Terceiros","account_template_88","other","ativo","True" "account_template_91","1.1.03.07","IMPORTAÇÕES EM ANDAMENTO","account_template_57","view","ativo","True" -"account_template_92","1.1.03.07.0001","D.I. nº 0000000-0 Importação","account_template_91","receivable","ativo","True" +"account_template_92","1.1.03.07.0001","D.I. nº 0000000-0 Importação","account_template_91","other","ativo","True" "account_template_93","1.1.03.08","COMPRAS PARA ENTREGA FUTURA","account_template_57","view","ativo","True" -"account_template_94","1.1.03.08.0001","Compras p/Entrega Futura","account_template_93","receivable","ativo","True" +"account_template_94","1.1.03.08.0001","Compras p/Entrega Futura","account_template_93","other","ativo","True" "account_template_95","1.1.04","DESPESAS DO EXERCÍCIO SEGUINTE","account_template_3","view","ativo","True" "account_template_96","1.1.04.01","SEGUROS A APROPRIAR","account_template_95","view","ativo","True" -"account_template_97","1.1.04.01.0001","Seguros de Veículos","account_template_96","receivable","ativo","True" -"account_template_98","1.1.04.01.0002","Seguros Prédios/Bens/Estoques","account_template_96","receivable","ativo","True" -"account_template_99","1.1.04.01.0003","Seguros s/Lucros Cessantes","account_template_96","receivable","ativo","True" +"account_template_97","1.1.04.01.0001","Seguros de Veículos","account_template_96","other","ativo","True" +"account_template_98","1.1.04.01.0002","Seguros Prédios/Bens/Estoques","account_template_96","other","ativo","True" +"account_template_99","1.1.04.01.0003","Seguros s/Lucros Cessantes","account_template_96","other","ativo","True" "account_template_100","1.1.04.02","ASSINATURAS A APROPRIAR","account_template_95","view","ativo","True" -"account_template_101","1.1.04.02.0001","Assinaturas de Jornais/Boletins/Revistas","account_template_100","receivable","ativo","True" +"account_template_101","1.1.04.02.0001","Assinaturas de Jornais/Boletins/Revistas","account_template_100","other","ativo","True" "account_template_102","1.1.04.03","DESPESAS FINANCEIRAS A APROPRIAR","account_template_95","view","ativo","True" -"account_template_103","1.1.04.03.0001","Juros s/ Financiamentos a Apropriar","account_template_102","receivable","ativo","True" +"account_template_103","1.1.04.03.0001","Juros s/ Financiamentos a Apropriar","account_template_102","other","ativo","True" "account_template_104","1.1.05","CONTAS RETIFICADORAS","account_template_3","view","ativo","True" "account_template_105","1.1.05.01","(-) DUPLICATAS DESCONTADAS","account_template_104","view","ativo","True" -"account_template_106","1.1.05.01.0001","(-) Banco Conta - Duplicata Descontada","account_template_105","receivable","ativo","True" +"account_template_106","1.1.05.01.0001","(-) Banco Conta - Duplicata Descontada","account_template_105","other","ativo","True" "account_template_107","1.2","ATIVO NÃO CIRCULANTE","account_template_2","view","ativo","True" "account_template_108","1.2.01","REALIZÁVEL A LONGO PRAZO","account_template_107","view","ativo","True" "account_template_109","1.2.01.01","VALORES MOBILIÁRIOS-MERC.CAP.INTERNO","account_template_108","view","ativo","True" -"account_template_110","1.2.01.01.0001","Aplicações Nacionais","account_template_109","receivable","ativo","True" +"account_template_110","1.2.01.01.0001","Aplicações Nacionais","account_template_109","other","ativo","True" "account_template_111","1.2.01.02","DÉBITOS DE SÓCIOS","account_template_108","view","ativo","True" -"account_template_112","1.2.01.02.0001","Sócio","account_template_111","receivable","ativo","True" +"account_template_112","1.2.01.02.0001","Sócio","account_template_111","other","ativo","True" "account_template_113","1.2.01.03","EMPRÉSTIMOS A EMPRESAS LIGADAS","account_template_108","view","ativo","True" -"account_template_114","1.2.01.03.0001","Empresa Ligada","account_template_113","receivable","ativo","True" +"account_template_114","1.2.01.03.0001","Empresa Ligada","account_template_113","other","ativo","True" "account_template_115","1.2.01.04","EMPRÉSTIMOS A TERCEIROS","account_template_108","view","ativo","True" -"account_template_116","1.2.01.04.0001","Empréstimo de Terceiros","account_template_115","receivable","ativo","True" +"account_template_116","1.2.01.04.0001","Empréstimo de Terceiros","account_template_115","other","ativo","True" "account_template_117","1.2.01.05","DEPÓSITOS JUDICIAIS","account_template_108","view","ativo","True" -"account_template_118","1.2.01.05.0001","Depósitos Judiciais","account_template_117","receivable","ativo","True" +"account_template_118","1.2.01.05.0001","Depósitos Judiciais","account_template_117","other","ativo","True" "account_template_119","1.2.02","INVESTIMENTOS","account_template_107","view","ativo","True" "account_template_120","1.2.02.01","PARTICIPAÇÕES SOCIETÁRIAS","account_template_119","view","ativo","True" -"account_template_121","1.2.02.01.0001","Participação Societárias","account_template_120","receivable","ativo","True" +"account_template_121","1.2.02.01.0001","Participação Societárias","account_template_120","other","ativo","True" "account_template_122","1.2.03","IMOBILIZADO - MATRIZ","account_template_107","view","ativo","True" "account_template_123","1.2.03.01","IMOBILIZADO","account_template_122","view","ativo","True" -"account_template_124","1.2.03.01.0001","Máquinas e Equipamentos ","account_template_123","receivable","ativo","True" -"account_template_125","1.2.03.01.0002","Terrenos","account_template_123","receivable","ativo","True" -"account_template_126","1.2.03.01.0003","Ferramentas","account_template_123","receivable","ativo","True" -"account_template_127","1.2.03.01.0004","Modelos, Moldes e Matrizes","account_template_123","receivable","ativo","True" -"account_template_128","1.2.03.01.0005","Móveis e Utensílios","account_template_123","receivable","ativo","True" -"account_template_129","1.2.03.01.0006","Veículos","account_template_123","receivable","ativo","True" -"account_template_130","1.2.03.01.0007","Equipamentos de Informática","account_template_123","receivable","ativo","True" -"account_template_131","1.2.03.01.0008","Instalações","account_template_123","receivable","ativo","True" -"account_template_132","1.2.03.01.0009","Benfeitoria em Imóveis de Terceiros","account_template_123","receivable","ativo","True" -"account_template_133","1.2.03.01.0010","Direito de Uso Linhas Telefônicas","account_template_123","receivable","ativo","True" -"account_template_134","1.2.03.01.0011","Edifícios e Construções","account_template_123","receivable","ativo","True" +"account_template_124","1.2.03.01.0001","Máquinas e Equipamentos ","account_template_123","other","ativo","True" +"account_template_125","1.2.03.01.0002","Terrenos","account_template_123","other","ativo","True" +"account_template_126","1.2.03.01.0003","Ferramentas","account_template_123","other","ativo","True" +"account_template_127","1.2.03.01.0004","Modelos, Moldes e Matrizes","account_template_123","other","ativo","True" +"account_template_128","1.2.03.01.0005","Móveis e Utensílios","account_template_123","other","ativo","True" +"account_template_129","1.2.03.01.0006","Veículos","account_template_123","other","ativo","True" +"account_template_130","1.2.03.01.0007","Equipamentos de Informática","account_template_123","other","ativo","True" +"account_template_131","1.2.03.01.0008","Instalações","account_template_123","other","ativo","True" +"account_template_132","1.2.03.01.0009","Benfeitoria em Imóveis de Terceiros","account_template_123","other","ativo","True" +"account_template_133","1.2.03.01.0010","Direito de Uso Linhas Telefônicas","account_template_123","other","ativo","True" +"account_template_134","1.2.03.01.0011","Edifícios e Construções","account_template_123","other","ativo","True" "account_template_135","1.2.03.02","CONSTRUÇÕES EM ANDAMENTO","account_template_122","view","ativo","True" -"account_template_136","1.2.03.02.0001","Imóvel","account_template_135","receivable","ativo","True" +"account_template_136","1.2.03.02.0001","Imóvel","account_template_135","other","ativo","True" "account_template_137","1.2.03.04","PARTICIPAÇÃO EM CONSÓRCIOS","account_template_122","view","ativo","True" -"account_template_138","1.2.03.04.0001","Consórcio","account_template_137","receivable","ativo","True" +"account_template_138","1.2.03.04.0001","Consórcio","account_template_137","other","ativo","True" "account_template_139","1.2.03.05","(-) DEPRECIAÇÃO ACUMULADA","account_template_122","view","ativo","True" -"account_template_140","1.2.03.05.0001","Deprec.de Máquinas e Equipamentos","account_template_139","receivable","ativo","True" -"account_template_141","1.2.03.05.0002","Deprec.de Modelos, Moldes e Matrizes","account_template_139","receivable","ativo","True" -"account_template_142","1.2.03.05.0003","Deprec.de Móveis e Utensílios","account_template_139","receivable","ativo","True" -"account_template_143","1.2.03.05.0004","Deprec.de Veículos","account_template_139","receivable","ativo","True" -"account_template_144","1.2.03.05.0005","Deprec.de Equip.de Informática","account_template_139","receivable","ativo","True" -"account_template_145","1.2.03.05.0006","Deprec.de Instalações","account_template_139","receivable","ativo","True" -"account_template_146","1.2.03.05.0007","Deprec.de Ferramentas","account_template_139","receivable","ativo","True" -"account_template_147","1.2.03.05.0008","Deprec.de Edificações","account_template_139","receivable","ativo","True" +"account_template_140","1.2.03.05.0001","Deprec.de Máquinas e Equipamentos","account_template_139","other","ativo","True" +"account_template_141","1.2.03.05.0002","Deprec.de Modelos, Moldes e Matrizes","account_template_139","other","ativo","True" +"account_template_142","1.2.03.05.0003","Deprec.de Móveis e Utensílios","account_template_139","other","ativo","True" +"account_template_143","1.2.03.05.0004","Deprec.de Veículos","account_template_139","other","ativo","True" +"account_template_144","1.2.03.05.0005","Deprec.de Equip.de Informática","account_template_139","other","ativo","True" +"account_template_145","1.2.03.05.0006","Deprec.de Instalações","account_template_139","other","ativo","True" +"account_template_146","1.2.03.05.0007","Deprec.de Ferramentas","account_template_139","other","ativo","True" +"account_template_147","1.2.03.05.0008","Deprec.de Edificações","account_template_139","other","ativo","True" "account_template_148","1.2.03.06","(-) AMORTIZAÇÃO ACUMULADA","account_template_122","view","ativo","True" -"account_template_149","1.2.03.06.0001","Amortiz.Benfeit.em Imóveis de Terceiros","account_template_148","receivable","ativo","True" -"account_template_150","1.2.03.06.0002","Amortiz.Direito Uso Linhas Telefônica","account_template_148","receivable","ativo","True" +"account_template_149","1.2.03.06.0001","Amortiz.Benfeit.em Imóveis de Terceiros","account_template_148","other","ativo","True" +"account_template_150","1.2.03.06.0002","Amortiz.Direito Uso Linhas Telefônica","account_template_148","other","ativo","True" "account_template_151","1.2.03.07","ICMS S/IMOBILIZADO-PARCELA NÃO CREDITADA","account_template_122","view","ativo","True" -"account_template_152","1.2.03.07.0001","ICMS s/ Imobilizado parc. não creditável","account_template_151","receivable","ativo","True" -"account_template_153","1.2.03.07.0002","(-) Amortização ICMS não creditado","account_template_151","receivable","ativo","True" +"account_template_152","1.2.03.07.0001","ICMS s/ Imobilizado parc. não creditável","account_template_151","other","ativo","True" +"account_template_153","1.2.03.07.0002","(-) Amortização ICMS não creditado","account_template_151","other","ativo","True" "account_template_154","1.2.04","IMOBILIZADO - FILIAL","account_template_107","view","ativo","True" "account_template_155","1.2.04.01","IMOBILIZADO","account_template_154","view","ativo","True" -"account_template_156","1.2.04.01.0001","Máquinas e Equipamentos","account_template_155","receivable","ativo","True" -"account_template_157","1.2.04.01.0002","Terrenos","account_template_155","receivable","ativo","True" -"account_template_158","1.2.04.01.0003","Ferramentas","account_template_155","receivable","ativo","True" -"account_template_159","1.2.04.01.0004","Edifícios","account_template_155","receivable","ativo","True" -"account_template_160","1.2.04.01.0005","Móveis e Utensílios","account_template_155","receivable","ativo","True" -"account_template_161","1.2.04.01.0006","Veículos","account_template_155","receivable","ativo","True" -"account_template_162","1.2.04.01.0007","Equipamentos de Informática","account_template_155","receivable","ativo","True" -"account_template_163","1.2.04.01.0008","Instalações","account_template_155","receivable","ativo","True" +"account_template_156","1.2.04.01.0001","Máquinas e Equipamentos","account_template_155","other","ativo","True" +"account_template_157","1.2.04.01.0002","Terrenos","account_template_155","other","ativo","True" +"account_template_158","1.2.04.01.0003","Ferramentas","account_template_155","other","ativo","True" +"account_template_159","1.2.04.01.0004","Edifícios","account_template_155","other","ativo","True" +"account_template_160","1.2.04.01.0005","Móveis e Utensílios","account_template_155","other","ativo","True" +"account_template_161","1.2.04.01.0006","Veículos","account_template_155","other","ativo","True" +"account_template_162","1.2.04.01.0007","Equipamentos de Informática","account_template_155","other","ativo","True" +"account_template_163","1.2.04.01.0008","Instalações","account_template_155","other","ativo","True" "account_template_164","1.2.04.02","(-) DEPRECIAÇÃO ACUMULADA - FILIAL","account_template_154","view","ativo","True" -"account_template_165","1.2.04.02.0001","Deprec.de Máquinas e Equipamentos","account_template_164","receivable","ativo","True" -"account_template_166","1.2.04.02.0003","Deprec.de Móveis e Utensílios","account_template_164","receivable","ativo","True" -"account_template_167","1.2.04.02.0004","Deprec.de Veículos","account_template_164","receivable","ativo","True" -"account_template_168","1.2.04.02.0005","Deprec.de Equip.de Informática","account_template_164","receivable","ativo","True" -"account_template_169","1.2.04.02.0006","Deprec.de Instalações","account_template_164","receivable","ativo","True" -"account_template_170","1.2.04.02.0007","Deprec.de Ferramentas","account_template_164","receivable","ativo","True" -"account_template_171","1.2.04.02.0008","Deprec.de Edifícios","account_template_164","receivable","ativo","True" +"account_template_165","1.2.04.02.0001","Deprec.de Máquinas e Equipamentos","account_template_164","other","ativo","True" +"account_template_166","1.2.04.02.0003","Deprec.de Móveis e Utensílios","account_template_164","other","ativo","True" +"account_template_167","1.2.04.02.0004","Deprec.de Veículos","account_template_164","other","ativo","True" +"account_template_168","1.2.04.02.0005","Deprec.de Equip.de Informática","account_template_164","other","ativo","True" +"account_template_169","1.2.04.02.0006","Deprec.de Instalações","account_template_164","other","ativo","True" +"account_template_170","1.2.04.02.0007","Deprec.de Ferramentas","account_template_164","other","ativo","True" +"account_template_171","1.2.04.02.0008","Deprec.de Edifícios","account_template_164","other","ativo","True" "account_template_172","1.2.04.03","(-) AMORTIZAÇÃO ACUMULADA - FILIAL","account_template_154","view","ativo","True" -"account_template_173","1.2.04.03.0001","Amortização Acumulada","account_template_172","receivable","ativo","True" +"account_template_173","1.2.04.03.0001","Amortização Acumulada","account_template_172","other","ativo","True" "account_template_174","1.2.05","BENS INTAGÍVEIS - MATRIZ","account_template_107","view","ativo","True" "account_template_175","1.2.05.01","INTANGÍVEL","account_template_174","view","ativo","True" -"account_template_176","1.2.05.01.0001","Marcas e Patentes","account_template_175","receivable","ativo","True" -"account_template_177","1.2.05.01.0002","Softwares","account_template_175","receivable","ativo","True" +"account_template_176","1.2.05.01.0001","Marcas e Patentes","account_template_175","other","ativo","True" +"account_template_177","1.2.05.01.0002","Softwares","account_template_175","other","ativo","True" "account_template_178","1.2.05.02","(-) AMORTIZAÇÃO DO INTANGÍVEL","account_template_174","view","ativo","True" -"account_template_179","1.2.05.02.0001","Amortiz.de Marcas e Patentes","account_template_178","receivable","ativo","True" -"account_template_180","1.2.05.02.0002","Amortização de Softwares","account_template_178","receivable","ativo","True" +"account_template_179","1.2.05.02.0001","Amortiz.de Marcas e Patentes","account_template_178","other","ativo","True" +"account_template_180","1.2.05.02.0002","Amortização de Softwares","account_template_178","other","ativo","True" "account_template_181","1.2.06","BENS INTANGÍVEIS - FILIAL","account_template_107","view","ativo","True" "account_template_182","1.2.06.01","INTANGÍVEL","account_template_181","view","ativo","True" -"account_template_183","1.2.06.01.0001","Softwares","account_template_182","receivable","ativo","True" +"account_template_183","1.2.06.01.0001","Softwares","account_template_182","other","ativo","True" "account_template_184","1.2.06.02","(-) AMORTIZAÇÃO DO INTANGÍVEL","account_template_181","view","ativo","True" -"account_template_185","1.2.06.02.0001","Amortização de Softwares","account_template_184","receivable","ativo","True" +"account_template_185","1.2.06.02.0001","Amortização de Softwares","account_template_184","other","ativo","True" "account_template_186","1.2.07","TRANSFERÊNCIAS DE ATIVO IMOBILIZADO","account_template_107","view","ativo","True" "account_template_187","1.2.07.01","TRANSFERÊNCIA DE ATIVO IMOBILIZADO","account_template_186","view","ativo","True" -"account_template_188","1.2.07.01.0001","Transferência de Ativo Imobilizado","account_template_187","receivable","ativo","True" +"account_template_188","1.2.07.01.0001","Transferência de Ativo Imobilizado","account_template_187","other","ativo","True" "account_template_189","1.2.08","DIFERIDO","account_template_107","view","ativo","True" "account_template_190","1.2.08.01","DESPESAS PRÉ-INDUSTRIAIS","account_template_189","view","ativo","True" -"account_template_191","1.2.08.01.0001","Gastos Gerais de Implantação","account_template_190","receivable","ativo","True" -"account_template_192","1.2.08.01.0002","(-) Amortização Acumulada","account_template_190","receivable","ativo","True" +"account_template_191","1.2.08.01.0001","Gastos Gerais de Implantação","account_template_190","other","ativo","True" +"account_template_192","1.2.08.01.0002","(-) Amortização Acumulada","account_template_190","other","ativo","True" "account_template_193","2","PASSIVO","account_template_1","view","passivo","True" "account_template_194","2.1","CIRCULANTE","account_template_193","view","passivo","True" "account_template_195","2.1.01","OBRIGAÇÕES A CURTO PRAZO","account_template_194","view","passivo","True" "account_template_196","2.1.01.01","FINANCIAMENTOS A CURTO PRAZO - SFN","account_template_195","view","passivo","True" -"account_template_197","2.1.01.01.0001","Banco Conta Empréstimo","account_template_196","payable","passivo","True" +"account_template_197","2.1.01.01.0001","Banco Conta Empréstimo","account_template_196","other","passivo","True" "account_template_198","2.1.01.02","CHEQUES A COMPENSAR","account_template_195","view","passivo","True" -"account_template_199","2.1.01.02.0001","Banco Conta a Compensar","account_template_198","payable","passivo","True" +"account_template_199","2.1.01.02.0001","Banco Conta a Compensar","account_template_198","other","passivo","True" "account_template_200","2.1.01.03","LIMITE DE CRÉDITO CHEQUE ESPECIAL","account_template_195","view","passivo","True" -"account_template_201","2.1.01.03.0001","Banco Conta Limite","account_template_200","payable","passivo","True" +"account_template_201","2.1.01.03.0001","Banco Conta Limite","account_template_200","other","passivo","True" "account_template_202","2.1.02","FORNECEDORES ","account_template_194","view","passivo","True" "account_template_203","2.1.02.01","FORNECEDORES NACIONAIS","account_template_202","view","passivo","True" "account_template_204","2.1.02.01.0001","Fornecedores Nacionais","account_template_203","payable","passivo","True" @@ -207,118 +207,118 @@ "account_template_206","2.1.02.02.0001","Fornecedores Internacionais","account_template_205","payable","passivo","True" "account_template_207","2.1.03","OBRIGAÇÕES TRABALHISTAS","account_template_194","view","passivo","True" "account_template_208","2.1.03.01","FOLHA DE PAGAMENTO - EMPREGADOS","account_template_207","view","passivo","True" -"account_template_209","2.1.03.01.0001","Salários a Pagar","account_template_208","payable","passivo","True" -"account_template_210","2.1.03.01.0002","Férias a Pagar","account_template_208","payable","passivo","True" -"account_template_211","2.1.03.01.0003","Rescisões a Pagar","account_template_208","payable","passivo","True" -"account_template_212","2.1.03.01.0004","13º Salário a Pagar","account_template_208","payable","passivo","True" -"account_template_213","2.1.03.01.0005","Comissões a Pagar","account_template_208","payable","passivo","True" +"account_template_209","2.1.03.01.0001","Salários a Pagar","account_template_208","other","passivo","True" +"account_template_210","2.1.03.01.0002","Férias a Pagar","account_template_208","other","passivo","True" +"account_template_211","2.1.03.01.0003","Rescisões a Pagar","account_template_208","other","passivo","True" +"account_template_212","2.1.03.01.0004","13º Salário a Pagar","account_template_208","other","passivo","True" +"account_template_213","2.1.03.01.0005","Comissões a Pagar","account_template_208","other","passivo","True" "account_template_214","2.1.03.02","PROVISÕES DE FÉRIAS E 13º SALÁRIO","account_template_207","view","passivo","True" -"account_template_215","2.1.03.02.0001","Provisão de Férias","account_template_214","payable","passivo","True" -"account_template_216","2.1.03.02.0002","Provisão de INSS s/Férias","account_template_214","payable","passivo","True" -"account_template_217","2.1.03.02.0003","Provisão de FGTS s/Férias","account_template_214","payable","passivo","True" -"account_template_218","2.1.03.02.0004","Provisão de 13º Salário","account_template_214","payable","passivo","True" -"account_template_219","2.1.03.02.0005","Provisão de INSS s/13º Salário","account_template_214","payable","passivo","True" -"account_template_220","2.1.03.02.0006","Provisão FGTS s/13º Salário","account_template_214","payable","passivo","True" +"account_template_215","2.1.03.02.0001","Provisão de Férias","account_template_214","other","passivo","True" +"account_template_216","2.1.03.02.0002","Provisão de INSS s/Férias","account_template_214","other","passivo","True" +"account_template_217","2.1.03.02.0003","Provisão de FGTS s/Férias","account_template_214","other","passivo","True" +"account_template_218","2.1.03.02.0004","Provisão de 13º Salário","account_template_214","other","passivo","True" +"account_template_219","2.1.03.02.0005","Provisão de INSS s/13º Salário","account_template_214","other","passivo","True" +"account_template_220","2.1.03.02.0006","Provisão FGTS s/13º Salário","account_template_214","other","passivo","True" "account_template_221","2.1.03.03","FOLHA DE PAGAMENTO - AUTÔNOMOS","account_template_207","view","passivo","True" -"account_template_222","2.1.03.03.0001","Rendimentos a Pagar","account_template_221","payable","passivo","True" +"account_template_222","2.1.03.03.0001","Rendimentos a Pagar","account_template_221","other","passivo","True" "account_template_223","2.1.03.04","FOLHA DE PAGAMENTO - DIRIGENTES","account_template_207","view","passivo","True" -"account_template_224","2.1.03.04.0001","Pro-Labore a Pagar","account_template_223","payable","passivo","True" +"account_template_224","2.1.03.04.0001","Pro-Labore a Pagar","account_template_223","other","passivo","True" "account_template_225","2.1.03.05","ENCARGOS SOCIAIS A PAGAR","account_template_207","view","passivo","True" -"account_template_226","2.1.03.05.0001","INSS a Recolher","account_template_225","payable","passivo","True" -"account_template_227","2.1.03.05.0002","FGTS a Recolher","account_template_225","payable","passivo","True" -"account_template_228","2.1.03.05.0003","Contribuição Sindical a Pagar","account_template_225","payable","passivo","True" -"account_template_229","2.1.03.05.0004","Previdência Privada a Recolher","account_template_225","payable","passivo","True" +"account_template_226","2.1.03.05.0001","INSS a Recolher","account_template_225","other","passivo","True" +"account_template_227","2.1.03.05.0002","FGTS a Recolher","account_template_225","other","passivo","True" +"account_template_228","2.1.03.05.0003","Contribuição Sindical a Pagar","account_template_225","other","passivo","True" +"account_template_229","2.1.03.05.0004","Previdência Privada a Recolher","account_template_225","other","passivo","True" "account_template_230","2.1.04","OBRIGAÇÕES TRIBUTÁRIAS","account_template_194","view","passivo","True" "account_template_231","2.1.04.01","IMPOSTOS RETIDOS A RECOLHER","account_template_230","view","passivo","True" -"account_template_232","2.1.04.01.0001","IRRF a Recolher - Pessoa Física","account_template_231","payable","passivo","True" -"account_template_233","2.1.04.01.0002","IRRF a Recolher - Pessoa Jurídica","account_template_231","payable","passivo","True" -"account_template_234","2.1.04.01.0003","ISS Retido a Recolher","account_template_231","payable","passivo","True" -"account_template_235","2.1.04.01.0004","PIS/COFINS/CSLL Retido a Recolher","account_template_231","payable","passivo","True" -"account_template_236","2.1.04.01.0005","INSS Retido a Recolher","account_template_231","payable","passivo","True" +"account_template_232","2.1.04.01.0001","IRRF a Recolher - Pessoa Física","account_template_231","other","passivo","True" +"account_template_233","2.1.04.01.0002","IRRF a Recolher - Pessoa Jurídica","account_template_231","other","passivo","True" +"account_template_234","2.1.04.01.0003","ISS Retido a Recolher","account_template_231","other","passivo","True" +"account_template_235","2.1.04.01.0004","PIS/COFINS/CSLL Retido a Recolher","account_template_231","other","passivo","True" +"account_template_236","2.1.04.01.0005","INSS Retido a Recolher","account_template_231","other","passivo","True" "account_template_237","2.1.04.02","IMPOSTOS E CONTRIBUIÇÃO S/ O LUCRO","account_template_230","view","passivo","True" -"account_template_238","2.1.04.02.0001","Provisão para o Imposto de Renda","account_template_237","payable","passivo","True" -"account_template_239","2.1.04.02.0002","Provisão Contrib.Social s/Lucro Líquido","account_template_237","payable","passivo","True" +"account_template_238","2.1.04.02.0001","Provisão para o Imposto de Renda","account_template_237","other","passivo","True" +"account_template_239","2.1.04.02.0002","Provisão Contrib.Social s/Lucro Líquido","account_template_237","other","passivo","True" "account_template_240","2.1.04.03","IMPOSTOS E CONTRIBUIÇÃO S/ RECEITAS","account_template_230","view","passivo","True" -"account_template_241","2.1.04.03.0001","ICMS a Recolher","account_template_240","payable","passivo","True" -"account_template_242","2.1.04.03.0002","COFINS a Recolher","account_template_240","payable","passivo","True" -"account_template_243","2.1.04.03.0003","PIS a Recolher","account_template_240","payable","passivo","True" -"account_template_244","2.1.04.03.0004","IPI a Recolher","account_template_240","payable","passivo","True" -"account_template_245","2.1.04.03.0005","ISS a Recolher","account_template_240","payable","passivo","True" +"account_template_241","2.1.04.03.0001","ICMS a Recolher","account_template_240","other","passivo","True" +"account_template_242","2.1.04.03.0002","COFINS a Recolher","account_template_240","other","passivo","True" +"account_template_243","2.1.04.03.0003","PIS a Recolher","account_template_240","other","passivo","True" +"account_template_244","2.1.04.03.0004","IPI a Recolher","account_template_240","other","passivo","True" +"account_template_245","2.1.04.03.0005","ISS a Recolher","account_template_240","other","passivo","True" "account_template_246","2.1.05","PARCELAMENTOS CURTO PRAZO","account_template_194","view","passivo","True" "account_template_247","2.1.05.01","PARCELAMENTOS TRIBUTÁRIOS","account_template_246","view","passivo","True" -"account_template_248","2.1.05.01.0001","COFINS Parcelamento","account_template_247","payable","passivo","True" -"account_template_249","2.1.05.01.0002","PIS Parcelamento","account_template_247","payable","passivo","True" -"account_template_250","2.1.05.01.0003","IPI Parcelamento","account_template_247","payable","passivo","True" -"account_template_251","2.1.05.01.0004","ICMS Parcelamento","account_template_247","payable","passivo","True" -"account_template_252","2.1.05.01.0005","IRPJ Parcelamento","account_template_247","payable","passivo","True" -"account_template_253","2.1.05.01.0006","CSLL Parcelamento","account_template_247","payable","passivo","True" -"account_template_254","2.1.05.01.0007","INSS Parcelamento","account_template_247","payable","passivo","True" -"account_template_255","2.1.05.01.0008","FGTS Parcelamento","account_template_247","payable","passivo","True" +"account_template_248","2.1.05.01.0001","COFINS Parcelamento","account_template_247","other","passivo","True" +"account_template_249","2.1.05.01.0002","PIS Parcelamento","account_template_247","other","passivo","True" +"account_template_250","2.1.05.01.0003","IPI Parcelamento","account_template_247","other","passivo","True" +"account_template_251","2.1.05.01.0004","ICMS Parcelamento","account_template_247","other","passivo","True" +"account_template_252","2.1.05.01.0005","IRPJ Parcelamento","account_template_247","other","passivo","True" +"account_template_253","2.1.05.01.0006","CSLL Parcelamento","account_template_247","other","passivo","True" +"account_template_254","2.1.05.01.0007","INSS Parcelamento","account_template_247","other","passivo","True" +"account_template_255","2.1.05.01.0008","FGTS Parcelamento","account_template_247","other","passivo","True" "account_template_256","2.1.06","OUTRAS OBRIGAÇÕES","account_template_194","view","passivo","True" "account_template_257","2.1.06.01","CONTAS DE CONSUMO","account_template_256","view","passivo","True" -"account_template_258","2.1.06.01.0001","Consumo de Água/Esgoto","account_template_257","payable","passivo","True" -"account_template_259","2.1.06.01.0003","Consumo de Energia Elétrica","account_template_257","payable","passivo","True" -"account_template_260","2.1.06.01.0004","Consumo de Telefone","account_template_257","payable","passivo","True" -"account_template_261","2.1.06.01.0005","Consumo de Internet","account_template_257","payable","passivo","True" +"account_template_258","2.1.06.01.0001","Consumo de Água/Esgoto","account_template_257","other","passivo","True" +"account_template_259","2.1.06.01.0003","Consumo de Energia Elétrica","account_template_257","other","passivo","True" +"account_template_260","2.1.06.01.0004","Consumo de Telefone","account_template_257","other","passivo","True" +"account_template_261","2.1.06.01.0005","Consumo de Internet","account_template_257","other","passivo","True" "account_template_262","2.1.06.02","OUTRAS CONTAS A PAGAR","account_template_256","view","passivo","True" -"account_template_263","2.1.06.02.0001","Cheques a Compensar","account_template_262","payable","passivo","True" -"account_template_264","2.1.06.02.0002","Seguros a Pagar","account_template_262","payable","passivo","True" -"account_template_265","2.1.06.02.0003","Assinaturas de Periódicos a Pagar","account_template_262","payable","passivo","True" -"account_template_266","2.1.06.02.0004","Aluguel a Pagar","account_template_262","payable","passivo","True" -"account_template_267","2.1.06.02.0005","Doações a Pagar","account_template_262","payable","passivo","True" -"account_template_268","2.1.06.02.0006","Pensão Alimenticia a Pagar","account_template_262","payable","passivo","True" +"account_template_263","2.1.06.02.0001","Cheques a Compensar","account_template_262","other","passivo","True" +"account_template_264","2.1.06.02.0002","Seguros a Pagar","account_template_262","other","passivo","True" +"account_template_265","2.1.06.02.0003","Assinaturas de Periódicos a Pagar","account_template_262","other","passivo","True" +"account_template_266","2.1.06.02.0004","Aluguel a Pagar","account_template_262","other","passivo","True" +"account_template_267","2.1.06.02.0005","Doações a Pagar","account_template_262","other","passivo","True" +"account_template_268","2.1.06.02.0006","Pensão Alimenticia a Pagar","account_template_262","other","passivo","True" "account_template_269","2.1.06.03","ADIANTAMENTO DE CLIENTES","account_template_256","view","passivo","True" -"account_template_270","2.1.06.03.0001","Adiantamento Clientes","account_template_269","payable","passivo","True" +"account_template_270","2.1.06.03.0001","Adiantamento Clientes","account_template_269","other","passivo","True" "account_template_271","2.2","PASSIVO NÃO CIRCULANTE","account_template_193","view","passivo","True" "account_template_272","2.2.01","EXIGÍVEL A LONGO PRAZO","account_template_271","view","passivo","True" "account_template_273","2.2.01.01","FINANCIAMENTOS A LONGO PRAZO - SFN","account_template_272","view","passivo","True" -"account_template_274","2.2.01.01.0001","Banco Conta Empréstimo","account_template_273","payable","passivo","True" +"account_template_274","2.2.01.01.0001","Banco Conta Empréstimo","account_template_273","other","passivo","True" "account_template_275","2.2.01.02","EMPRÉSTIMO DE SÓCIOS","account_template_272","view","passivo","True" -"account_template_276","2.2.01.02.0001","Sócio","account_template_275","payable","passivo","True" +"account_template_276","2.2.01.02.0001","Sócio","account_template_275","other","passivo","True" "account_template_277","2.2.01.03","EMPRÉSTIMO DE EMPRESAS LIGADAS","account_template_272","view","passivo","True" -"account_template_278","2.2.01.03.0001","Empresas Ligadas","account_template_277","payable","passivo","True" +"account_template_278","2.2.01.03.0001","Empresas Ligadas","account_template_277","other","passivo","True" "account_template_279","2.2.01.04","EMPRÉSTIMOS A TERCEIROS","account_template_272","view","passivo","True" -"account_template_280","2.2.01.04.0001","Terceiro","account_template_279","payable","passivo","True" +"account_template_280","2.2.01.04.0001","Terceiro","account_template_279","other","passivo","True" "account_template_281","2.2.01.05","PARCELAMENTOS TRIBUTÁRIOS","account_template_272","view","passivo","True" -"account_template_282","2.2.01.05.0001","COFINS Parcelamento","account_template_281","payable","passivo","True" -"account_template_283","2.2.01.05.0002","PIS Parcelamento","account_template_281","payable","passivo","True" -"account_template_284","2.2.01.05.0003","IPI Parcelamento","account_template_281","payable","passivo","True" -"account_template_285","2.2.01.05.0004","ICMS Parcelamento","account_template_281","payable","passivo","True" -"account_template_286","2.2.01.05.0005","ISS Parcelamento","account_template_281","payable","passivo","True" -"account_template_287","2.2.01.05.0006","IRPJ Parcelamento","account_template_281","payable","passivo","True" -"account_template_288","2.2.01.05.0007","CSLL Parcelamento","account_template_281","payable","passivo","True" -"account_template_289","2.2.01.05.0008","INSS Parcelamento","account_template_281","payable","passivo","True" -"account_template_290","2.2.01.05.0009","FGTS Parcelamento","account_template_281","payable","passivo","True" +"account_template_282","2.2.01.05.0001","COFINS Parcelamento","account_template_281","other","passivo","True" +"account_template_283","2.2.01.05.0002","PIS Parcelamento","account_template_281","other","passivo","True" +"account_template_284","2.2.01.05.0003","IPI Parcelamento","account_template_281","other","passivo","True" +"account_template_285","2.2.01.05.0004","ICMS Parcelamento","account_template_281","other","passivo","True" +"account_template_286","2.2.01.05.0005","ISS Parcelamento","account_template_281","other","passivo","True" +"account_template_287","2.2.01.05.0006","IRPJ Parcelamento","account_template_281","other","passivo","True" +"account_template_288","2.2.01.05.0007","CSLL Parcelamento","account_template_281","other","passivo","True" +"account_template_289","2.2.01.05.0008","INSS Parcelamento","account_template_281","other","passivo","True" +"account_template_290","2.2.01.05.0009","FGTS Parcelamento","account_template_281","other","passivo","True" "account_template_291","2.2.03","RECEITA DIFERIDA","account_template_271","view","passivo","True" "account_template_292","2.2.03.01","RECEITAS DIFERIDAS","account_template_291","view","passivo","True" -"account_template_293","2.2.03.01.0001","Receitas a Realizar","account_template_292","payable","passivo","True" +"account_template_293","2.2.03.01.0001","Receitas a Realizar","account_template_292","other","passivo","True" "account_template_294","2.2.03.02","CUSTOS DIFERIDOS","account_template_291","view","passivo","True" -"account_template_295","2.2.03.02.0001","Custos Diferidos","account_template_294","payable","passivo","True" +"account_template_295","2.2.03.02.0001","Custos Diferidos","account_template_294","other","passivo","True" "account_template_296","2.2.03.03","DESPESAS DIFERIDAS","account_template_291","view","passivo","True" -"account_template_297","2.2.03.03.0001","Despesas Diferidas","account_template_296","payable","passivo","True" +"account_template_297","2.2.03.03.0001","Despesas Diferidas","account_template_296","other","passivo","True" "account_template_298","2.4","PATRIMÔNIO LÍQUIDO","account_template_193","view","passivo","True" "account_template_299","2.4.01","CAPITAL SOCIAL","account_template_298","view","passivo","True" "account_template_300","2.4.01.01","CAPITAL SOCIAL REALIZADO","account_template_299","view","passivo","True" -"account_template_301","2.4.01.01.0001","Capital Social Realizado","account_template_300","payable","passivo","True" +"account_template_301","2.4.01.01.0001","Capital Social Realizado","account_template_300","other","passivo","True" "account_template_302","2.4.01.02","(-) CAPITAL A REALIZAR","account_template_299","view","passivo","True" -"account_template_303","2.4.01.02.0001","Capital Social a Realizar ","account_template_302","payable","passivo","True" +"account_template_303","2.4.01.02.0001","Capital Social a Realizar ","account_template_302","other","passivo","True" "account_template_304","2.4.02","RESERVAS","account_template_298","view","passivo","True" "account_template_305","2.4.02.01","RESERVAS DE CAPITAL","account_template_304","view","passivo","True" -"account_template_306","2.4.02.01.0001","Reserva de Correção do Capital Realizado","account_template_305","payable","passivo","True" +"account_template_306","2.4.02.01.0001","Reserva de Correção do Capital Realizado","account_template_305","other","passivo","True" "account_template_307","2.4.02.02","AJUSTES DE AVALIAÇÃO PATRIMONIAL","account_template_304","view","passivo","True" -"account_template_308","2.4.02.02.0001","Ajustes de Avaliação Patrimonial","account_template_307","payable","passivo","True" +"account_template_308","2.4.02.02.0001","Ajustes de Avaliação Patrimonial","account_template_307","other","passivo","True" "account_template_309","2.4.02.03","RESERVAS DE LUCROS","account_template_304","view","passivo","True" -"account_template_310","2.4.02.03.0001","Reserva de Lucros","account_template_309","payable","passivo","True" -"account_template_311","2.4.02.03.0002","Reserva para Aumento de Capital","account_template_309","payable","passivo","True" +"account_template_310","2.4.02.03.0001","Reserva de Lucros","account_template_309","other","passivo","True" +"account_template_311","2.4.02.03.0002","Reserva para Aumento de Capital","account_template_309","other","passivo","True" "account_template_312","2.4.02.04","PREJUÍZOS ACUMULADOS","account_template_304","view","passivo","True" -"account_template_313","2.4.02.04.0002","(-) Prejuízos Acumulados","account_template_312","payable","passivo","True" -"account_template_314","2.4.02.04.0003","Ajustes Credores Exercícios Anteriores","account_template_312","payable","passivo","True" -"account_template_315","2.4.02.04.0001","Ajustes Devedores Exercícios Anteriores","account_template_312","payable","passivo","True" +"account_template_313","2.4.02.04.0002","(-) Prejuízos Acumulados","account_template_312","other","passivo","True" +"account_template_314","2.4.02.04.0003","Ajustes Credores Exercícios Anteriores","account_template_312","other","passivo","True" +"account_template_315","2.4.02.04.0001","Ajustes Devedores Exercícios Anteriores","account_template_312","other","passivo","True" "account_template_316","2.4.02.05","RESULTADO DO EXERCÍCIO","account_template_304","view","passivo","True" -"account_template_317","2.4.02.05.0001","Lucro do Exercício","account_template_316","payable","passivo","True" -"account_template_318","2.4.02.05.0002","Prejuízo do Exercício","account_template_316","payable","passivo","True" +"account_template_317","2.4.02.05.0001","Lucro do Exercício","account_template_316","other","passivo","True" +"account_template_318","2.4.02.05.0002","Prejuízo do Exercício","account_template_316","other","passivo","True" "account_template_319","2.4.02.06","(-) LUCROS DISTRIBUÍDOS","account_template_304","view","passivo","True" -"account_template_320","2.4.02.06.0001","Lucros Distribuídos","account_template_319","payable","passivo","True" +"account_template_320","2.4.02.06.0001","Lucros Distribuídos","account_template_319","other","passivo","True" "account_template_321","3","CONTAS DE RESULTADO - CUSTOS E DESPESAS","account_template_1","view","despesa","True" "account_template_322","3.1","CUSTOS","account_template_321","view","despesa","True" "account_template_323","3.1.01","CUSTOS DAS MERCADORIAS E PRODUTOS","account_template_322","view","despesa","True" @@ -337,8 +337,8 @@ "account_template_336","3.1.02.03.0005","13º Salário","account_template_331","other","despesa","True" "account_template_337","3.1.02.03.0006","Aviso Prévio/Indeniz.Trabalhistas","account_template_331","other","despesa","True" "account_template_338","3.1.02.03.0007","Gratificações","account_template_331","other","despesa","True" -"account_template_339","3.1.02.03.0008","INSS Empresa","account_template_331","payable","passivo","True" -"account_template_340","3.1.02.03.0009","FGTS ","account_template_331","payable","passivo","True" +"account_template_339","3.1.02.03.0008","INSS Empresa","account_template_331","other","despesa","True" +"account_template_340","3.1.02.03.0009","FGTS ","account_template_331","other","despesa","True" "account_template_341","3.1.02.03.0010","Adicional Insalubridade","account_template_331","other","despesa","True" "account_template_342","3.1.02.03.0011","Vale Transporte","account_template_331","other","despesa","True" "account_template_343","3.1.02.03.0012","PAT - Programa Alim. Trabalhador","account_template_331","other","despesa","True" diff --git a/addons/l10n_br/data/account.account.type.csv b/addons/l10n_br/data/account.account.type.csv index 9f3844cdd2e..1b1d8cfddac 100644 --- a/addons/l10n_br/data/account.account.type.csv +++ b/addons/l10n_br/data/account.account.type.csv @@ -1,6 +1,6 @@ "id","code","name","close_method" -"ativo","1","Ativo","unreconciled" -"passivo","2","Passivo","unreconciled" +"ativo","1","Ativo","balance" +"passivo","2","Passivo","balance" "despesa","3","Despesas","balance" "receita","4","Receita","balance" "resultado","5","Resultado","balance" diff --git a/addons/l10n_br/data/account.tax.code.template.csv b/addons/l10n_br/data/account.tax.code.template.csv index 4622200982f..5768324cc3d 100644 --- a/addons/l10n_br/data/account.tax.code.template.csv +++ b/addons/l10n_br/data/account.tax.code.template.csv @@ -1,14 +1,13 @@ -"id","code","name","parent_id:id","sign" -"tax_code_chart_root","","Códigos de Impostos Brasileiros","","1" -"tax_code_1","ICMS","ICMS Interno","tax_code_chart_root","1" -"tax_code_2","ICMS","ICMS Externo","tax_code_chart_root","1" -"tax_code_3","ICMS Subist","ICMS Subist","tax_code_chart_root","1" -"tax_code_4","IPI","IPI","tax_code_chart_root","1" -"tax_code_5","PIS","PIS","tax_code_chart_root","1" -"tax_code_6","COFINS","COFINS","tax_code_chart_root","1" -"tax_code_7","IRPJ","IRPJ","tax_code_chart_root","1" -"tax_code_8","IR","IR","tax_code_chart_root","1" -"tax_code_9","ISS","ISS","tax_code_chart_root","1" -"tax_code_10","CSLL","CSLL","tax_code_chart_root","1" +"id","code","name","parent_id:id","sign","domain","tax_discount" +"tax_code_chart_root","","Códigos de Impostos Brasileiros","","1","",0 +"tax_code_1","ICMS","ICMS","tax_code_chart_root","1","icms",1 +"tax_code_2","ICMS Subist","ICMS Subist","tax_code_chart_root","1","icmsst",0 +"tax_code_3","IPI","IPI","tax_code_chart_root","1","ipi",0 +"tax_code_4","PIS","PIS","tax_code_chart_root","1","pis",1 +"tax_code_5","COFINS","COFINS","tax_code_chart_root","1","cofins",1 +"tax_code_6","IRPJ","IRPJ","tax_code_chart_root","1","irpj",1 +"tax_code_7","IR","IR","tax_code_chart_root","1","ir",1 +"tax_code_8","ISS","ISS","tax_code_chart_root","1","iss",1 +"tax_code_9","CSLL","CSLL","tax_code_chart_root","1","csll",1 diff --git a/addons/l10n_br/data/account_tax_template.xml b/addons/l10n_br/data/account_tax_template.xml index 1aa0ab88afa..58f860e0d90 100644 --- a/addons/l10n_br/data/account_tax_template.xml +++ b/addons/l10n_br/data/account_tax_template.xml @@ -5,360 +5,92 @@ IPI IPI - vat + vat 0.00 - + + + + - - - - - + + + + + IPI 2% IPI 2% - vat + vat 0.02 - + + + + - - - - - + + + + + IPI 3% IPI 3% - vat + vat 0.03 - + + + + - - - - - + + + + + IPI 4% IPI 4% - vat + vat 0.04 - + + + + - - - - - + + + + + IPI 5% IPI 5% - vat + vat 0.05 - + + + + - - - - - + + + + + IPI 7% IPI 7% - vat + vat 0.07 - - - - - - - - - - IPI 8% - IPI 8% - vat - 0.08 - False - - - - - - - - - IPI 10% - IPI 10% - vat - 0.10 - - - - - - - - - - IPI 12% - IPI 12% - vat - 0.12 - - - - - - - - - - IPI 13% - IPI 13% - vat - 0.13 - - - - - - - - - - IPI 15% - IPI 15% - vat - 0.15 - - - - - - - - - - IPI 16% - IPI 16% - vat - 0.16 - - - - - - - - - - IPI 18% - IPI 18% - vat - 0.18 - - - - - - - - - - IPI 20% - IPI 20% - vat - 0.20 - - - - - - - - - - IPI 22% - IPI 22% - vat - 0.22 - - - - - - - - - - IPI 25% - IPI 25% - vat - 0.25 - - - - - - - - - - IPI 27% - IPI 27% - vat - 0.27 - - - - - - - - - - IPI 30% - IPI 30% - vat - 0.30 - - - - - - - - - - IPI 35% - IPI 35% - vat - 0.35 - - - - - - - - - - IPI 40% - IPI 40% - vat - 0.40 - - - - - - - - - - IPI 42% - IPI 42% - vat - 0.42 - - - - - - - - - - IPI 45% - IPI 45% - vat - 0.45 - - - - - - - - - - IPI 50% - IPI 50% - vat - 0.50 - - - - - - - - - - IPI 60% - IPI 60% - vat - 0.60 - - - - - - - - - - IPI 330% - IPI 330% - vat - 3.30 - - - - - - - - - - ICMS Interno - ICMS Interno - vat - 0.00 - - - - - - - - - - ICMS Externo - ICMS Externo - vat - 0.00 - - - - - - - - - - ICMS Subist - ICMS Subist - vat - 0.00 - + + + + @@ -366,171 +98,609 @@ + + IPI 8% + IPI 8% + vat + 0.08 + + + + + + + + + + + + + IPI 10% + IPI 10% + vat + 0.10 + + + + + + + + + + + + + IPI 12% + IPI 12% + vat + 0.12 + + + + + + + + + + + + + IPI 13% + IPI 13% + vat + 0.13 + + + + + + + + + + + + + IPI 15% + IPI 15% + vat + 0.15 + + + + + + + + + + + + + IPI 16% + IPI 16% + vat + 0.16 + + + + + + + + + + + + + IPI 18% + IPI 18% + vat + 0.18 + + + + + + + + + + + + + IPI 20% + IPI 20% + vat + 0.20 + + + + + + + + + + + + + IPI 22% + IPI 22% + vat + 0.22 + + + + + + + + + + + + + IPI 25% + IPI 25% + vat + 0.25 + + + + + + + + + + + + + IPI 27% + IPI 27% + vat + 0.27 + + + + + + + + + + + + + IPI 30% + IPI 30% + vat + 0.30 + + + + + + + + + + + + + IPI 35% + IPI 35% + vat + 0.35 + + + + + + + + + + + + + IPI 40% + IPI 40% + vat + 0.40 + + + + + + + + + + + + + IPI 42% + IPI 42% + vat + 0.42 + + + + + + + + + + + + + IPI 45% + IPI 45% + vat + 0.45 + + + + + + + + + + + + + IPI 50% + IPI 50% + vat + 0.50 + + + + + + + + + + + + + IPI 60% + IPI 60% + vat + 0.60 + + + + + + + + + + + + + IPI 330% + IPI 330% + vat + 3.30 + + + + + + + + + + + + + ICMS Interno + ICMS Interno + vat + 0.00 + + + + + + + + + + + + + ICMS Externo + ICMS Externo + vat + 0.00 + + + + + + + + + + + + + ICMS Subist + ICMS Subist + vat + 0.00 + + + + + + + + + - ICMS 7% - ICMS 7% - vat + ICMS Externo 7% + ICMS Externo 7% + vat 0.07 - + + - - - - - - + + + + + - ICMS 12% - ICMS 12% - vat + ICMS Externo 12% + ICMS Externo 12% + vat 0.12 - + + - - - - - + + + + + - ICMS 19% - ICMS 19% - vat + ICMS Interno 19% + ICMS Interno 19% + vat 0.19 - + + - + - ICMS 26% - ICMS 26% - vat + ICMS Interno 26% + ICMS Interno 26% + vat 0.26 - + + - + PIS PIS - vat + vat 0.00 - + + + + - - - - - + + + + + PIS 0,65% PIS 0,65% - vat + vat 0.0065 - + + + + + + + + + + + + + COFINS + COFINS + vat + 0.00 + + + + - - - - - COFINS - COFINS - vat - 0.00 - - - - - - - - + COFINS 3% COFINS 3% - vat + vat 0.03 - + + + + + + + + + + + + + IRPJ + IRPJ + vat + 0.00 + + - + - - IRPJ - IRPJ - vat + + IR + IR + vat 0.00 - + + - + - - IR - IR - vat + + ISS + ISS + vat 0.00 - + + - + + + + ISS 1% + ISS 1% + vat + 0.01 + + + + + + + + + + + ISS 2% + ISS 2% + vat + 0.02 + + + + + + + + + + + ISS 3% + ISS 3% + vat + 0.03 + + + + + + + + + + + ISS 4% + ISS 4% + vat + 0.04 + + + + + + + + + + + ISS 5% + ISS 5% + vat + 0.05 + + + + + + + + - - ISS - ISS - vat + + CSLL + CSLL + vat 0.00 - + + - - - - CSLL - CSLL - vat - 0.00 - - - - - - - + + - + \ No newline at end of file diff --git a/addons/l10n_br/data/l10n_br_account_chart_template.xml b/addons/l10n_br/data/l10n_br_account_chart_template.xml index 79ce5bd0310..9dbcb4d558f 100644 --- a/addons/l10n_br/data/l10n_br_account_chart_template.xml +++ b/addons/l10n_br/data/l10n_br_account_chart_template.xml @@ -1,15 +1,16 @@ + Planilha de Contas Brasileira - + - - - + + + @@ -17,8 +18,8 @@ Generate Chart of Accounts from a Chart Template. You will be asked to pass the name of the company, the chart template to follow, the no. of digits to generate the code for your accounts and Bank account, currency to create Journals. Thus,the pure copy of chart Template is generated. This is the same wizard that runs from Financial Management/Configuration/Financial Accounting/Financial Accounts/Generate Chart of Accounts from a Chart Template. - automatic - + open + onskip diff --git a/addons/l10n_br/data/l10n_br_data.xml b/addons/l10n_br/data/l10n_br_data.xml new file mode 100644 index 00000000000..5a785f0f08f --- /dev/null +++ b/addons/l10n_br/data/l10n_br_data.xml @@ -0,0 +1,673 @@ + + + + + + + 01 + Operação Tributável com Alíquota Básica + + + + + 02 + Operação Tributável com Alíquota Diferenciada + + + + + 03 + Operação Tributável com Alíquota por Unidade de Medida de Produto + + + + + 04 + Operação Tributável Monofásica - Revenda a Alíquota Zero + + + + + 05 + Operação Tributável por Substituição Tributária + + + + + 06 + Operação Tributável a Alíquota zero + + + + + 07 + Operação Isenta da Contribuição + + + + + 08 + Operação sem Incidência da Contribuição + + + + + 09 + Operação com Suspensão da Contribuição + + + + + 49 + Outras Operações de Saída + + + + + 50 + Operação com Direito a Crédito - Vinculada Exclusivamente a Receita Tributada no Mercado Interno + + + + + 51 + Operação com Direito a Crédito - Vinculada Exclusivamente a Receita Não-Tributada no Mercado Interno + + + + + 52 + Operação com Direito a Crédito - Vinculada Exclusivamente a Receita de Exportação + + + + + 53 + Operação com Direito a Crédito - Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno + + + + + 54 + Operação com Direito a Crédito - Vinculada a Receitas Tributadas no Mercado Interno e de Exportação + + + + + 55 + Operação com Direito a Crédito - Vinculada a Receitas Não Tributadas no Mercado Interno e de Exportação + + + + + 56 + Operação com Direito a Crédito - Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno e de Exportação + + + + + 60 + Crédito Presumido - Operação de Aquisição Vinculada Exclusivamente a Receita Tributada no Mercado Interno + + + + + 61 + Crédito Presumido - Operação de Aquisição Vinculada Exclusivamente a Receita Não-Tributada no Mercado Interno + + + + + 62 + Crédito Presumido - Operação de Aquisição Vinculada Exclusivamente a Receita de Exportação + + + + + 63 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno + + + + + 64 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Tributadas no Mercado Interno e de Exportação + + + + + 65 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Não-Tributadas no Mercado Interno e de Exportação + + + + + 66 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno e de Exportação + + + + + 67 + Crédito Presumido - Outras Operações + + + + + 70 + Operação de Aquisição sem Direito a Crédito + + + + + 71 + Operação de Aquisição com Isenção + + + + + 72 + Operação de Aquisição com Suspensão + + + + + 73 + Operação de Aquisição a Alíquota Zero + + + + + 74 + Operação de Aquisição sem Incidência da Contribuição + + + + + 75 + Operação de Aquisição por Substituição Tributária + + + + + 98 + Outras Operações de Entrada + + + + + 99 + Outras Operações + + + + + 01 + Operação Tributável com Alíquota Básica + + + + + 02 + Operação Tributável com Alíquota Diferenciada + + + + + 03 + Operação Tributável com Alíquota por Unidade de Medida de Produto + + + + + 04 + Operação Tributável Monofásica - Revenda a Alíquota Zero + + + + + 05 + Operação Tributável por Substituição Tributária + + + + + 06 + Operação Tributável a Alíquota Zero + + + + + 07 + Operação Isenta da Contribuição + + + + + 08 + Operação sem Incidência da Contribuição + + + + + 09 + Operação com Suspensão da Contribuição + + + + + 49 + Outras Operações de Saída + + + + + 50 + Operação com Direito a Crédito - Vinculada Exclusivamente a Receita Tributada no Mercado Interno + + + + + 51 + Operação com Direito a Crédito - Vinculada Exclusivamente a Receita Não Tributada no Mercado Interno + + + + + 52 + Operação com Direito a Crédito - Vinculada Exclusivamente a Receita de Exportação + + + + + 53 + Operação com Direito a Crédito - Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno + + + + + 54 + Operação com Direito a Crédito - Vinculada a Receitas Tributadas no Mercado Interno e de Exportação + + + + + 55 + Operação com Direito a Crédito - Vinculada a Receitas Não-Tributadas no Mercado Interno e de Exportação + + + + + 56 + Operação com Direito a Crédito - Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno, e de Exportação + + + + + 60 + Crédito Presumido - Operação de Aquisição Vinculada Exclusivamente a Receita Tributada no Mercado Interno + + + + + 61 + Crédito Presumido - Operação de Aquisição Vinculada Exclusivamente a Receita Não-Tributada no Mercado Interno + + + + + 62 + Crédito Presumido - Operação de Aquisição Vinculada Exclusivamente a Receita de Exportação + + + + + 63 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno + + + + + 64 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Tributadas no Mercado Interno e de Exportação + + + + + 65 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Não-Tributadas no Mercado Interno e de Exportação + + + + + 66 + Crédito Presumido - Operação de Aquisição Vinculada a Receitas Tributadas e Não-Tributadas no Mercado Interno, e de Exportação + + + + + 67 + Crédito Presumido - Outras Operações + + + + + 70 + Operação de Aquisição sem Direito a Crédito + + + + + 71 + Operação de Aquisição com Isenção + + + + + 72 + Operação de Aquisição com Suspensão + + + + + 73 + Operação de Aquisição a Alíquota Zero + + + + + 74 + Operação de Aquisição sem Incidência da Contribuição + + + + + 75 + Operação de Aquisição por Substituição Tributária + + + + + 98 + Outras Operações de Entrada + + + + + 99 + Outras Operações + + + + + 00 + Entrada com recuperação de crédito + + + + + 01 + Entrada tributada com alíquota zero + + + + + 02 + Entrada isenta + + + + + 03 + Entrada não-tributada + + + + + 04 + Entrada imune + + + + + 05 + Entrada com suspensão + + + + + 49 + Outras entradas + + + + + 50 + Saída tributada + + + + + 51 + Saída tributada com alíquota zero + + + + + 52 + Saída isenta + + + + + 53 + Saída não-tributada + + + + + 54 + Saída imune + + + + + 55 + Saída com suspensão + + + + + 99 + Outras saídas + + + + + 00 + Tributada integralmente + + + + + 10 + Tributada e com cobrança do ICMS por substituição tributária + + + + + 20 + Com redução de base de cálculo + + + + + 30 + Isenta ou não tributada e com cobrança do ICMS por substituição tributária + + + + + 40 + Isenta + + + + + 41 + Não tributada + + + + + 50 + Suspensão + + + + + 51 + Diferimento + + + + + 60 + ICMS cobrado anteriormente por substituição tributária + + + + + 70 + Com redução de base de cálculo e cobrança do ICMS por substituição tributária + + + + + 90 + Outras + + + + + 101 + Simples Nacional - Tributada pelo Simples Nacional com permissão de crédito + + + + + 102 + Simples Nacional - Tributada pelo Simples Nacional sem permissão de crédito + + + + + 103 + Simples Nacional - Isenção do ICMS no Simples Nacional para faixa de receita bruta + + + + + 201 + Simples Nacional - Tributada pelo Simples Nacional com permissão de crédito e com cobrança do ICMS por substituição tributária + + + + + 202 + Simples Nacional - Tributada pelo Simples Nacional sem permissão de crédito e com cobrança do ICMS por substituição tributária + + + + + 203 + Simples Nacional - Isenção do ICMS no Simples Nacional para faixa de receita bruta e com cobrança do ICMS por substituição tributária + + + + + 300 + Simples Nacional - Imune + + + + + 400 + Simples Nacional - Não tributada pelo Simples Nacional + + + + + 500 + Simples Nacional - ICMS cobrado anteriormente por substituição tributária (substituído) ou por antecipação + + + + + 900 + Simples Nacional - Outros + + + + + 101 + Simples Nacional - Tributada pelo Simples Nacional com permissão de crédito + + + + + 102 + Simples Nacional - Tributada pelo Simples Nacional sem permissão de crédito + + + + + 103 + Simples Nacional - Isenção do ICMS no Simples Nacional para faixa de receita bruta + + + + + 201 + Simples Nacional - Tributada pelo Simples Nacional com permissão de crédito e com cobrança do ICMS por substituição tributária + + + + + 202 + Simples Nacional - Tributada pelo Simples Nacional sem permissão de crédito e com cobrança do ICMS por substituição tributária + + + + + 203 + Simples Nacional - Isenção do ICMS no Simples Nacional para faixa de receita bruta e com cobrança do ICMS por substituição tributária + + + + + 300 + Simples Nacional - Imune + + + + + 400 + Simples Nacional - Não tributada pelo Simples Nacional + + + + + 500 + Simples Nacional - ICMS cobrado anteriormente por substituição tributária (substituído) ou por antecipação + + + + + 900 + Simples Nacional - Outros + + + + + diff --git a/addons/l10n_br/l10n_br.py b/addons/l10n_br/l10n_br.py new file mode 100644 index 00000000000..af387334cd1 --- /dev/null +++ b/addons/l10n_br/l10n_br.py @@ -0,0 +1,84 @@ +# -*- encoding: utf-8 -*- +################################################################################# +# # +# Copyright (C) 2009 Renato Lima - Akretion # +# # +#This program is free software: you can redistribute it and/or modify # +#it under the terms of the GNU Affero General Public License as published by # +#the Free Software Foundation, either version 3 of the License, or # +#(at your option) any later version. # +# # +#This program is distributed in the hope that it will be useful, # +#but WITHOUT ANY WARRANTY; without even the implied warranty of # +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +#GNU General Public License for more details. # +# # +#You should have received a copy of the GNU General Public License # +#along with this program. If not, see . # +################################################################################# + +from osv import fields, osv + +class l10n_br_account_cst_template(osv.osv): + _name = 'l10n_br_account.cst.template' + _description = 'Tax Situation Code Template' + _columns = { + 'code': fields.char('Code', size=8,required=True), + 'name': fields.char('Description', size=64), + 'tax_code_template_id': fields.many2one('account.tax.code.template', 'Tax Code Template',required=True), + } + + def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=80): + if not args: + args = [] + if context is None: + context = {} + ids = self.search(cr, user, ['|',('name',operator,name),('code',operator,name)] + args, limit=limit, context=context) + return self.name_get(cr, user, ids, context) + + def name_get(self, cr, uid, ids, context=None): + if not ids: + return [] + reads = self.read(cr, uid, ids, ['name', 'code'], context=context) + res = [] + for record in reads: + name = record['name'] + if record['code']: + name = record['code'] + ' - '+name + res.append((record['id'], name)) + return res + +l10n_br_account_cst_template() + +class l10n_br_account_cst(osv.osv): + _name = 'l10n_br_account.cst' + _description = 'Tax Situation Code' + _columns = { + 'code': fields.char('Code', size=8,required=True), + 'name': fields.char('Description', size=64), + 'tax_code_id': fields.many2one('account.tax.code', 'Tax Code',required=True), + } + + def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=80): + if not args: + args = [] + if context is None: + context = {} + ids = self.search(cr, user, ['|',('name',operator,name),('code',operator,name)] + args, limit=limit, context=context) + return self.name_get(cr, user, ids, context) + + def name_get(self, cr, uid, ids, context=None): + if not ids: + return [] + reads = self.read(cr, uid, ids, ['name', 'code'], context=context) + res = [] + for record in reads: + name = record['name'] + if record['code']: + name = record['code'] + ' - '+name + res.append((record['id'], name)) + return res + +l10n_br_account_cst() + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file diff --git a/addons/l10n_br/l10n_br_view.xml b/addons/l10n_br/l10n_br_view.xml new file mode 100644 index 00000000000..361f52746ce --- /dev/null +++ b/addons/l10n_br/l10n_br_view.xml @@ -0,0 +1,80 @@ + + + + + + l10n_br.cst.form + l10n_br_account.cst.template + form + +
+ + + + + +
+ + + l10n_br.cst.tree + l10n_br_account.cst.template + tree + + + + + + + + + + + Tax Situation Code Template + ir.actions.act_window + l10n_br_account.cst.template + tree,form + form + + + + + l10n_br.cst.form + l10n_br_account.cst + form + +
+ + + + + +
+ + + l10n_br.cst.tree + l10n_br_account.cst + tree + + + + + + + + + + + Tax Situation Code + ir.actions.act_window + l10n_br_account.cst + tree,form + form + + + + + + + +
+
\ No newline at end of file diff --git a/addons/l10n_br/security/ir.model.access.csv b/addons/l10n_br/security/ir.model.access.csv new file mode 100644 index 00000000000..2a1ecd6910f --- /dev/null +++ b/addons/l10n_br/security/ir.model.access.csv @@ -0,0 +1,3 @@ +"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink" +"l10n_br_account_cst","l10n_br_account.cst","model_l10n_br_account_cst","account.group_account_invoice",1,1,1,1 +"l10n_br_account_cst_template","l10n_br_account.cst.template","model_l10n_br_account_cst_template","account.group_account_invoice",1,1,1,1 From e36bb82bf428d3a14282e9d99ef86112acce6ee0 Mon Sep 17 00:00:00 2001 From: "renatonlima@gmail.com" <> Date: Mon, 3 Oct 2011 10:45:40 -0300 Subject: [PATCH 023/163] brazilian localization module merge bzr revid: renatonlima@gmail.com-20111003134540-1ol1qrnw76zxgabl --- addons/l10n_br/i18n/pt_BR.po | 217 ++++++++++++++++++++++++++++++----- 1 file changed, 188 insertions(+), 29 deletions(-) diff --git a/addons/l10n_br/i18n/pt_BR.po b/addons/l10n_br/i18n/pt_BR.po index e154e0a2c84..649669bca75 100644 --- a/addons/l10n_br/i18n/pt_BR.po +++ b/addons/l10n_br/i18n/pt_BR.po @@ -1,42 +1,201 @@ -# Brazilian Portuguese translation for openobject-addons -# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 -# This file is distributed under the same license as the openobject-addons package. -# FIRST AUTHOR , 2011. +# Translation of OpenERP Server. +# This file contains the translation of the following modules: +# * l10n_br # msgid "" msgstr "" -"Project-Id-Version: openobject-addons\n" -"Report-Msgid-Bugs-To: FULL NAME \n" -"POT-Creation-Date: 2011-01-07 06:40+0000\n" -"PO-Revision-Date: 2011-03-07 18:00+0000\n" -"Last-Translator: Alexsandro Haag \n" -"Language-Team: Brazilian Portuguese \n" +"Project-Id-Version: OpenERP Server 6.0.3\n" +"Report-Msgid-Bugs-To: support@openerp.com\n" +"POT-Creation-Date: 2011-09-19 17:22+0000\n" +"PO-Revision-Date: 2011-09-19 17:22+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-09-05 05:58+0000\n" -"X-Generator: Launchpad (build 13830)\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: l10n_br +#: field:account.tax,tax_discount:0 +#: field:account.tax.code,tax_discount:0 +#: field:account.tax.code.template,tax_discount:0 +#: field:account.tax.template,tax_discount:0 +msgid "Discount this Tax in Prince" +msgstr "Descontar Imposto do Preço" + +#. module: l10n_br +#: model:ir.actions.act_window,name:l10n_br.action_l10n_br_cst_form +#: model:ir.model,name:l10n_br.model_l10n_br_account_cst +#: model:ir.ui.menu,name:l10n_br.menu_action_l10n_br_cst +#: view:l10n_br_account.cst:0 +msgid "Tax Situation Code" +msgstr "Código de Situação Tributária" + +#. module: l10n_br +#: model:ir.model,name:l10n_br.model_account_tax_code +#: field:l10n_br_account.cst,tax_code_id:0 +msgid "Tax Code" +msgstr "Código da taxa" + +#. module: l10n_br +#: help:account.tax.code,domain:0 +#: help:account.tax.code.template,domain:0 +msgid "This field is only used if you develop your own module allowing developers to create specific taxes in a custom domain." +msgstr "Este campo é usado somente se você desenvolver seu proprio modulos para criar impostos ou taxas especificas." + +#. module: l10n_br +#: field:account.tax,amount_mva:0 +#: field:account.tax.template,amount_mva:0 +msgid "MVA Percent" +msgstr "Percentual MVA" + +#. module: l10n_br +#: field:l10n_br_account.cst,name:0 +#: field:l10n_br_account.cst.template,name:0 +msgid "Description" +msgstr "Descrição" + +#. module: l10n_br +#: model:ir.model,name:l10n_br.model_account_journal +msgid "Journal" +msgstr "Diário" + +#. module: l10n_br +#: help:account.tax.template,amount_mva:0 +#: help:account.tax.template,base_reduction:0 +msgid "For taxes of type percentage, enter % ratio between 0-1." +msgstr "Um percentual decimal em % entre 0-1." + +#. module: l10n_br +#: field:account.tax,base_reduction:0 +#: field:account.tax.template,base_reduction:0 +msgid "Redution" +msgstr "Redução" + +#. module: l10n_br +#: constraint:account.tax.code.template:0 +msgid "Error ! You can not create recursive Tax Codes." +msgstr "Erro ! Você não pode criar Códigos de Impostos recursivos" + +#. module: l10n_br +#: help:account.tax,amount_mva:0 +#: help:account.tax,base_reduction:0 +msgid "Um percentual decimal em % entre 0-1." +msgstr "Um percentual decimal em % entre 0-1." + +#. module: l10n_br +#: model:ir.model,name:l10n_br.model_account_tax +msgid "account.tax" +msgstr "account.tax" + +#. module: l10n_br +#: model:ir.actions.act_window,name:l10n_br.action_l10n_br_cst_template_form +#: model:ir.model,name:l10n_br.model_l10n_br_account_cst_template +#: model:ir.ui.menu,name:l10n_br.menu_action_l10n_br_cst_template +#: view:l10n_br_account.cst.template:0 +msgid "Tax Situation Code Template" +msgstr "Modelo de Código de Situação Tributária" + +#. module: l10n_br +#: model:ir.model,name:l10n_br.model_wizard_multi_charts_accounts +msgid "wizard.multi.charts.accounts" +msgstr "wizard.multi.charts.accounts" #. module: l10n_br #: model:ir.actions.todo,note:l10n_br.config_call_account_template_brazilian_localization -msgid "" -"Generate Chart of Accounts from a Chart Template. You will be asked to pass " -"the name of the company, the chart template to follow, the no. of digits to " -"generate the code for your accounts and Bank account, currency to create " -"Journals. Thus,the pure copy of chart Template is generated.\n" -" This is the same wizard that runs from Financial " -"Management/Configuration/Financial Accounting/Financial Accounts/Generate " -"Chart of Accounts from a Chart Template." -msgstr "" -"Gera o Plano de Contas a partir de um Plano Modelo. Será solicitado que você " -"informe o nome da empresa, o modelo do plano para seguir, o número de " -"dígitos para gerar o código de suas contas, a conta bancária e moeda para " -"criar os diários. Assim, a cópia pura do Plano Modelo é gerada.\n" -" Este é o mesmo assistente que roda a partir de Contas/Configuração/Conta " -"Financeira/Conta/Contas/Gerar Plano de Contas a partir de um Plano Modelo." +msgid "Generate Chart of Accounts from a Chart Template. You will be asked to pass the name of the company, the chart template to follow, the no. of digits to generate the code for your accounts and Bank account, currency to create Journals. Thus,the pure copy of chart Template is generated.\n" +" This is the same wizard that runs from Financial Management/Configuration/Financial Accounting/Financial Accounts/Generate Chart of Accounts from a Chart Template." +msgstr "Generate Chart of Accounts from a Chart Template. You will be asked to pass the name of the company, the chart template to follow, the no. of digits to generate the code for your accounts and Bank account, currency to create Journals. Thus,the pure copy of chart Template is generated.\n" +" This is the same wizard that runs from Financial Management/Configuration/Financial Accounting/Financial Accounts/Generate Chart of Accounts from a Chart Template." + +#. module: l10n_br +#: field:account.journal,internal_sequence:0 +msgid "Internal Sequence" +msgstr "Sequência Interna" + +#. module: l10n_br +#: help:account.tax,tax_discount:0 +#: help:account.tax.code,tax_discount:0 +#: help:account.tax.code.template,tax_discount:0 +#: help:account.tax.template,tax_discount:0 +msgid "Mark it for (ICMS, PIS e etc.)." +msgstr "Marque no Caso de (ICMS, PIS, COFINS, ISS e etc.)." + +#. module: l10n_br +#: field:account.tax.code,domain:0 +#: field:account.tax.code.template,domain:0 +msgid "Domain" +msgstr "Domínio" + +#. module: l10n_br +#: field:l10n_br_account.cst,code:0 +#: field:l10n_br_account.cst.template,code:0 +msgid "Code" +msgstr "Código" + +#. module: l10n_br +#: constraint:account.tax.code:0 +msgid "Error ! You can not create recursive accounts." +msgstr "Erro ! Você não pode criar contas recursivas" + +#. module: l10n_br +#: model:ir.model,name:l10n_br.model_account_tax_template +msgid "account.tax.template" +msgstr "account.tax.template" + +#. module: l10n_br +#: sql_constraint:account.journal:0 +msgid "The name of the journal must be unique per company !" +msgstr "O nome do diário deve ser único por empresa !" #. module: l10n_br -#: model:ir.module.module,description:l10n_br.module_meta_information #: model:ir.module.module,shortdesc:l10n_br.module_meta_information msgid "Brazilian Localization" msgstr "Localização Brasileira" + +#. module: l10n_br +#: sql_constraint:account.journal:0 +msgid "The code of the journal must be unique per company !" +msgstr "O código do diário deve ser único por empresa!" + +#. module: l10n_br +#: model:ir.module.module,description:l10n_br.module_meta_information +msgid "Brazilian Localization. This module consists in:\n" +"- Generic Brazilian chart of accounts\n" +"- Brazilian taxes such as:\n" +" - IPI\n" +" - ICMS\n" +" - PIS\n" +" - COFINS\n" +" - ISS\n" +" - IR\n" +" - IRPJ\n" +" - CSLL\n" +"- Tax Situation Code (CST) required for the electronic fiscal invoicing (NFe)\n" +"\n" +"The field tax_discount has also been added in the account.tax.template and account.tax objects to allow the proper computation of some Brazilian VATs such as ICMS. The chart of account creation wizard has been extended to propagate those new data properly.\n" +"\n" +"It's important to note however that this module lack many implementations to use OpenERP properly in Brazil. Those implementations (such as the electronic fiscal Invoicing which is already operational) are brought by more than 15 additional modules of the Brazilian Launchpad localization project https://launchpad.net/openerp.pt-br-localiz and their dependencies in the extra addons branch. Those modules aim at not breaking with the remarkable OpenERP modularity, this is why they are numerous but small. One of the reasons for maintaining those modules apart is that Brazilian Localization leaders need commit rights agility to complete the localization as companies fund the remaining legal requirements (such as soon fiscal ledgers, accounting SPED, fiscal SPED and PAF ECF that are still missing as September 2011). Those modules are also strictly licensed under AGPL V3 and today don't come with any additional paid permission for online use of 'private modules'." +msgstr "Localização Brasileira, este módulo consiste em:\n" +"- Plano de contas contábeis genérico para empresas brasileiras;\n" +"- Cadastro dos impostos brasileiros como:\n" +"        - IPI\n" +"        - ICMS\n" +"        - PIS\n" +"        - COFINS\n" +"        - ISS\n" +"        - IR\n" +"        - IRPJ\n" +"        - CSLL\n" +"- Código de situação tributária, necessário para emissão das notas ficais e nota fiscal eletrônica.\n" +"\n" +"Também foi adicionado o campo tax_discount nos objetos account.tax.template e account.tax para calcular alguns impostos brasileiros como o ICMS, PIS, COFINS e ISS por exemplo. Estendido o wizard de criação de plano de contas para copiar essa informação para os impostos da empresa assim como o código de situação tributária destes impostos.\n" +"\n" +"E importante notar que esse módulo não conta com a maioria das implementações necessárias para a utilização do OpenERP no Brasil. Essas implementações complementares (como por exemplo a emissão da NFe que já é funcional) estão contidas dentro dos mais 15 de módulos do projeto Launchpad da localização brasileira https://launchpad.net/openerp.pt-br-localiz e as suas dependências que estão na branch extra-addons. Esses módulos procuram não diminuir a grande modularidade do OpenERP, por isso eles são pequenos módulos. Uma das razões para mantê-los num projeto separado é a necessidade dos líderes e desenvolvedores de localização terem agilidade nos commits para melhorar a localização brasileira a medida que clientes financiam a implementação dos vários requerimentos legais como em breve, Livros Fiscais, SPED Contábil, SPED Fiscal e PAF-ECF (que ainda faltam em Setembro de 2011). Esses módulos são apenas sobre licença AGPL v3 e hoje não contem permissões especial paga para módulos 'privados online'." + +#. module: l10n_br +#: model:ir.model,name:l10n_br.model_account_tax_code_template +#: field:l10n_br_account.cst.template,tax_code_template_id:0 +msgid "Tax Code Template" +msgstr "Modelo de código de taxa" + From f501f0a6dd0eb362a6566b1d67771870f7e93343 Mon Sep 17 00:00:00 2001 From: "renatonlima@gmail.com" <> Date: Mon, 3 Oct 2011 11:38:07 -0300 Subject: [PATCH 024/163] brazilian localization module merge bzr revid: renatonlima@gmail.com-20111003143807-w62hklw6cade9evf --- addons/l10n_br/data/account.account.type.csv | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/l10n_br/data/account.account.type.csv b/addons/l10n_br/data/account.account.type.csv index 1b1d8cfddac..9f3844cdd2e 100644 --- a/addons/l10n_br/data/account.account.type.csv +++ b/addons/l10n_br/data/account.account.type.csv @@ -1,6 +1,6 @@ "id","code","name","close_method" -"ativo","1","Ativo","balance" -"passivo","2","Passivo","balance" +"ativo","1","Ativo","unreconciled" +"passivo","2","Passivo","unreconciled" "despesa","3","Despesas","balance" "receita","4","Receita","balance" "resultado","5","Resultado","balance" From 58c3f5c93ebad356f4e5d652cfc001f2177f48b3 Mon Sep 17 00:00:00 2001 From: Valentin Lab Date: Tue, 4 Oct 2011 09:48:42 +0200 Subject: [PATCH 025/163] [imp] be more coherent to send widget as usual as form template data. This can be used in mobile version or other templates that would like to subclass the main FormView class. bzr revid: valentin.lab@kalysto.org-20111004074842-txpar1ph0utc2eqd --- addons/web/static/src/js/view_form.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 11ebad8d093..d10c6989ff8 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -85,7 +85,7 @@ openerp.web.FormView = openerp.web.View.extend( /** @lends openerp.web.FormView# this.fields_view = data; var frame = new (this.registry.get_object('frame'))(this, this.fields_view.arch); - this.rendered = QWeb.render(this.form_template, { 'frame': frame, 'view': this }); + this.rendered = QWeb.render(this.form_template, { 'frame': frame, 'view': this, 'widget': this }); } this.$element.html(this.rendered); _.each(this.widgets, function(w) { From dca92e2cc152733c9c6b928ca527b4ff74023d1d Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Fri, 7 Oct 2011 17:37:19 +0200 Subject: [PATCH 026/163] [FIX] share: correct default value bzr revid: chs@openerp.com-20111007153719-2lq8ntxom3y8g2xj --- addons/share/wizard/share_wizard.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/share/wizard/share_wizard.py b/addons/share/wizard/share_wizard.py index b66ccc2dd47..bee96b882b8 100644 --- a/addons/share/wizard/share_wizard.py +++ b/addons/share/wizard/share_wizard.py @@ -134,7 +134,7 @@ class share_wizard(osv.osv_memory): 'message': fields.text("Personal Message", help="An optional personal message, to be included in the e-mail notification."), } _defaults = { - 'user_type' : 'new', + 'user_type' : 'emails', 'domain': lambda self, cr, uid, context, *a: context.get('domain', '[]'), 'share_root_url': lambda self, cr, uid, context, *a: context.get('share_root_url') or _('Please specify "share_root_url" in context'), 'action_id': lambda self, cr, uid, context, *a: context.get('action_id'), From a9e4c19856af011d676a4842d0985d6aa8b6bddc Mon Sep 17 00:00:00 2001 From: Maxime Chambreuil Date: Fri, 7 Oct 2011 17:43:55 -0400 Subject: [PATCH 027/163] [UPG] Upgrade to 6.1 bzr revid: maxime.chambreuil@savoirfairelinux.com-20111007214355-6y0000e1pnkvpfer --- addons/l10n_ca/account_tax_en.xml | 26 +++++++++++++------------- addons/l10n_ca/account_tax_fr.xml | 26 +++++++++++++------------- 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/addons/l10n_ca/account_tax_en.xml b/addons/l10n_ca/account_tax_en.xml index 8eadcf518b0..0ce4c98969a 100644 --- a/addons/l10n_ca/account_tax_en.xml +++ b/addons/l10n_ca/account_tax_en.xml @@ -15,7 +15,7 @@ - GST (5%) + GST - 5% (MB) GST 0.050000 percent @@ -32,7 +32,7 @@ - PST (7%) + PST - 7% PST 0.070000 percent @@ -59,7 +59,7 @@ - GST (5%) + GST - 5% (PE) GST 0.050000 percent @@ -76,7 +76,7 @@ - PST (10%) + PST - 10% PST 0.100000 percent @@ -103,7 +103,7 @@ - GST (5%) + GST - 5% (QC) GST 0.050000 percent @@ -120,7 +120,7 @@ - PST (8.5%) + PST - 8.5% PST 0.085000 percent @@ -147,7 +147,7 @@ - GST (5%) + GST - 5% (SK) GST 0.050000 percent @@ -164,7 +164,7 @@ - PST (5%) + PST - 5% PST 0.050000 percent @@ -182,7 +182,7 @@ - HST (12%) + HST - 12% HST12 0.120000 percent @@ -196,7 +196,7 @@ - HST (13%) + HST - 13% HST13 0.130000 percent @@ -210,7 +210,7 @@ - HST (13.5%) + HST - 13.5% HST135 0.135000 percent @@ -224,7 +224,7 @@ - HST (15%) + HST - 15% HST15 0.150000 percent @@ -240,7 +240,7 @@ - GST (5%) + GST - 5% GST 0.050000 percent diff --git a/addons/l10n_ca/account_tax_fr.xml b/addons/l10n_ca/account_tax_fr.xml index 61181d5324a..6ae3c08c893 100644 --- a/addons/l10n_ca/account_tax_fr.xml +++ b/addons/l10n_ca/account_tax_fr.xml @@ -15,7 +15,7 @@ - TPS (5%) + TPS - 5% (MB) TPS 0.050000 percent @@ -32,7 +32,7 @@ - TVP (7%) + TVP - 7% TVP 0.700000 percent @@ -59,7 +59,7 @@ - TPS (5%) + TPS - 5% (PE) TPS 0.050000 percent @@ -76,7 +76,7 @@ - TVP (10%) + TVP - 10% TVP 0.100000 percent @@ -103,7 +103,7 @@ - TPS (5%) + TPS - 5% (QC) TPS 0.050000 percent @@ -120,7 +120,7 @@ - TVQ (8.5%) + TVQ - 8.5% TVQ 0.085000 percent @@ -147,7 +147,7 @@ - TPS (5%) + TPS - 5% (SK) TPS 0.050000 percent @@ -164,7 +164,7 @@ - TVP (5%) + TVP - 5% (SK) TVP 0.050000 percent @@ -182,7 +182,7 @@ - TVH (12%) + TVH - 12% TVH12 0.120000 percent @@ -196,7 +196,7 @@ - TVH (13%) + TVH - 13% TVH13 0.130000 percent @@ -210,7 +210,7 @@ - TVH (13.5%) + TVH - 13.5% TVH135 0.135000 percent @@ -224,7 +224,7 @@ - TVH (15%) + TVH - 15% TVH15 0.150000 percent @@ -240,7 +240,7 @@ - TPS (5%) + TPS - 5% TPS 0.050000 percent From a1e57977275af752c2b8e9c9c644523fbeb7425b Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Mon, 10 Oct 2011 16:25:49 +0200 Subject: [PATCH 028/163] [FIX] share+portal: fix share wizard. [IMP] share wizard: share_root_url and share_url are now function fields bzr revid: chs@openerp.com-20111010142549-uvco15xdf2198e0x --- addons/portal/wizard/share_wizard.py | 4 -- addons/portal/wizard/share_wizard_view.xml | 6 +-- addons/share/wizard/share_wizard.py | 53 ++++++++++------------ addons/share/wizard/share_wizard_view.xml | 8 +++- 4 files changed, 32 insertions(+), 39 deletions(-) diff --git a/addons/portal/wizard/share_wizard.py b/addons/portal/wizard/share_wizard.py index c1366b5dbf0..ab639bdeccc 100644 --- a/addons/portal/wizard/share_wizard.py +++ b/addons/portal/wizard/share_wizard.py @@ -40,10 +40,6 @@ class share_wizard_portal(osv.osv_memory): _columns = { 'user_ids': fields.many2many('res.users', 'share_wizard_res_user_rel', 'share_id', 'user_id', 'Existing users', domain=[('share', '=', True)]), 'group_ids': fields.many2many('res.groups', 'share_wizard_res_group_rel', 'share_id', 'group_id', 'Existing groups', domain=[('share', '=', False)]), - - # no clean way to extend selection yet, copy the field. - 'user_type': fields.selection(_user_type_selection,'Users to share with', - help="Select the type of user(s) you would like to share data with."), } def is_portal_manager(self, cr, uid, context=None): diff --git a/addons/portal/wizard/share_wizard_view.xml b/addons/portal/wizard/share_wizard_view.xml index f16334b68a3..9bee027c3e2 100644 --- a/addons/portal/wizard/share_wizard_view.xml +++ b/addons/portal/wizard/share_wizard_view.xml @@ -8,11 +8,7 @@ form - - - - - + diff --git a/addons/share/wizard/share_wizard.py b/addons/share/wizard/share_wizard.py index bee96b882b8..82eb814e54a 100644 --- a/addons/share/wizard/share_wizard.py +++ b/addons/share/wizard/share_wizard.py @@ -119,24 +119,35 @@ class share_wizard(osv.osv_memory): values['name'] = action.name return super(share_wizard,self).create(cr, uid, values, context=context) + + def _share_root_url(self, cr, uid, ids, _fieldname, _args, context=None): + result = dict.fromkeys(ids, '') + data = dict(dbname=cr.dbname, login='', password='') + for this in self.browse(cr, uid, ids, context=context): + result[this.id] = this.share_url_template % data + return result + _columns = { 'action_id': fields.many2one('ir.actions.act_window', 'Action to share', required=True, help="The action that opens the screen containing the data you wish to share."), 'domain': fields.char('Domain', size=256, help="Optional domain for further data filtering"), - 'user_type': fields.selection(_user_type_selection,'Users to share with', + 'user_type': fields.selection(lambda s, *a, **k: s._user_type_selection(*a, **k),'Users to share with', required=True, help="Select the type of user(s) you would like to share data with."), 'new_users': fields.text("Emails"), 'access_mode': fields.selection([('readonly','Can view'),('readwrite','Can edit')],'Access Mode', required=True, help="Access rights to be granted on the shared documents."), 'result_line_ids': fields.one2many('share.wizard.result.line', 'share_wizard_id', 'Summary', readonly=True), - 'share_root_url': fields.char('Share Access URL', size=512, readonly=True, tooltip='Main access page for users that are granted shared access'), + 'share_url_template': fields.char('Share Access URL Template', size=512, + help='Template for share url. May contains %(dbname)s, %(login)s and %(password)s'), + 'share_root_url': fields.function(_share_root_url, 'Share Access URL', type='char', size=512, readonly=True, + help='Main access page for users that are granted shared access'), 'name': fields.char('Share Title', size=64, required=True, help="Title for the share (displayed to users as menu and shortcut name)"), 'message': fields.text("Personal Message", help="An optional personal message, to be included in the e-mail notification."), } _defaults = { 'user_type' : 'emails', 'domain': lambda self, cr, uid, context, *a: context.get('domain', '[]'), - 'share_root_url': lambda self, cr, uid, context, *a: context.get('share_root_url') or _('Please specify "share_root_url" in context'), + 'share_url_template': lambda self, cr, uid, context, *a: context.get('share_url_template') or _('Please specify "share_url_template" in context'), 'action_id': lambda self, cr, uid, context, *a: context.get('action_id'), 'access_mode': 'readonly', } @@ -537,12 +548,11 @@ class share_wizard(osv.osv_memory): try: domain = safe_eval(wizard_data.domain) if domain: - domain_expr = expression.expression(domain) for rel_field, model in fields_relations: related_domain = [] if not rel_field: continue for element in domain: - if domain_expr._is_leaf(element): + if expression.is_leaf(element): left, operator, right = element left = '%s.%s'%(rel_field, left) element = left, operator, right @@ -555,19 +565,6 @@ class share_wizard(osv.osv_memory): raise osv.except_osv(_('Sharing access could not be created'), _('Sorry, the current screen and filter you are trying to share are not supported at the moment.\nYou may want to try a simpler filter.')) - def _finish_result_lines(self, cr, uid, wizard_data, share_group_id, context=None): - """Perform finalization of the share, and populate the summary""" - share_root_url = wizard_data.share_root_url - format_url = '%(dbname)s' in share_root_url - for result in wizard_data.result_line_ids: - # share_root_url may contain placeholders for dbname, login and password - share_url = (share_root_url % \ - {'login': quote_plus(result.user_id.login), - 'password': '', # kept empty for security reasons - 'dbname': quote_plus(cr.dbname)}) \ - if format_url else share_root_url - result.write({'share_url': share_url}, context=context) - def _check_preconditions(self, cr, uid, wizard_data, context=None): self._assert(wizard_data.action_id and wizard_data.access_mode, _('Action and Access Mode are required to create a shared access'), @@ -662,15 +659,6 @@ class share_wizard(osv.osv_memory): # C. self._create_indirect_sharing_rules(cr, current_user, wizard_data, group_id, obj1, context=context) - # so far, so good -> check summary results and return them - self._finish_result_lines(cr, uid, wizard_data, group_id, context=context) - - # update share URL to make it generic - generic_share_url = wizard_data.share_root_url % {'dbname': cr.dbname, - 'login': '', - 'password': ''} - wizard_data.write({'share_root_url': generic_share_url}, context=context) - # refresh wizard_data wizard_data = self.browse(cr, uid, ids[0], context=context) @@ -742,11 +730,20 @@ share_wizard() class share_result_line(osv.osv_memory): _name = 'share.wizard.result.line' _rec_name = 'user_id' + + + def _share_url(self, cr, uid, ids, _fieldname, _args, context=None): + result = dict.fromkeys(ids, '') + for this in self.browse(cr, uid, ids, context=context): + data = dict(dbname=cr.dbname, login=this.login, password='') # password is kept empty for security reasons + result[this.id] = this.share_wizard_id.share_url_template % data + return result + _columns = { 'user_id': fields.many2one('res.users', required=True, readonly=True), 'login': fields.related('user_id', 'login', string='Login', type='char', size=64, required=True, readonly=True), 'password': fields.char('Password', size=64, readonly=True), - 'share_url': fields.char('Share URL', size=512, required=True), + 'share_url': fields.function(_share_url, 'Share URL', type='char', size=512), 'share_wizard_id': fields.many2one('share.wizard', 'Share Wizard', required=True), 'newly_created': fields.boolean('Newly created', readonly=True), } diff --git a/addons/share/wizard/share_wizard_view.xml b/addons/share/wizard/share_wizard_view.xml index 5087b85d7bd..dedb7c7f4bc 100644 --- a/addons/share/wizard/share_wizard_view.xml +++ b/addons/share/wizard/share_wizard_view.xml @@ -29,6 +29,10 @@ form
+ + + + @@ -78,7 +82,7 @@ - 'action_id' (id of action) - 'domain' (string expression for full domain to apply as sent to server, with dynamic data like 'uid' replaced by actual value (i.e. after eval)!) - - 'share_root_url' : URL for direct access to share page (may include %(login)s and %(password)s placeholders) + - 'share_url_template' : URL for direct access to share page (may include %(login)s and %(password)s placeholders) --> Share Wizard @@ -94,7 +98,7 @@ - 'action_id' (id of action) - 'domain' (string expression for full domain to apply as sent to server, with dynamic data like 'uid' replaced by actual value (i.e. after eval)!) - - 'share_root_url' : URL for direct access to share page (may include %(login)s and %(password)s placeholders) + - 'share_url_template' : URL for direct access to share page (may include %(login)s and %(password)s placeholders) --> Share Wizard From cb7cc66a2e53c325fce682346b7930648f8f16a5 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Mon, 10 Oct 2011 16:29:53 +0200 Subject: [PATCH 029/163] [IMP] share: convert web part to v6.1 bzr revid: chs@openerp.com-20111010142953-90ylj17cc1416o5f --- addons/share/__openerp__.py | 7 +- addons/share/static/src/css/share.css | 5 ++ addons/share/static/src/js/share.js | 43 ++++++++++++ addons/share/web/__init__.py | 2 - addons/share/web/controllers.py | 49 -------------- addons/share/web/editors.py | 94 --------------------------- 6 files changed, 53 insertions(+), 147 deletions(-) create mode 100644 addons/share/static/src/css/share.css create mode 100644 addons/share/static/src/js/share.js delete mode 100644 addons/share/web/__init__.py delete mode 100644 addons/share/web/controllers.py delete mode 100644 addons/share/web/editors.py diff --git a/addons/share/__openerp__.py b/addons/share/__openerp__.py index f6a0c93285d..ec026742f87 100644 --- a/addons/share/__openerp__.py +++ b/addons/share/__openerp__.py @@ -3,6 +3,7 @@ # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (). +# Copyright (C) 2010-2011 OpenERP SA (). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as @@ -22,7 +23,7 @@ { "name" : "Web Share", - "version" : "1.5", + "version" : "2.0", "depends" : ["base", "mail"], "author" : "OpenERP SA", "category": 'Hidden', @@ -53,7 +54,9 @@ synchronization with other companies, etc. 'installable': True, 'web': True, 'certificate' : '001301246528927038493', - 'images': ['images/share_wizard.jpeg','images/sharing_wizard_step1.jpeg', 'images/sharing_wizard_step2.jpeg'], + 'js': ['static/src/js/share.js'], + 'css': ['static/src/css/share.css'], + 'images': ['static/src/img/share_wizard.jpeg','static/src/img/sharing_wizard_step1.jpeg', 'static/src/img/sharing_wizard_step2.jpeg'], } # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/share/static/src/css/share.css b/addons/share/static/src/css/share.css new file mode 100644 index 00000000000..781bfe197f1 --- /dev/null +++ b/addons/share/static/src/css/share.css @@ -0,0 +1,5 @@ + +.openerp li.oe_share { + background: url(../img/share.png) no-repeat; + padding-left: 20px; +} diff --git a/addons/share/static/src/js/share.js b/addons/share/static/src/js/share.js new file mode 100644 index 00000000000..8a8294d0f12 --- /dev/null +++ b/addons/share/static/src/js/share.js @@ -0,0 +1,43 @@ + +openerp.share = function(instance) { + +instance.web.Sidebar = instance.web.Sidebar.extend({ + + add_default_sections: function() { + this._super(); + this.add_items('Sharing', [{ + label: 'Share', + callback: this.on_sidebar_click_share, + classname: 'oe_share', + }]); + }, + + on_sidebar_click_share: function(item) { + var self = this; + var view = this.widget_parent + var action = view.widget_parent.action; + + var share_url_template = _('%s//%s/?db=%%(dbname)s&login=%%(login)s').sprintf(document.location.protocol, document.location.host); + var Share = new instance.web.DataSet(this, 'share.wizard', view.dataset.get_context()); + + Share.create({ + name: action.name, + domain: view.dataset.domain, + action_id: action.id, + share_url_template: share_url_template, + }, function(result) { + var share_id = result.result; + console.log('share_id', share_id); + + var step1 = Share.call('go_step_1', [[share_id],], function(result) { + var action = result; + console.log('step1', action); + self.do_action(action); + }); + }); + + }, + +}); + +}; diff --git a/addons/share/web/__init__.py b/addons/share/web/__init__.py deleted file mode 100644 index f95bb222c10..00000000000 --- a/addons/share/web/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -import controllers -import editors \ No newline at end of file diff --git a/addons/share/web/controllers.py b/addons/share/web/controllers.py deleted file mode 100644 index e682c8d9709..00000000000 --- a/addons/share/web/controllers.py +++ /dev/null @@ -1,49 +0,0 @@ -import urlparse -import cherrypy - -from openobject import rpc -from openobject.tools import expose, ast - -import openerp.controllers - - - -class ShareWizardController(openerp.controllers.SecuredController): - _cp_path = "/share" - - @expose() - def index(self, domain, context, view_id, search_domain='[]', action_id=None): - context = ast.literal_eval(context) - - if not action_id: - # This should not be needed anymore, but just in case users are - # running the module with an older version of the web client... - - # to remove soon-ish - action_id = rpc.RPCProxy('ir.actions.act_window').search( - [('view_id','=',int(view_id))], context=context) - if not action_id: return "" - - action_id = action_id[0] - - domain = ast.literal_eval(domain) - domain.extend(ast.literal_eval(search_domain)) - - scheme, netloc, _, _, _ = urlparse.urlsplit(cherrypy.request.base) - share_root_url = urlparse.urlunsplit(( - scheme, netloc, '/openerp/login', - 'db=%(dbname)s&user=%(login)s&password=%(password)s', '')) - - context.update( - #active_ids=share_wiz_id, - #active_id=share_wiz_id[0], - _terp_view_name='Share Wizard', - share_root_url=share_root_url) - Share = rpc.RPCProxy('share.wizard') - sharing_view_id = Share.create({ - 'domain': str(domain), - 'action_id': action_id and int(action_id) - }, context) - return openerp.controllers.actions.execute( - Share.go_step_1([sharing_view_id], context), - ids=[sharing_view_id], context=context) diff --git a/addons/share/web/editors.py b/addons/share/web/editors.py deleted file mode 100644 index 677de4a8317..00000000000 --- a/addons/share/web/editors.py +++ /dev/null @@ -1,94 +0,0 @@ -# -*- coding: utf-8 -*- -import openobject.templating - -class FormEditor(openobject.templating.TemplateEditor): - templates = ['/openerp/controllers/templates/form.mako'] - MAIN_FORM_BODY = u'id="main_form_body"' - - def insert_share_button(self, output): - # Insert the share button on the form title H1 line, at the very end, - # but only if the user is a member of the sharing group - share_opener_insertion = output.index('% endif', output.index( - '/view_diagram/process', - output.index(self.MAIN_FORM_BODY))) + len('% endif') - return output[:share_opener_insertion] + ''' - <% - if 'has_share' not in cp.session: - cp.session['has_share'] = rpc.RPCProxy('share.wizard').has_share() - %> - % if cp.session['has_share'] and buttons.toolbar and not is_dashboard: - - - - - \n - % endif -''' + output[share_opener_insertion:] - - def edit(self, template, template_text): - return self.insert_share_button( - super(FormEditor, self).edit(template, template_text)) - - -class SidebarEditor(openobject.templating.TemplateEditor): - templates = ['/openerp/widgets/templates/sidebar.mako'] - ADD_SHARE_SECTION = u'id="sidebar"' - - def insert_share_link(self, output): - # Insert the link on the line, right after the link to open the - # attachment form, but only if the user is a member of the sharing group - share_opener_insertion = output.index( - '\n', - output.index(self.ADD_SHARE_SECTION)) + 1 - return output[:share_opener_insertion] + ''' - <% - if 'has_share' not in cp.session: - cp.session['has_share'] = rpc.RPCProxy('share.wizard').has_share() - %> - % if cp.session['has_share']: -

${_("Sharing")}

- - - \n - % endif -''' + output[share_opener_insertion:] - - def edit(self, template, template_text): - return self.insert_share_link( - super(SidebarEditor, self).edit(template, template_text)) From b46ef4b9605c0b276dfa51779a873c6deb2c9289 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Mon, 10 Oct 2011 16:54:06 +0200 Subject: [PATCH 030/163] [FIX] share: correct function fields labels bzr revid: chs@openerp.com-20111010145406-0k4au407iwv9e31n --- addons/share/wizard/share_wizard.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/share/wizard/share_wizard.py b/addons/share/wizard/share_wizard.py index 82eb814e54a..20f175b1e0b 100644 --- a/addons/share/wizard/share_wizard.py +++ b/addons/share/wizard/share_wizard.py @@ -139,7 +139,7 @@ class share_wizard(osv.osv_memory): 'result_line_ids': fields.one2many('share.wizard.result.line', 'share_wizard_id', 'Summary', readonly=True), 'share_url_template': fields.char('Share Access URL Template', size=512, help='Template for share url. May contains %(dbname)s, %(login)s and %(password)s'), - 'share_root_url': fields.function(_share_root_url, 'Share Access URL', type='char', size=512, readonly=True, + 'share_root_url': fields.function(_share_root_url, string='Share Access URL', type='char', size=512, readonly=True, help='Main access page for users that are granted shared access'), 'name': fields.char('Share Title', size=64, required=True, help="Title for the share (displayed to users as menu and shortcut name)"), 'message': fields.text("Personal Message", help="An optional personal message, to be included in the e-mail notification."), @@ -743,7 +743,7 @@ class share_result_line(osv.osv_memory): 'user_id': fields.many2one('res.users', required=True, readonly=True), 'login': fields.related('user_id', 'login', string='Login', type='char', size=64, required=True, readonly=True), 'password': fields.char('Password', size=64, readonly=True), - 'share_url': fields.function(_share_url, 'Share URL', type='char', size=512), + 'share_url': fields.function(_share_url, string='Share URL', type='char', size=512), 'share_wizard_id': fields.many2one('share.wizard', 'Share Wizard', required=True), 'newly_created': fields.boolean('Newly created', readonly=True), } From 339d6c856a4b08e87bb973f150002f8b626f4fb5 Mon Sep 17 00:00:00 2001 From: "nicolas.bessi@camptocamp.com" <> Date: Wed, 12 Oct 2011 10:33:50 +0200 Subject: [PATCH 031/163] =?UTF-8?q?[FIX]=C2=A0translation=20and=20formatti?= =?UTF-8?q?ng=20support=20in=20report=5Fwebkit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bzr revid: nicolas.bessi@camptocamp.com-20111012083350-lgzjye93lqp2nhkr --- addons/report_webkit/webkit_report.py | 39 +-------------------------- 1 file changed, 1 insertion(+), 38 deletions(-) diff --git a/addons/report_webkit/webkit_report.py b/addons/report_webkit/webkit_report.py index bda6c193af2..8d6373e412b 100644 --- a/addons/report_webkit/webkit_report.py +++ b/addons/report_webkit/webkit_report.py @@ -181,52 +181,15 @@ class WebKitParser(report_sxw): os.unlink(out) return pdf - - def setLang(self, lang): - if not lang: - lang = 'en_US' - self.localcontext['lang'] = lang - def translate_call(self, src): """Translate String.""" ir_translation = self.pool.get('ir.translation') res = ir_translation._get_source(self.parser_instance.cr, self.parser_instance.uid, - self.name, 'report', self.localcontext.get('lang', 'en_US'), src) + self.name, 'report', self.parser_instance.localcontext.get('lang', 'en_US'), src) if not res : return src return res - def formatLang(self, value, digits=None, date=False, date_time=False, grouping=True, monetary=False): - """format using the know cursor, language from localcontext""" - if digits is None: - digits = self.parser_instance.get_digits(value) - if isinstance(value, (str, unicode)) and not value: - return '' - pool_lang = self.pool.get('res.lang') - lang = self.localcontext['lang'] - - lang_ids = pool_lang.search(self.parser_instance.cr, self.parser_instance.uid, [('code','=',lang)])[0] - lang_obj = pool_lang.browse(self.parser_instance.cr, self.parser_instance.uid, lang_ids) - - if date or date_time: - if not str(value): - return '' - - date_format = lang_obj.date_format - parse_format = '%Y-%m-%d' - if date_time: - value=value.split('.')[0] - date_format = date_format + " " + lang_obj.time_format - parse_format = '%Y-%m-%d %H:%M:%S' - if not isinstance(value, time.struct_time): - return time.strftime(date_format, time.strptime(value, parse_format)) - - else: - date = datetime(*value.timetuple()[:6]) - return date.strftime(date_format) - - return lang_obj.format('%.' + str(digits) + 'f', value, grouping=grouping, monetary=monetary) - # override needed to keep the attachments storing procedure def create_single_pdf(self, cursor, uid, ids, data, report_xml, context=None): """generate the PDF""" From 98eec0b1b1278c9d586865a2952b0bd573e46aed Mon Sep 17 00:00:00 2001 From: "Amit Parmar (OpenERP)" Date: Wed, 12 Oct 2011 14:37:44 +0530 Subject: [PATCH 032/163] [IMP] Redefine tolltip on the user preference wizard bzr revid: aar@tinyerp.com-20111012090744-1tep155wp1g464nk --- addons/base_setup/base_setup_views.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/base_setup/base_setup_views.xml b/addons/base_setup/base_setup_views.xml index 01051c4cc60..69a9f6580a4 100644 --- a/addons/base_setup/base_setup_views.xml +++ b/addons/base_setup/base_setup_views.xml @@ -61,7 +61,7 @@ Define Users's Preferences - This will set the default preferences for all users. After this, each user will be able to update his own preferences. + This will set the default prefereneces for all users (existing and new ones). After this, each user will be able to update his own preferences. From e7bc9f0683aa8fe5abb4991aa99ff2c28bce8b52 Mon Sep 17 00:00:00 2001 From: "Amit Parmar (OpenERP)" Date: Wed, 12 Oct 2011 15:34:59 +0530 Subject: [PATCH 033/163] [IMP] Add menutip to create your employees menu bzr revid: aar@tinyerp.com-20111012100459-xvqm6x70ofydvoqs --- addons/hr/hr_installer.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/hr/hr_installer.xml b/addons/hr/hr_installer.xml index 263f842b5b4..6626b3ee0f8 100644 --- a/addons/hr/hr_installer.xml +++ b/addons/hr/hr_installer.xml @@ -15,6 +15,7 @@ form tree,form + Create employees form and link each employee to a user if you want your employees to have access to the database. You can assign some categories to your employees in order to be able to perform massive operations on all the employees of the same category like allocating holidays.
From 0b803c6852af147c6f423d11754ccff88259b931 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Thu, 13 Oct 2011 17:33:02 +0200 Subject: [PATCH 034/163] [IMP] share: put the sidebar item in the "Other Options" section bzr revid: chs@openerp.com-20111013153302-ts5yds22n15zdb4h --- addons/share/static/src/js/share.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/share/static/src/js/share.js b/addons/share/static/src/js/share.js index 8a8294d0f12..96ff5dc4dd6 100644 --- a/addons/share/static/src/js/share.js +++ b/addons/share/static/src/js/share.js @@ -5,7 +5,7 @@ instance.web.Sidebar = instance.web.Sidebar.extend({ add_default_sections: function() { this._super(); - this.add_items('Sharing', [{ + this.add_items('other', [{ label: 'Share', callback: this.on_sidebar_click_share, classname: 'oe_share', From 9f964ca29d1fbf334c8bde793936822a2d1cddd7 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Fri, 14 Oct 2011 11:43:24 +0200 Subject: [PATCH 035/163] [IMP] share: share_url_template is read from ir_config_parameter bzr revid: chs@openerp.com-20111014094324-wpj3265vwinel3rj --- addons/share/static/src/js/share.js | 2 -- addons/share/wizard/share_wizard.py | 17 ++++++++++------- addons/share/wizard/share_wizard_view.xml | 2 -- 3 files changed, 10 insertions(+), 11 deletions(-) diff --git a/addons/share/static/src/js/share.js b/addons/share/static/src/js/share.js index 96ff5dc4dd6..68df8eec878 100644 --- a/addons/share/static/src/js/share.js +++ b/addons/share/static/src/js/share.js @@ -17,14 +17,12 @@ instance.web.Sidebar = instance.web.Sidebar.extend({ var view = this.widget_parent var action = view.widget_parent.action; - var share_url_template = _('%s//%s/?db=%%(dbname)s&login=%%(login)s').sprintf(document.location.protocol, document.location.host); var Share = new instance.web.DataSet(this, 'share.wizard', view.dataset.get_context()); Share.create({ name: action.name, domain: view.dataset.domain, action_id: action.id, - share_url_template: share_url_template, }, function(result) { var share_id = result.result; console.log('share_id', share_id); diff --git a/addons/share/wizard/share_wizard.py b/addons/share/wizard/share_wizard.py index 20f175b1e0b..1cd8104100c 100644 --- a/addons/share/wizard/share_wizard.py +++ b/addons/share/wizard/share_wizard.py @@ -119,12 +119,18 @@ class share_wizard(osv.osv_memory): values['name'] = action.name return super(share_wizard,self).create(cr, uid, values, context=context) + def share_url_template(self, cr, uid, _ids, context=None): + # NOTE: take _ids in parameter to allow usage through browse_record objects + base_url = self.pool.get('ir.config_parameter').get_param(cr, uid, 'web.base.url', default='', context=context) + if base_url: + base_url += '/?db=%(dbname)s&login=%(login)s' + return base_url def _share_root_url(self, cr, uid, ids, _fieldname, _args, context=None): result = dict.fromkeys(ids, '') - data = dict(dbname=cr.dbname, login='', password='') + data = dict(dbname=cr.dbname, login='') for this in self.browse(cr, uid, ids, context=context): - result[this.id] = this.share_url_template % data + result[this.id] = this.share_url_template() % data return result _columns = { @@ -137,8 +143,6 @@ class share_wizard(osv.osv_memory): 'access_mode': fields.selection([('readonly','Can view'),('readwrite','Can edit')],'Access Mode', required=True, help="Access rights to be granted on the shared documents."), 'result_line_ids': fields.one2many('share.wizard.result.line', 'share_wizard_id', 'Summary', readonly=True), - 'share_url_template': fields.char('Share Access URL Template', size=512, - help='Template for share url. May contains %(dbname)s, %(login)s and %(password)s'), 'share_root_url': fields.function(_share_root_url, string='Share Access URL', type='char', size=512, readonly=True, help='Main access page for users that are granted shared access'), 'name': fields.char('Share Title', size=64, required=True, help="Title for the share (displayed to users as menu and shortcut name)"), @@ -147,7 +151,6 @@ class share_wizard(osv.osv_memory): _defaults = { 'user_type' : 'emails', 'domain': lambda self, cr, uid, context, *a: context.get('domain', '[]'), - 'share_url_template': lambda self, cr, uid, context, *a: context.get('share_url_template') or _('Please specify "share_url_template" in context'), 'action_id': lambda self, cr, uid, context, *a: context.get('action_id'), 'access_mode': 'readonly', } @@ -735,8 +738,8 @@ class share_result_line(osv.osv_memory): def _share_url(self, cr, uid, ids, _fieldname, _args, context=None): result = dict.fromkeys(ids, '') for this in self.browse(cr, uid, ids, context=context): - data = dict(dbname=cr.dbname, login=this.login, password='') # password is kept empty for security reasons - result[this.id] = this.share_wizard_id.share_url_template % data + data = dict(dbname=cr.dbname, login=this.login) + result[this.id] = this.share_wizard_id.share_url_template() % data return result _columns = { diff --git a/addons/share/wizard/share_wizard_view.xml b/addons/share/wizard/share_wizard_view.xml index dedb7c7f4bc..128b32b07da 100644 --- a/addons/share/wizard/share_wizard_view.xml +++ b/addons/share/wizard/share_wizard_view.xml @@ -82,7 +82,6 @@ - 'action_id' (id of action) - 'domain' (string expression for full domain to apply as sent to server, with dynamic data like 'uid' replaced by actual value (i.e. after eval)!) - - 'share_url_template' : URL for direct access to share page (may include %(login)s and %(password)s placeholders) --> Share Wizard @@ -98,7 +97,6 @@ - 'action_id' (id of action) - 'domain' (string expression for full domain to apply as sent to server, with dynamic data like 'uid' replaced by actual value (i.e. after eval)!) - - 'share_url_template' : URL for direct access to share page (may include %(login)s and %(password)s placeholders) --> Share Wizard From 5de33e50224033523288fba1593da2ef5f706e9a Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Fri, 14 Oct 2011 14:12:12 +0200 Subject: [PATCH 036/163] [IMP] share bzr revid: chs@openerp.com-20111014121212-zyipo1v68rm7f64c --- addons/share/static/src/css/share.css | 10 ++- addons/share/static/src/js/share.js | 100 +++++++++++++++++++------- 2 files changed, 84 insertions(+), 26 deletions(-) diff --git a/addons/share/static/src/css/share.css b/addons/share/static/src/css/share.css index 781bfe197f1..3b47a065b1e 100644 --- a/addons/share/static/src/css/share.css +++ b/addons/share/static/src/css/share.css @@ -1,5 +1,13 @@ -.openerp li.oe_share { +.openerp li.oe-share { background: url(../img/share.png) no-repeat; padding-left: 20px; } + +.openerp a.oe-share { + background: url(../img/share.png) no-repeat; + display: block; + float: left; + width: 20px; + height: 20px; +} diff --git a/addons/share/static/src/js/share.js b/addons/share/static/src/js/share.js index 68df8eec878..391d2ceb1b2 100644 --- a/addons/share/static/src/js/share.js +++ b/addons/share/static/src/js/share.js @@ -1,41 +1,91 @@ openerp.share = function(instance) { +var QWeb = instance.web.qweb; +QWeb.add_template('/share/static/src/xml/share.xml'); + +function launch_wizard(self, view) { + + var action = view.widget_parent.action; + var Share = new instance.web.DataSet(self, 'share.wizard', view.dataset.get_context()); + + console.log(view); + + domain = view.dataset.domain; + if (view.fields_view.type == 'form') { + domain = new instance.web.CompoundDomain(domain, [['id', '=', view.datarecord.id]]); + } + + Share.create({ + name: action.name, + domain: domain, + action_id: action.id, + }, function(result) { + var share_id = result.result; + var step1 = Share.call('go_step_1', [[share_id],], function(result) { + var action = result; + self.do_action(action); + }); + }); +} + +var _has_share = null; +function if_has_share(yes, no) { + if (!_has_share) { + _has_share = $.Deferred(function() { + var self = this; + var session = instance.webclient.session; + session.on_session_invalid.add_last(function() { _has_share = null; }); + var func = new instance.web.Model(session, "share.wizard").get_func("has_share"); + func(session.uid).pipe(function(res) { + if(res) { + self.resolve(); + } else { + self.reject(); + } + }); + }); + } + _has_share.done(yes).fail(no); +} + instance.web.Sidebar = instance.web.Sidebar.extend({ add_default_sections: function() { this._super(); - this.add_items('other', [{ - label: 'Share', - callback: this.on_sidebar_click_share, - classname: 'oe_share', - }]); + var self = this; + if_has_share(function() { + self.add_items('other', [{ + label: 'Share', + callback: self.on_sidebar_click_share, + classname: 'oe-share', + }]); + }); }, on_sidebar_click_share: function(item) { - var self = this; var view = this.widget_parent - var action = view.widget_parent.action; - - var Share = new instance.web.DataSet(this, 'share.wizard', view.dataset.get_context()); - - Share.create({ - name: action.name, - domain: view.dataset.domain, - action_id: action.id, - }, function(result) { - var share_id = result.result; - console.log('share_id', share_id); - - var step1 = Share.call('go_step_1', [[share_id],], function(result) { - var action = result; - console.log('step1', action); - self.do_action(action); - }); - }); - + launch_wizard(this, view); }, }); + +instance.web.ViewManagerAction.include({ + start: function() { + var self = this; + if_has_share(function() { + self.$element.find('a.oe-share').click(self.on_click_share); + }, function() { + self.$element.find('a.oe-share').remove(); + }); + return this._super.apply(this, arguments); + }, + + on_click_share: function(e) { + e.preventDefault(); + launch_wizard(this, this.views[this.active_view].controller); + }, +}); + }; From e7888afb9dc03ce9d68eda47ec3de8d39de9633d Mon Sep 17 00:00:00 2001 From: "Vidhin Mehta (OpenERP)" Date: Mon, 17 Oct 2011 18:51:16 +0530 Subject: [PATCH 037/163] [IMP]implement code for save and move functionality in view editor. bzr revid: vme@tinyerp.com-20111017132116-rntmapdk4g043gpa --- addons/web/static/src/js/view_editor.js | 41 ++++++++++++++++++++++--- 1 file changed, 37 insertions(+), 4 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index d42470003b6..5fadfdaa289 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -95,7 +95,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ var p_list = parent_list.slice(1); if (val.child_id.length != 0) { _.each(val.child_id, function(val, key) { - if (val.id==check_id) { + if (val.id == check_id) { if (p_list.length!=0) { self.save_object(val, p_list, child_obj_list); } else { @@ -144,18 +144,21 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ get_data: function() { var self = this; + var view_arch_list = []; var view_id =(($("input[name='radiogroup']:checked").parent()).parent()).attr('data-id'); var ve_dataset = new openerp.web.DataSet(this, 'ir.ui.view'); ve_dataset.read_ids([parseInt(view_id)], ['arch'], function (arch) { one_object = self.parse_xml(arch[0].arch,view_id); - one_object.arch = arch[0].arch; + view_arch_list.push({"view_id" : view_id, "arch" : arch[0].arch}); dataset = new openerp.web.DataSetSearch(self, 'ir.ui.view', null, null); dataset.read_slice([], {domain : [['inherit_id','=', parseInt(view_id)]]}, function (result) { _.each(result, function(res) { + view_arch_list.push({"view_id":res.id,"arch":res.arch}); self.inherit_view(one_object, res); }); return self.edit_view({"main_object": one_object, - "parent_child_id": self.parent_child_list(one_object, [])}); + "parent_child_id": self.parent_child_list(one_object, []), + "arch": view_arch_list}); }); }); }, @@ -226,7 +229,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ var main_list = _.flatten(element.att_list); return _.include(main_list, check[0]); }); - if(list_1 != 0){ + if(list_1.length != 0){ (check_list.length == 1)? obj = list_1[0] : check_list.shift(); } break; @@ -373,10 +376,39 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ $(last_tr).after(rec); }); } + var arch1 = one_object["arch"][0].arch; + root = $(arch1).filter(":first")[0]; + self.get_node(one_object["arch"][0].arch, + one_object['main_object'][0].child_id[0], + parseInt(id_tr), + one_object['main_object'][0].child_id[0].chld_id, level, one_object); break; } }); }, + get_node: function(arch, obj, id, child_list, level, one_object){ + var self = this; + var children_list = $(arch).children(); + if(obj.level <= level){ + if(id != obj.id){ + for(var i=0;i< children_list.length; i++){ + if(obj.child_id){var child_list = obj.child_id}; + + self.get_node(children_list[i], obj.child_id[i], id, child_list, level, one_object); + } + }else{ + var next = $(arch).next() + $(next).after(arch); + var index = _.indexOf(child_list,obj) + var re_insert_obj = child_list.splice(index,1); + child_list.splice(index+1, 0, re_insert_obj[0]); + var p = $(arch).parents(); + one_object["arch"][0].arch = p[p.length-1]; + utfstring = unescape(encodeURIComponent(p)); + return; + } + } + }, on_expand: function(self){ var level = parseInt($(self).closest("tr[id^='viewedit-']").attr('level')); var cur_tr = $(self).closest("tr[id^='viewedit-']"); @@ -390,6 +422,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ }, on_collapse: function(self, parent_child_id, id, main_object) { var id = self.id.split('-')[1]; + var datas = _.detect(parent_child_id,function(res) { return res.key == id; }); From 455aa3879f98c10f191a2847b93d3fdc8f3babc9 Mon Sep 17 00:00:00 2001 From: "Bharat (OpenERP)" Date: Tue, 18 Oct 2011 11:17:29 +0530 Subject: [PATCH 038/163] [FIX] account : Added domain in account/board_account_view.xml in order to show the invoices that are in pro-forma state in Account Dashboard lp bug: https://launchpad.net/bugs/876481 fixed bzr revid: bde@tinyerp.com-20111018054729-v576zaphxmxzpsez --- addons/account/board_account_view.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account/board_account_view.xml b/addons/account/board_account_view.xml index e5b262c07f9..1ffcdec1d41 100644 --- a/addons/account/board_account_view.xml +++ b/addons/account/board_account_view.xml @@ -40,7 +40,7 @@ - + From ebcad72bcd72d83f077568ad51ef8727d9a0a2db Mon Sep 17 00:00:00 2001 From: "Vidhin Mehta (OpenERP)" Date: Wed, 19 Oct 2011 15:20:44 +0530 Subject: [PATCH 039/163] [imp]implement code for xml saving and moving element of xml. bzr revid: vme@tinyerp.com-20111019095044-1z54rlklwlkvbsqq --- addons/web/static/src/js/view_editor.js | 41 +++++++++++++++---------- 1 file changed, 25 insertions(+), 16 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index 5fadfdaa289..ccf0e4f75d6 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -301,7 +301,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } }); $("img[id^='side-']").click(function() { - var side = $(this).closest("tr[id^='viewedit-']") + var side = $(this).closest("tr[id^='viewedit-']"); var id_tr = (side.attr('id')).split('-')[1]; var img = side.find("img[id='parentimg-"+id_tr+"']").attr('src'); ; var level = side.attr('level'); @@ -376,38 +376,47 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ $(last_tr).after(rec); }); } + var arch1 = one_object["arch"][0].arch; root = $(arch1).filter(":first")[0]; self.get_node(one_object["arch"][0].arch, one_object['main_object'][0].child_id[0], parseInt(id_tr), - one_object['main_object'][0].child_id[0].chld_id, level, one_object); + one_object['main_object'][0].child_id[0].chld_id, level , + one_object["arch"][0].view_id); break; } }); }, - get_node: function(arch, obj, id, child_list, level, one_object){ + get_node: function(arch, obj, id, child_list, level, view_id){ var self = this; var children_list = $(arch).children(); if(obj.level <= level){ - if(id != obj.id){ + if(id == obj.id){ + var next = $(arch).next() + $(next).after(arch); + var parent = $(arch).parents(); + parent = parent[parent.length-1]; + var convert_to_utf = ""; + var s = new XMLSerializer(); + var stream = { + write : function(string) + {convert_to_utf = convert_to_utf + string + "";} + }; + s.serializeToStream(parent, stream, "UTF-8"); + convert_to_utf = convert_to_utf.replace('xmlns="http://www.w3.org/1999/xhtml"', ""); + convert_to_utf = '' + convert_to_utf; + dataset = new openerp.web.DataSet(this, 'ir.ui.view'); + dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ + }); + }else{ for(var i=0;i< children_list.length; i++){ if(obj.child_id){var child_list = obj.child_id}; - - self.get_node(children_list[i], obj.child_id[i], id, child_list, level, one_object); + self.get_node(children_list[i], obj.child_id[i], id, child_list, level, view_id); } - }else{ - var next = $(arch).next() - $(next).after(arch); - var index = _.indexOf(child_list,obj) - var re_insert_obj = child_list.splice(index,1); - child_list.splice(index+1, 0, re_insert_obj[0]); - var p = $(arch).parents(); - one_object["arch"][0].arch = p[p.length-1]; - utfstring = unescape(encodeURIComponent(p)); - return; } } + }, on_expand: function(self){ var level = parseInt($(self).closest("tr[id^='viewedit-']").attr('level')); From a6074e08d5c047d451d8b865c5b24634376fd122 Mon Sep 17 00:00:00 2001 From: "Atik Agewan (OpenERP)" Date: Wed, 19 Oct 2011 16:19:57 +0530 Subject: [PATCH 040/163] [IMP] mrp_repair:use company wise warehouse id bzr revid: aag@tinyerp.com-20111019104957-q9mqc8g9bwyve5tw --- addons/mrp_repair/mrp_repair.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index f8d77ea8224..023c91a54b0 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -686,11 +686,12 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): # TOCHECK: Find stock location for user's company warehouse or # repair order's company's warehouse (company_id field is added in fix of lp:831583) company_id = self.pool.get('res.company')._company_default_get(cr, uid, 'mrp.repair', context=context) - warehouse_ids = warehouse_obj.search(cr, uid, [], context=context) + warehouse_ids = warehouse_obj.search(cr, uid, [('company_id','=',company_id)], context=context) + stock_id = False if warehouse_ids: stock_id = warehouse_obj.browse(cr, uid, warehouse_ids[0], context=context).lot_stock_id.id to_invoice = (guarantee_limit and datetime.strptime(guarantee_limit, '%Y-%m-%d') < datetime.now()) - + return {'value': { 'to_invoice': to_invoice, 'location_id': stock_id, From 0101378e100d6cdb6c9242c00caa01bd63d20db4 Mon Sep 17 00:00:00 2001 From: "Vidhin Mehta (OpenERP)" Date: Thu, 20 Oct 2011 18:47:27 +0530 Subject: [PATCH 041/163] [IMP]implement code for get view according to element moving from db. bzr revid: vme@tinyerp.com-20111020131727-ks0awx1z18g0ytf0 --- addons/web/static/src/js/view_editor.js | 110 +++++++++++++++--------- 1 file changed, 69 insertions(+), 41 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index ccf0e4f75d6..a645593f437 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -46,7 +46,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ //to do }, "Edit": function(){ - self.xml_id = 0 ; + self.xml_id=0; self.get_data(); }, "Close": function(){ @@ -80,9 +80,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ if (attrs.nodeName != "position") { obj.att_list.push( [attrs.nodeName,attrs.nodeValue] ); } - }); - render_name+= ">"; }); obj.name = render_name; @@ -109,7 +107,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } }, - xml_node_create: function(xml, root, parent_list, parent_id, main_object){ + xml_node_create: function(xml, root, parent_list, parent_id, main_object ){ var self = this; var child_obj_list = []; var children_list = $(xml).filter(root).children(); @@ -284,7 +282,6 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ this.dialog.$element.html(QWeb.render('view_editor', { 'data': one_object['main_object'], })); - $("tr[id^='viewedit-']").click(function() { $("tr[id^='viewedit-']").removeClass('ui-selected'); $(this).addClass('ui-selected'); @@ -304,12 +301,23 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ var side = $(this).closest("tr[id^='viewedit-']"); var id_tr = (side.attr('id')).split('-')[1]; var img = side.find("img[id='parentimg-"+id_tr+"']").attr('src'); ; - var level = side.attr('level'); + var level = parseInt(side.attr('level')); var list_shift =[]; var last_tr; var cur_tr = side; list_shift.push(side); var next_tr; + var ls = side; + var view_id; + var view_xml_id; + while(1){ + ls = ls.prev(); + if(($(ls).find('a').text()).search("view_id") != -1 && parseInt(ls.attr('level')) < level){ + view_id = parseInt(($(ls).find('a').text()).replace(/[^0-9]+/g,'')); + view_xml_id = (ls.attr('id')).split('-')[1]; + break; + } + } switch (this.id) { case "side-add": break; @@ -320,7 +328,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ case "side-up": while (1) { var prev_tr = cur_tr.prev(); - if(level >= prev_tr.attr('level') || prev_tr.length == 0) { + if(level >= parseInt(prev_tr.attr('level')) || prev_tr.length == 0) { last_tr = prev_tr; break; } @@ -329,7 +337,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ if (img) { while (1) { next_tr = side.next(); - if (next_tr.attr('level') <= level || next_tr.length == 0) { + if ( parseInt(next_tr.attr('level')) <= level || next_tr.length == 0) { break; } else { list_shift.push(next_tr); @@ -337,7 +345,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } } } - if (last_tr.length != 0 && last_tr.attr('level') == level) { + if (last_tr.length != 0 && parseInt(last_tr.attr('level')) == level) { _.each(list_shift, function(rec) { $(last_tr).before(rec); }); @@ -347,7 +355,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ if (img) { while (1) { next_tr = cur_tr.next(); - if (next_tr.attr('level') <= level || next_tr.length == 0) { + if ( parseInt(next_tr.attr('level')) <= level || next_tr.length == 0) { last_tr = next_tr; break; } else { @@ -359,7 +367,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ else { last_tr = cur_tr.next(); } - if (last_tr.length != 0 && last_tr.attr('level') == level) { + if (last_tr.length != 0 && parseInt(last_tr.attr('level')) == level) { var last_tr_id = (last_tr.attr('id')).split('-')[1]; img = last_tr.find("img[id='parentimg-" + last_tr_id + "']").attr('src'); if (img) { @@ -375,48 +383,69 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ _.each(list_shift, function(rec) { $(last_tr).after(rec); }); + self.save_move_arch(one_object, view_id, view_xml_id, id_tr, level); } - - var arch1 = one_object["arch"][0].arch; - root = $(arch1).filter(":first")[0]; - self.get_node(one_object["arch"][0].arch, - one_object['main_object'][0].child_id[0], - parseInt(id_tr), - one_object['main_object'][0].child_id[0].chld_id, level , - one_object["arch"][0].view_id); break; } }); }, - get_node: function(arch, obj, id, child_list, level, view_id){ + save_move_arch: function(one_object, view_id, view_xml_id, id_tr, level){ var self = this; - var children_list = $(arch).children(); - if(obj.level <= level){ - if(id == obj.id){ - var next = $(arch).next() - $(next).after(arch); - var parent = $(arch).parents(); - parent = parent[parent.length-1]; - var convert_to_utf = ""; - var s = new XMLSerializer(); - var stream = { - write : function(string) - {convert_to_utf = convert_to_utf + string + "";} - }; - s.serializeToStream(parent, stream, "UTF-8"); - convert_to_utf = convert_to_utf.replace('xmlns="http://www.w3.org/1999/xhtml"', ""); - convert_to_utf = '' + convert_to_utf; - dataset = new openerp.web.DataSet(this, 'ir.ui.view'); - dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ + var arch = _.detect(one_object['arch'],function(element){ + return element.view_id == view_id; + }); + var obj = self.get_view_object(view_xml_id, one_object['main_object'], []); + return self.get_node(arch.arch, obj[0].child_id[0], parseInt(id_tr), [], parseInt(level), + parseInt(view_id), arch); + }, + get_view_object: function(view_xml_id, one_object,result){ + var self = this; + if(result.length==0){ + var check = _.detect(one_object , function(obj){ + return view_xml_id==obj.id; }); + if(check){result.push(check);}; + _.each(one_object, function(obj){ + self.get_view_object(view_xml_id, obj.child_id, result); + }); + } + return result; + }, + get_node: function(arch1, obj, id, child_list, level, view_id, arch){ + var self = this; + console.log(obj.id,id); + var children_list = $(arch1).children(); + if(obj.level <= level){ + if(parseInt(id) == obj.id){ + var next = $(arch1).next() + $(next).after(arch1); + var parent = $(arch1).parents(); + console.log(id,"--------",obj.id); + console.log(next,"========",arch1); + parent = parent[parent.length-1]; + var convert_to_utf = ""; + var s = new XMLSerializer(); + var stream = { + write : function(string) + {convert_to_utf = convert_to_utf + string + "";} + }; + var index = _.indexOf(child_list,obj) + var re_insert_obj = child_list.splice(index,1); + child_list.splice(index+1, 0, re_insert_obj[0]); + s.serializeToStream(parent, stream, "UTF-8"); + convert_to_utf = convert_to_utf.replace('xmlns="http://www.w3.org/1999/xhtml"', ""); + convert_to_utf = '' + convert_to_utf; + arch.arch = convert_to_utf; + dataset = new openerp.web.DataSet(this, 'ir.ui.view'); + dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ + }); }else{ for(var i=0;i< children_list.length; i++){ if(obj.child_id){var child_list = obj.child_id}; - self.get_node(children_list[i], obj.child_id[i], id, child_list, level, view_id); + self.get_node(children_list[i], obj.child_id[i], id, child_list, level, view_id, arch); } } } - }, on_expand: function(self){ var level = parseInt($(self).closest("tr[id^='viewedit-']").attr('level')); @@ -431,7 +460,6 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ }, on_collapse: function(self, parent_child_id, id, main_object) { var id = self.id.split('-')[1]; - var datas = _.detect(parent_child_id,function(res) { return res.key == id; }); From bbd8f2dc258720ab0ab40b87227f83cb1bb51afa Mon Sep 17 00:00:00 2001 From: Geoff Gardiner <> Date: Thu, 20 Oct 2011 18:51:45 +0530 Subject: [PATCH 042/163] [FIX] : [6.1 RC1] installation labels very poor English lp bug: https://launchpad.net/bugs/878149 fixed bzr revid: bde@tinyerp.com-20111020132145-kry8nhxw0j2g2n03 --- addons/account_anglo_saxon/__openerp__.py | 2 +- addons/account_followup/__openerp__.py | 2 +- addons/hr_attendance/__openerp__.py | 2 +- addons/hr_attendance/hr_attendance_view.xml | 10 +++++----- addons/hr_contract/__openerp__.py | 2 +- addons/hr_holidays/__openerp__.py | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/addons/account_anglo_saxon/__openerp__.py b/addons/account_anglo_saxon/__openerp__.py index 8cf6a37c3fc..52ec0588e88 100644 --- a/addons/account_anglo_saxon/__openerp__.py +++ b/addons/account_anglo_saxon/__openerp__.py @@ -19,7 +19,7 @@ ############################################################################## { - "name" : "Anglo-Saxon Accouting", + "name" : "Anglo-Saxon Accounting", "version" : "1.2", "author" : "OpenERP SA, Veritos", "website" : "http://tinyerp.com - http://veritos.nl", diff --git a/addons/account_followup/__openerp__.py b/addons/account_followup/__openerp__.py index ca6321d5672..3f794682e06 100644 --- a/addons/account_followup/__openerp__.py +++ b/addons/account_followup/__openerp__.py @@ -20,7 +20,7 @@ ############################################################################## { - 'name': 'Followups Management', + 'name': 'Followup Management', 'version': '1.0', 'category': 'Accounting & Finance', 'complexity': "normal", diff --git a/addons/hr_attendance/__openerp__.py b/addons/hr_attendance/__openerp__.py index 3d945910144..5f0054c3634 100644 --- a/addons/hr_attendance/__openerp__.py +++ b/addons/hr_attendance/__openerp__.py @@ -21,7 +21,7 @@ { - 'name': 'Attendances', + 'name': 'Attendance', 'version': '1.1', 'category': 'Human Resources', 'complexity': "easy", diff --git a/addons/hr_attendance/hr_attendance_view.xml b/addons/hr_attendance/hr_attendance_view.xml index 7a65ce7f88c..a264f9c0331 100644 --- a/addons/hr_attendance/hr_attendance_view.xml +++ b/addons/hr_attendance/hr_attendance_view.xml @@ -50,7 +50,7 @@ search - + @@ -68,7 +68,7 @@ - Attendances + Attendance hr.attendance form tree,form @@ -79,7 +79,7 @@ - + @@ -116,8 +116,8 @@ - diff --git a/addons/hr_contract/__openerp__.py b/addons/hr_contract/__openerp__.py index a0d303383f7..febc29a89c4 100644 --- a/addons/hr_contract/__openerp__.py +++ b/addons/hr_contract/__openerp__.py @@ -21,7 +21,7 @@ { - 'name': "Employee's Contracts", + 'name': "Employee Contracts", 'version': '1.0', 'category': 'Human Resources', 'complexity': "easy", diff --git a/addons/hr_holidays/__openerp__.py b/addons/hr_holidays/__openerp__.py index 563bb409b41..ec12b884201 100644 --- a/addons/hr_holidays/__openerp__.py +++ b/addons/hr_holidays/__openerp__.py @@ -21,7 +21,7 @@ { - "name": "Leaves Management", + "name": "Leave Management", "version": "1.5", "author": ['OpenERP SA', 'Axelor'], "category": "Human Resources", From 4acc77df77a104412de0642be78aceccec3e80af Mon Sep 17 00:00:00 2001 From: "Divyesh Makwana (Open ERP)" Date: Fri, 21 Oct 2011 17:09:58 +0530 Subject: [PATCH 043/163] [Fix]Point Of Sale : Point of sale can not install with Add More fearure Wizard lp bug: https://launchpad.net/bugs/877136 fixed bzr revid: mdi@tinyerp.com-20111021113958-jjxwmhgnlxton7gf --- addons/base_setup/base_setup.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/base_setup/base_setup.py b/addons/base_setup/base_setup.py index c11bb273ff0..59adf25e015 100644 --- a/addons/base_setup/base_setup.py +++ b/addons/base_setup/base_setup.py @@ -39,7 +39,7 @@ DEFAULT_MODULES = { 'Accounting & Finance' : ['account'], 'Purchase Management' : ['purchase'], 'Human Resources' : ['hr',], - 'Point of Sales' : ['pos',], + 'Point of Sales' : ['point_of_sale',], 'Marketing' : ['marketing',], } @@ -58,7 +58,7 @@ class base_setup_installer(osv.osv_memory): if fields is None: fields = {} - fields = {} + fields = {} category_proxy = self.pool.get('ir.module.category') domain = [('parent_id', '=', False), ('name', '!=', 'Uncategorized'), @@ -389,14 +389,14 @@ class user_preferences_config(osv.osv_memory): ('extended','Extended')], 'Interface', required=True, help= "If you use OpenERP for the first time we strongly advise you to select the simplified interface, which has less features but is easier. You can always switch later from the user preferences." ), 'menu_tips': fields.boolean('Display Tips', help="Check out this box if you want to always display tips on each menu action"), - + } _defaults={ 'view' : lambda self,cr,uid,*args: self.pool.get('res.users').browse(cr, uid, uid).view or 'simple', 'context_lang' : 'en_US', 'menu_tips' : True } - + def default_get(self, cr, uid, fields, context=None): if context is None: context = {} From d417951b98b51850005ced499c557cdce86e0c08 Mon Sep 17 00:00:00 2001 From: "Kirti Savalia (OpenERP)" Date: Fri, 21 Oct 2011 17:35:35 +0530 Subject: [PATCH 044/163] [ADD]: new view for Unrealized Gains and losses bzr revid: ksa@tinyerp.com-20111021120535-6zq4qwyg7zpl5rle --- addons/account/account.py | 6 ++++++ addons/account/account_menuitem.xml | 1 + addons/account/account_view.xml | 31 +++++++++++++++++++++++++++++ 3 files changed, 38 insertions(+) diff --git a/addons/account/account.py b/addons/account/account.py index 95c9b9f7b71..48d32e2aca5 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -418,6 +418,12 @@ class account_account(osv.osv): 'balance': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Balance', multi='balance'), 'credit': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Credit', multi='balance'), 'debit': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Debit', multi='balance'), +# 'foreign_balance': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Debit', multi='balance'), + 'foreign_balance': fields.char('Foreign Balance', size=10), + 'adjusted_balance': fields.char('Adjusted Balance', size=10), + 'gain_loss_unrealized_balance':fields.char('Unrealized Gain Loss Balance', size=10), +# 'adjusted_balance': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Debit', multi='balance'), +# 'gain_loss_unrealized_balance': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Debit', multi='balance'), 'reconcile': fields.boolean('Allow Reconciliation', help="Check this box if this account allows reconciliation of journal items."), 'shortcut': fields.char('Shortcut', size=12), 'tax_ids': fields.many2many('account.tax', 'account_account_tax_default_rel', diff --git a/addons/account/account_menuitem.xml b/addons/account/account_menuitem.xml index 89538603ae7..367442b7fc6 100644 --- a/addons/account/account_menuitem.xml +++ b/addons/account/account_menuitem.xml @@ -43,6 +43,7 @@ + [('parent_id','=',False)]
+ + account.account.tree1 + account.account + tree + 21 + + + + + + + + + + + + + + + Unrealized Gains and losses + account.account + tree + + [('currency_id','!=',False)] + + + + + + +jQuery MD5 Plugin Tests + + + +

jQuery MD5 Plugin Tests

+

+
+

+
    + + + + + + + \ No newline at end of file diff --git a/addons/web/static/lib/jquery.MD5/tests/tests.js b/addons/web/static/lib/jquery.MD5/tests/tests.js new file mode 100644 index 00000000000..ab70f2f991b --- /dev/null +++ b/addons/web/static/lib/jquery.MD5/tests/tests.js @@ -0,0 +1,57 @@ +/* + * jQuery MD5 Plugin Tests 1.1 + * https://github.com/blueimp/jQuery-MD5 + * + * Copyright 2010, Sebastian Tschan + * https://blueimp.net + * + * Licensed under the MIT license: + * http://creativecommons.org/licenses/MIT/ + */ + +/*global jQuery, module, test, strictEqual */ + +(function ($) { + 'use strict'; + + module('Hex-encoded MD5'); + + test('Creating hex-encoded MD5 hash of an ASCII value', function () { + strictEqual($.md5('value'), '2063c1608d6e0baf80249c42e2be5804'); + }); + + test('Creating hex-encoded MD5 hash of an UTF-8 value', function () { + strictEqual($.md5('日本'), '4dbed2e657457884e67137d3514119b3'); + }); + + module('Hex-encoded HMAC-MD5'); + + test('Creating hex-encoded HMAC-MD5 hash of an ASCII value and key', function () { + strictEqual($.md5('value', 'key'), '01433efd5f16327ea4b31144572c67f6'); + }); + + test('Creating hex-encoded HMAC-MD5 hash of an UTF-8 value and key', function () { + strictEqual($.md5('日本', '日本'), 'c78b8c7357926981cc04740bd3e9d015'); + }); + + module('Raw MD5'); + + test('Creating raw MD5 hash of an ASCII value', function () { + strictEqual($.md5('value', null, true), ' c\xc1`\x8dn\x0b\xaf\x80$\x9cB\xe2\xbeX\x04'); + }); + + test('Creating raw MD5 hash of an UTF-8 value', function () { + strictEqual($.md5('日本', null, true), 'M\xbe\xd2\xe6WEx\x84\xe6q7\xd3QA\x19\xb3'); + }); + + module('Raw HMAC-MD5'); + + test('Creating raw HMAC-MD5 hash of an ASCII value and key', function () { + strictEqual($.md5('value', 'key', true), '\x01C>\xfd_\x162~\xa4\xb3\x11DW,g\xf6'); + }); + + test('Creating raw HMAC-MD5 hash of an UTF-8 value and key', function () { + strictEqual($.md5('日本', '日本', true), '\xc7\x8b\x8csW\x92i\x81\xcc\x04t\x0b\xd3\xe9\xd0\x15'); + }); + +}(typeof jQuery === 'function' ? jQuery : this)); \ No newline at end of file From c68d85140742ff1090175e64815ffa09f2f77104 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 10:37:43 +0200 Subject: [PATCH 068/163] [IMP] Removed hard-coded AMIGrAve's face from kanban view. Compute gravatar url using md5. bzr revid: fme@openerp.com-20111025083743-d9g90sy1g9cx2ueg --- addons/web_kanban/static/src/js/kanban.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index 72df590fbf4..761952d5af2 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -69,7 +69,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ }, kanban_gravatar: function(email, size) { size = size || 22; - var email_md5 = '2eb60ad22dadcf4dc456b28390a80268'; + var email_md5 = $.md5(email); return 'http://www.gravatar.com/avatar/' + email_md5 + '.png?s=' + size; }, transform_qweb_template: function(node) { From 55ad46220db83d2f5d6dd86d243d0d9843b74511 Mon Sep 17 00:00:00 2001 From: "Yogesh (OpenERP)" Date: Tue, 25 Oct 2011 14:19:51 +0530 Subject: [PATCH 069/163] [IMP] improve css and view. bzr revid: ysa@tinyerp.com-20111025084951-0ty7vt1kfw0nrykr --- addons/web/static/src/css/base.css | 26 +++++++++++--- addons/web/static/src/xml/base.xml | 54 +++++++++++++++--------------- 2 files changed, 49 insertions(+), 31 deletions(-) diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index 34ec885b2a9..88d419c4059 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -1410,12 +1410,30 @@ ul.oe-arrow-list li.oe-arrow-list-selected .oe-arrow-list-after { border-color: rgba(0,0,0,0); border-left-color: #B5B9FF; } -.openerp .view_editor{ +.openerp .oe_view_editor { + border-collapse: collapse; + padding: 0; + align: left; + width: 100%; +} +.openerp .oe_view_editor_colum{ font-size: 90%; font-weight: normal; - height : 10%; padding: 0; border-bottom: 1px solid #CFCCCC; } - - +.openerp .oe_view_editor_row:hover{ + background-color: #F3F3F3; +} +.openerp .oe_view_editor_tree_grid{ + text-align: left; + white-space: nowrap; + border-collapse: collapse; + width: 100%; +} +.openerp .oe_view_editor_tree_grid a:hover { + color: blue; +} +.openerp .oe_view_editor_tree_grid a { + display: block; +} diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml index 27a99f61c05..323854fa7a3 100644 --- a/addons/web/static/src/xml/base.xml +++ b/addons/web/static/src/xml/base.xml @@ -1279,17 +1279,17 @@ - +
    - - - + + - </tr><tr> From 125ce4ec850062c2df619ac789067e3bd666facd Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Fri, 28 Oct 2011 10:50:51 +0200 Subject: [PATCH 145/163] [FIX] on a button action, ListView should send the content of the corresponding record as (evaluation) context also needs to set active_id, and let's throw active_ids and active_model in for the same price lp bug: https://launchpad.net/bugs/881301 fixed bzr revid: xmo@openerp.com-20111028085051-p49564vmrozkr1fr --- addons/web/static/src/js/view_list.js | 30 +++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/addons/web/static/src/js/view_list.js b/addons/web/static/src/js/view_list.js index 0db60c72c07..e891a6c7db7 100644 --- a/addons/web/static/src/js/view_list.js +++ b/addons/web/static/src/js/view_list.js @@ -524,6 +524,17 @@ openerp.web.ListView = openerp.web.View.extend( /** @lends openerp.web.ListView# return field.name === name; }); if (!action) { return; } + + var c = new openerp.web.CompoundContext(); + c.set_eval_context(_.extend({ + active_id: id, + active_ids: [id], + active_model: this.dataset.model + }, this.records.get(id).toContext())); + if (action.context) { + c.add(action.context); + } + action.context = c; this.do_execute_action(action, this.dataset, id, callback); }, /** @@ -1446,6 +1457,25 @@ var Record = openerp.web.Class.extend(/** @lends Record# */{ } return {data: form_data}; + }, + /** + * Converts the current record to a format expected by context evaluations + * (identical to record.attributes, except m2o fields are their integer + * value rather than a pair) + */ + toContext: function () { + var output = {}, attrs = this.attributes; + for(var k in attrs) { + var val = attrs[k]; + if (typeof val !== 'object') { + output[k] = val; + } else if (val instanceof Array) { + output[k] = val[0]; + } else { + throw new Error("Can't convert value " + val + " to context"); + } + } + return output; } }); Record.include(Events); From 4df4d335e60f0d2e8d71e07f8dd17addc63bac9b Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Fri, 28 Oct 2011 10:52:12 +0200 Subject: [PATCH 146/163] [IMP] remove a few object trailing commas bzr revid: xmo@openerp.com-20111028085212-vjpb1oejd8cv24mt --- addons/web/static/src/js/chrome.js | 6 +++--- addons/web/static/src/js/views.js | 10 +++++----- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index 484c58ef2c4..22c2b0ba2ea 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -29,11 +29,11 @@ openerp.web.Notification = openerp.web.Widget.extend(/** @lends openerp.web.Not warn: function(title, text) { this.$element.notify('create', 'oe_notification_alert', { title: title, - text: text, + text: text }, { - expires: false, + expires: false }); - }, + } }); diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index d243fa55230..4e8f6d30022 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -569,7 +569,7 @@ session.web.Sidebar = session.web.Widget.extend({ { label: _t("Manage Views"), callback: this.call_default_on_sidebar, - title: _t("Manage views of the current object"), + title: _t("Manage views of the current object") }, { label: _t("Edit Workflow"), callback: this.call_default_on_sidebar, @@ -578,7 +578,7 @@ session.web.Sidebar = session.web.Widget.extend({ }, { label: _t("Customize Object"), callback: this.call_default_on_sidebar, - title: _t("Manage views of the current object"), + title: _t("Manage views of the current object") } ]); @@ -586,10 +586,10 @@ session.web.Sidebar = session.web.Widget.extend({ this.add_items('other', [ { label: _t("Import"), - callback: this.call_default_on_sidebar, + callback: this.call_default_on_sidebar }, { label: _t("Export"), - callback: this.call_default_on_sidebar, + callback: this.call_default_on_sidebar }, { label: _t("Translate"), callback: this.call_default_on_sidebar, @@ -629,7 +629,7 @@ session.web.Sidebar = session.web.Widget.extend({ var $section = $(session.web.qweb.render("Sidebar.section", { section_id: section_id, name: name, - classname: 'oe_sidebar_' + code, + classname: 'oe_sidebar_' + code })); $section.appendTo(this.$element.find('div.sidebar-actions')); this.sections[code] = $section; From 75b37008da5e145a060af3a188ce463543c9cdcc Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Fri, 28 Oct 2011 11:45:35 +0200 Subject: [PATCH 147/163] [fix] problem in function field not returning correctly all fields bzr revid: nicolas.vanhoren@openerp.com-20111028094535-4qgoj3eno3khdn8v --- addons/project_issue/project_issue.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/project_issue/project_issue.py b/addons/project_issue/project_issue.py index 5575eee71d8..228a899a640 100644 --- a/addons/project_issue/project_issue.py +++ b/addons/project_issue/project_issue.py @@ -92,8 +92,8 @@ class project_issue(crm.crm_case, osv.osv): res = {} for issue in self.browse(cr, uid, ids, context=context): + res[issue.id] = {} for field in fields: - res[issue.id] = {} duration = 0 ans = False hours = 0 From 0384b8bfbf551ae357ede89bf2b4c3d041a371ab Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Fri, 28 Oct 2011 12:39:57 +0200 Subject: [PATCH 149/163] [FIX] hr_timesheet_sheet: attendance state of an employee was sometimes not correctly stated on the timesheet.sheet when uid had more than one employee assigned. Removed useless and stupid code that was messing to find on which employee to check the attendance status, as it's given on the sheet. Replaced by a fields.related bzr revid: qdp-launchpad@openerp.com-20111028103957-nkekeqjuyn44phnv --- .../hr_timesheet_sheet/hr_timesheet_sheet.py | 21 +------------------ 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py index 5e0fc9a5b36..b6bfedf1328 100644 --- a/addons/hr_timesheet_sheet/hr_timesheet_sheet.py +++ b/addons/hr_timesheet_sheet/hr_timesheet_sheet.py @@ -143,25 +143,6 @@ class hr_timesheet_sheet(osv.osv): res[record[0]]['total_difference'] = record[3] return res - def _state_attendance(self, cr, uid, ids, name, args, context=None): - emp_obj = self.pool.get('hr.employee') - result = {} - link_emp = {} - emp_ids = [] - - for sheet in self.browse(cr, uid, ids, context=context): - result[sheet.id] = 'none' - emp_ids2 = emp_obj.search(cr, uid, - [('user_id', '=', sheet.user_id.id)], context=context) - if emp_ids2: - link_emp[emp_ids2[0]] = sheet.id - emp_ids.append(emp_ids2[0]) - for emp in emp_obj.browse(cr, uid, emp_ids, context=context): - if emp.id in link_emp: - sheet_id = link_emp[emp.id] - result[sheet_id] = emp.state - return result - def check_employee_attendance_state(self, cr, uid, sheet_id, context=None): ids_signin = self.pool.get('hr.attendance').search(cr,uid,[('sheet_id', '=', sheet_id),('action','=','sign_in')]) ids_signout = self.pool.get('hr.attendance').search(cr,uid,[('sheet_id', '=', sheet_id),('action','=','sign_out')]) @@ -286,7 +267,7 @@ class hr_timesheet_sheet(osv.osv): help=' * The \'Draft\' state is used when a user is encoding a new and unconfirmed timesheet. \ \n* The \'Confirmed\' state is used for to confirm the timesheet by user. \ \n* The \'Done\' state is used when users timesheet is accepted by his/her senior.'), - 'state_attendance' : fields.function(_state_attendance, type='selection', selection=[('absent', 'Absent'), ('present', 'Present'),('none','No employee defined')], string='Current Status'), + 'state_attendance' : fields.related('employee_id', 'state', type='selection', selection=[('absent', 'Absent'), ('present', 'Present')], string='Current Status'), 'total_attendance_day': fields.function(_total_day, string='Total Attendance', multi="_total_day"), 'total_timesheet_day': fields.function(_total_day, string='Total Timesheet', multi="_total_day"), 'total_difference_day': fields.function(_total_day, string='Difference', multi="_total_day"), From 04b619f7bb8339259b7d17b9ec90a71669f67c61 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Fri, 28 Oct 2011 14:26:08 +0200 Subject: [PATCH 150/163] [FIX] incorrect rendering of hidden graphs dhtmlx is apparently entirely unable to render invisible graphs (hidden via display:none on itself or a parent, visibility: hidden does not trouble it), it apparently uses the actual size of the graph container in its rendering and display:none elements have no dimensions. A graph in an o2m in a secondary tab gets rendered in display:none environment yielding a completely broken and unusable graph. Worked around this by deferring the graph's rendering until visibility: the actual graph rendering is stored in a function which is periodically deferred (via setTimeout) until we know the graph view is visible (meaning its root element isn't invisible anymore). Ideally, we'd use a library which is not broken instead... The check periodicity is currently set to 100ms, seems sufficiently reactive for our purposes. lp bug: https://launchpad.net/bugs/880789 fixed bzr revid: xmo@openerp.com-20111028122608-6hyi7lqpr3jh9rw3 --- addons/web_graph/static/src/js/graph.js | 179 ++++++++++++++---------- 1 file changed, 105 insertions(+), 74 deletions(-) diff --git a/addons/web_graph/static/src/js/graph.js b/addons/web_graph/static/src/js/graph.js index bac147b1a91..33321da970a 100644 --- a/addons/web_graph/static/src/js/graph.js +++ b/addons/web_graph/static/src/js/graph.js @@ -29,6 +29,14 @@ openerp.web_graph.GraphView = openerp.web.View.extend({ this.columns = []; this.group_field = null; this.is_loaded = $.Deferred(); + + this.renderer = null; + }, + stop: function () { + if (this.renderer) { + clearTimeout(this.renderer); + } + this._super(); }, do_show: function () { this.$element.show(); @@ -256,90 +264,113 @@ openerp.web_graph.GraphView = openerp.web.View.extend({ x_axis = abscissa_description; y_axis = ordinate_description; } - - var bar_chart = new dhtmlXChart({ - view: view_chart, - container: this.element_id+"-barchart", - value:"#"+group_list[0].group+"#", - gradient: "3d", - border: false, - width: 1024, - tooltip:{ - template: _.sprintf("#%s#, %s=#%s#", - this.abscissa, group_list[0].text, group_list[0].group) - }, - radius: 0, - color:group_list[0].color, - origin:0, - xAxis: x_axis, - yAxis: y_axis, - padding: { - left: 75 - }, - legend: { - values: group_list, - align:"left", - valign:"top", - layout: "x", - marker: { - type:"round", - width:12 - } + + var renderer = function () { + if (self.$element.is(':hidden')) { + self.renderer = setTimeout(renderer, 100); + return; } - }); - for (var m = 1; m Date: Mon, 31 Oct 2011 14:22:31 +0530 Subject: [PATCH 151/163] [Fix]fix browser issue of converting jquery dom to string. bzr revid: vme@tinyerp.com-20111031085231-kd32p1593xx1qxlt --- addons/web/static/src/js/view_editor.js | 47 ++++++++++++++++--------- 1 file changed, 30 insertions(+), 17 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index 7828c4366c9..b92654ea42f 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -56,6 +56,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ this.view_edit_dialog.open(); action_manager.appendTo(this.view_edit_dialog); action_manager.do_action(action); + }, check_attr: function(xml, tag, level) { var obj = new Object(); @@ -307,7 +308,8 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ var view_xml_id; while(1){ ls = ls.prev(); - if(($(ls).find('a').text()).search("view_id") != -1 && parseInt(ls.attr('level')) < level){ + if((self.edit_xml_dialog.$element.find(ls).find('a').text()).search("view_id") != -1 + && parseInt(ls.attr('level')) < level){ view_id = parseInt(($(ls).find('a').text()).replace(/[^0-9]+/g,'')); view_xml_id = (ls.attr('id')).split('-')[1]; break; @@ -342,7 +344,8 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } if (last_tr.length != 0 && parseInt(last_tr.attr('level')) == level - && ($(last_tr).find('a').text()).search("view_id") == -1) { + && + (self.edit_xml_dialog.$element.find(last_tr).find('a').text()).search("view_id") == -1) { _.each(list_shift, function(rec) { $(last_tr).before(rec); }); @@ -369,7 +372,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ var last_tr_id = (last_tr.attr('id')).split('-')[1]; img = last_tr.find("img[id='parentimg-" + last_tr_id + "']").attr('src'); if (img) { - this.edit_xml_dialog.$element.find("img[id='parentimg-" + last_tr_id + "']").attr('src', '/web/static/src/img/expand.gif'); + self.edit_xml_dialog.$element.find("img[id='parentimg-" + last_tr_id + "']").attr('src', '/web/static/src/img/expand.gif'); while (1) { var next_tr = last_tr.next(); if (next_tr.attr('level') <= level || next_tr.length == 0) break; @@ -379,7 +382,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } list_shift.reverse(); - if(($(side.next()).find('a').text()).search("view_id") == -1){ + if((self.edit_xml_dialog.$element.find(side.next()).find('a').text()).search("view_id") == -1){ _.each(list_shift, function(rec) { $(last_tr).after(rec); }); @@ -444,19 +447,15 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ child_list.splice(index-1, 0, re_insert_obj[0]); } parent = parent[parent.length-1]; - var convert_to_utf = ""; - var xml_serilalizer = new XMLSerializer(); - var stream = { - write : function(string) - {convert_to_utf = convert_to_utf + string + "";} - }; - xml_serilalizer.serializeToStream(parent, stream, "UTF-8"); - convert_to_utf = convert_to_utf.replace('xmlns="http://www.w3.org/1999/xhtml"', ""); - convert_to_utf = '' + convert_to_utf; - arch.arch = convert_to_utf; - dataset = new openerp.web.DataSet(this, 'ir.ui.view'); - dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ - }); + var convert_to_utf = self.xml2Str(parent); + if(convert_to_utf){ + convert_to_utf = convert_to_utf.replace('xmlns="http://www.w3.org/1999/xhtml"', ""); + convert_to_utf = '' + convert_to_utf; + arch.arch = convert_to_utf; + dataset = new openerp.web.DataSet(this, 'ir.ui.view'); + dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ + }); + } } if(obj.level <= level){ _.each(list_obj_xml, function(child_node){ @@ -465,6 +464,20 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } } }, + xml2Str: function(xmlNode) { + try { + return (new XMLSerializer()).serializeToString(xmlNode); + } + catch (e) { + try { + return xmlNode.xml; + } + catch (e) { + return false; + } + } + + }, on_expand: function(expand_img){ var level = parseInt($(expand_img).closest("tr[id^='viewedit-']").attr('level')); From 41ebcc4079a57cbb619e00cebdb75d792f2e386e Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Mon, 31 Oct 2011 11:27:52 +0100 Subject: [PATCH 152/163] [imp] added non editable implementation for o2m & m2m bzr revid: nicolas.vanhoren@openerp.com-20111031102752-qdsfzzj747h5yp1w --- addons/web/static/src/js/view_form.js | 28 +++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 6f499a0adf7..8955237ce39 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1955,6 +1955,9 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ self.load_views(); }); }, + is_readonly: function() { + return this.readonly || this.force_readonly; + }, load_views: function() { var self = this; @@ -1972,7 +1975,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ } if(view.view_type === "list") { view.options.selectable = self.multi_selection; - if (self.readonly) { + if (self.is_readonly()) { view.options.addable = null; view.options.deletable = null; } @@ -1997,10 +2000,10 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ this.viewmanager.on_controller_inited.add_last(function(view_type, controller) { if (view_type == "list") { controller.o2m = self; - if (self.readonly) + if (self.is_readonly()) controller.set_editable(false); } else if (view_type == "form") { - if (self.readonly) { + if (self.is_readonly()) { controller.on_toggle_readonly(); $(controller.$element.find(".oe_form_buttons")[0]).children().remove(); } @@ -2220,7 +2223,7 @@ openerp.web.form.One2ManyListView = openerp.web.ListView.extend({ }, do_activate_record: function(index, id) { var self = this; - if (self.o2m.readonly) + if (self.o2m.is_readonly) return; var pop = new openerp.web.form.FormOpenPopup(self.o2m.view); pop.show_element(self.o2m.field.relation, id, self.o2m.build_context(),{ @@ -2282,11 +2285,14 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ validate: function() { this.invalid = false; }, + is_readonly: function() { + return this.readonly || this.force_readonly; + }, load_view: function() { var self = this; this.list_view = new openerp.web.form.Many2ManyListView(this, this.dataset, false, { - 'addable': self.readonly ? null : 'Add', - 'deletable': self.readonly ? false : true, + 'addable': self.is_readonly() ? null : 'Add', + 'deletable': self.is_readonly() ? false : true, 'selectable': self.multi_selection }); this.list_view.m2m_field = this; @@ -3030,6 +3036,13 @@ openerp.web.form.widgets = new openerp.web.Registry({ 'binary': 'openerp.web.form.FieldBinaryFile', 'statusbar': 'openerp.web.form.FieldStatus' }); + +openerp.web.form.FieldMany2ManyReadonly = openerp.web.form.FieldMany2Many.extend({ + force_readonly: true +}); +openerp.web.form.FieldOne2ManyReadonly = openerp.web.form.FieldOne2Many.extend({ + force_readonly: true +}); openerp.web.form.readonly = openerp.web.form.widgets.clone({ 'char': 'openerp.web.form.FieldCharReadonly', 'email': 'openerp.web.form.FieldEmailReadonly', @@ -3040,6 +3053,9 @@ openerp.web.form.readonly = openerp.web.form.widgets.clone({ 'datetime': 'openerp.web.form.FieldCharReadonly', 'selection' : 'openerp.web.form.FieldSelectionReadonly', 'many2one': 'openerp.web.form.FieldMany2OneReadonly', + 'many2many' : 'openerp.web.form.FieldMany2ManyReadonly', + 'one2many' : 'openerp.web.form.FieldOne2ManyReadonly', + 'one2many_list' : 'openerp.web.form.FieldOne2ManyReadonly', 'boolean': 'openerp.web.form.FieldBooleanReadonly', 'float': 'openerp.web.form.FieldCharReadonly', 'integer': 'openerp.web.form.FieldCharReadonly', From 85012767c8b9d09ffdbe2a4f1496db24f3c8d27c Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Mon, 31 Oct 2011 11:43:04 +0100 Subject: [PATCH 153/163] [imp] allowed to click on an element of a readonly o2m to open it in a popup bzr revid: nicolas.vanhoren@openerp.com-20111031104304-b3ur1j34nqe4o674 --- addons/web/static/src/js/view_form.js | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 8955237ce39..a1dcd726127 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2223,8 +2223,6 @@ openerp.web.form.One2ManyListView = openerp.web.ListView.extend({ }, do_activate_record: function(index, id) { var self = this; - if (self.o2m.is_readonly) - return; var pop = new openerp.web.form.FormOpenPopup(self.o2m.view); pop.show_element(self.o2m.field.relation, id, self.o2m.build_context(),{ auto_write: false, @@ -2233,7 +2231,8 @@ openerp.web.form.One2ManyListView = openerp.web.ListView.extend({ read_function: function() { return self.o2m.dataset.read_ids.apply(self.o2m.dataset, arguments); }, - form_view_options: {'not_interactible_on_create':true} + form_view_options: {'not_interactible_on_create':true}, + readonly: self.o2m.is_readonly() }); pop.on_write.add(function(id, data) { self.o2m.dataset.write(id, data, {}, function(r) { @@ -2578,6 +2577,7 @@ openerp.web.form.FormOpenPopup = openerp.web.OldWidget.extend(/** @lends openerp * - read_function * - parent_view * - form_view_options + * - readonly */ show_element: function(model, row_id, context, options) { this.model = model; @@ -2617,7 +2617,13 @@ openerp.web.form.FormOpenPopup = openerp.web.OldWidget.extend(/** @lends openerp this.view_form.set_embedded_view(this.options.alternative_form_view); } this.view_form.appendTo(this.$element.find("#" + this.element_id + "_view_form")); + var once = $.Deferred().then(function() { + if (self.options.readonly) { + self.view_form.on_toggle_readonly(); + } + }); this.view_form.on_loaded.add_last(function() { + once.resolve(); var $buttons = self.view_form.$element.find(".oe_form_buttons"); $buttons.html(QWeb.render("FormOpenPopup.form.buttons")); var $nbutton = $buttons.find(".oe_formopenpopup-form-save"); @@ -2626,6 +2632,9 @@ openerp.web.form.FormOpenPopup = openerp.web.OldWidget.extend(/** @lends openerp self.stop(); }); }); + if (self.options.readonly) { + $nbutton.hide(); + } var $cbutton = $buttons.find(".oe_formopenpopup-form-close"); $cbutton.click(function() { self.stop(); From 0d75c597cd0f6b27e85b82779f61172ff66093a3 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Mon, 31 Oct 2011 11:54:44 +0100 Subject: [PATCH 154/163] [fix] potential problem with m2o bzr revid: nicolas.vanhoren@openerp.com-20111031105444-mjdgrhuylh146ryy --- addons/web/static/src/js/view_form.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index a1dcd726127..cd015bf1fe2 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1829,7 +1829,7 @@ openerp.web.form.FieldMany2One = openerp.web.form.Field.extend({ self.original_value = undefined; self._change_int_ext_value(rval); }; - if(typeof(value) === "number") { + if(!(typeof(value) instanceof Array)) { var dataset = new openerp.web.DataSetStatic(this, this.field.relation, self.build_context()); dataset.name_get([value], function(data) { real_set_value(data[0]); @@ -3000,7 +3000,7 @@ openerp.web.form.FieldMany2OneReadonly = openerp.web.form.FieldCharReadonly.exte var real_set_value = function(rval) { self.$element.find('div').text(rval ? rval[1] : ''); }; - if(typeof(value) === "number") { + if(!(typeof(value) instanceof Array)) { var dataset = new openerp.web.DataSetStatic( this, this.field.relation, self.build_context()); dataset.name_get([value], function(data) { From 499b2e033aea69e1059df442e45effaa9eea7491 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Mon, 31 Oct 2011 12:06:20 +0100 Subject: [PATCH 155/163] [fix] typo bzr revid: nicolas.vanhoren@openerp.com-20111031110620-b00p18d0ebckr4xt --- addons/web/static/src/js/view_form.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index cd015bf1fe2..aeddf2945d0 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1829,7 +1829,7 @@ openerp.web.form.FieldMany2One = openerp.web.form.Field.extend({ self.original_value = undefined; self._change_int_ext_value(rval); }; - if(!(typeof(value) instanceof Array)) { + if (value && !(value instanceof Array)) { var dataset = new openerp.web.DataSetStatic(this, this.field.relation, self.build_context()); dataset.name_get([value], function(data) { real_set_value(data[0]); @@ -3000,7 +3000,7 @@ openerp.web.form.FieldMany2OneReadonly = openerp.web.form.FieldCharReadonly.exte var real_set_value = function(rval) { self.$element.find('div').text(rval ? rval[1] : ''); }; - if(!(typeof(value) instanceof Array)) { + if (value && !(value instanceof Array)) { var dataset = new openerp.web.DataSetStatic( this, this.field.relation, self.build_context()); dataset.name_get([value], function(data) { From 16b9b4347709d3406b4e4281f25d8cb6dfe156cb Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Mon, 31 Oct 2011 12:09:37 +0100 Subject: [PATCH 156/163] [imp] modified many2one in readonly mode to be able to click on it to open a popup bzr revid: nicolas.vanhoren@openerp.com-20111031110937-den8gj0j5zwfflw3 --- addons/web/static/src/js/view_form.js | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index aeddf2945d0..0294f248978 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2632,13 +2632,14 @@ openerp.web.form.FormOpenPopup = openerp.web.OldWidget.extend(/** @lends openerp self.stop(); }); }); - if (self.options.readonly) { - $nbutton.hide(); - } var $cbutton = $buttons.find(".oe_formopenpopup-form-close"); $cbutton.click(function() { self.stop(); }); + if (self.options.readonly) { + $nbutton.hide(); + $cbutton.text(_t("Close")); + } self.view_form.do_show(); }); this.dataset.on_write.add(this.on_write); @@ -2998,7 +2999,15 @@ openerp.web.form.FieldMany2OneReadonly = openerp.web.form.FieldCharReadonly.exte self.update_dom(); self.on_value_changed(); var real_set_value = function(rval) { - self.$element.find('div').text(rval ? rval[1] : ''); + self.value = rval; + var div = $(self.$element.find('div')); + div.html(''); + var a = $(div.find("a")); + a.text(rval ? rval[1] : ''); + a.click(function() { + var pop = new openerp.web.form.FormOpenPopup(self.view); + pop.show_element(self.field.relation, self.value[0],self.build_context(), {readonly:true}); + }); }; if (value && !(value instanceof Array)) { var dataset = new openerp.web.DataSetStatic( From 04435177466d1caeb20936145b47777b9620ae70 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Mon, 31 Oct 2011 16:49:07 +0100 Subject: [PATCH 157/163] [fix] problem with m2o search popup, should not be multi-selectable bzr revid: nicolas.vanhoren@openerp.com-20111031154907-uf9way132l54n7lw --- addons/web/static/src/js/view_form.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 0294f248978..237199d5472 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2428,10 +2428,7 @@ openerp.web.form.SelectCreatePopup = openerp.web.OldWidget.extend(/** @lends ope this.searchview.stop(); } this.searchview = new openerp.web.SearchView(this, - this.dataset, false, { - "selectable": !this.options.disable_multiple_selection, - "deletable": false - }); + this.dataset, false, {}); this.searchview.on_search.add(function(domains, contexts, groupbys) { if (self.initial_ids) { self.do_search(domains.concat([[["id", "in", self.initial_ids]], self.domain]), @@ -2458,7 +2455,9 @@ openerp.web.form.SelectCreatePopup = openerp.web.OldWidget.extend(/** @lends ope }); self.view_list = new openerp.web.form.SelectCreateListView(self, self.dataset, false, - _.extend({'deletable': false}, self.options.list_view_options || {})); + _.extend({'deletable': false, + 'selectable': !self.options.disable_multiple_selection + }, self.options.list_view_options || {})); self.view_list.popup = self; self.view_list.appendTo($("#" + self.element_id + "_view_list")).pipe(function() { self.view_list.do_show(); From 3d22bb8b55d48e5ee8226f023555f003288b157a Mon Sep 17 00:00:00 2001 From: Launchpad Translations on behalf of openerp <> Date: Wed, 2 Nov 2011 05:05:06 +0000 Subject: [PATCH 158/163] Launchpad automatic translations update. bzr revid: launchpad_translations_on_behalf_of_openerp-20111031053342-z3epayy8yamdvd59 bzr revid: launchpad_translations_on_behalf_of_openerp-20111102045643-x5bniok5k0bav5f1 bzr revid: launchpad_translations_on_behalf_of_openerp-20111101051007-ckkd2x2dixj2lenq bzr revid: launchpad_translations_on_behalf_of_openerp-20111102050506-4162o2sku85ys9m3 --- addons/account/i18n/da.po | 29 +- addons/account_asset/i18n/da.po | 529 ++++++++++++++++++++++++++++ addons/base_calendar/i18n/da.po | 16 +- addons/idea/i18n/da.po | 18 +- addons/web/po/da.po | 4 +- addons/web/po/de.po | 4 +- addons/web/po/es.po | 4 +- addons/web/po/es_EC.po | 4 +- addons/web/po/et.po | 4 +- addons/web/po/fr.po | 4 +- addons/web/po/gl.po | 4 +- addons/web/po/it.po | 4 +- addons/web/po/nl_BE.po | 4 +- addons/web/po/sl.po | 4 +- addons/web_calendar/po/da.po | 4 +- addons/web_calendar/po/de.po | 4 +- addons/web_calendar/po/es.po | 4 +- addons/web_calendar/po/es_EC.po | 4 +- addons/web_calendar/po/et.po | 4 +- addons/web_calendar/po/fr.po | 4 +- addons/web_calendar/po/gl.po | 4 +- addons/web_calendar/po/it.po | 4 +- addons/web_calendar/po/nl_BE.po | 4 +- addons/web_calendar/po/sk.po | 4 +- addons/web_calendar/po/sl.po | 4 +- addons/web_dashboard/po/da.po | 4 +- addons/web_dashboard/po/de.po | 4 +- addons/web_dashboard/po/es.po | 4 +- addons/web_dashboard/po/es_EC.po | 4 +- addons/web_dashboard/po/et.po | 4 +- addons/web_dashboard/po/fr.po | 4 +- addons/web_dashboard/po/gl.po | 4 +- addons/web_dashboard/po/it.po | 4 +- addons/web_dashboard/po/nl_BE.po | 4 +- addons/web_dashboard/po/sk.po | 4 +- addons/web_dashboard/po/sl.po | 4 +- addons/web_default_home/po/da.po | 38 ++ addons/web_default_home/po/de.po | 38 ++ addons/web_default_home/po/es.po | 4 +- addons/web_default_home/po/es_EC.po | 38 ++ addons/web_default_home/po/et.po | 38 ++ addons/web_default_home/po/fr.po | 4 +- addons/web_default_home/po/gl.po | 4 +- addons/web_default_home/po/it.po | 38 ++ addons/web_default_home/po/nl_BE.po | 38 ++ addons/web_default_home/po/sk.po | 38 ++ addons/web_default_home/po/sl.po | 4 +- addons/web_diagram/po/da.po | 4 +- addons/web_diagram/po/de.po | 4 +- addons/web_diagram/po/es.po | 4 +- addons/web_diagram/po/es_EC.po | 4 +- addons/web_diagram/po/et.po | 4 +- addons/web_diagram/po/gl.po | 4 +- addons/web_diagram/po/it.po | 4 +- addons/web_diagram/po/nl_BE.po | 4 +- addons/web_diagram/po/sl.po | 4 +- addons/web_mobile/po/da.po | 4 +- addons/web_mobile/po/de.po | 4 +- addons/web_mobile/po/es.po | 4 +- addons/web_mobile/po/es_EC.po | 4 +- addons/web_mobile/po/et.po | 4 +- addons/web_mobile/po/fr.po | 4 +- addons/web_mobile/po/gl.po | 4 +- addons/web_mobile/po/it.po | 4 +- addons/web_mobile/po/nl_BE.po | 4 +- addons/web_mobile/po/sk.po | 4 +- addons/web_mobile/po/sl.po | 4 +- 67 files changed, 939 insertions(+), 143 deletions(-) create mode 100644 addons/account_asset/i18n/da.po create mode 100644 addons/web_default_home/po/da.po create mode 100644 addons/web_default_home/po/de.po create mode 100644 addons/web_default_home/po/es_EC.po create mode 100644 addons/web_default_home/po/et.po create mode 100644 addons/web_default_home/po/it.po create mode 100644 addons/web_default_home/po/nl_BE.po create mode 100644 addons/web_default_home/po/sk.po diff --git a/addons/account/i18n/da.po b/addons/account/i18n/da.po index d258fd10504..c01fc25b02c 100644 --- a/addons/account/i18n/da.po +++ b/addons/account/i18n/da.po @@ -8,14 +8,14 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2011-01-11 11:14+0000\n" -"PO-Revision-Date: 2010-11-22 07:21+0000\n" -"Last-Translator: Martin Pihl \n" +"PO-Revision-Date: 2011-11-01 21:03+0000\n" +"Last-Translator: OpenERP Danmark / Mikhael Saxtorph \n" "Language-Team: Danish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 05:05+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-02 04:56+0000\n" +"X-Generator: Launchpad (build 14214)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 @@ -39,8 +39,7 @@ msgstr "" msgid "" "You cannot remove/deactivate an account which is set as a property to any " "Partner." -msgstr "" -"Du kan ikke fjerne/deaktivere en konto som er sat til ejerskab af en Partner." +msgstr "Du kan ikke fjerne/deaktivere en konto som er tilknyttet en kontakt." #. module: account #: view:account.move.reconcile:0 @@ -131,7 +130,7 @@ msgstr "" #. module: account #: report:account.tax.code.entries:0 msgid "Accounting Entries-" -msgstr "Konto posteringer-" +msgstr "Posteringer" #. module: account #: code:addons/account/account.py:1291 @@ -328,6 +327,8 @@ msgid "" "Installs localized accounting charts to match as closely as possible the " "accounting needs of your company based on your country." msgstr "" +"Installerer lokal kontoplan, der passer så godt som muligt til jeres firmas " +"behov, baseret på land." #. module: account #: code:addons/account/wizard/account_move_journal.py:63 @@ -1749,7 +1750,7 @@ msgstr "" #. module: account #: sql_constraint:account.move.line:0 msgid "Wrong credit or debit value in accounting entry !" -msgstr "" +msgstr "Forkert kredit eller debet værdi i posteringerne!" #. module: account #: view:account.invoice.report:0 @@ -1851,7 +1852,7 @@ msgstr "" #: model:process.node,note:account.process_node_reconciliation0 #: model:process.node,note:account.process_node_supplierreconciliation0 msgid "Comparison between accounting and payment entries" -msgstr "" +msgstr "Sammenligning mellem bogførings- og betalingsindtastninger" #. module: account #: view:account.tax:0 @@ -2083,7 +2084,7 @@ msgstr "" #. module: account #: view:product.category:0 msgid "Accounting Properties" -msgstr "" +msgstr "Regnskab, egenskaber" #. module: account #: report:account.journal.period.print:0 @@ -2683,7 +2684,7 @@ msgstr "" #. module: account #: model:ir.ui.menu,name:account.menu_finance_accounting msgid "Financial Accounting" -msgstr "" +msgstr "Finans" #. module: account #: view:account.pl.report:0 @@ -3016,13 +3017,13 @@ msgstr "Indløb" #: model:ir.actions.act_window,name:account.action_account_installer #: view:wizard.multi.charts.accounts:0 msgid "Accounting Application Configuration" -msgstr "" +msgstr "Regnskabsmodulets konfigurering" #. module: account #: model:ir.actions.act_window,name:account.open_board_account #: model:ir.ui.menu,name:account.menu_board_account msgid "Accounting Dashboard" -msgstr "" +msgstr "Regnskab, overblik" #. module: account #: field:account.bank.statement,balance_start:0 @@ -6628,7 +6629,7 @@ msgstr "" #: view:account.invoice.report:0 #: field:report.invoice.created,date_invoice:0 msgid "Invoice Date" -msgstr "" +msgstr "Faktura dato" #. module: account #: help:res.partner,credit:0 diff --git a/addons/account_asset/i18n/da.po b/addons/account_asset/i18n/da.po new file mode 100644 index 00000000000..b79dc82abb5 --- /dev/null +++ b/addons/account_asset/i18n/da.po @@ -0,0 +1,529 @@ +# Danish translation for openobject-addons +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openobject-addons package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openobject-addons\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2009-11-24 12:54+0000\n" +"PO-Revision-Date: 2011-11-01 12:06+0000\n" +"Last-Translator: OpenERP Danmark / Mikhael Saxtorph \n" +"Language-Team: Danish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-02 04:56+0000\n" +"X-Generator: Launchpad (build 14214)\n" + +#. module: account_asset +#: model:ir.actions.act_window,name:account_asset.action_account_asset_asset_list_normal +#: model:ir.ui.menu,name:account_asset.menu_action_account_asset_asset_list_normal +msgid "Open Assets" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,method_end:0 +#: field:account.asset.property.history,method_end:0 +msgid "Ending date" +msgstr "Slut dato" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Depreciation board" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +#: field:account.asset.asset,name:0 +#: field:account.asset.board,asset_id:0 +#: field:account.asset.property,asset_id:0 +#: field:account.invoice.line,asset_id:0 +#: field:account.move.line,asset_id:0 +#: model:ir.actions.act_window,name:account_asset.action_account_asset_asset_form +#: model:ir.model,name:account_asset.model_account_asset_asset +#: model:ir.ui.menu,name:account_asset.menu_action_account_asset_asset_form +msgid "Asset" +msgstr "" + +#. module: account_asset +#: constraint:ir.actions.act_window:0 +msgid "Invalid model name in the action definition." +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,method:0 +msgid "Linear" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Change duration" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,child_ids:0 +msgid "Child assets" +msgstr "" + +#. module: account_asset +#: field:account.asset.board,value_asset:0 +msgid "Asset Value" +msgstr "" + +#. module: account_asset +#: wizard_field:account.asset.modify,init,name:0 +msgid "Reason" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +#: field:account.asset.asset,entry_ids:0 +#: wizard_field:account.asset.compute,asset_compute,move_ids:0 +msgid "Entries" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.compute,asset_compute:0 +msgid "Generated entries" +msgstr "" + +#. module: account_asset +#: wizard_field:account.asset.modify,init,method_delay:0 +#: field:account.asset.property,method_delay:0 +#: field:account.asset.property.history,method_delay:0 +msgid "Number of interval" +msgstr "" + +#. module: account_asset +#: wizard_button:account.asset.compute,asset_compute,asset_open:0 +msgid "Open entries" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +#: model:ir.actions.act_window,name:account_asset.action_account_asset_asset_list +#: model:ir.ui.menu,name:account_asset.menu_action_account_asset_asset_list +#: model:ir.ui.menu,name:account_asset.menu_finance_Assets +#: model:ir.ui.menu,name:account_asset.menu_finance_config_Assets +msgid "Assets" +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,method:0 +msgid "Progressive" +msgstr "" + +#. module: account_asset +#: model:ir.actions.act_window,name:account_asset.action_account_asset_asset_list_draft +#: model:ir.ui.menu,name:account_asset.menu_action_account_asset_asset_list_draft +msgid "Draft Assets" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.modify,init:0 +#: wizard_field:account.asset.modify,init,note:0 +#: view:account.asset.property.history:0 +msgid "Notes" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Change history" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Depreciation entries" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Methods" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.modify,init:0 +msgid "Asset properties to modify" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,partner_id:0 +msgid "Partner" +msgstr "" + +#. module: account_asset +#: wizard_field:account.asset.modify,init,method_period:0 +#: field:account.asset.property,method_period:0 +#: field:account.asset.property.history,method_period:0 +msgid "Period per interval" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Depreciation duration" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,account_analytic_id:0 +msgid "Analytic account" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,state:0 +msgid "State" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Depreciation methods" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Other information" +msgstr "" + +#. module: account_asset +#: field:account.asset.board,value_asset_cumul:0 +msgid "Cumul. value" +msgstr "" + +#. module: account_asset +#: view:account.asset.property:0 +msgid "Assets methods" +msgstr "" + +#. module: account_asset +#: constraint:ir.ui.view:0 +msgid "Invalid XML for View Architecture!" +msgstr "" + +#. module: account_asset +#: model:ir.model,name:account_asset.model_account_asset_property +msgid "Asset property" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.compute,asset_compute:0 +#: wizard_view:account.asset.compute,init:0 +#: wizard_button:account.asset.compute,init,asset_compute:0 +#: model:ir.actions.wizard,name:account_asset.wizard_asset_compute +#: model:ir.ui.menu,name:account_asset.menu_wizard_asset_compute +msgid "Compute assets" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.modify,init:0 +#: wizard_button:account.asset.modify,init,asset_modify:0 +#: model:ir.actions.wizard,name:account_asset.wizard_asset_modify +msgid "Modify asset" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Confirm asset" +msgstr "" + +#. module: account_asset +#: view:account.asset.property.history:0 +#: model:ir.model,name:account_asset.model_account_asset_property_history +msgid "Asset history" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,date:0 +msgid "Date created" +msgstr "" + +#. module: account_asset +#: model:ir.module.module,description:account_asset.module_meta_information +msgid "" +"Financial and accounting asset management.\n" +" Allows to define\n" +" * Asset category. \n" +" * Assets.\n" +" *Asset usage period and property.\n" +" " +msgstr "" + +#. module: account_asset +#: field:account.asset.board,value_gross:0 +#: field:account.asset.property,value_total:0 +msgid "Gross value" +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,method_time:0 +msgid "Ending period" +msgstr "" + +#. module: account_asset +#: field:account.asset.board,name:0 +msgid "Asset name" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Accounts information" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,note:0 +#: field:account.asset.category,note:0 +#: field:account.asset.property.history,note:0 +msgid "Note" +msgstr "" + +#. module: account_asset +#: selection:account.asset.asset,state:0 +#: selection:account.asset.property,state:0 +msgid "Draft" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,type:0 +msgid "Depr. method type" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,account_asset_id:0 +msgid "Asset account" +msgstr "" + +#. module: account_asset +#: field:account.asset.property.history,asset_property_id:0 +msgid "Method" +msgstr "" + +#. module: account_asset +#: selection:account.asset.asset,state:0 +msgid "Normal" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,method_progress_factor:0 +msgid "Progressif factor" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,localisation:0 +msgid "Localisation" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,method:0 +msgid "Computation method" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,method_time:0 +msgid "Time method" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,active:0 +msgid "Active" +msgstr "" + +#. module: account_asset +#: field:account.asset.property.history,user_id:0 +msgid "User" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,property_ids:0 +msgid "Asset method name" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,date:0 +#: field:account.asset.property.history,date:0 +msgid "Date" +msgstr "" + +#. module: account_asset +#: field:account.asset.board,value_net:0 +msgid "Net value" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.close,init:0 +#: model:ir.actions.wizard,name:account_asset.wizard_asset_close +msgid "Close asset" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,history_ids:0 +msgid "History" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,account_actif_id:0 +msgid "Depreciation account" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,period_id:0 +#: wizard_field:account.asset.compute,init,period_id:0 +msgid "Period" +msgstr "" + +#. module: account_asset +#: model:ir.actions.act_window,name:account_asset.action_account_asset_category_form +#: model:ir.ui.menu,name:account_asset.menu_action_account_asset_category_form +msgid "Asset Category" +msgstr "" + +#. module: account_asset +#: wizard_button:account.asset.close,init,end:0 +#: wizard_button:account.asset.compute,init,end:0 +#: wizard_button:account.asset.modify,init,end:0 +msgid "Cancel" +msgstr "" + +#. module: account_asset +#: selection:account.asset.asset,state:0 +#: wizard_button:account.asset.compute,asset_compute,end:0 +#: selection:account.asset.property,state:0 +msgid "Close" +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,state:0 +msgid "Open" +msgstr "" + +#. module: account_asset +#: constraint:ir.model:0 +msgid "" +"The Object name must start with x_ and not contain any special character !" +msgstr "" + +#. module: account_asset +#: model:ir.module.module,shortdesc:account_asset.module_meta_information +msgid "Asset management" +msgstr "" + +#. module: account_asset +#: view:account.asset.board:0 +#: field:account.asset.property,board_ids:0 +#: model:ir.model,name:account_asset.model_account_asset_board +msgid "Asset board" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,state:0 +msgid "Global state" +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,method_time:0 +msgid "Delay" +msgstr "" + +#. module: account_asset +#: wizard_view:account.asset.close,init:0 +msgid "General information" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,journal_analytic_id:0 +msgid "Analytic journal" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,name:0 +msgid "Method name" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,journal_id:0 +msgid "Journal" +msgstr "" + +#. module: account_asset +#: field:account.asset.property.history,name:0 +msgid "History name" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Close method" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,entry_asset_ids:0 +msgid "Asset Entries" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,category_id:0 +#: view:account.asset.category:0 +#: field:account.asset.category,name:0 +#: model:ir.model,name:account_asset.model_account_asset_category +msgid "Asset category" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "Depreciation" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,code:0 +#: field:account.asset.category,code:0 +msgid "Asset code" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,value_total:0 +msgid "Total value" +msgstr "" + +#. module: account_asset +#: selection:account.asset.asset,state:0 +msgid "View" +msgstr "" + +#. module: account_asset +#: view:account.asset.asset:0 +msgid "General info" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,sequence:0 +msgid "Sequence" +msgstr "" + +#. module: account_asset +#: field:account.asset.property,value_residual:0 +msgid "Residual value" +msgstr "" + +#. module: account_asset +#: wizard_button:account.asset.close,init,asset_close:0 +msgid "End of asset" +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,type:0 +msgid "Direct" +msgstr "" + +#. module: account_asset +#: selection:account.asset.property,type:0 +msgid "Indirect" +msgstr "" + +#. module: account_asset +#: field:account.asset.asset,parent_id:0 +msgid "Parent asset" +msgstr "" + +#. module: account_asset +#: model:ir.actions.act_window,name:account_asset.action_account_asset_asset_tree +#: model:ir.ui.menu,name:account_asset.menu_action_account_asset_asset_tree +msgid "Asset Hierarchy" +msgstr "" diff --git a/addons/base_calendar/i18n/da.po b/addons/base_calendar/i18n/da.po index fa9b3182a94..7f5acd64cf8 100644 --- a/addons/base_calendar/i18n/da.po +++ b/addons/base_calendar/i18n/da.po @@ -8,14 +8,14 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2011-01-11 11:14+0000\n" -"PO-Revision-Date: 2011-09-23 15:56+0000\n" -"Last-Translator: FULL NAME \n" +"PO-Revision-Date: 2011-11-01 20:11+0000\n" +"Last-Translator: OpenERP Danmark / Henning Dinsen \n" "Language-Team: Danish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 05:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-02 04:56+0000\n" +"X-Generator: Launchpad (build 14214)\n" #. module: base_calendar #: selection:calendar.alarm,trigger_related:0 @@ -49,7 +49,7 @@ msgstr "" #. module: base_calendar #: field:calendar.event.edit.all,name:0 msgid "Title" -msgstr "" +msgstr "Titel" #. module: base_calendar #: selection:base.calendar.set.exrule,freq:0 @@ -66,7 +66,7 @@ msgstr "" #. module: base_calendar #: view:calendar.attendee:0 msgid "Invitation" -msgstr "" +msgstr "Invitation" #. module: base_calendar #: help:calendar.event,recurrency:0 @@ -78,7 +78,7 @@ msgstr "" #: model:ir.actions.act_window,name:base_calendar.action_res_alarm_view #: model:ir.ui.menu,name:base_calendar.menu_crm_meeting_avail_alarm msgid "Alarms" -msgstr "" +msgstr "Alarmer" #. module: base_calendar #: selection:base.calendar.set.exrule,week_list:0 @@ -145,7 +145,7 @@ msgstr "Marts" #: code:addons/base_calendar/wizard/base_calendar_set_exrule.py:90 #, python-format msgid "Warning !" -msgstr "Advarsel!" +msgstr "Advarsel !" #. module: base_calendar #: selection:base.calendar.set.exrule,week_list:0 diff --git a/addons/idea/i18n/da.po b/addons/idea/i18n/da.po index 69d23eb2e90..d37dbf8fc94 100644 --- a/addons/idea/i18n/da.po +++ b/addons/idea/i18n/da.po @@ -8,14 +8,14 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2011-01-11 11:15+0000\n" -"PO-Revision-Date: 2010-11-20 07:54+0000\n" -"Last-Translator: Martin Pihl \n" +"PO-Revision-Date: 2011-11-01 20:17+0000\n" +"Last-Translator: OpenERP Danmark / Henning Dinsen \n" "Language-Team: Danish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 05:14+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-02 04:56+0000\n" +"X-Generator: Launchpad (build 14214)\n" #. module: idea #: help:idea.category,visibility:0 @@ -43,7 +43,7 @@ msgstr "Kommentarer" #. module: idea #: view:idea.idea:0 msgid "Submit Vote" -msgstr "Indsend Stemme" +msgstr "Indsend stemme" #. module: idea #: model:ir.actions.act_window,name:idea.action_report_vote_all @@ -492,7 +492,7 @@ msgstr "" #. module: idea #: field:idea.category,summary:0 msgid "Summary" -msgstr "" +msgstr "Kort beskrivelse" #. module: idea #: field:idea.idea,name:0 @@ -551,7 +551,7 @@ msgstr "Luk" #: view:idea.idea:0 #: view:report.vote:0 msgid "Open" -msgstr "" +msgstr "Åbn" #. module: idea #: view:report.vote:0 @@ -667,7 +667,7 @@ msgstr "" #. module: idea #: view:idea.idea:0 msgid "Accept" -msgstr "" +msgstr "Godkend" #. module: idea #: field:idea.post.vote,vote:0 @@ -678,7 +678,7 @@ msgstr "" #: view:report.vote:0 #: field:report.vote,year:0 msgid "Year" -msgstr "" +msgstr "År" #. module: idea #: view:idea.select:0 diff --git a/addons/web/po/da.po b/addons/web/po/da.po index cefd844d49a..c0931065d1e 100644 --- a/addons/web/po/da.po +++ b/addons/web/po/da.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-12 04:44+0000\n" -"X-Generator: Launchpad (build 14124)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/de.po b/addons/web/po/de.po index 027f34f9866..0a26630321f 100644 --- a/addons/web/po/de.po +++ b/addons/web/po/de.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/es.po b/addons/web/po/es.po index 508b4e62245..9bd7071871b 100644 --- a/addons/web/po/es.po +++ b/addons/web/po/es.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/es_EC.po b/addons/web/po/es_EC.po index eb2283f6fe5..588408ba979 100644 --- a/addons/web/po/es_EC.po +++ b/addons/web/po/es_EC.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:29+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/et.po b/addons/web/po/et.po index 75269bf5cda..6b6da84f3a5 100644 --- a/addons/web/po/et.po +++ b/addons/web/po/et.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/fr.po b/addons/web/po/fr.po index a4287a31030..df35344c558 100644 --- a/addons/web/po/fr.po +++ b/addons/web/po/fr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/gl.po b/addons/web/po/gl.po index b43664b9bee..34b2d50085f 100644 --- a/addons/web/po/gl.po +++ b/addons/web/po/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/it.po b/addons/web/po/it.po index fc53244533b..647030fd4ea 100644 --- a/addons/web/po/it.po +++ b/addons/web/po/it.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-09 05:22+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/nl_BE.po b/addons/web/po/nl_BE.po index 2a2dccb1712..3d649b59b9d 100644 --- a/addons/web/po/nl_BE.po +++ b/addons/web/po/nl_BE.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:29+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web/po/sl.po b/addons/web/po/sl.po index bc63e7ff313..54349249817 100644 --- a/addons/web/po/sl.po +++ b/addons/web/po/sl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web/static/src/js/view_form.js:355 msgid "" diff --git a/addons/web_calendar/po/da.po b/addons/web_calendar/po/da.po index a064b4cdc1f..68e2b21a673 100644 --- a/addons/web_calendar/po/da.po +++ b/addons/web_calendar/po/da.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-12 04:44+0000\n" -"X-Generator: Launchpad (build 14124)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/de.po b/addons/web_calendar/po/de.po index c0719196cb2..27e0168a44e 100644 --- a/addons/web_calendar/po/de.po +++ b/addons/web_calendar/po/de.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/es.po b/addons/web_calendar/po/es.po index 25e6c8c24d6..9e0c5f32f98 100644 --- a/addons/web_calendar/po/es.po +++ b/addons/web_calendar/po/es.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 06:05+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/es_EC.po b/addons/web_calendar/po/es_EC.po index 2aea3aa063f..6b9cf2145dd 100644 --- a/addons/web_calendar/po/es_EC.po +++ b/addons/web_calendar/po/es_EC.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/et.po b/addons/web_calendar/po/et.po index f9086495da6..b08c52fbfc7 100644 --- a/addons/web_calendar/po/et.po +++ b/addons/web_calendar/po/et.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/fr.po b/addons/web_calendar/po/fr.po index 7679850c593..5f04d2d7182 100644 --- a/addons/web_calendar/po/fr.po +++ b/addons/web_calendar/po/fr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/gl.po b/addons/web_calendar/po/gl.po index 73ecf153937..7705a7cda2f 100644 --- a/addons/web_calendar/po/gl.po +++ b/addons/web_calendar/po/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/it.po b/addons/web_calendar/po/it.po index 29bbe86b507..5b98572ab45 100644 --- a/addons/web_calendar/po/it.po +++ b/addons/web_calendar/po/it.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-09 05:22+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/nl_BE.po b/addons/web_calendar/po/nl_BE.po index ecb2d565787..b071632ea47 100644 --- a/addons/web_calendar/po/nl_BE.po +++ b/addons/web_calendar/po/nl_BE.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/sk.po b/addons/web_calendar/po/sk.po index 168ca1d2adf..f879c6b13f1 100644 --- a/addons/web_calendar/po/sk.po +++ b/addons/web_calendar/po/sk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_calendar/po/sl.po b/addons/web_calendar/po/sl.po index 40f8f43a756..80c32b8728b 100644 --- a/addons/web_calendar/po/sl.po +++ b/addons/web_calendar/po/sl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_calendar/static/src/xml/web_calendar.xml:0 msgid " " diff --git a/addons/web_dashboard/po/da.po b/addons/web_dashboard/po/da.po index 8df0abb1499..312ceaa7327 100644 --- a/addons/web_dashboard/po/da.po +++ b/addons/web_dashboard/po/da.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-12 04:44+0000\n" -"X-Generator: Launchpad (build 14124)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/de.po b/addons/web_dashboard/po/de.po index 6e2b8e003a3..1fecf9c9550 100644 --- a/addons/web_dashboard/po/de.po +++ b/addons/web_dashboard/po/de.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/es.po b/addons/web_dashboard/po/es.po index 8cd91812416..9686bc1b517 100644 --- a/addons/web_dashboard/po/es.po +++ b/addons/web_dashboard/po/es.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 06:05+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/es_EC.po b/addons/web_dashboard/po/es_EC.po index 11cf8918d7f..24ae8287a6d 100644 --- a/addons/web_dashboard/po/es_EC.po +++ b/addons/web_dashboard/po/es_EC.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/et.po b/addons/web_dashboard/po/et.po index 381db624021..06fccba4842 100644 --- a/addons/web_dashboard/po/et.po +++ b/addons/web_dashboard/po/et.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/fr.po b/addons/web_dashboard/po/fr.po index b02d061cdd2..a8c0e7ba530 100644 --- a/addons/web_dashboard/po/fr.po +++ b/addons/web_dashboard/po/fr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/gl.po b/addons/web_dashboard/po/gl.po index b7a081aff6f..16edea4823f 100644 --- a/addons/web_dashboard/po/gl.po +++ b/addons/web_dashboard/po/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/it.po b/addons/web_dashboard/po/it.po index 2986cb8ccd0..90e98cd48bc 100644 --- a/addons/web_dashboard/po/it.po +++ b/addons/web_dashboard/po/it.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/nl_BE.po b/addons/web_dashboard/po/nl_BE.po index 40dcc0438a7..57a9fdadbf5 100644 --- a/addons/web_dashboard/po/nl_BE.po +++ b/addons/web_dashboard/po/nl_BE.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/sk.po b/addons/web_dashboard/po/sk.po index d2c2b2160a0..a9e11093ef1 100644 --- a/addons/web_dashboard/po/sk.po +++ b/addons/web_dashboard/po/sk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_dashboard/po/sl.po b/addons/web_dashboard/po/sl.po index 9eee401c427..01a5bf45deb 100644 --- a/addons/web_dashboard/po/sl.po +++ b/addons/web_dashboard/po/sl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_dashboard/static/src/xml/web_dashboard.xml:0 msgid "Reset" diff --git a/addons/web_default_home/po/da.po b/addons/web_default_home/po/da.po new file mode 100644 index 00000000000..989daa78361 --- /dev/null +++ b/addons/web_default_home/po/da.po @@ -0,0 +1,38 @@ +# Danish translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-10-11 14:02+0000\n" +"Last-Translator: Jonas Mortensen \n" +"Language-Team: Danish \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "Velkommen til din nye OpenERP instans." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "Husk at tilføje denne side til dine favoritter." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "Husk dit log ind:" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "Vælg den første OpenERP Applikation som du ønsker at installere." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "Installér" diff --git a/addons/web_default_home/po/de.po b/addons/web_default_home/po/de.po new file mode 100644 index 00000000000..2363aea8505 --- /dev/null +++ b/addons/web_default_home/po/de.po @@ -0,0 +1,38 @@ +# German translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-10-10 12:40+0000\n" +"Last-Translator: Felix Schubert \n" +"Language-Team: German \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "Willkommen zu Ihrer neuen OpenERP Instanz." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "Denken Sie daran ein Lesezeichen für diese Seite zu setzen." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "Anmeldung speichern" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "Wählen Sie die erste OpenERP Anwendung die Sie installieren möchten." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "Installieren" diff --git a/addons/web_default_home/po/es.po b/addons/web_default_home/po/es.po index 4f35e5b6345..5120f12015d 100644 --- a/addons/web_default_home/po/es.po +++ b/addons/web_default_home/po/es.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 06:05+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_default_home/static/src/xml/web_default_home.xml:0 msgid "Welcome to your new OpenERP instance." diff --git a/addons/web_default_home/po/es_EC.po b/addons/web_default_home/po/es_EC.po new file mode 100644 index 00000000000..077b51cbeee --- /dev/null +++ b/addons/web_default_home/po/es_EC.po @@ -0,0 +1,38 @@ +# Spanish (Ecuador) translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-10-07 16:00+0000\n" +"Last-Translator: Cristian Salamea (Gnuthink) \n" +"Language-Team: Spanish (Ecuador) \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "Bienvenido a tu nueva instancia de OpenERP" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "Recuerda marcar esta página" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "Recordar tu inicio de sesión" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "Escoge la primea Aplicación OpenERP que deseas instalar..." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "Instalar" diff --git a/addons/web_default_home/po/et.po b/addons/web_default_home/po/et.po new file mode 100644 index 00000000000..a2dedb192d4 --- /dev/null +++ b/addons/web_default_home/po/et.po @@ -0,0 +1,38 @@ +# Estonian translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-10-10 19:29+0000\n" +"Last-Translator: Aare Vesi \n" +"Language-Team: Estonian \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "Paigalda" diff --git a/addons/web_default_home/po/fr.po b/addons/web_default_home/po/fr.po index ec8855f86cf..e1b15ca7021 100644 --- a/addons/web_default_home/po/fr.po +++ b/addons/web_default_home/po/fr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:09+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_default_home/static/src/xml/web_default_home.xml:0 msgid "Welcome to your new OpenERP instance." diff --git a/addons/web_default_home/po/gl.po b/addons/web_default_home/po/gl.po index 4069197dec9..5783af8a2fb 100644 --- a/addons/web_default_home/po/gl.po +++ b/addons/web_default_home/po/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_default_home/static/src/xml/web_default_home.xml:0 msgid "Welcome to your new OpenERP instance." diff --git a/addons/web_default_home/po/it.po b/addons/web_default_home/po/it.po new file mode 100644 index 00000000000..a9f3a86854b --- /dev/null +++ b/addons/web_default_home/po/it.po @@ -0,0 +1,38 @@ +# Italian translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-10-08 13:41+0000\n" +"Last-Translator: Nicola Riolini - Micronaet \n" +"Language-Team: Italian \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "Benvenuto nella nuova istanza di OpenERP" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "Ricordarsi di aggiungere ai preferiti questa pagina" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "Ricordare il proprio login:" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "Scegliere la prima applicazione OpenERP che volete installare..." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "Installa" diff --git a/addons/web_default_home/po/nl_BE.po b/addons/web_default_home/po/nl_BE.po new file mode 100644 index 00000000000..1f046075120 --- /dev/null +++ b/addons/web_default_home/po/nl_BE.po @@ -0,0 +1,38 @@ +# Dutch (Belgium) translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-10-07 09:07+0000\n" +"Last-Translator: Niels Huylebroeck \n" +"Language-Team: Dutch (Belgium) \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "Welkom bij uw nieuwe OpenERP." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "Gelieve een bookmark voor deze pagina te maken." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "Vergeet je login niet:" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "Kies welke OpenERP Applicatie je wilt installeren..." + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "Installeer" diff --git a/addons/web_default_home/po/sk.po b/addons/web_default_home/po/sk.po new file mode 100644 index 00000000000..bf766fb65b0 --- /dev/null +++ b/addons/web_default_home/po/sk.po @@ -0,0 +1,38 @@ +# Slovak translation for openerp-web +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openerp-web package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openerp-web\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-10-07 10:39+0200\n" +"PO-Revision-Date: 2011-11-01 13:27+0000\n" +"Last-Translator: FULL NAME \n" +"Language-Team: Slovak \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-11-02 05:05+0000\n" +"X-Generator: Launchpad (build 14214)\n" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Welcome to your new OpenERP instance." +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember to bookmark this page." +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Remember your login:" +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Choose the first OpenERP Application you want to install.." +msgstr "" + +#: addons/web_default_home/static/src/xml/web_default_home.xml:0 +msgid "Install" +msgstr "" diff --git a/addons/web_default_home/po/sl.po b/addons/web_default_home/po/sl.po index d9f10a9e92f..2f9d918cb49 100644 --- a/addons/web_default_home/po/sl.po +++ b/addons/web_default_home/po/sl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_default_home/static/src/xml/web_default_home.xml:0 msgid "Welcome to your new OpenERP instance." diff --git a/addons/web_diagram/po/da.po b/addons/web_diagram/po/da.po index e91754b6da3..b0a68cf641c 100644 --- a/addons/web_diagram/po/da.po +++ b/addons/web_diagram/po/da.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-12 04:44+0000\n" -"X-Generator: Launchpad (build 14124)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/de.po b/addons/web_diagram/po/de.po index 2aa5e23eb13..1a511d763ba 100644 --- a/addons/web_diagram/po/de.po +++ b/addons/web_diagram/po/de.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/es.po b/addons/web_diagram/po/es.po index 192c69b6428..465cc16f401 100644 --- a/addons/web_diagram/po/es.po +++ b/addons/web_diagram/po/es.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 06:05+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/es_EC.po b/addons/web_diagram/po/es_EC.po index 0aff9dc73a0..3faa86e9bc5 100644 --- a/addons/web_diagram/po/es_EC.po +++ b/addons/web_diagram/po/es_EC.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/et.po b/addons/web_diagram/po/et.po index f2f3816fafa..5f8e394d816 100644 --- a/addons/web_diagram/po/et.po +++ b/addons/web_diagram/po/et.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/gl.po b/addons/web_diagram/po/gl.po index 0aca25055d3..27f4dc017fa 100644 --- a/addons/web_diagram/po/gl.po +++ b/addons/web_diagram/po/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/it.po b/addons/web_diagram/po/it.po index f9ab13eaec5..c3ced470ca6 100644 --- a/addons/web_diagram/po/it.po +++ b/addons/web_diagram/po/it.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-09 05:22+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/nl_BE.po b/addons/web_diagram/po/nl_BE.po index 6f574501bba..4d2999c099d 100644 --- a/addons/web_diagram/po/nl_BE.po +++ b/addons/web_diagram/po/nl_BE.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_diagram/po/sl.po b/addons/web_diagram/po/sl.po index 9cce3a3564e..6766b54fb3c 100644 --- a/addons/web_diagram/po/sl.po +++ b/addons/web_diagram/po/sl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_diagram/static/src/xml/base_diagram.xml:0 msgid "New Node" diff --git a/addons/web_mobile/po/da.po b/addons/web_mobile/po/da.po index e0dbdc552d1..d61a3cba5b8 100644 --- a/addons/web_mobile/po/da.po +++ b/addons/web_mobile/po/da.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-12 04:44+0000\n" -"X-Generator: Launchpad (build 14124)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/de.po b/addons/web_mobile/po/de.po index 701026b9331..ab74249a7ba 100644 --- a/addons/web_mobile/po/de.po +++ b/addons/web_mobile/po/de.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/es.po b/addons/web_mobile/po/es.po index 9a9e02c4893..0995630c08e 100644 --- a/addons/web_mobile/po/es.po +++ b/addons/web_mobile/po/es.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 06:05+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/es_EC.po b/addons/web_mobile/po/es_EC.po index 5cff1023c4f..73dbcaea7e7 100644 --- a/addons/web_mobile/po/es_EC.po +++ b/addons/web_mobile/po/es_EC.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/et.po b/addons/web_mobile/po/et.po index 5b8d74c0c5b..c3e3994a9d9 100644 --- a/addons/web_mobile/po/et.po +++ b/addons/web_mobile/po/et.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-11 05:42+0000\n" -"X-Generator: Launchpad (build 14123)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/fr.po b/addons/web_mobile/po/fr.po index b64bcecfb1e..aead113ca02 100644 --- a/addons/web_mobile/po/fr.po +++ b/addons/web_mobile/po/fr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/gl.po b/addons/web_mobile/po/gl.po index 4049dfb8d1f..482a3e05f58 100644 --- a/addons/web_mobile/po/gl.po +++ b/addons/web_mobile/po/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/it.po b/addons/web_mobile/po/it.po index 8d155374c0a..fdfce4385f5 100644 --- a/addons/web_mobile/po/it.po +++ b/addons/web_mobile/po/it.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-09 05:22+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/nl_BE.po b/addons/web_mobile/po/nl_BE.po index f483032890b..0a1171f1fe9 100644 --- a/addons/web_mobile/po/nl_BE.po +++ b/addons/web_mobile/po/nl_BE.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-08 05:30+0000\n" -"X-Generator: Launchpad (build 14110)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/sk.po b/addons/web_mobile/po/sk.po index 5e10f135cf9..d550414317a 100644 --- a/addons/web_mobile/po/sk.po +++ b/addons/web_mobile/po/sk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-24 05:18+0000\n" -"X-Generator: Launchpad (build 14185)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" diff --git a/addons/web_mobile/po/sl.po b/addons/web_mobile/po/sl.po index 041141d4824..8141108f9a9 100644 --- a/addons/web_mobile/po/sl.po +++ b/addons/web_mobile/po/sl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-20 04:48+0000\n" -"X-Generator: Launchpad (build 14165)\n" +"X-Launchpad-Export-Date: 2011-11-01 05:10+0000\n" +"X-Generator: Launchpad (build 14197)\n" #: addons/web_mobile/static/src/xml/web_mobile.xml:0 msgid "OpenERP" From c0c775014605a45a63fd6ccb40461a3762eb1244 Mon Sep 17 00:00:00 2001 From: "Yogesh (OpenERP)" Date: Tue, 1 Nov 2011 12:21:05 +0530 Subject: [PATCH 159/163] [FIX] vieweditor:- used close method instead of manually destory. bzr revid: ysa@tinyerp.com-20111101065105-kurbcohyig31qudu --- addons/web/static/src/js/view_editor.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index e042ee1d889..8aebced3e98 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -48,7 +48,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ self.get_data(); }, "Close": function(){ - $(this).dialog('destroy'); + this.view_edit_dialog.close(); } }, }); @@ -262,7 +262,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ //todo }, "Close": function(){ - $(this).dialog('destroy'); + this.edit_xml_dialog.close(); } } }); From 21a5438b3a50f1f4b1f258f23f52bc029de106a6 Mon Sep 17 00:00:00 2001 From: "Yogesh (OpenERP)" Date: Tue, 1 Nov 2011 12:24:21 +0530 Subject: [PATCH 160/163] [FIX] bzr revid: ysa@tinyerp.com-20111101065421-kk7ixnqsrqon3th8 --- addons/web/static/src/js/view_editor.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index 8aebced3e98..429192570f1 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -48,7 +48,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ self.get_data(); }, "Close": function(){ - this.view_edit_dialog.close(); + self.view_edit_dialog.close(); } }, }); @@ -262,7 +262,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ //todo }, "Close": function(){ - this.edit_xml_dialog.close(); + self.edit_xml_dialog.close(); } } }); From c1a65b4970a93c30488aa4df14d0ebf36e3a86aa Mon Sep 17 00:00:00 2001 From: "Vidhin Mehta (OpenERP)" Date: Wed, 2 Nov 2011 10:52:29 +0530 Subject: [PATCH 161/163] [IMP]removed direct use of jquery. bzr revid: vme@tinyerp.com-20111102052229-kyld21aha689n9p0 --- addons/web/static/src/js/view_editor.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index b92654ea42f..98804f5c03d 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -280,7 +280,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ 'data': one_object['main_object'], })); this.edit_xml_dialog.$element.find("tr[id^='viewedit-']").click(function() { - $("tr[id^='viewedit-']").removeClass('ui-selected'); + self.edit_xml_dialog.$element.find("tr[id^='viewedit-']").removeClass('ui-selected'); $(this).addClass('ui-selected'); }); this.edit_xml_dialog.$element.find("img[id^='parentimg-']").click(function() { @@ -372,7 +372,8 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ var last_tr_id = (last_tr.attr('id')).split('-')[1]; img = last_tr.find("img[id='parentimg-" + last_tr_id + "']").attr('src'); if (img) { - self.edit_xml_dialog.$element.find("img[id='parentimg-" + last_tr_id + "']").attr('src', '/web/static/src/img/expand.gif'); + self.edit_xml_dialog.$element.find("img[id='parentimg-" + last_tr_id + "']"). + attr('src', '/web/static/src/img/expand.gif'); while (1) { var next_tr = last_tr.next(); if (next_tr.attr('level') <= level || next_tr.length == 0) break; From 6159ab1714c9a171f1d7eda20f8503ae85e26f35 Mon Sep 17 00:00:00 2001 From: "Vidhin Mehta (OpenERP)" Date: Wed, 2 Nov 2011 11:47:35 +0530 Subject: [PATCH 162/163] [IMP]impove save and move funcationality. bzr revid: vme@tinyerp.com-20111102061735-28mlg6y4qrvdku4g --- addons/web/static/src/js/view_editor.js | 30 +++++++++++-------------- 1 file changed, 13 insertions(+), 17 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index 98804f5c03d..f41b77f1744 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -33,7 +33,6 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ radio:true }, }; - var action_manager = new openerp.web.ActionManager(this); this.view_edit_dialog = new openerp.web.Dialog(this,{ modal: true, title: 'ViewEditor', @@ -52,28 +51,23 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } }, }); - this.view_edit_dialog.start(); - this.view_edit_dialog.open(); + this.view_edit_dialog.start().open(); + var action_manager = new openerp.web.ActionManager(this); action_manager.appendTo(this.view_edit_dialog); action_manager.do_action(action); - }, check_attr: function(xml, tag, level) { - var obj = new Object(); - obj.child_id = []; - obj.id = this.xml_id++; - obj.level = level+1; + var obj = {'child_id':[],'id':this.xml_id++,'level':level+1,'att_list':[],'name':""}; var render_name = "<" + tag; - obj.att_list = []; obj.att_list.push(tag); $(xml).each(function() { _.each(this.attributes, function(attrs){ if (tag != 'button') { if (attrs.nodeName == "string" || attrs.nodeName == "name" || attrs.nodeName == "index") { - render_name += ' ' + attrs.nodeName + '=' + '"' + attrs.nodeValue + '"' ; } + render_name += ' ' + attrs.nodeName + '=' + '"' + attrs.nodeValue + '"' ;} } else { if (attrs.nodeName == "name") { - render_name += ' ' + attrs.nodeName + '=' + '"' + attrs.nodeValue + '"'; } + render_name += ' ' + attrs.nodeName + '=' + '"' + attrs.nodeValue + '"';} } obj.att_list.push( [attrs.nodeName,attrs.nodeValue] ); }); @@ -368,6 +362,9 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ else { last_tr = cur_tr.next(); } + if((self.edit_xml_dialog.$element.find(last_tr).find('a').text()).search("view_id") != -1){ + return; + } if (last_tr.length != 0 && parseInt(last_tr.attr('level')) == level) { var last_tr_id = (last_tr.attr('id')).split('-')[1]; img = last_tr.find("img[id='parentimg-" + last_tr_id + "']").attr('src'); @@ -383,12 +380,11 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } list_shift.reverse(); - if((self.edit_xml_dialog.$element.find(side.next()).find('a').text()).search("view_id") == -1){ - _.each(list_shift, function(rec) { - $(last_tr).after(rec); - }); - self.save_move_arch(one_object, view_id, view_xml_id, id_tr, level, "down"); - } + _.each(list_shift, function(rec) { + $(last_tr).after(rec); + }); + self.save_move_arch(one_object, view_id, view_xml_id, id_tr, level, "down"); + } break; } From 82ea675d0f954b6b62fba37a48d578ffe42b27ab Mon Sep 17 00:00:00 2001 From: "Yogesh (OpenERP)" Date: Wed, 2 Nov 2011 17:10:34 +0530 Subject: [PATCH 163/163] [IMP] View editor :- implement functionality of preview button. bzr revid: ysa@tinyerp.com-20111102114034-nmj18kx32igvqdub --- addons/web/static/src/js/view_editor.js | 28 +++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index 09cfe84c702..a93f71e87bc 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -130,13 +130,14 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ get_data: function() { var self = this; var view_arch_list = []; - var view_id =((this.view_edit_dialog.$element.find("input[name='radiogroup']:checked").parent()).parent()).attr('data-id'); + self.main_view_id =((this.view_edit_dialog.$element.find("input[name='radiogroup']:checked").parent()).parent()).attr('data-id'); var ve_dataset = new openerp.web.DataSet(this, 'ir.ui.view'); - ve_dataset.read_ids([parseInt(view_id)], ['arch'], function (arch) { - one_object = self.parse_xml(arch[0].arch,view_id); - view_arch_list.push({"view_id" : view_id, "arch" : arch[0].arch}); + ve_dataset.read_ids([parseInt(self.main_view_id)], ['arch', 'type'], function (arch) { + one_object = self.parse_xml(arch[0].arch,self.main_view_id); + self.main_view_type = arch[0].type + view_arch_list.push({"view_id" : self.main_view_id, "arch" : arch[0].arch}); dataset = new openerp.web.DataSetSearch(self, 'ir.ui.view', null, null); - dataset.read_slice([], {domain : [['inherit_id','=', parseInt(view_id)]]}, function (result) { + dataset.read_slice([], {domain : [['inherit_id','=', parseInt(self.main_view_id)]]}, function (result) { _.each(result, function(res) { view_arch_list.push({"view_id":res.id,"arch":res.arch}); self.inherit_view(one_object, res); @@ -263,7 +264,22 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ //todo }, "Preview": function(){ - //todo + var action = { + context:self.session.user_context, + res_model : self.model, + views : [[self.main_view_id, self.main_view_type]], + type: 'ir.actions.act_window', + target: "new", + flags: { + sidebar: false, + views_switcher: false, + action_buttons:false, + search_view:false, + pager:false, + }, + }; + var action_manager = new openerp.web.ActionManager(self); + action_manager.do_action(action); }, "Close": function(){ self.edit_xml_dialog.close();
    +
    - + @@ -1297,36 +1297,36 @@
    - + - - - - - + + + + + Export From b6a0874f4cc406788f0bf7045e279f43f8bd82ed Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 10:51:12 +0200 Subject: [PATCH 070/163] [FIX] disgusting hack to skip around race condition When clicking on an action button, form view first saves then executes the action. In doing so, it causes the o2m field to call ListView#reload_content twice without waiting for the reloading to end, generating a race condition in ListView.List#render_dataset. As a result, the read_slice callback fills the list twice (once for each #reload_content call), resulting in everything being duplicated. Clear the content of the records collection before adding stuff. note: collections should dedup on ids. lp bug: https://launchpad.net/bugs/877965 fixed bzr revid: xmo@openerp.com-20111025085112-q38q8m0k2mopwadg --- addons/web/static/src/js/view_list.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_list.js b/addons/web/static/src/js/view_list.js index 4408cab8e3b..bf6f79b9cc0 100644 --- a/addons/web/static/src/js/view_list.js +++ b/addons/web/static/src/js/view_list.js @@ -1206,6 +1206,10 @@ openerp.web.ListView.Groups = openerp.web.Class.extend( /** @lends openerp.web.L var options = { offset: page * limit, limit: limit }; //TODO xmo: investigate why we need to put the setTimeout setTimeout(function() {dataset.read_slice(fields, options , function (records) { + // FIXME: ignominious hacks, parents (aka form view) should not send two ListView#reload_content concurrently + if (self.records.length) { + self.records.reset(null, {silent: true}); + } if (!self.datagroup.openable) { view.configure_pager(dataset); } else { @@ -1546,7 +1550,8 @@ var Collection = openerp.web.Class.extend(/** @lends Collection# */{ * @param {Array} [records] * @returns this */ - reset: function (records) { + reset: function (records, options) { + options = options || {}; _(this._proxies).each(function (proxy) { proxy.reset(); }); @@ -1557,7 +1562,9 @@ var Collection = openerp.web.Class.extend(/** @lends Collection# */{ if (records) { this.add(records); } - this.trigger('reset', this); + if (!options.silent) { + this.trigger('reset', this); + } return this; }, /** From 2102484af45a6bfae846db2a317f5b0561d4941c Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Tue, 25 Oct 2011 11:40:09 +0200 Subject: [PATCH 071/163] [FIX] share: add missing file bzr revid: chs@openerp.com-20111025094009-s9mgam03rww08s08 --- addons/share/static/src/xml/share.xml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 addons/share/static/src/xml/share.xml diff --git a/addons/share/static/src/xml/share.xml b/addons/share/static/src/xml/share.xml new file mode 100644 index 00000000000..9a1363846a0 --- /dev/null +++ b/addons/share/static/src/xml/share.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + From bf3465b3b5bebeb3d2d033f9536bbf4afbb4642f Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 11:44:19 +0200 Subject: [PATCH 072/163] [FIX] Kanban: if the name of the column is long, folding is ugly the text overflow the colum bzr revid: fme@openerp.com-20111025094419-3org5d0cy7895lil --- addons/web_kanban/static/src/css/kanban.css | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/web_kanban/static/src/css/kanban.css b/addons/web_kanban/static/src/css/kanban.css index 82143e460d1..35ab36a0188 100644 --- a/addons/web_kanban/static/src/css/kanban.css +++ b/addons/web_kanban/static/src/css/kanban.css @@ -14,6 +14,7 @@ height:20px; align:center; font-size:24px; + white-space: nowrap; } .openerp .oe_kanban_view .ui-sortable-placeholder { From 0132b2ebd006a04dc0230edb97d0282aead54ee9 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 13:09:05 +0200 Subject: [PATCH 073/163] [IMP] remove redundant empty string in fetching of root 'logging' logger bzr revid: xmo@openerp.com-20111025110905-6yqz2gyppb574xod --- openerp-web | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openerp-web b/openerp-web index 4cddd373c11..02ec921f422 100755 --- a/openerp-web +++ b/openerp-web @@ -88,7 +88,7 @@ if __name__ == "__main__": with open(options.log_config) as file: dct = json.load(file) logging.config.dictConfig(dct) - logging.getLogger("").setLevel(getattr(logging, options.log_level.upper())) + logging.getLogger().setLevel(getattr(logging, options.log_level.upper())) else: logging.basicConfig(level=getattr(logging, options.log_level.upper())) From 1ee677eadbfa3e4c7d9836c48bea735f41f6a5a7 Mon Sep 17 00:00:00 2001 From: "Vidhin Mehta (OpenERP)" Date: Tue, 25 Oct 2011 16:40:12 +0530 Subject: [PATCH 074/163] [IMP]implement save and move functionality with all type of views and tag. bzr revid: vme@tinyerp.com-20111025111012-o991yy8rm666yk91 --- addons/web/static/src/js/view_editor.js | 101 ++++++++++++++++-------- 1 file changed, 66 insertions(+), 35 deletions(-) diff --git a/addons/web/static/src/js/view_editor.js b/addons/web/static/src/js/view_editor.js index a645593f437..29a3f083883 100644 --- a/addons/web/static/src/js/view_editor.js +++ b/addons/web/static/src/js/view_editor.js @@ -77,10 +77,8 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ if (attrs.nodeName == "name") { render_name += ' ' + attrs.nodeName + '=' + '"' + attrs.nodeValue + '"'; } } - if (attrs.nodeName != "position") { - obj.att_list.push( [attrs.nodeName,attrs.nodeValue] ); - } - }); + obj.att_list.push( [attrs.nodeName,attrs.nodeValue] ); + }); render_name+= ">"; }); obj.name = render_name; @@ -189,7 +187,13 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ check_list.push(_.without($.trim(part.replace(/[^a-zA-Z 0-9 _]+/g,'!')).split("!"),"")); }); } else { - check_list = [_.flatten(xpath_object[0].child_id[0].att_list)]; + var temp = []; + _.each(xpath_object[0].child_id[0].att_list, function(list){ + if(!_.include(list, "position")){ + temp.push(list); + } + }); + check_list = [_.flatten(temp)]; } self.full_path_search(check_list ,one_object ,xpath_object); }); @@ -345,10 +349,13 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } } } - if (last_tr.length != 0 && parseInt(last_tr.attr('level')) == level) { + if (last_tr.length != 0 + && parseInt(last_tr.attr('level')) == level + && ($(last_tr).find('a').text()).search("view_id") == -1) { _.each(list_shift, function(rec) { $(last_tr).before(rec); }); + self.save_move_arch(one_object, view_id, view_xml_id, id_tr, level, "up"); } break; case "side-down": @@ -379,25 +386,40 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ last_tr = next_tr; } } + list_shift.reverse(); - _.each(list_shift, function(rec) { - $(last_tr).after(rec); - }); - self.save_move_arch(one_object, view_id, view_xml_id, id_tr, level); + if(($(side.next()).find('a').text()).search("view_id") == -1){ + _.each(list_shift, function(rec) { + $(last_tr).after(rec); + }); + self.save_move_arch(one_object, view_id, view_xml_id, id_tr, level, "down"); + } } break; } }); }, - save_move_arch: function(one_object, view_id, view_xml_id, id_tr, level){ + + save_move_arch: function(one_object, view_id, view_xml_id, id_tr, level, move_direct){ var self = this; var arch = _.detect(one_object['arch'],function(element){ return element.view_id == view_id; }); var obj = self.get_view_object(view_xml_id, one_object['main_object'], []); + if(($(arch.arch).filter("data")).length != 0 && view_xml_id != 0){ + var check_list = _.flatten(obj[0].child_id[0].att_list); + arch.arch = _.detect($(arch.arch).children(), function(xml_child){ + var temp_obj = self.check_attr(xml_child, xml_child.tagName.toLowerCase()); + var main_list = _.flatten(temp_obj.att_list); + check_list = _.uniq(check_list); + var insert = _.intersection(main_list,check_list); + if(insert.length == check_list.length ){return xml_child;} + }); + } return self.get_node(arch.arch, obj[0].child_id[0], parseInt(id_tr), [], parseInt(level), - parseInt(view_id), arch); + parseInt(view_id), arch, move_direct); }, + get_view_object: function(view_xml_id, one_object,result){ var self = this; if(result.length==0){ @@ -411,42 +433,49 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } return result; }, - get_node: function(arch1, obj, id, child_list, level, view_id, arch){ + + get_node: function(arch1, obj, id, child_list, level, view_id, arch, move_direct){ var self = this; - console.log(obj.id,id); var children_list = $(arch1).children(); - if(obj.level <= level){ - if(parseInt(id) == obj.id){ - var next = $(arch1).next() - $(next).after(arch1); + var list_obj_xml = _.zip(children_list,obj.child_id); + if(id){ + if(obj.id == id){ + var id; var parent = $(arch1).parents(); - console.log(id,"--------",obj.id); - console.log(next,"========",arch1); - parent = parent[parent.length-1]; - var convert_to_utf = ""; - var s = new XMLSerializer(); - var stream = { - write : function(string) - {convert_to_utf = convert_to_utf + string + "";} - }; var index = _.indexOf(child_list,obj) var re_insert_obj = child_list.splice(index,1); - child_list.splice(index+1, 0, re_insert_obj[0]); - s.serializeToStream(parent, stream, "UTF-8"); + if(move_direct == "down"){ + var next = $(arch1).next(); + $(next).after(arch1); + child_list.splice(index+1, 0, re_insert_obj[0]); + }else{ + var prev = $(arch1).prev(); + $(prev).before(arch1); + child_list.splice(index-1, 0, re_insert_obj[0]); + } + parent = parent[parent.length-1]; + var convert_to_utf = ""; + var xml_serilalizer = new XMLSerializer(); + var stream = { + write : function(string) + {convert_to_utf = convert_to_utf + string + "";} + }; + xml_serilalizer.serializeToStream(parent, stream, "UTF-8"); convert_to_utf = convert_to_utf.replace('xmlns="http://www.w3.org/1999/xhtml"', ""); convert_to_utf = '' + convert_to_utf; arch.arch = convert_to_utf; dataset = new openerp.web.DataSet(this, 'ir.ui.view'); - dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ + dataset.write(parseInt(view_id),{"arch":convert_to_utf},function(r){ + }); + } + if(obj.level <= level){ + _.each(list_obj_xml, function(child_node){ + self.get_node(child_node[0], child_node[1], id, obj.child_id, level, view_id, arch, move_direct); }); - }else{ - for(var i=0;i< children_list.length; i++){ - if(obj.child_id){var child_list = obj.child_id}; - self.get_node(children_list[i], obj.child_id[i], id, child_list, level, view_id, arch); - } } } }, + on_expand: function(self){ var level = parseInt($(self).closest("tr[id^='viewedit-']").attr('level')); var cur_tr = $(self).closest("tr[id^='viewedit-']"); @@ -458,6 +487,7 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ } else return nxt_tr; } }, + on_collapse: function(self, parent_child_id, id, main_object) { var id = self.id.split('-')[1]; var datas = _.detect(parent_child_id,function(res) { @@ -469,5 +499,6 @@ openerp.web.ViewEditor = openerp.web.Widget.extend({ tr.show(); }); } + }); }; From b3803586d3db50e83982cab0ee2f139340a99e29 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 13:12:13 +0200 Subject: [PATCH 075/163] [IMP] merge split map and filter into a single listcomp bzr revid: xmo@openerp.com-20111025111213-6ryfsuv1jzfetxmu --- openerp-web | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/openerp-web b/openerp-web index 02ec921f422..a56fa2cbfe7 100755 --- a/openerp-web +++ b/openerp-web @@ -60,17 +60,11 @@ if __name__ == "__main__": if os.path.exists(path_addons): options.addons_path.append(path_addons) - def remove_end_slash(text): - if text[-1] in '/\\': - return text[:-1] - return text - - def drop_false_path(path): - if os.path.exists(path): - return True - - options.addons_path = map(remove_end_slash, options.addons_path) - options.addons_path = filter(drop_false_path, options.addons_path) + options.addons_path = [ + path[:-1] if path[-1] in r'\/' else path + for path in options.addons_path + if os.path.exists(path) + ] for path_addons in options.addons_path: if path_addons not in sys.path: From ebc4af352c8274f73915d1d3b2e0a6d24b81b2da Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 13:14:50 +0200 Subject: [PATCH 076/163] [IMP] sort some imports in launcher script bzr revid: xmo@openerp.com-20111025111450-1hkci8y2nrqxif55 --- openerp-web | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/openerp-web b/openerp-web index a56fa2cbfe7..1493a84abac 100755 --- a/openerp-web +++ b/openerp-web @@ -1,11 +1,11 @@ #!/usr/bin/env python +import json +import logging +import logging.config import optparse import os import sys -import json import tempfile -import logging -import logging.config import werkzeug.serving import werkzeug.contrib.fixers From fc5593d4e1b56b7f2f9a8e7f90ae5c6ab65a6e5d Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 13:51:34 +0200 Subject: [PATCH 077/163] [ADD] Kanban: Added kanban_image function in rendering context. bzr revid: fme@openerp.com-20111025115134-rsxpaupi8rmtib0v --- addons/web_kanban/static/src/js/kanban.js | 30 ++++++++++++++--------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index 761952d5af2..d8fcbd1b6cc 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -50,6 +50,14 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ } } }, + get_qweb_context: function(record) { + return { + record: this.do_transform_record(record), + kanban_color: _.bind(this.kanban_color, this), + kanban_gravatar: _.bind(this.kanban_gravatar, this), + kanban_image: _.bind(this.kanban_image, this) + } + }, kanban_color: function(variable) { var number_of_color_schemes = 8, index = 0; @@ -72,6 +80,10 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ var email_md5 = $.md5(email); return 'http://www.gravatar.com/avatar/' + email_md5 + '.png?s=' + size; }, + kanban_image: function(model, field, id) { + id = id || ''; + return '/web/binary/image?session_id=' + this.session.session_id + '&model=' + model + '&field=' + field + '&id=' + id; + }, transform_qweb_template: function(node) { var qweb_prefix = QWeb.prefix; switch (node.tag) { @@ -234,11 +246,9 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ if (self.all_display_data[i].records[j].id == record_id) { _.extend(self.all_display_data[i].records[j], records[0]); self.$element.find("#main_" + record_id).children().remove(); - self.$element.find("#main_" + record_id).append(self.qweb.render('kanban-box', { - record: self.do_transform_record(self.all_display_data[i].records[j]), - kanban_color: self.kanban_color, - kanban_gravatar: self.kanban_gravatar - })); + self.$element.find("#main_" + record_id).append( + self.qweb.render('kanban-box', self.get_qweb_context(self.all_display_data[i].records[j])) + ); break; } } @@ -363,17 +373,15 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ } this.source_index = {}; }, - on_reload_kanban: function (){ + on_reload_kanban: function() { var self = this; _.each(self.all_display_data, function(data, index) { if (data.records.length > 0){ _.each(data.records, function(record) { self.$element.find("#main_" + record.id).children().remove(); - self.$element.find("#main_" + record.id).append(self.qweb.render('kanban-box', { - record: self.do_transform_record(record), - kanban_color: self.kanban_color, - kanban_gravatar: self.kanban_gravatar - })); + self.$element.find("#main_" + record.id).append( + self.qweb.render('kanban-box', self.get_qweb_context(record)) + ); }); } }); From 6b0cf3ea36dff8fb592f8a0329360d7f1e28140c Mon Sep 17 00:00:00 2001 From: "Rucha (Open ERP)" Date: Tue, 25 Oct 2011 17:50:55 +0530 Subject: [PATCH 078/163] [IMP]: account: Added help text on new menu and fields for unrealized gain or loss bzr revid: rpa@tinyerp.com-20111025122055-h9cjx6z7op70fndt --- addons/account/account.py | 9 ++++++--- addons/account/account_view.xml | 1 + 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/addons/account/account.py b/addons/account/account.py index 6037f6a42c4..c44f4d18725 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -428,9 +428,12 @@ class account_account(osv.osv): 'balance': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Balance', multi='balance'), 'credit': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Credit', multi='balance'), 'debit': fields.function(__compute, fnct_inv=_set_credit_debit, digits_compute=dp.get_precision('Account'), string='Debit', multi='balance'), - 'foreign_balance': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Foreign Balance', multi='balance'), - 'adjusted_balance': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Adjusted Balance', multi='balance'), - 'unrealized_gain_loss': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Unrealized Gain or Loss', multi='balance'), + 'foreign_balance': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Foreign Balance', multi='balance', + help="Total amount (in Secondary currency) for transactions held in secondary currency for this account."), + 'adjusted_balance': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Adjusted Balance', multi='balance', + help="Total amount (in Company currency) for transactions held in secondary currency for this account."), + 'unrealized_gain_loss': fields.function(__compute, digits_compute=dp.get_precision('Account'), string='Unrealized Gain or Loss', multi='balance', + help="Value of Loss or Gain due to changes in exchange rate when doing multi-currency transactions."), 'reconcile': fields.boolean('Allow Reconciliation', help="Check this box if this account allows reconciliation of journal items."), 'exchange_rate': fields.related('currency_id', 'rate', type='float', string='Exchange Rate'), 'shortcut': fields.char('Shortcut', size=12), diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index 96e7f64dbd7..bcb5ba9d11c 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -320,6 +320,7 @@ tree [('currency_id','!=',False)] + When doing multi-currency transactions, you may loose or gain some amount due to changes in exchange rate, Unrealized Gain or Loss shows this amount for accounts (having secondary currency). Date: Tue, 25 Oct 2011 14:39:39 +0200 Subject: [PATCH 079/163] [FIX] Fixed HR Employee kanban view. Required fields not specified. No need for a gravatar because we already use the photo image field bzr revid: fme@openerp.com-20111025123939-82kv144cwurgxtb6 --- addons/hr/hr_view.xml | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/addons/hr/hr_view.xml b/addons/hr/hr_view.xml index f0399a4f5a3..a59269bd3ff 100644 --- a/addons/hr/hr_view.xml +++ b/addons/hr/hr_view.xml @@ -132,31 +132,20 @@ kanban +
    -
    + - - - - - + +
    - + - + + - - - - + + id="side-edit" src="/web/static/src/img/icons/gtk-edit.png" style="cursor: pointer;"/> + + + +
    - - - - -
    - -
    +
    - - - - - - +
    From a34f06dd4cb617227cd68b955ba65c6d7d18eda2 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Tue, 25 Oct 2011 14:42:51 +0200 Subject: [PATCH 080/163] [imp] changed default mode of o2m to tree (was tree,form) bzr revid: nicolas.vanhoren@openerp.com-20111025124251-uy67cprw499wcb7c --- addons/web/static/src/js/view_form.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 1f1b5b8ef6f..d227b091645 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1936,7 +1936,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ }); var modes = this.node.attrs.mode; - modes = !!modes ? modes.split(",") : ["tree", "form"]; + modes = !!modes ? modes.split(",") : ["tree"]; var views = []; _.each(modes, function(mode) { var view = { From cd5fa3e417244c9e148b1c976271f9b366680e4d Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 15:22:54 +0200 Subject: [PATCH 081/163] [FIX] Fixed hr.applicant kanban view bzr revid: fme@openerp.com-20111025132254-gfx5kcnip0281szl --- addons/hr_recruitment/hr_recruitment_view.xml | 21 ++++++++----------- 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/addons/hr_recruitment/hr_recruitment_view.xml b/addons/hr_recruitment/hr_recruitment_view.xml index 3310dbcf4ef..6b863121369 100644 --- a/addons/hr_recruitment/hr_recruitment_view.xml +++ b/addons/hr_recruitment/hr_recruitment_view.xml @@ -286,24 +286,21 @@ kanban + + + +
    - - - - - -
    - - - - - -
    +
    From 7451d66e4b2e59c926d0746dc8767f763b1e218d Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 15:23:26 +0200 Subject: [PATCH 082/163] [ADD] search: prefix to the view title when the current view is searchable: bzr revid: xmo@openerp.com-20111025132326-83i1t2adn4o5vsjo --- addons/web/static/src/js/views.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index b7a3d185bc1..78abe6a8fdb 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -444,6 +444,16 @@ session.web.ViewManagerAction = session.web.ViewManager.extend(/** @lends oepner if (!self.action.name && fvg) { self.$element.find('.oe_view_title').text(fvg.arch.attrs.string || fvg.name); } + + var $title = self.$element.find('.oe_view_title'), + $search_prefix = $title.find('span'); + if (controller.searchable !== false) { + if (!$search_prefix.length) { + $title.prepend('' + _t("Search:") + ''); + } + } else { + $search_prefix.remove(); + } }); }, shortcut_check : function(view) { From 69f909a9a16e55f17e4bb76324ce8b2f21670dac Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 15:24:12 +0200 Subject: [PATCH 083/163] [REN] 'New' button of ListView to 'Create' bzr revid: xmo@openerp.com-20111025132412-4vx57uf1vipcyfkq --- addons/web/static/src/js/view_list.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_list.js b/addons/web/static/src/js/view_list.js index 32ed7cf0741..0db60c72c07 100644 --- a/addons/web/static/src/js/view_list.js +++ b/addons/web/static/src/js/view_list.js @@ -11,7 +11,7 @@ openerp.web.ListView = openerp.web.View.extend( /** @lends openerp.web.ListView# // whether the column headers should be displayed 'header': true, // display addition button, with that label - 'addable': _t("New"), + 'addable': _t("Create"), // whether the list view can be sorted, note that once a view has been // sorted it can not be reordered anymore 'sortable': true, From 904b7b99fc097acb1caaeeeb55538c9215638daa Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 16:13:28 +0200 Subject: [PATCH 084/163] [FIX] Fixed product kanban view bzr revid: fme@openerp.com-20111025141328-dl3w7wg05spblo9i --- addons/product/product_view.xml | 34 ++++++++++++++------------------- addons/stock/product_view.xml | 34 ++++++++++++++------------------- 2 files changed, 28 insertions(+), 40 deletions(-) diff --git a/addons/product/product_view.xml b/addons/product/product_view.xml index 254a75fdcdc..7600eb93c87 100644 --- a/addons/product/product_view.xml +++ b/addons/product/product_view.xml @@ -202,39 +202,33 @@ kanban + + + +
    -
    - - - - -
    - [] - - - -
    +
    + +
    - @@ -255,7 +249,7 @@ - + Products ir.actions.act_window diff --git a/addons/stock/product_view.xml b/addons/stock/product_view.xml index 39d155b57d4..4205efd3efa 100644 --- a/addons/stock/product_view.xml +++ b/addons/stock/product_view.xml @@ -127,39 +127,33 @@ kanban + + + +
    -
    - - - - - - + +
    No Stock
    On Hand , Available
    -
    Public Price : , Cost :
    +
    + Public Price : , + Cost : +
    - - - - -
    - [] - - - -
    +
    + +
    - @@ -170,7 +164,7 @@
    From 59c9d34417feb2f4ac84efb2cf2fe153dc864276 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Tue, 25 Oct 2011 16:37:38 +0200 Subject: [PATCH 085/163] [ADD] title to all viewmanager variants Uses the string of the current view arch by default, overridden with action name by ViewManagerAction. Mostly of use for/with o2m and m2m fields bzr revid: xmo@openerp.com-20111025143738-yugscol5kabg8whv --- addons/web/static/src/js/views.js | 17 ++++++++++++++++- addons/web/static/src/xml/base.xml | 6 +++--- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index 78abe6a8fdb..3c1889e66c9 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -271,6 +271,10 @@ session.web.ViewManager = session.web.Widget.extend(/** @lends session.web.View } } } + $.when(view_promise).then(function () { + self.$element.find('.oe_view_title:first').text( + self.display_title()); + }); return view_promise; }, /** @@ -331,7 +335,15 @@ session.web.ViewManager = session.web.Widget.extend(/** @lends session.web.View /** * Called by children view after executing an action */ - on_action_executed: function () {} + on_action_executed: function () {}, + display_title: function () { + var view = this.views[this.active_view]; + if (view) { + // ick + return view.controller.fields_view.arch.attrs.string; + } + return ''; + } }); session.web.ViewManagerAction = session.web.ViewManager.extend(/** @lends oepnerp.web.ViewManagerAction# */{ @@ -522,6 +534,9 @@ session.web.ViewManagerAction = session.web.ViewManager.extend(/** @lends oepner return false; }); }); + }, + display_title: function () { + return this.action.name; } }); diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml index 7e081520ffc..da96ad8be8b 100644 --- a/addons/web/static/src/xml/base.xml +++ b/addons/web/static/src/xml/base.xml @@ -415,6 +415,9 @@
    - - - - - - + +
    No Stock
    On Hand , Available
    -
    Public Price : , Cost :
    +
    + Public Price : , + Cost : +
    +

    + +

    -

    - -

      From 7e27f4355fb165a618101d35bf1e10cb47a6376c Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Tue, 25 Oct 2011 17:21:55 +0200 Subject: [PATCH 086/163] [FIX] lp:878756 Inheritancy problem in view based on the changed label 'not invoices' => 'not invoiced' introduced in revision 5397 lp bug: https://launchpad.net/bugs/878756 fixed bzr revid: qdp-launchpad@openerp.com-20111025152155-kw420cspz7upw5zv --- addons/purchase/purchase_view.xml | 4 ++-- addons/purchase_requisition/purchase_requisition_view.xml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/purchase/purchase_view.xml b/addons/purchase/purchase_view.xml index 71bb002a284..69c283fd8de 100644 --- a/addons/purchase/purchase_view.xml +++ b/addons/purchase/purchase_view.xml @@ -246,7 +246,7 @@ - + @@ -282,7 +282,7 @@ - + diff --git a/addons/purchase_requisition/purchase_requisition_view.xml b/addons/purchase_requisition/purchase_requisition_view.xml index 06ee94c3941..fdddb4b7fee 100644 --- a/addons/purchase_requisition/purchase_requisition_view.xml +++ b/addons/purchase_requisition/purchase_requisition_view.xml @@ -21,7 +21,7 @@ purchase.order - + @@ -34,7 +34,7 @@ purchase.order - + From 6c1525d84994774f9c31f1531639701fa966ff1f Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Tue, 25 Oct 2011 18:20:01 +0200 Subject: [PATCH 087/163] [IMP] account: find() method of account.fiscalyear will now filter correctly on company_id if needed bzr revid: qdp-launchpad@openerp.com-20111025162001-6um2vm5f277bf0n2 --- addons/account/account.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/addons/account/account.py b/addons/account/account.py index dcf5c474077..865fc1c44d8 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -901,9 +901,16 @@ class account_fiscalyear(osv.osv): return True def find(self, cr, uid, dt=None, exception=True, context=None): + if context is None: context = {} if not dt: dt = time.strftime('%Y-%m-%d') - ids = self.search(cr, uid, [('date_start', '<=', dt), ('date_stop', '>=', dt)]) + args = [('date_start', '<=' ,dt), ('date_stop', '>=', dt)] + if context.get('company_id', False): + args.append(('company_id', '=', context['company_id'])) + else: + company_id = self.pool.get('res.users').browse(cr, uid, uid, context=context).company_id.id + args.append(('company_id', '=', company_id)) + ids = self.search(cr, uid, args, context=context) if not ids: if exception: raise osv.except_osv(_('Error !'), _('No fiscal year defined for this date !\nPlease create one.')) From dd514b567dbdf30e9367c827965c7c936d51453a Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Tue, 25 Oct 2011 18:20:31 +0200 Subject: [PATCH 088/163] [imp] made m2m support readonly bzr revid: nicolas.vanhoren@openerp.com-20111025162031-wsjaebu713nht3i1 --- addons/web/static/src/js/view_form.js | 53 +++++++++++++++++++++------ 1 file changed, 41 insertions(+), 12 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index d227b091645..e3584c21c13 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2196,6 +2196,7 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this._super(view, node); this.list_id = _.uniqueId("many2many"); this.is_started = $.Deferred(); + this.is_setted = $.Deferred(); }, start: function() { this._super.apply(this, arguments); @@ -2207,18 +2208,10 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this.dataset.on_unlink.add_last(function(ids) { self.on_ui_change(); }); - - this.list_view = new openerp.web.form.Many2ManyListView(this, this.dataset, false, { - 'addable': 'Add', - 'selectable': self.multi_selection - }); - this.list_view.m2m_field = this; - this.list_view.on_loaded.add_last(function() { - self.is_started.resolve(); + + this.is_setted.then(function() { + self.load_view(); }); - setTimeout(function () { - self.list_view.appendTo($("#" + self.list_id)); - }, 0); }, set_value: function(value) { value = value || []; @@ -2229,15 +2222,51 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this.dataset.set_ids(value); var self = this; $.when(this.is_started).then(function() { + console.log("lalala"); self.list_view.reload_content(); }); + this.is_setted.resolve(); }, get_value: function() { return [commands.replace_with(this.dataset.ids)]; }, validate: function() { this.invalid = false; - // TODO niv + }, + load_view: function() { + console.info("yop"); + var self = this; + this.list_view = new openerp.web.form.Many2ManyListView(this, this.dataset, false, { + 'addable': self.readonly ? null : 'Add', + 'deletable': self.readonly ? false : true, + 'selectable': self.multi_selection + }); + this.list_view.m2m_field = this; + var loaded = $.Deferred(); + this.list_view.on_loaded.add_last(function() { + self.is_started.resolve(); + loaded.resolve(); + }); + setTimeout(function () { + self.list_view.appendTo($("#" + self.list_id)); + }, 0); + return loaded; + }, + update_dom: function() { + this._super.apply(this, arguments); + var self = this; + if (this.previous_readonly !== this.readonly) { + this.previous_readonly = this.readonly; + if (this.list_view) { + $.when(this.is_started).then(function() { + self.list_view.stop(); + $.when(self.load_view()).then(function() { + console.log("lalala2"); + self.list_view.reload_content(); + }); + }); + } + } } }); From 20e5cb63a43dcd135f3b3ecedb2e7d444c3dc53b Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 18:35:31 +0200 Subject: [PATCH 089/163] [FIX] json_node_to_xml: whitespaces wrongly inserted around text nodes causing bugs in kanban views. bzr revid: fme@openerp.com-20111025163531-nxr8gb4j2f7wne2a --- addons/web/static/src/js/views.js | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/addons/web/static/src/js/views.js b/addons/web/static/src/js/views.js index 78abe6a8fdb..41be7a18286 100644 --- a/addons/web/static/src/js/views.js +++ b/addons/web/static/src/js/views.js @@ -953,19 +953,19 @@ session.web.View = session.web.Widget.extend(/** @lends session.web.View# */{ } }); -session.web.json_node_to_xml = function(node, single_quote, indent) { +session.web.json_node_to_xml = function(node, human_readable, indent) { // For debugging purpose, this function will convert a json node back to xml // Maybe usefull for xml view editor + indent = indent || 0; + var sindent = (human_readable ? (new Array(indent + 1).join('\t')) : ''), + r = sindent + '<' + node.tag, + cr = human_readable ? '\n' : ''; if (typeof(node) === 'string') { - return node; - } - else if (typeof(node.tag) !== 'string' || !node.children instanceof Array || !node.attrs instanceof Object) { + return sindent + node; + } else if (typeof(node.tag) !== 'string' || !node.children instanceof Array || !node.attrs instanceof Object) { throw("Node a json node"); } - indent = indent || 0; - var sindent = new Array(indent + 1).join('\t'), - r = sindent + '<' + node.tag; for (var attr in node.attrs) { var vattr = node.attrs[attr]; if (typeof(vattr) !== 'string') { @@ -973,19 +973,19 @@ session.web.json_node_to_xml = function(node, single_quote, indent) { vattr = JSON.stringify(vattr); } vattr = vattr.replace(/&/g, '&').replace(//g, '>').replace(/"/g, '"'); - if (single_quote) { + if (human_readable) { vattr = vattr.replace(/"/g, "'"); } r += ' ' + attr + '="' + vattr + '"'; } if (node.children && node.children.length) { - r += '>\n'; + r += '>' + cr; var childs = []; for (var i = 0, ii = node.children.length; i < ii; i++) { - childs.push(session.web.json_node_to_xml(node.children[i], single_quote, indent + 1)); + childs.push(session.web.json_node_to_xml(node.children[i], human_readable, indent + 1)); } - r += childs.join('\n'); - r += '\n' + sindent + ''; + r += childs.join(cr); + r += cr + sindent + ''; return r; } else { return r + '/>'; From f13ac6ab76628d3488a34521d3d5577d128a21af Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 18:51:28 +0200 Subject: [PATCH 090/163] [IMP] Kanban: add underscore to rendering context of kanban boxes bzr revid: fme@openerp.com-20111025165128-ud1b2lsoe3uhlsjm --- addons/web_kanban/static/src/js/kanban.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index d8fcbd1b6cc..b0ec9f26b82 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -55,7 +55,8 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ record: this.do_transform_record(record), kanban_color: _.bind(this.kanban_color, this), kanban_gravatar: _.bind(this.kanban_gravatar, this), - kanban_image: _.bind(this.kanban_image, this) + kanban_image: _.bind(this.kanban_image, this), + '_' : _ } }, kanban_color: function(variable) { From 17dfb2256d1b8ae477c8d9b63a72d90c6b92dbba Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 18:58:10 +0200 Subject: [PATCH 091/163] [IMP] Improved project.task kanban view [ADD] Added static folder structure for the pad image [FIX] Added relation for field user_email. Using user_id for gravatar won't work. bzr revid: fme@openerp.com-20111025165810-eu5718pd0p2dagib --- addons/project/project.py | 1 + addons/project/project_view.xml | 18 +++++++++--------- .../static/src/img/kanban-pad-openerp.png | Bin 0 -> 410 bytes 3 files changed, 10 insertions(+), 9 deletions(-) create mode 100644 addons/project/static/src/img/kanban-pad-openerp.png diff --git a/addons/project/project.py b/addons/project/project.py index 05bed8a9b9a..3431aaec229 100644 --- a/addons/project/project.py +++ b/addons/project/project.py @@ -471,6 +471,7 @@ class task(osv.osv): 'company_id': fields.many2one('res.company', 'Company'), 'id': fields.integer('ID', readonly=True), 'color': fields.integer('Color Index'), + 'user_email': fields.related('user_id', 'user_email', type='char', string='User Email', readonly=True), } _defaults = { diff --git a/addons/project/project_view.xml b/addons/project/project_view.xml index 94724993a9d..3f638000b40 100644 --- a/addons/project/project_view.xml +++ b/addons/project/project_view.xml @@ -325,8 +325,10 @@ + + http://pad.openerp.com/
      @@ -338,7 +340,7 @@
      - +
      @@ -350,9 +352,7 @@
      @@ -360,17 +360,17 @@

      diff --git a/addons/project/static/src/img/kanban-pad-openerp.png b/addons/project/static/src/img/kanban-pad-openerp.png new file mode 100644 index 0000000000000000000000000000000000000000..ad64c5aea0e668dffe62df3a4f390d3892211ee1 GIT binary patch literal 410 zcmex=_Q(EP1x3Kq!y4?5LRl6;e{H*R8bSPY2y@_Ly#$?&;TmL>4 PzPPb}Lc%(0`~Noqfn#N* literal 0 HcmV?d00001 From de31afa995eb169a92c75dbad930b917252c7f78 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 20:50:30 +0200 Subject: [PATCH 092/163] [FIX] Password fields values are not hidden lp bug: https://launchpad.net/bugs/880804 fixed bzr revid: fme@openerp.com-20111025185030-vw69honpjoaekh2v --- addons/web/static/src/js/view_form.js | 11 +++++++++++ addons/web/static/src/xml/base.xml | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index e3584c21c13..c701f21fee1 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1170,6 +1170,10 @@ openerp.web.form.Field = openerp.web.form.Widget.extend(/** @lends openerp.web.f openerp.web.form.FieldChar = openerp.web.form.Field.extend({ template: 'FieldChar', + init: function (view, node) { + this._super(view, node); + this.password = this.node.attrs.password === 'True' || this.node.attrs.password === '1'; + }, start: function() { this._super.apply(this, arguments); this.$element.find('input').change(this.on_ui_change); @@ -2858,9 +2862,16 @@ openerp.web.form.FieldReadonly = openerp.web.form.Field.extend({ }); openerp.web.form.FieldCharReadonly = openerp.web.form.FieldReadonly.extend({ template: 'FieldChar.readonly', + init: function(view, node) { + this._super(view, node); + this.password = this.node.attrs.password === 'True' || this.node.attrs.password === '1'; + }, set_value: function (value) { this._super.apply(this, arguments); var show_value = openerp.web.format_value(value, this, ''); + if (this.password) { + show_value = new Array(show_value.length + 1).join('*'); + } this.$element.find('div').text(show_value); return show_value; } diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml index 7e081520ffc..7b330cd8112 100644 --- a/addons/web/static/src/xml/base.xml +++ b/addons/web/static/src/xml/base.xml @@ -763,7 +763,7 @@

      - Date: Tue, 25 Oct 2011 21:26:39 +0200 Subject: [PATCH 093/163] [FIX] Fixed project.issue kanban view Also fixed some indenting bzr revid: fme@openerp.com-20111025192639-062sauerwzqhik67 --- addons/project_issue/project_issue.py | 3 ++- addons/project_issue/project_issue_view.xml | 16 ++++++++++------ 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/addons/project_issue/project_issue.py b/addons/project_issue/project_issue.py index e94349e028f..5575eee71d8 100644 --- a/addons/project_issue/project_issue.py +++ b/addons/project_issue/project_issue.py @@ -226,7 +226,8 @@ class project_issue(crm.crm_case, osv.osv): multi='compute_day', type="float", store=True), 'inactivity_days': fields.function(_compute_day, string='Days since last action', \ multi='compute_day', type="integer", help="Difference in days between last action and current date"), - 'color': fields.integer('Color Index'), + 'color': fields.integer('Color Index'), + 'user_email': fields.related('user_id', 'user_email', type='char', string='User Email', readonly=True), 'message_ids': fields.one2many('mail.message', 'res_id', 'Messages', domain=[('model','=',_name)]), 'date_action_last': fields.datetime('Last Action', readonly=1), 'date_action_next': fields.datetime('Next Action', readonly=1), diff --git a/addons/project_issue/project_issue_view.xml b/addons/project_issue/project_issue_view.xml index 00e6a00c163..c6d852cfde0 100644 --- a/addons/project_issue/project_issue_view.xml +++ b/addons/project_issue/project_issue_view.xml @@ -261,15 +261,19 @@ - + - + Project Issue Kanban project.issue kanban - + + + + +
      @@ -283,7 +287,7 @@
      - +
      @@ -315,11 +319,11 @@ - +

      From 39904f481ad27984cb985e56083ab618f7dc109b Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Tue, 25 Oct 2011 22:48:47 +0200 Subject: [PATCH 094/163] [FIX] Fixed partner kanban view (Missing tags) [ADD] Added partners image for kanban view bzr revid: fme@openerp.com-20111025204847-qjalrra46mgxmvvn --- openerp/addons/base/res/res_partner_view.xml | 34 ++++++++++-------- .../base/static/src/img/kanban_partner.png | Bin 0 -> 6952 bytes 2 files changed, 20 insertions(+), 14 deletions(-) create mode 100644 openerp/addons/base/static/src/img/kanban_partner.png diff --git a/openerp/addons/base/res/res_partner_view.xml b/openerp/addons/base/res/res_partner_view.xml index 5f3ebf73f46..33fde6c5d1b 100644 --- a/openerp/addons/base/res/res_partner_view.xml +++ b/openerp/addons/base/res/res_partner_view.xml @@ -105,13 +105,16 @@ - + res.partner.address.kanban res.partner.address kanban - + + + + @@ -133,22 +136,22 @@ @@ -157,7 +160,7 @@
      - +
      - , + ,
      - , + ,
      - , + ,
      - @@ -475,7 +481,7 @@
      - + diff --git a/openerp/addons/base/static/src/img/kanban_partner.png b/openerp/addons/base/static/src/img/kanban_partner.png new file mode 100644 index 0000000000000000000000000000000000000000..56a8ef11d0ff6a6bf358562cba450d1e4bd30dd5 GIT binary patch literal 6952 zcmZ`;bx;&uw5AqVy1RCll7^+0?i2x0LO{AZT)JCo0fm(=B}7uXJETOE6c*`{Tte#c zd;h&Z-kkg0Z|2PT?wvU^_s%zS67-&_6B95HU|?VnYig)Ge`JOKfRFpQS2}sEJQA+8 zwz>+&!+%lOS(fpb0eWhf_&l=4|3YolMee^O+*8rvkrn#5iUasKi z6Iu4YF4mmAJMzKB&s6FA_AnA8vHEW^FKEhadHcUyFf~ znsREO?9(@PhfSslUV(`(-SE3C#tDACS0;CSvJwRa@A9AIrC*bRdyy`K(Ko8Xzu*_x z-;d2n1l%>@N^#pvE&}m`DYZ7kB*ra{L0*S=8v$I2_rD3Y4vP2DPXNKoTfRM(< zTlq87W+KLhDf&OAZU5L9AZw9VnEDB$rqAoWi>F5%_?tcYu|@x_tq)7e6>nd%$hmT@ zy>W&Mgz~!us(H&%=44+KNUW%_Syx>}>K-yN85OT}fw{8cTzOq;x4c2zl5`>>P>{4V zV?7zHwH1+`P4LQLD)P_iW?|4hm@Yf}CySB(Z$3{lQvAf^2L_|x-GyIoy=)Ai%bgDx ze`Wm@hMT_!9?5YOb+pkuZ}288&Ul^~gy%1;4@`KV?{9@;J@vj_X#&RqcJ`i;Ojdt! zHz!AjX|=e#iZM>~Y`(rWJYG0zmZ( z-L_{tT3}f*i)%ejA-=L4#J(}BKE&acnv`-aDI&i1Fy+b1C_R+!b|$R5Bc!wO#~uRr z^4RhWa6|~tFDyiKcgsh|#x{Y7`uh4nGBQkHFqln5gaTYr%*HU9@HPcEo$)E(0s@gv z^0M*G^sF~!w#P~&Czi|+4+DcoA=fNM?8KMj`DmNoG~p1XlJ)!7{R=XfHjeIRWDPgM+JN zsYix`8>irDj3dSbl@dcOCKv4ZH`b-4gi$vdF&35<6Fe93VTm0a*agI@YXVf&9zt-A z4^(Z08(gH@0$!XQ99Wo7|G<+C2|=A*qjq-iQ=UCTZEO%t3J9S7>=9JEyQ5-@P-|^ekF`kZ{+11Q|IaX@Dw+o`D~=^L~vI`h8$|+w-{f?x?_QQlT(5;KG!0vGrlF za^FY6IMsVuoWjqv0Tv{;Xt2FU`oQ@3cyH`5HVZ{hb0fgiH%vN0c7BOaG5&+a1`313 zS~#9Ljn07`SM!9J2m~a24)rN4Y@yN`<1K3G_~W6fs7b#;MWyJicA-rKkU#1{)P;hq zl5{P1y4Ay%I0}rupN#g<;`h!E;EeP0^~|ILGWo=7VN57vlL+b|(YYbqgf;BcbT9$| zR(Y<67p*p^q!WVeWuQO{ppr(UW#BDb$As~U_?&_GrD@Ye>Mih82iX0u@uu+6Iu0FJ z*zLOE`y2&X8d#PU*mVtzj*iY&xN`uA4W*D66dUT}!#+sCXUu0=2kUW%3@pZ~1J@wr zijKZ=)q3RBGN9gm2@IJ#ED$%Cp?E!mO%6s(VE|=&!hc4Jz)WxogUe@x7RYdc#Utb- z#Geq4rU-QS!aQSoCL>PH(MNKa)<&c)j*djZL3p*Q2fr^N2iI1D<>eI-e_PKAJsjhC zrl>}19U)P~d?X<3H<;-tRt8KM-Hq)V0qV=BV9mAApNo#$42d5(FNMKjZkVG@V>*SuB z-|RgN)^=g6rETvC-BdnCFTSaD`et~g=)}q-2Pb-=TM?DnM1oLp z3g0CED2Rm657g%NSu3E`(oA2x1?gct%a^m{C-Vz;Il>oL;zA|l_R>7yf<{(GnWHCJ zG~VIOOShMJxm)g|l(xwb*Be0_H->PMo?#cd%d6Yqe}2=9ub5;zsLeVB{ZcV#*?SDR zW1$X>ipr+6qLX{!5p_@EbIlaZl?lb&SFl#WK+~o$yw$^HKzo=T*2g4u17>45Tg+(h%{Y_05snSH8%moE%5)!VZNLHJm)d36_reBMv~yD zC}^N?w8Mh=j3w)}_hIxbStFEzsLHkk$pD9;ib%Y9j^fEG!jw0yd5bq-^X-}x= z>+553$>@I;fbQ+B5PD*Pz$lE!r|B)HZ-tm{dq!p$i1@2^=cy5`xLbynV_Oj=?GmH+ z<-qD*bU}7`6Wev{E%9n$Ee#P6koMW(65rGFP1tB%U5pLaOH|9-S9mEEUK6b_T5FI}=6iMlSz?4_7w0>}$jHg-T-n1*^ux`&1Jh5a*&NI2E2sfarGC5v^yZ2tO{XG>wy z-=~IOp(J1uR{4nE%!G^m8_|nT^pr_^4YL?(k^}lj`x%WOq!dCKT$V$jl*r%EdPID1 zi!Y3Bk{%hc6`(xbVR_DZoIM1?p8f?bI$uaRswOo1Zb`y9wYlz0x*UfIeEcn=*2@%e&kBvv^V=j%-N(r*Ss6Tp@~(?j;!2*>HUx*t;DC6F`E01O*l@ixF(ET)+%f%rg%HX z!@fhN^8Q=~1~ok$-+1APZd>l#TH^IQ9Q^GXbQmp2{B+!kcIfJF=gmEaRxP38A9FT1 zE`>;-8s{ujQbt-!!PQ&Ja_S*;;9hRXn!lTg0x0$Glc(`Z%4fO1icX%zgEpaf84fgU zeui-vJjK^B!8_Ruwjbw}A>%lBU} zOAC`SVM?b_;zX-O(rIS_15+{fz1b@@i?Oilh8{p8Avkb283lD}(Yks+m?ej6_8Ji_ zz^_Qd*$KD(5p;N|Z1YDdpE4;>aU-w-K>0C}!)SUUM9yVJJCE?+*IBofw!k~_fovvSG0rrKYM;7Fz2+m1h4l{?^dN)Uw+l;9;qRf$4{i(MOmBob!- zdYsGMGdZP5j)TQ@NdqCQj--!UmBkug_$4UzX0pG{L%c_VvHOngm&d$@Yy_8Qc!n`B zC07z?*aS99qpQ4-5%j~9oWdiH*PVzAuN@Irc~j-8=PxRj$*txZydwqHwF^F3}qe2Zmb2$_RhS;yCLQ7C*{uJ*RQ$)s84&( zza+yhrg$!l6DgGh-o`Orlv4Oho_EsaKn5G9mTbzE5I35ZuzCDGuniK8c=i}-UwFZ| ztBtP}`IM{Fb%p9sJxxdOo-Mbf-go`jg0uT1)%hqCyh7XaW{!w&nNqk6{ENasH7J34kh-W){QZ z?Ob)Q^)*_RH?mGI+OY7dm=x2z${%FgZu2f>`)7vkQ-F!>I&3tgb#;`&?)T5ak};^! zKlT>4(XXE6OJRS@tchOm+3sBqIJ5eDduc5nN;(0jYI3P)#xCQrJE2 zO(kWP?mGOM3Gd7vGBHjW(#a9V{xp>ffUZRCLhYaHPPbYrsGkOGRV~!Q`#Gn7O7y=x z`ShSbqZ?lPpo|ch;^K~k`-h1irGk3)){{!eya@?Fk}_DXIK?mWI~`N#P2aB(w(kJT zPm$O+&xC?5A6jl(#wwKF=r9{M+A}}R76EYTejvyw>jHGB8JcTvgPC`k2HsUzScP6? zS4u}Ta4~RxYF$h1*-8{TiJ5Ufn%e3lwKoh-3Ly`{Wdu4pw-P@Z=*W?INp?l!vBm}q zo5S6iL|&>l$oiQil*eJby0 z>O(gfNxt6j>y`KH+y^_7Znb;9lZp`6-U%+UBolEDvoPB3u+-=erHxH^lq9Ut8oq&W zOi}UQkwK&^{p(!1AYl$_*MpcjSn!gpjPx4UuO@RUjhtpTyRL<=fV$m8=JqgrJ=qep z_gNFO&|hr;f)z?LlynyvnX7x}%ut>WBQ)?l2=*ACuS>uAVc%07g69>(guoFt6Kd)a zsDX~xZEjjmwj`Oe-h2rp^yXuy<`eyxo;yQGy1O>rtIvjZle=wsd&f!*zxAqte*cClZEbYGnuMS zE0t)>`7snlxz+VtQ@F*9ZvSZemtJ?6yF4e+phRl9wnv#qP6AV<)_Wa9%u{0)wf9d= zOX&`6-vVE^kE8v%+(r21lC|%QR#C+RypO-4)L-tr)h2!ysb8WVb()sJCgChf#2~5>*&F4A&-c0#Uptfkff~rW zvsANsB1pv<+LlYPa zFb~<*zDK0L#E;oDDr~7I(fVAY6rh9sqUdJsb>~Stt!NRgrHE_SPXdXfq{T(~aRe>oW$H4yExvyJPO z+br=_fjIe(TeQ%9?y1b8s|9 zba8>ulHW6yQe#M8j9>3(TlnXcwL%BnMdN3OxiWRDQ?UnqS|j`wv9~h}+)5N$m3u`* zn*PItLPQKX8gv>RD8u~_qPRFwrfgI9$o4E!I#c6M^f{)Jvi5B`!eU2YUwzN!<6!2?Z2P1PCsgh=tW)}t*6Sfs1qICCVdGa z5z2ud-q|j(Y|0Mn?u%#psCxEBWAk-Ea%Uw|S1gl?EVa~A@+hNKxRkY?0ZX^vE7~i< zY-wLAv83zi84?as?*KHER1bqXFet4Z1Y3NvZixg(fnWTNB0Vh0*f8y4Khd~MF&+oe zBWv5#`jB<&NNhD;~o=nFLzr@b5Q$u^K5jt|qRFs}VuqFBRbl?$aIqZt=bH9)O@iBR{np!beEdx5~ z=>^gl`SAH$f>+D3hMJmMY+B~~5Ap6S;vT)lj3sK{mM)G~!#G#&H!^hP?om+j13hc^ zfI*QQ_(4vMudx`qw$gC_?_FFNAyIO8{g`u`7Xw8Gk*3LDJXk}KV#Zs06&=}RcHBfO zy3E#!G8bffzt-E&bxftnRXCQEN^JU|BjcTk2nN-?U>i2BX znskp%=-vmsA0Vv0PoP~67$#&X(gUw~?q4t;1MzWWZ8B(OFYdn&@tb~VWE4-icfZW% zJZ<3_O<9L=KWfWt1ukFu-{khpye*-cx&94e){8d;3ccaic3eo#nqL_{0r5TZq zP`uZjfq-T&(MDS|6Q;|rFAj!PW*ps4OBbI|$J`7xqV`9chE>$+r-{M~j-x!>83Q4v zrx12Mtm>5=&%2Z>kIVsiP*HVJ+F#CX8k%0+9TUOVw^)MTuZ(J5|Cn*KwO{eUsk#jm zYj~lrAKJgguY-xi(cI!}3AkZd?n)G6`bPW23U;kJFNUk=3~jvdIIlQ@83(FmHWZ8Y8Pz1h#{z>ahx@)H$zvpX;>L$FczNpMqvDQBdB z#h*pVx2#jiGTz~OjXLR>7^wSzd}(*$T2x#0mO@2g zuZ#Ug+xB=uI{mtNQ3JGr*ca_yZYAA(+32aI+^~(0lyYMz5weQBjU3d@9{9T=`bpD! zpG?A|qWyxH^fcAO(G^R=L!MjRO#vEadcnmne1a=-S(drvHlR^SILe#8?@z1=29*?t zwmqH|Z@xvlJ~TRIUR$fV^Cv;8CX+`#eRFm9VnxsY%h#^}57Pg%n>& zeeTR|b3q;K5?_~7REW4zs;N-SeSJT$2=@h-S0@+ZvUAjw6QwZ8FZke~_H2S=1Lp@u z4aQ!GHi88Bv&3aQ{6ak9a6m=HpYrd0Go#Kbp1LowgC_I?a-P4_u-CNyC{>h)6#xD% z&w^-7J>~Jiooe)qoDg)XrP4Q8&CJ$Rrj(Z}8=LVobx~`maKJ+;C>E8AJ7n1r(KBPb zY~JYT@!RKn{G~8wS`7|2a63XFcE-g~v!{bi}PF7}#>Nf{AMUf)k=LcgF7+1QZD zsy0J^P9BN*i~nYY$Z3jjA;zx9$1^tiTqdv}9PwVYzpOYJF-D>^a#?>O6+pUsZjxuT z8r)t19~BuS)TTB{a=6zV)}yDlADJ#vwv8oj$QSeIg+gd(lgGoL?9<5e4vJbDDaEH+ zB&A#L^blX5kr&LR@FUGBUe!SjL$hskHhR@8r`fXTI=A(VbMgc1p#*TsvIIL;MfOcZam}(xN&#o^ zfh}zb^w&Lq6506Vu)jIT4U|#)9&l!S{~=E_EBZ#kYje&|&pnarX|^b9jFAVp>)s_L z0vk^R`ycww5ml&Ys-D6Uvf18w(<9BDUhQt?OoCjRSN43$qf)k^IFqSxE?q2zsK(c!R7VTCe@5E-35&Bsd(ZQZBv2aA-V75* zwMel#L&(R&?!MP}Sf~YFd43A(4*h{gN>9=4 zcs(}v=~t8GNE2pVnS8lZUevXArfdeIn3UG5SAmINlg=?(>uivrok7qC=y3S`-G`MB zIlF)7yHGVP=fb1e4-KKF?E$>wCM{PE3v2z9A4^N&kEWJE)b=YD1Z@(w6?UP3gZ*?8MM z5{8J75RCtE2}559L#2eEQcw|IArUDdA@#C5o&O_n^RRWY5BUED;{Q}n9tHIO-C*Eh r@9SsfZHM9K=O^Ig?&4!(iW#s<=;n3nQ literal 0 HcmV?d00001 From 0d2ae40a70ba3be3ccf8e439b4ed92a1ec4719d6 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Wed, 26 Oct 2011 01:31:41 +0200 Subject: [PATCH 095/163] [FIX] Complete refactoring of project_long_term, with following changes: do not use resources but users on phases: - to be consistent with project members and task responsible - if the user is linked to a resource, it uses the calendar of the resource (holidays for example) better YML tests Complete rewrite of the scheduling mechanism: - Schedule phases: - write project.user.allocation based on scheduling - schedule resources based on members on the project - new constraint: force some users on a phase - Schedule tasks: - set user if no user on task - set start and end date some useability improvements We still have to work on better Gantt view but I think the scheduling is working correctly now. bzr revid: fp@tinyerp.com-20111025233141-cgctwe8spxhko2gn --- addons/project_long_term/__openerp__.py | 2 - addons/project_long_term/project_long_term.py | 777 +++++------------- .../project_long_term_demo.xml | 104 +-- .../project_long_term_view.xml | 157 ++-- .../security/ir.model.access.csv | 12 +- .../test/phase_constraint.yml | 3 +- .../test/project_schedule_consecutive_day.yml | 9 +- .../project_schedule_without_wroking_hour.yml | 3 +- .../test/schedule_phase_tasks.yml | 90 -- .../test/schedule_project_phases.yml | 40 +- .../test/schedule_project_tasks.yml | 26 +- .../test/test_schedule_phases_case1.yml | 8 +- .../test/test_schedule_phases_case2.yml | 2 +- .../test/test_schedule_tasks_case1.yml | 9 +- addons/project_long_term/wizard/__init__.py | 1 - .../wizard/project_compute_phases.py | 23 +- .../wizard/project_compute_phases_view.xml | 42 +- .../wizard/project_compute_tasks.py | 2 +- .../wizard/project_compute_tasks_view.xml | 42 +- .../wizard/project_schedule_tasks.py | 51 -- .../wizard/project_schedule_tasks_view.xml | 33 - addons/resource/resource.py | 28 +- 22 files changed, 356 insertions(+), 1108 deletions(-) delete mode 100644 addons/project_long_term/test/schedule_phase_tasks.yml delete mode 100644 addons/project_long_term/wizard/project_schedule_tasks.py delete mode 100644 addons/project_long_term/wizard/project_schedule_tasks_view.xml diff --git a/addons/project_long_term/__openerp__.py b/addons/project_long_term/__openerp__.py index ef57f53e5f1..31522d63ea2 100644 --- a/addons/project_long_term/__openerp__.py +++ b/addons/project_long_term/__openerp__.py @@ -49,13 +49,11 @@ Features 'test/test_schedule_phases_case2.yml', 'test/project_schedule_consecutive_day.yml', 'test/project_schedule_without_wroking_hour.yml', - 'test/schedule_phase_tasks.yml', 'test/phase_constraint.yml', 'test/test_schedule_tasks_case1.yml', ], "update_xml": [ "security/ir.model.access.csv", - "wizard/project_schedule_tasks_view.xml", "project_long_term_view.xml", "project_long_term_workflow.xml", "wizard/project_compute_phases_view.xml", diff --git a/addons/project_long_term/project_long_term.py b/addons/project_long_term/project_long_term.py index 7cd6697b67a..77fa3f38c02 100644 --- a/addons/project_long_term/project_long_term.py +++ b/addons/project_long_term/project_long_term.py @@ -22,7 +22,7 @@ from datetime import datetime from tools.translate import _ from osv import fields, osv -from resource.faces import task as Task +from resource.faces import task as Task from operator import itemgetter class project_phase(osv.osv): @@ -74,40 +74,43 @@ class project_phase(osv.osv): return False return True - def _check_constraint_start(self, cr, uid, ids, context=None): - phase = self.read(cr, uid, ids[0], ['date_start', 'constraint_date_start'], context=context) - if phase['date_start'] and phase['constraint_date_start'] and phase['date_start'] < phase['constraint_date_start']: - return False - return True - - def _check_constraint_end(self, cr, uid, ids, context=None): - phase = self.read(cr, uid, ids[0], ['date_end', 'constraint_date_end'], context=context) - if phase['date_end'] and phase['constraint_date_end'] and phase['date_end'] > phase['constraint_date_end']: - return False - return True - def _get_default_uom_id(self, cr, uid): model_data_obj = self.pool.get('ir.model.data') model_data_id = model_data_obj._get_id(cr, uid, 'product', 'uom_hour') return model_data_obj.read(cr, uid, [model_data_id], ['res_id'])[0]['res_id'] - def _compute(self, cr, uid, ids, field_name, arg, context=None): + def _compute_progress(self, cr, uid, ids, field_name, arg, context=None): res = {} if not ids: return res for phase in self.browse(cr, uid, ids, context=context): - tot = 0.0 + if phase.state=='done': + res[phase.id] = 100.0 + continue + elif phase.state=="cancelled": + res[phase.id] = 0.0 + continue + elif not phase.task_ids: + res[phase.id] = 0.0 + continue + + tot = done = 0.0 for task in phase.task_ids: - tot += task.planned_hours - res[phase.id] = tot + tot += task.total_hours + done += min(task.effective_hours, task.total_hours) + + if not tot: + res[phase.id] = 0.0 + else: + res[phase.id] = round(100.0 * done / tot, 2) return res _columns = { 'name': fields.char("Name", size=64, required=True), - 'date_start': fields.date('Start Date', help="It's computed by the scheduler according the project date or the end date of the previous phase.", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), - 'date_end': fields.date('End Date', help=" It's computed by the scheduler according to the start date and the duration.", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), - 'constraint_date_start': fields.date('Minimum Start Date', help='force the phase to start after this date', states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), - 'constraint_date_end': fields.date('Deadline', help='force the phase to finish before this date', states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), + 'date_start': fields.datetime('Start Date', help="It's computed by the scheduler according the project date or the end date of the previous phase.", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), + 'date_end': fields.datetime('End Date', help=" It's computed by the scheduler according to the start date and the duration.", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), + 'constraint_date_start': fields.datetime('Minimum Start Date', help='force the phase to start after this date', states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), + 'constraint_date_end': fields.datetime('Deadline', help='force the phase to finish before this date', states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), 'project_id': fields.many2one('project.project', 'Project', required=True), 'next_phase_ids': fields.many2many('project.phase', 'project_phase_rel', 'prv_phase_id', 'next_phase_id', 'Next Phases', states={'cancelled':[('readonly',True)]}), 'previous_phase_ids': fields.many2many('project.phase', 'project_phase_rel', 'next_phase_id', 'prv_phase_id', 'Previous Phases', states={'cancelled':[('readonly',True)]}), @@ -115,74 +118,27 @@ class project_phase(osv.osv): 'duration': fields.float('Duration', required=True, help="By default in days", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), 'product_uom': fields.many2one('product.uom', 'Duration UoM', required=True, help="UoM (Unit of Measure) is the unit of measurement for Duration", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), 'task_ids': fields.one2many('project.task', 'phase_id', "Project Tasks", states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), - 'resource_ids': fields.one2many('project.resource.allocation', 'phase_id', "Project Resources",states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), - 'responsible_id': fields.many2one('res.users', 'Responsible', states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}), + 'user_force_ids': fields.many2many('res.users', string='Force Assigned Users'), + 'user_ids': fields.one2many('project.user.allocation', 'phase_id', "Assigned Users",states={'done':[('readonly',True)], 'cancelled':[('readonly',True)]}, + help="The ressources on the project can be computed automatically by the scheduler"), 'state': fields.selection([('draft', 'New'), ('open', 'In Progress'), ('pending', 'Pending'), ('cancelled', 'Cancelled'), ('done', 'Done')], 'State', readonly=True, required=True, help='If the phase is created the state \'Draft\'.\n If the phase is started, the state becomes \'In Progress\'.\n If review is needed the phase is in \'Pending\' state.\ \n If the phase is over, the states is set to \'Done\'.'), - 'total_hours': fields.function(_compute, string='Total Hours'), + 'progress': fields.function(_compute_progress, string='Progress', help="Computed based on related tasks"), } _defaults = { - 'responsible_id': lambda obj,cr,uid,context: uid, 'state': 'draft', 'sequence': 10, 'product_uom': lambda self,cr,uid,c: self.pool.get('product.uom').search(cr, uid, [('name', '=', _('Day'))], context=c)[0] } - _order = "project_id, date_start, sequence, name" + _order = "project_id, date_start, sequence" _constraints = [ (_check_recursion,'Loops in phases not allowed',['next_phase_ids', 'previous_phase_ids']), (_check_dates, 'Phase start-date must be lower than phase end-date.', ['date_start', 'date_end']), ] def onchange_project(self, cr, uid, ids, project, context=None): - result = {} - result['date_start'] = False - project_obj = self.pool.get('project.project') - if project: - project_id = project_obj.browse(cr, uid, project, context=context) - result['date_start'] = project_id.date_start - return {'value': result} - - - def _check_date_start(self, cr, uid, phase, date_end, context=None): - """ - Check And Compute date_end of phase if change in date_start < older time. - """ - uom_obj = self.pool.get('product.uom') - resource_obj = self.pool.get('resource.resource') - cal_obj = self.pool.get('resource.calendar') - calendar_id = phase.project_id.resource_calendar_id and phase.project_id.resource_calendar_id.id or False - resource_id = resource_obj.search(cr, uid, [('user_id', '=', phase.responsible_id.id)]) - if resource_id: - res = resource_obj.read(cr, uid, resource_id, ['calendar_id'], context=context)[0] - cal_id = res.get('calendar_id', False) and res.get('calendar_id')[0] or False - if cal_id: - calendar_id = cal_id - default_uom_id = self._get_default_uom_id(cr, uid) - avg_hours = uom_obj._compute_qty(cr, uid, phase.product_uom.id, phase.duration, default_uom_id) - work_times = cal_obj.interval_min_get(cr, uid, calendar_id, date_end, avg_hours or 0.0, resource_id and resource_id[0] or False) - dt_start = work_times[0][0].strftime('%Y-%m-%d') - self.write(cr, uid, [phase.id], {'date_start': dt_start, 'date_end': date_end.strftime('%Y-%m-%d')}, context=context) - - def _check_date_end(self, cr, uid, phase, date_start, context=None): - """ - Check And Compute date_end of phase if change in date_end > older time. - """ - uom_obj = self.pool.get('product.uom') - resource_obj = self.pool.get('resource.resource') - cal_obj = self.pool.get('resource.calendar') - calendar_id = phase.project_id.resource_calendar_id and phase.project_id.resource_calendar_id.id or False - resource_id = resource_obj.search(cr, uid, [('user_id', '=', phase.responsible_id.id)], context=context) - if resource_id: - res = resource_obj.read(cr, uid, resource_id, ['calendar_id'], context=context)[0] - cal_id = res.get('calendar_id', False) and res.get('calendar_id')[0] or False - if cal_id: - calendar_id = cal_id - default_uom_id = self._get_default_uom_id(cr, uid) - avg_hours = uom_obj._compute_qty(cr, uid, phase.product_uom.id, phase.duration, default_uom_id) - work_times = cal_obj.interval_get(cr, uid, calendar_id, date_start, avg_hours or 0.0, resource_id and resource_id[0] or False) - dt_end = work_times[-1][1].strftime('%Y-%m-%d') - self.write(cr, uid, [phase.id], {'date_start': date_start.strftime('%Y-%m-%d'), 'date_end': dt_end}, context=context) + return {} def copy(self, cr, uid, id, default=None, context=None): if default is None: @@ -211,208 +167,58 @@ class project_phase(osv.osv): self.write(cr, uid, ids, {'state': 'done'}) return True - def generate_phase(self, cr, uid, ids, f, parent=False, context=None): - if context is None: - context = {} - phase_ids = [] - data_pool = self.pool.get('ir.model.data') - uom_pool = self.pool.get('product.uom') - task_pool = self.pool.get('project.task') - data_model, day_uom_id = data_pool.get_object_reference(cr, uid, 'product', 'uom_day') - for phase in self.browse(cr, uid, ids, context=context): - avg_days = uom_pool._compute_qty(cr, uid, phase.product_uom.id, phase.duration, day_uom_id) - duration = str(avg_days) + 'd' - # Create a new project for each phase - str_resource = ('%s & '*len(phase.resource_ids))[:-2] - str_vals = str_resource % tuple(map(lambda x: 'Resource_%s'%x.resource_id.id, phase.resource_ids)) + def generate_phase(self, cr, uid, phases, context=None): + context = context or {} + result = "" - # Phases Defination for the Project - s = ''' + task_pool = self.pool.get('project.task') + for phase in phases: + if phase.state in ('done','cancelled'): + continue + duration_uom = { + 'days': 'd', 'day': 'd', 'd':'d', + 'months': 'm', 'month':'month', 'm':'m', + 'weeks': 'w', 'week': 'w', 'w':'w', + 'hours': 'H', 'hour': 'H', 'h':'H', + }.get(phase.product_uom.name.lower(), "h") + duration = str(phase.duration) + duration_uom + result += ''' def Phase_%s(): title = \"%s\" - effort = \'%s\' - resource = %s -'''%(phase.id, phase.name, duration, str_vals or False) - - # Recalculate date_start and date_end - # according to constraints on date start and date end on phase - start_date = '' - end_date = '' + effort = \"%s\"''' % (phase.id, phase.name, duration) + start = [] if phase.constraint_date_start: - start_date = datetime.strptime(phase.constraint_date_start, '%Y-%m-%d') - s += ''' - start = \"%s\" -'''%(datetime.strftime(start_date, "%Y-%m-%d")) - else: - if parent: - start = 'up.Phase_%s.end' % (parent.id) - s += ''' - start = %s -'''%(start) - else: - start = phase.project_id.date_start or phase.date_start - s += ''' - start = \"%s\" -'''%(start) - - if phase.constraint_date_end : - end_date= datetime.strptime(phase.constraint_date_end, '%Y-%m-%d') - s += ''' - end = \"%s\" -'''%(datetime.strftime(end_date, "%Y-%m-%d")) + start.append('datetime.datetime.strptime("'+str(phase.constraint_date_start)+'", "%Y-%m-%d %H:%M:%S")') + for previous_phase in phase.previous_phase_ids: + start.append("up.Phase_%s.end" % (previous_phase.id,)) + if start: + result += ''' + start = max(%s) +''' % (','.join(start)) + if phase.user_force_ids: + result += ''' + resource = %s +''' % '|'.join(map(lambda x: 'User_'+str(x.id), phase.user_force_ids)) - #start = datetime.strftime((datetime.strptime(start, "%Y-%m-%d")), "%Y-%m-%d") + result += task_pool._generate_task(cr, uid, phase.task_ids, ident=8, context=context) + result += "\n" - phase_ids.append(phase.id) - parent = False - task_ids = [] - todo_task_ids = task_pool.search(cr, uid, [('id', 'in', map(lambda x : x.id, phase.task_ids)), - ('state', 'in', ['draft', 'open', 'pending']) - ], order='sequence') - if todo_task_ids : - for task in task_pool.browse(cr, uid, todo_task_ids, context=context): - s += task_pool.generate_task(cr, uid, task.id, parent=parent, flag=False, context=context) - if not parent: - parent = task - task_ids.append(task.id) - - f += s + '\n' - # Recursive call till all the next phases scheduled - for next_phase in phase.next_phase_ids: - if next_phase.state in ['draft', 'open', 'pending']: - rf, rphase_ids = self.generate_phase(cr, uid, [next_phase.id], f = '', parent=phase, context=context) - f += rf +'\n' - phase_ids += rphase_ids - else: - continue - return f, phase_ids - - def schedule_tasks(self, cr, uid, ids, context=None): - """ - Schedule tasks base on faces lib - """ - if context is None: - context = {} - if type(ids) in (long, int,): - ids = [ids] - task_pool = self.pool.get('project.task') - resource_pool = self.pool.get('resource.resource') - for phase in self.browse(cr, uid, ids, context=context): - project = phase.project_id - calendar_id = project.resource_calendar_id and project.resource_calendar_id.id or False - start_date = project.date_start - #Creating resources using the member of the Project - u_ids = [i.id for i in project.members] - resource_objs = resource_pool.generate_resources(cr, uid, u_ids, calendar_id, context=context) - start_date = datetime.strftime((datetime.strptime(start_date, "%Y-%m-%d")), "%Y-%m-%d") - func_str = '' - start = start_date - minimum_time_unit = 1 - # default values - working_hours_per_day = 24 - working_days_per_week = 7 - working_days_per_month = 30 - working_days_per_year = 365 - - vacation = [] - if calendar_id: - working_hours_per_day = 8 #TODO: it should be come from calendars - working_days_per_week = 5 - working_days_per_month = 20 - working_days_per_year = 200 - vacation = tuple(resource_pool.compute_vacation(cr, uid, calendar_id, context=context)) - - working_days = resource_pool.compute_working_calendar(cr, uid, calendar_id, context=context) - - cls_str = '' - # Creating Resources for the Project - for key, vals in resource_objs.items(): - cls_str +=''' - class Resource_%s(Resource): - title = \"%s\" - vacation = %s - efficiency = %s -'''%(key, vals.get('name',False), vals.get('vacation', False), vals.get('efficiency', False)) - - # Create a new project for each phase - func_str += ''' -def Phase_%d(): - from resource.faces import Resource - title = \"%s\" - start = \'%s\' - minimum_time_unit = %s - working_hours_per_day = %s - working_days_per_week = %s - working_days_per_month = %s - working_days_per_year = %s - vacation = %s - working_days = %s -'''%(phase.id, phase.name, start, minimum_time_unit, working_hours_per_day, working_days_per_week, working_days_per_month, working_days_per_year, vacation, working_days ) - - parent = False - task_ids = [] - todo_task_ids = task_pool.search(cr, uid, [('id', 'in', map(lambda x : x.id, phase.task_ids)), - ('state', 'in', ['draft', 'open', 'pending']) - ], order='sequence') - for task in task_pool.browse(cr, uid, todo_task_ids, context=context): - func_str += task_pool.generate_task(cr, uid, task.id, parent=parent, flag=True, context=context) - if not parent: - parent = task - task_ids.append(task.id) - func_str += cls_str - phase_id = phase.id - #check known constraints before running Face algorithm in order to have the error translated - if not phase.project_id.date_start: - raise osv.except_osv(_('Error !'),_('Task Scheduling is not possible.\nProject should have the Start date for scheduling.')) - # Allocating Memory for the required Project and Pahses and Resources - exec(func_str) - Phase = eval('Phase_%d' % phase.id) - phase = None - try: - phase = Task.BalancedProject(Phase) - except Exception, e: - raise osv.except_osv(_('Error !'),e) - - for task_id in task_ids: - task = eval("phase.Task_%d" % task_id) - start_date = task.start.to_datetime() - end_date = task.end.to_datetime() - - task_pool.write(cr, uid, [task_id], { - 'date_start': start_date.strftime('%Y-%m-%d %H:%M:%S'), - 'date_end': end_date.strftime('%Y-%m-%d %H:%M:%S') - }, context=context) - return True + return result project_phase() -class project_resource_allocation(osv.osv): - _name = 'project.resource.allocation' - _description = 'Project Resource Allocation' - _rec_name = 'resource_id' - - def get_name(self, cr, uid, ids, field_name, arg, context=None): - res = {} - for allocation in self.browse(cr, uid, ids, context=context): - name = allocation.phase_id.name - name += ' (%s%%)' %(allocation.useability) - res[allocation.id] = name - return res +class project_user_allocation(osv.osv): + _name = 'project.user.allocation' + _description = 'Phase User Allocation' + _rec_name = 'user_id' _columns = { - 'name': fields.function(get_name, type='char', size=256), - 'resource_id': fields.many2one('resource.resource', 'Resource', required=True), + 'user_id': fields.many2one('res.users', 'User', required=True), 'phase_id': fields.many2one('project.phase', 'Project Phase', ondelete='cascade', required=True), 'project_id': fields.related('phase_id', 'project_id', type='many2one', relation="project.project", string='Project', store=True), - 'user_id': fields.related('resource_id', 'user_id', type='many2one', relation="res.users", string='User'), - 'date_start': fields.date('Start Date', help="Starting Date"), - 'date_end': fields.date('End Date', help="Ending Date"), - 'useability': fields.float('Availability', help="Availability of this resource for this project phase in percentage (=50%)"), + 'date_start': fields.datetime('Start Date', help="Starting Date"), + 'date_end': fields.datetime('End Date', help="Ending Date"), } - _defaults = { - 'useability': 100, - } - -project_resource_allocation() +project_user_allocation() class project(osv.osv): _inherit = "project.project" @@ -420,161 +226,104 @@ class project(osv.osv): 'phase_ids': fields.one2many('project.phase', 'project_id', "Project Phases"), 'resource_calendar_id': fields.many2one('resource.calendar', 'Working Time', help="Timetable working hours to adjust the gantt diagram report", states={'close':[('readonly',True)]} ), } - def generate_members(self, cr, uid, ids, context=None): - """ - Return a list of Resource Class objects for the resources allocated to the phase. - """ - res = {} - resource_pool = self.pool.get('resource.resource') - for project in self.browse(cr, uid, ids, context=context): - user_ids = map(lambda x:x.id, project.members) - calendar_id = project.resource_calendar_id and project.resource_calendar_id.id or False - resource_objs = resource_pool.generate_resources(cr, uid, user_ids, calendar_id, context=context) - res[project.id] = resource_objs - return res - - def schedule_phases(self, cr, uid, ids, context=None): - """ - Schedule phase base on faces lib - """ - if context is None: - context = {} + def _schedule_header(self, cr, uid, ids, context=None): + context = context or {} if type(ids) in (long, int,): ids = [ids] - phase_pool = self.pool.get('project.phase') - task_pool = self.pool.get('project.task') + projects = self.browse(cr, uid, ids, context=context) + + for project in projects: + if not project.members: + raise osv.except_osv(_('Warning !'),_("You must assign members on the project '%s' !") % (project.name,)) + resource_pool = self.pool.get('resource.resource') - data_pool = self.pool.get('ir.model.data') - resource_allocation_pool = self.pool.get('project.resource.allocation') - data_model, day_uom_id = data_pool.get_object_reference(cr, uid, 'product', 'uom_day') - - #Checking the Valid Phase resource allocation from project member - for project in self.browse(cr, uid, ids, context=context): - flag = False - res_missing = [] - members_ids = [] - if project.members: - members_ids = [user.id for user in project.members] - for phase in project.phase_ids: - if phase.resource_ids: - res_ids = [ re.id for re in phase.resource_ids] - for res in resource_allocation_pool.browse(cr, uid, res_ids, context=context): - if res.resource_id.user_id.id not in members_ids: - res_missing += [res.resource_id.name] - flag = True - if flag: - raise osv.except_osv(_('Warning !'),_("Resource(s) %s is(are) not member(s) of the project '%s' .") % (",".join(res_missing), project.name)) + result = "from resource.faces import *\n" + result += "import datetime\n" for project in self.browse(cr, uid, ids, context=context): - root_phase_ids = phase_pool.search(cr, uid, [('project_id', '=', project.id), - ('state', 'in', ['draft', 'open', 'pending']), - ('previous_phase_ids', '=', False) - ]) - calendar_id = project.resource_calendar_id and project.resource_calendar_id.id or False - start_date = project.date_start - #if start_date: - # start_date = datetime.strftime((datetime.strptime(start_date, "%Y-%m-%d")), "%Y-%m-%d") - #Creating resources using the member of the Project u_ids = [i.id for i in project.members] + for task in project.tasks: + if task.state in ('done','cancelled'): + continue + if task.user_id and (task.user_id.id not in u_ids): + u_ids.append(task.user_id.id) + calendar_id = project.resource_calendar_id and project.resource_calendar_id.id or False resource_objs = resource_pool.generate_resources(cr, uid, u_ids, calendar_id, context=context) - func_str = '' - start = start_date - minimum_time_unit = 1 - # default values - working_hours_per_day = 24 - working_days_per_week = 7 - working_days_per_month = 30 - working_days_per_year = 365 - - vacation = [] - if calendar_id: - working_hours_per_day = 8 #TODO: it should be come from calendars - working_days_per_week = 5 - working_days_per_month = 20 - working_days_per_year = 200 - vacation = tuple(resource_pool.compute_vacation(cr, uid, calendar_id, context=context)) - - working_days = resource_pool.compute_working_calendar(cr, uid, calendar_id, context=context) - - cls_str = '' - # Creating Resources for the Project for key, vals in resource_objs.items(): - cls_str +=''' - class Resource_%s(Resource): - title = \"%s\" - vacation = %s - efficiency = %s -'''%(key, vals.get('name',False), vals.get('vacation', False), vals.get('efficiency', False)) - - # Create a new project for each phase - func_str += ''' -def Project_%d(): - from resource.faces import Resource + result +=''' +class User_%s(Resource): + title = \"%s\" + efficiency = %s +''' % (key, vals.get('name',False), vals.get('efficiency', False)) + + result += ''' +def Project(): + ''' + return result + + def _schedule_project(self, cr, uid, project, context=None): + resource_pool = self.pool.get('resource.resource') + calendar_id = project.resource_calendar_id and project.resource_calendar_id.id or False + working_days = resource_pool.compute_working_calendar(cr, uid, calendar_id, context=context) + # TODO: check if we need working_..., default values are ok. + result = """ + def Project_%d(): title = \"%s\" start = \'%s\' - minimum_time_unit = %s - working_hours_per_day = %s - working_days_per_week = %s - working_days_per_month = %s - working_days_per_year = %s + working_days = %s + resource = %s +""" % ( + project.id, project.name, + project.date_start, working_days, + '|'.join(['User_'+str(x.id) for x in project.members]) + ) + vacation = calendar_id and tuple(resource_pool.compute_vacation(cr, uid, calendar_id, context=context)) or False + if vacation: + result+= """ vacation = %s - working_days = %s -'''%(project.id, project.name, start, minimum_time_unit, working_hours_per_day, working_days_per_week, working_days_per_month, working_days_per_year, vacation, working_days ) - - func_str += cls_str - phase_ids = [] - for root_phase in phase_pool.browse(cr, uid, root_phase_ids, context=context): - phases, child_phase_ids = phase_pool.generate_phase(cr, uid, [root_phase.id], '', context=context) - func_str += phases - phase_ids += child_phase_ids - - project_id = project.id - if not project.date_start: - raise osv.except_osv(_('Error !'),_('Task Scheduling is not possible.\nProject should have the Start date for scheduling.')) - # Allocating Memory for the required Project and Phases and Resources - exec(func_str) - Project = eval('Project_%d' % project.id) - project = None - try: - project = Task.BalancedProject(Project) - except Exception, e: - raise osv.except_osv(_('Error !'), e) - - for phase_id in phase_ids: - act_phase = phase_pool.browse(cr, uid, phase_id, context=context) - resources = act_phase.resource_ids - phase = eval("project.Phase_%d" % phase_id) - start_date = phase.start.to_datetime() - end_date = phase.end.to_datetime() - - if resources: - for res in resources: - vals = {} - vals.update({'date_start' : start_date }) - vals.update({'date_end' : end_date}) - resource_allocation_pool.write(cr, uid, res.id, vals, context=context) - if act_phase.task_ids: - for task in act_phase.task_ids: - vals = {} - #Getting values of the Tasks - temp = eval("phase.Task_%s"%task.id) - if temp.booked_resource: - res_name = temp.booked_resource[0].title - res_id = resource_pool.search(cr, uid,[('name','=',res_name)], context = context) - if res_id: - res = resource_pool.browse(cr, uid, res_id[0], context = context) - vals.update({'user_id' : res.user_id.id}) - - vals.update({'date_start' : temp.start.strftime('%Y-%m-%d %H:%M:%S')}) - vals.update({'date_end' : temp.end.strftime('%Y-%m-%d %H:%M:%S')}) - task_pool.write(cr, uid, task.id, vals, context=context) +""" % ( vacation, ) + return result - phase_pool.write(cr, uid, [phase_id], { - 'date_start': start_date.strftime('%Y-%m-%d'), - 'date_end': end_date.strftime('%Y-%m-%d') - }, context=context) - return True + def schedule_phases(self, cr, uid, ids, context=None): + context = context or {} + if type(ids) in (long, int,): + ids = [ids] + projects = self.browse(cr, uid, ids, context=context) + result = self._schedule_header(cr, uid, ids, context=context) + for project in projects: + result += self._schedule_project(cr, uid, project, context=context) + result += self.pool.get('project.phase').generate_phase(cr, uid, project.phase_ids, context=context) + + local_dict = {} + exec result in local_dict + projects_gantt = Task.BalancedProject(local_dict['Project']) + + for project in projects: + project_gantt = getattr(projects_gantt, 'Project_%d' % (project.id,)) + for phase in project.phase_ids: + if phase.state in ('done','cancelled'): + continue + # Maybe it's better to update than unlink/create if it already exists ? + p = getattr(project_gantt, 'Phase_%d' % (phase.id,)) + + self.pool.get('project.user.allocation').unlink(cr, uid, + [x.id for x in phase.user_ids], + context=context + ) + + for r in p.booked_resource: + self.pool.get('project.user.allocation').create(cr, uid, { + 'user_id': int(r.name[5:]), + 'phase_id': phase.id, + 'date_start': p.start.strftime('%Y-%m-%d %H:%M:%S'), + 'date_end': p.end.strftime('%Y-%m-%d %H:%M:%S') + }, context=context) + self.pool.get('project.phase').write(cr, uid, [phase.id], { + 'date_start': p.start.strftime('%Y-%m-%d %H:%M:%S'), + 'date_end': p.end.strftime('%Y-%m-%d %H:%M:%S') + }, context=context) + return True #TODO: DO Resource allocation and compute availability def compute_allocation(self, rc, uid, ids, start_date, end_date, context=None): @@ -584,186 +333,68 @@ def Project_%d(): return allocation def schedule_tasks(self, cr, uid, ids, context=None): - """ - Schedule task base on faces lib - """ - if context is None: - context = {} + context = context or {} if type(ids) in (long, int,): ids = [ids] - task_pool = self.pool.get('project.task') - resource_pool = self.pool.get('resource.resource') - data_pool = self.pool.get('ir.model.data') - data_model, day_uom_id = data_pool.get_object_reference(cr, uid, 'product', 'uom_day') + projects = self.browse(cr, uid, ids, context=context) + result = self._schedule_header(cr, uid, ids, context=context) + for project in projects: + result += self._schedule_project(cr, uid, project, context=context) + result += self.pool.get('project.task')._generate_task(cr, uid, project.tasks, ident=4, context=context) - for project in self.browse(cr, uid, ids, context=context): - calendar_id = project.resource_calendar_id and project.resource_calendar_id.id or False - start_date = project.date_start - - #Checking the Valid Phase resource allocation from project member - flag = False - res_missing = [] - members_ids = [] - if project.members: - members_ids = [user.id for user in project.members] - for phase in project.phase_ids: - if phase.resource_ids: - res_ids = [ re.id for re in phase.resource_ids] - for res in self.pool.get('project.resource.allocation').browse(cr, uid, res_ids, context=context): - if res.resource_id.user_id.id not in members_ids: - res_missing += [res.resource_id.name] - flag = True - if flag: - raise osv.except_osv(_('Warning !'),_("Resource(s) %s is(are) not member(s) of the project '%s' .") % (",".join(res_missing), project.name)) - #Creating resources using the member of the Project - u_ids = [i.id for i in project.members] - resource_objs = resource_pool.generate_resources(cr, uid, u_ids, calendar_id, context=context) - try: - start_date = datetime.strftime((datetime.strptime(start_date, "%Y-%m-%d")), "%Y-%m-%d") - except: - raise osv.except_osv(_('Error !'),_('Task Scheduling is not possible.\nProject should have the Start date for scheduling.')) - func_str = '' - start = start_date - minimum_time_unit = 1 - # default values - working_hours_per_day = 24 - working_days_per_week = 7 - working_days_per_month = 30 - working_days_per_year = 365 - - vacation = [] - if calendar_id: - working_hours_per_day = 8 #TODO: it should be come from calendars - working_days_per_week = 5 - working_days_per_month = 20 - working_days_per_year = 200 - vacation = tuple(resource_pool.compute_vacation(cr, uid, calendar_id, context=context)) + local_dict = {} + exec result in local_dict + projects_gantt = Task.BalancedProject(local_dict['Project']) - working_days = resource_pool.compute_working_calendar(cr, uid, calendar_id, context=context) - - cls_str = '' - # Creating Resources for the Project - for key, vals in resource_objs.items(): - cls_str +=''' - class Resource_%s(Resource): - title = \"%s\" - vacation = %s - efficiency = %s -'''%(key, vals.get('name',False), vals.get('vacation', False), vals.get('efficiency', False)) - - # Create a new project for each phase - func_str += ''' -def Project_%d(): - from resource.faces import Resource - title = \"%s\" - start = \'%s\' - minimum_time_unit = %s - working_hours_per_day = %s - working_days_per_week = %s - working_days_per_month = %s - working_days_per_year = %s - vacation = %s - working_days = %s -'''%(project.id, project.name, start, minimum_time_unit, working_hours_per_day, working_days_per_week, working_days_per_month, working_days_per_year, vacation, working_days ) - - parent = False - task_ids = [] - todo_task_ids = task_pool.search(cr, uid, [('project_id', '=', project.id), - ('state', 'in', ['draft', 'open', 'pending']) - ], order='sequence') - if todo_task_ids: - for task in task_pool.browse(cr, uid, todo_task_ids, context=context): - func_str += task_pool.generate_task(cr, uid, task.id, parent=parent, flag=True,context=context) - if not parent: - parent = task - task_ids.append(task.id) - func_str += cls_str + for project in projects: + project_gantt = getattr(projects_gantt, 'Project_%d' % (project.id,)) + for task in project.tasks: + if task.state in ('done','cancelled'): + continue - if not project.date_start:# or not project.members: - raise osv.except_osv(_('Error !'),_('Task Scheduling is not possible.\nProject should have the Start date for scheduling.')) - # Allocating Memory for the required Project and Phases and Resources - exec(func_str) - Project = eval('Project_%d' % project.id) - project = None - try: - project = Task.BalancedProject(Project) - except Exception, e: - raise osv.except_osv(_('Error !'), e) - - for task_id in task_ids: - task = eval("project.Task_%d" % task_id) - start_date = task.start.to_datetime() - end_date = task.end.to_datetime() - - task_pool.write(cr, uid, [task_id], { - 'date_start': start_date.strftime('%Y-%m-%d %H:%M:%S'), - 'date_end': end_date.strftime('%Y-%m-%d %H:%M:%S') - }, context=context) + p = getattr(project_gantt, 'Task_%d' % (task.id,)) + + self.pool.get('project.task').write(cr, uid, [task.id], { + 'date_start': p.start.strftime('%Y-%m-%d %H:%M:%S'), + 'date_end': p.end.strftime('%Y-%m-%d %H:%M:%S') + }, context=context) + if (not task.user_id) and (p.booked_resource): + self.pool.get('project.task').write(cr, uid, [task.id], { + 'user_id': int(p.booked_resource[0].name[5:]), + }, context=context) return True - project() -class resource_resource(osv.osv): - _inherit = "resource.resource" - def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False): - if context is None: - context = {} - if context.get('project_id',False): - project_pool = self.pool.get('project.project') - project_rec = project_pool.browse(cr, uid, context['project_id'], context=context) - user_ids = [user_id.id for user_id in project_rec.members] - args.append(('user_id','in',user_ids)) - return super(resource_resource, self).search(cr, uid, args, offset, limit, order, context, count) - -resource_resource() - class project_task(osv.osv): _inherit = "project.task" _columns = { 'phase_id': fields.many2one('project.phase', 'Project Phase'), } - _defaults = { - 'user_id' : False - } + def _generate_task(self, cr, uid, tasks, ident=4, context=None): + context = context or {} + result = "" + ident = ' '*ident + for task in tasks: + if task.state in ('done','cancelled'): + continue + result += ''' +%sdef Task_%s(): +%s title = \"%s\" +%s todo = \"%.2fH\" +%s effort = \"%.2fH\"''' % (ident,task.id, ident,task.name, ident,task.remaining_hours, ident,task.total_hours) + start = [] + for t2 in task.parent_ids: + start.append("up.Task_%s.end" % (t2.id,)) + if start: + result += ''' +%s start = max(%s) +''' % (ident,','.join(start)) - def generate_task(self, cr, uid, task_id, parent=False, flag=False, context=None): - if context is None: - context = {} - task = self.browse(cr, uid, task_id, context=context) - duration = str(task.planned_hours)+ 'H' - str_resource = False - parent = task.parent_ids - if task.phase_id.resource_ids: - str_resource = ('%s | '*len(task.phase_id.resource_ids))[:-2] - str_resource = str_resource % tuple(map(lambda x: 'Resource_%s'%x.resource_id.id, task.phase_id.resource_ids)) - # Task Defination for the Phase of the Project - if not flag: - s = ''' - def Task_%s(): - title = \"%s\" - effort = \'%s\' - resource = %s -'''%(task.id, task.name, duration, str_resource) - if task.child_ids: - seq = [[child.planned_hours, child.id] for child in task.child_ids] - seq.sort(key=itemgetter(0)) - s +=''' - start = up.Task_%s.end - '''%(seq[-1][1]) - else: - s = ''' - def Task_%s(): - title = \"%s\" - effort = \'%s\' - resource = %s -'''%(task.id, task.name, duration, str_resource) - if task.child_ids: - seq = [[child.planned_hours, child.id] for child in task.child_ids] - seq.sort(key=itemgetter(0)) - s +=''' - start = up.Task_%s.end -'''%(seq[-1][1]) - s += '\n' - return s + if task.user_id: + result += ''' +%s resource = %s +''' % (ident, 'User_'+str(task.user_id.id)) + + result += "\n" + return result project_task() -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/project_long_term/project_long_term_demo.xml b/addons/project_long_term/project_long_term_demo.xml index 961b0c62c9b..252bcdd0e9d 100644 --- a/addons/project_long_term/project_long_term_demo.xml +++ b/addons/project_long_term/project_long_term_demo.xml @@ -1,55 +1,9 @@ - - - - - Analyst - - - - - - Project Manager - - - - - - Technical Leader - - - - - - Developer - - - - - - Designer - - - - - - Tester - - - - - - Project Finacial Manager - - - - - - + @@ -58,7 +12,6 @@ This Demo data file Human Resources, Phases and Resources,Tasks allocation and 30 - @@ -68,7 +21,6 @@ This Demo data file Human Resources, Phases and Resources,Tasks allocation and 20 - @@ -78,7 +30,6 @@ This Demo data file Human Resources, Phases and Resources,Tasks allocation and 20 - @@ -88,7 +39,6 @@ This Demo data file Human Resources, Phases and Resources,Tasks allocation and 90 - @@ -98,7 +48,6 @@ This Demo data file Human Resources, Phases and Resources,Tasks allocation and 30 - @@ -108,56 +57,9 @@ This Demo data file Human Resources, Phases and Resources,Tasks allocation and 10 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/addons/project_long_term/project_long_term_view.xml b/addons/project_long_term/project_long_term_view.xml index 49b306ebfd5..b5af969f554 100644 --- a/addons/project_long_term/project_long_term_view.xml +++ b/addons/project_long_term/project_long_term_view.xml @@ -5,29 +5,29 @@ # ------------------------------------------------------ - # Project Resource Allocation + # Project User Allocation # ------------------------------------------------------ - - project.resource.allocation.gantt - project.resource.allocation + + project.user.allocation.gantt + project.user.allocation gantt - + - - project.resource.allocation.calendar - project.resource.allocation + + project.user.allocation.calendar + project.user.allocation calendar - + @@ -35,53 +35,51 @@ - - project.resource.allocation.form - project.resource.allocation + + project.user.allocation.form + project.user.allocation form -
      + - + -
      - - project.resource.allocation.list - project.resource.allocation + + project.user.allocation.list + project.user.allocation tree - - + + - - - project.resource.allocation.search - project.resource.allocation + + project.user.allocation.search + project.user.allocation search - + - + - + @@ -90,12 +88,12 @@ - Resources Allocation - project.resource.allocation + Users Allocation + project.user.allocation form gantt,tree,form,calendar {} - + @@ -110,32 +108,27 @@
      - - - - - - - + + + + + - - + - - - - + + + + - - - + + - @@ -162,38 +155,9 @@ -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      - -
      @@ -16,6 +15,6 @@
      -
      +
      From f0714ccd72b61f66d565a8f8b8073b66756ff44a Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 12:05:38 +0200 Subject: [PATCH 103/163] [imp] removed useless logging bzr revid: nicolas.vanhoren@openerp.com-20111026100538-momcgi4s3lxy560l --- addons/web/static/src/js/view_form.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index c701f21fee1..cf5d98bb3e6 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2226,7 +2226,6 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this.dataset.set_ids(value); var self = this; $.when(this.is_started).then(function() { - console.log("lalala"); self.list_view.reload_content(); }); this.is_setted.resolve(); @@ -2238,7 +2237,6 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this.invalid = false; }, load_view: function() { - console.info("yop"); var self = this; this.list_view = new openerp.web.form.Many2ManyListView(this, this.dataset, false, { 'addable': self.readonly ? null : 'Add', @@ -2265,7 +2263,6 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ $.when(this.is_started).then(function() { self.list_view.stop(); $.when(self.load_view()).then(function() { - console.log("lalala2"); self.list_view.reload_content(); }); }); From 08e6b980b6bfe96b8d7d9166a3444e084a1b65a9 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 14:05:09 +0200 Subject: [PATCH 104/163] [FIX] onclick not going through correctly if set.toFront is called in onmousedown handler, in webkit-based browsers bzr revid: xmo@openerp.com-20111026120509-wmj3onhkrnps6xee --- addons/web_diagram/static/lib/js/dracula_graph.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web_diagram/static/lib/js/dracula_graph.js b/addons/web_diagram/static/lib/js/dracula_graph.js index df9945882a7..ff8ba3a423d 100644 --- a/addons/web_diagram/static/lib/js/dracula_graph.js +++ b/addons/web_diagram/static/lib/js/dracula_graph.js @@ -164,7 +164,7 @@ Graph.Renderer.Raphael = function(element, graph, width, height) { this.dx = e.clientX; this.dy = e.clientY; selfRef.isDrag = this; - this.set && this.set.animate({"fill-opacity": .1}, 200) && this.set.toFront(); + this.set && this.set.animate({"fill-opacity": .1}, 200); e.preventDefault && e.preventDefault(); } }; From d47d63357c05d95bc6ff6f035ade02449bd266d0 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 14:13:31 +0200 Subject: [PATCH 105/163] [IMP] update Raphael library, because why not bzr revid: xmo@openerp.com-20111026121331-8h4i4hs381r4vgej --- addons/web_diagram/static/lib/js/raphael-min.js | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/addons/web_diagram/static/lib/js/raphael-min.js b/addons/web_diagram/static/lib/js/raphael-min.js index 8718b5bc749..e69ea16a809 100644 --- a/addons/web_diagram/static/lib/js/raphael-min.js +++ b/addons/web_diagram/static/lib/js/raphael-min.js @@ -1,7 +1,8 @@ -/* - * Raphael 1.3.1 - JavaScript Vector Library - * - * Copyright (c) 2008 - 2009 Dmitry Baranovskiy (http://raphaeljs.com) - * Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license. - */ -Raphael=(function(){var a=/[, ]+/,aO=/^(circle|rect|path|ellipse|text|image)$/,L=document,au=window,l={was:"Raphael" in au,is:au.Raphael},an=function(){if(an.is(arguments[0],"array")){var d=arguments[0],e=w[aW](an,d.splice(0,3+an.is(d[0],al))),S=e.set();for(var R=0,a0=d[m];R

      ";if(ag.childNodes[m]!=2){return null;}}an.svg=!(an.vml=an.type=="VML");aT[aY]=an[aY];an._id=0;an._oid=0;an.fn={};an.is=function(e,d){d=aZ.call(d);return((d=="object"||d=="undefined")&&typeof e==d)||(e==null&&d=="null")||aZ.call(aw.call(e).slice(8,-1))==d;};an.setWindow=function(d){au=d;L=au.document;};var aD=function(e){if(an.vml){var d=/^\s+|\s+$/g;aD=aj(function(R){var S;R=(R+at)[aP](d,at);try{var a0=new ActiveXObject("htmlfile");a0.write("");a0.close();S=a0.body;}catch(a2){S=createPopup().document.body;}var i=S.createTextRange();try{S.style.color=R;var a1=i.queryCommandValue("ForeColor");a1=((a1&255)<<16)|(a1&65280)|((a1&16711680)>>>16);return"#"+("000000"+a1[aA](16)).slice(-6);}catch(a2){return"none";}});}else{var E=L.createElement("i");E.title="Rapha\xebl Colour Picker";E.style.display="none";L.body[aL](E);aD=aj(function(i){E.style.color=i;return L.defaultView.getComputedStyle(E,at).getPropertyValue("color");});}return aD(e);};an.hsb2rgb=aj(function(a3,a1,a7){if(an.is(a3,"object")&&"h" in a3&&"s" in a3&&"b" in a3){a7=a3.b;a1=a3.s;a3=a3.h;}var R,S,a8;if(a7==0){return{r:0,g:0,b:0,hex:"#000"};}if(a3>1||a1>1||a7>1){a3/=255;a1/=255;a7/=255;}var a0=~~(a3*6),a4=(a3*6)-a0,E=a7*(1-a1),e=a7*(1-(a1*a4)),a9=a7*(1-(a1*(1-a4)));R=[a7,e,E,E,a9,a7,a7][a0];S=[a9,a7,a7,e,E,E,a9][a0];a8=[E,E,a9,a7,a7,e,E][a0];R*=255;S*=255;a8*=255;var a5={r:R,g:S,b:a8},d=(~~R)[aA](16),a2=(~~S)[aA](16),a6=(~~a8)[aA](16);d=d[aP](aU,"0");a2=a2[aP](aU,"0");a6=a6[aP](aU,"0");a5.hex="#"+d+a2+a6;return a5;},an);an.rgb2hsb=aj(function(d,e,a1){if(an.is(d,"object")&&"r" in d&&"g" in d&&"b" in d){a1=d.b;e=d.g;d=d.r;}if(an.is(d,"string")){var a3=an.getRGB(d);d=a3.r;e=a3.g;a1=a3.b;}if(d>1||e>1||a1>1){d/=255;e/=255;a1/=255;}var a0=g(d,e,a1),i=aI(d,e,a1),R,E,S=a0;if(i==a0){return{h:0,s:0,b:a0};}else{var a2=(a0-i);E=a2/a0;if(d==a0){R=(e-a1)/a2;}else{if(e==a0){R=2+((a1-d)/a2);}else{R=4+((d-e)/a2);}}R/=6;R<0&&R++;R>1&&R--;}return{h:R,s:E,b:S};},an);var aE=/,?([achlmqrstvxz]),?/gi;an._path2string=function(){return this.join(",")[aP](aE,"$1");};function aj(E,e,d){function i(){var R=Array[aY].slice.call(arguments,0),a0=R[az]("\u25ba"),S=i.cache=i.cache||{},a1=i.count=i.count||[];if(S[Q](a0)){return d?d(S[a0]):S[a0];}a1[m]>=1000&&delete S[a1.shift()];a1[f](a0);S[a0]=E[aW](e,R);return d?d(S[a0]):S[a0];}return i;}an.getRGB=aj(function(d){if(!d||!!((d=d+at).indexOf("-")+1)){return{r:-1,g:-1,b:-1,hex:"none",error:1};}if(d=="none"){return{r:-1,g:-1,b:-1,hex:"none"};}!(({hs:1,rg:1})[Q](d.substring(0,2))||d.charAt()=="#")&&(d=aD(d));var S,i,E,a2,a3,a0=d.match(x);if(a0){if(a0[2]){a2=G(a0[2].substring(5),16);E=G(a0[2].substring(3,5),16);i=G(a0[2].substring(1,3),16);}if(a0[3]){a2=G((a3=a0[3].charAt(3))+a3,16);E=G((a3=a0[3].charAt(2))+a3,16);i=G((a3=a0[3].charAt(1))+a3,16);}if(a0[4]){a0=a0[4][z](/\s*,\s*/);i=W(a0[0]);E=W(a0[1]);a2=W(a0[2]);}if(a0[5]){a0=a0[5][z](/\s*,\s*/);i=W(a0[0])*2.55;E=W(a0[1])*2.55;a2=W(a0[2])*2.55;}if(a0[6]){a0=a0[6][z](/\s*,\s*/);i=W(a0[0]);E=W(a0[1]);a2=W(a0[2]);return an.hsb2rgb(i,E,a2);}if(a0[7]){a0=a0[7][z](/\s*,\s*/);i=W(a0[0])*2.55;E=W(a0[1])*2.55;a2=W(a0[2])*2.55;return an.hsb2rgb(i,E,a2);}a0={r:i,g:E,b:a2};var e=(~~i)[aA](16),R=(~~E)[aA](16),a1=(~~a2)[aA](16);e=e[aP](aU,"0");R=R[aP](aU,"0");a1=a1[aP](aU,"0");a0.hex="#"+e+R+a1;return a0;}return{r:-1,g:-1,b:-1,hex:"none",error:1};},an);an.getColor=function(e){var i=this.getColor.start=this.getColor.start||{h:0,s:1,b:e||0.75},d=this.hsb2rgb(i.h,i.s,i.b);i.h+=0.075;if(i.h>1){i.h=0;i.s-=0.2;i.s<=0&&(this.getColor.start={h:0,s:1,b:i.b});}return d.hex;};an.getColor.reset=function(){delete this.start;};an.parsePathString=aj(function(d){if(!d){return null;}var i={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},e=[];if(an.is(d,"array")&&an.is(d[0],"array")){e=av(d);}if(!e[m]){(d+at)[aP](/([achlmqstvz])[\s,]*((-?\d*\.?\d*(?:e[-+]?\d+)?\s*,?\s*)+)/ig,function(R,E,a1){var a0=[],S=aZ.call(E);a1[aP](/(-?\d*\.?\d*(?:e[-+]?\d+)?)\s*,?\s*/ig,function(a3,a2){a2&&a0[f](+a2);});while(a0[m]>=i[S]){e[f]([E][aS](a0.splice(0,i[S])));if(!i[S]){break;}}});}e[aA]=an._path2string;return e;});an.findDotsAtSegment=function(e,d,be,bc,a0,R,a2,a1,a8){var a6=1-a8,a5=aM(a6,3)*e+aM(a6,2)*3*a8*be+a6*3*a8*a8*a0+aM(a8,3)*a2,a3=aM(a6,3)*d+aM(a6,2)*3*a8*bc+a6*3*a8*a8*R+aM(a8,3)*a1,ba=e+2*a8*(be-e)+a8*a8*(a0-2*be+e),a9=d+2*a8*(bc-d)+a8*a8*(R-2*bc+d),bd=be+2*a8*(a0-be)+a8*a8*(a2-2*a0+be),bb=bc+2*a8*(R-bc)+a8*a8*(a1-2*R+bc),a7=(1-a8)*e+a8*be,a4=(1-a8)*d+a8*bc,E=(1-a8)*a0+a8*a2,i=(1-a8)*R+a8*a1,S=(90-ab.atan((ba-bd)/(a9-bb))*180/ab.PI);(ba>bd||a91){bi=ab.sqrt(by)*bi;bg=ab.sqrt(by)*bg;}var E=bi*bi,br=bg*bg,bt=(a4==S?-1:1)*ab.sqrt(ab.abs((E*br-E*bn*bn-br*bo*bo)/(E*bn*bn+br*bo*bo))),bd=bt*bi*bn/bg+(a9+a8)/2,bc=bt*-bg*bo/bi+(bE+bD)/2,a3=ab.asin(((bE-bc)/bg).toFixed(7)),a2=ab.asin(((bD-bc)/bg).toFixed(7));a3=a9a2){a3=a3-R*2;}if(!S&&a2>a3){a2=a2-R*2;}}else{a3=bb[0];a2=bb[1];bd=bb[2];bc=bb[3];}var a7=a2-a3;if(ab.abs(a7)>bf){var be=a2,bh=a8,a5=bD;a2=a3+bf*(S&&a2>a3?1:-1);a8=bd+bi*ab.cos(a2);bD=bc+bg*ab.sin(a2);bm=K(a8,bD,bi,bg,ba,0,S,bh,a5,[a2,be,bd,bc]);}a7=a2-a3;var a1=ab.cos(a3),bC=ab.sin(a3),a0=ab.cos(a2),bB=ab.sin(a2),bp=ab.tan(a7/4),bs=4/3*bi*bp,bq=4/3*bg*bp,bz=[a9,bE],bx=[a9+bs*bC,bE-bq*a1],bw=[a8+bs*bB,bD-bq*a0],bu=[a8,bD];bx[0]=2*bz[0]-bx[0];bx[1]=2*bz[1]-bx[1];if(bb){return[bx,bw,bu][aS](bm);}else{bm=[bx,bw,bu][aS](bm)[az]()[z](",");var bk=[];for(var bv=0,bl=bm[m];bv1000000000000&&(a0=0.5);ab.abs(S)>1000000000000&&(S=0.5);if(a0>0&&a0<1){e=M(i,d,R,E,a9,a8,a5,a2,a0);a6[f](e.x);a3[f](e.y);}if(S>0&&S<1){e=M(i,d,R,E,a9,a8,a5,a2,S);a6[f](e.x);a3[f](e.y);}a7=(a8-2*E+d)-(a2-2*a8+E);a4=2*(E-d)-2*(a8-E);a1=d-E;a0=(-a4+ab.sqrt(a4*a4-4*a7*a1))/2/a7;S=(-a4-ab.sqrt(a4*a4-4*a7*a1))/2/a7;ab.abs(a0)>1000000000000&&(a0=0.5);ab.abs(S)>1000000000000&&(S=0.5);if(a0>0&&a0<1){e=M(i,d,R,E,a9,a8,a5,a2,a0);a6[f](e.x);a3[f](e.y);}if(S>0&&S<1){e=M(i,d,R,E,a9,a8,a5,a2,S);a6[f](e.x);a3[f](e.y);}return{min:{x:aI[aW](0,a6),y:aI[aW](0,a3)},max:{x:g[aW](0,a6),y:g[aW](0,a3)}};}),H=aj(function(a9,a4){var R=r(a9),a5=a4&&r(a4),a6={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},d={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},a0=function(ba,bb){var i,bc;if(!ba){return["C",bb.x,bb.y,bb.x,bb.y,bb.x,bb.y];}!(ba[0] in {T:1,Q:1})&&(bb.qx=bb.qy=null);switch(ba[0]){case"M":bb.X=ba[1];bb.Y=ba[2];break;case"A":ba=["C"][aS](K[aW](0,[bb.x,bb.y][aS](ba.slice(1))));break;case"S":i=bb.x+(bb.x-(bb.bx||bb.x));bc=bb.y+(bb.y-(bb.by||bb.y));ba=["C",i,bc][aS](ba.slice(1));break;case"T":bb.qx=bb.x+(bb.x-(bb.qx||bb.x));bb.qy=bb.y+(bb.y-(bb.qy||bb.y));ba=["C"][aS](aK(bb.x,bb.y,bb.qx,bb.qy,ba[1],ba[2]));break;case"Q":bb.qx=ba[1];bb.qy=ba[2];ba=["C"][aS](aK(bb.x,bb.y,ba[1],ba[2],ba[3],ba[4]));break;case"L":ba=["C"][aS](aX(bb.x,bb.y,ba[1],ba[2]));break;case"H":ba=["C"][aS](aX(bb.x,bb.y,ba[1],bb.y));break;case"V":ba=["C"][aS](aX(bb.x,bb.y,bb.x,ba[1]));break;case"Z":ba=["C"][aS](aX(bb.x,bb.y,bb.X,bb.Y));break;}return ba;},e=function(ba,bb){if(ba[bb][m]>7){ba[bb].shift();var bc=ba[bb];while(bc[m]){ba.splice(bb++,0,["C"][aS](bc.splice(0,6)));}ba.splice(bb,1);a7=g(R[m],a5&&a5[m]||0);}},E=function(be,bd,bb,ba,bc){if(be&&bd&&be[bc][0]=="M"&&bd[bc][0]!="M"){bd.splice(bc,0,["M",ba.x,ba.y]);bb.bx=0;bb.by=0;bb.x=be[bc][1];bb.y=be[bc][2];a7=g(R[m],a5&&a5[m]||0);}};for(var a2=0,a7=g(R[m],a5&&a5[m]||0);a23){return{container:1,x:arguments[0],y:arguments[1],width:arguments[2],height:arguments[3]};}}},aG=function(d,i){var e=this;for(var E in i){if(i[Q](E)&&!(E in d)){switch(typeof i[E]){case"function":(function(R){d[E]=d===e?R:function(){return R[aW](e,arguments);};})(i[E]);break;case"object":d[E]=d[E]||{};aG.call(this,d[E],i[E]);break;default:d[E]=i[E];break;}}}},ak=function(d,e){d==e.top&&(e.top=d.prev);d==e.bottom&&(e.bottom=d.next);d.next&&(d.next.prev=d.prev);d.prev&&(d.prev.next=d.next);},Y=function(d,e){if(e.top===d){return;}ak(d,e);d.next=null;d.prev=e.top;e.top.next=d;e.top=d;},k=function(d,e){if(e.bottom===d){return;}ak(d,e);d.next=e.bottom;d.prev=null;e.bottom.prev=d;e.bottom=d;},A=function(e,d,i){ak(e,i);d==i.top&&(i.top=e);d.next&&(d.next.prev=e);e.next=d.next;e.prev=d;d.next=e;},aq=function(e,d,i){ak(e,i);d==i.bottom&&(i.bottom=e);d.prev&&(d.prev.next=e);e.prev=d.prev;d.prev=e;e.next=d;},s=function(d){return function(){throw new Error("Rapha\xebl: you are calling to method \u201c"+d+"\u201d of removed object");};},ar=/^r(?:\(([^,]+?)\s*,\s*([^\)]+?)\))?/;if(an.svg){aT[aY].svgns="http://www.w3.org/2000/svg";aT[aY].xlink="http://www.w3.org/1999/xlink";var O=function(d){return +d+(~~d===d)*0.5;},V=function(S){for(var e=0,E=S[m];e0.5)*2-1);aM(a1-0.5,2)+aM(S-0.5,2)>0.25&&(S=ab.sqrt(0.25-aM(a1-0.5,2))*ba+0.5)&&S!=0.5&&(S=S.toFixed(5)-0.00001*ba);}return at;});a7=a7[z](/\s*\-\s*/);if(a4=="linear"){var a0=a7.shift();a0=-W(a0);if(isNaN(a0)){return null;}var R=[0,0,ab.cos(a0*ab.PI/180),ab.sin(a0*ab.PI/180)],a6=1/(g(ab.abs(R[2]),ab.abs(R[3]))||1);R[2]*=a6;R[3]*=a6;if(R[2]<0){R[0]=-R[2];R[2]=0;}if(R[3]<0){R[1]=-R[3];R[3]=0;}}var a3=p(a7);if(!a3){return null;}var e=aJ(a4+"Gradient");e.id="r"+(an._id++)[aA](36);aJ(e,a4=="radial"?{fx:a1,fy:S}:{x1:R[0],y1:R[1],x2:R[2],y2:R[3]});d.defs[aL](e);for(var a2=0,a8=a3[m];a2a1.height)&&(a1.height=a0.y+a0.height-a1.y);(a0.x+a0.width-a1.x>a1.width)&&(a1.width=a0.x+a0.width-a1.x);}}E&&this.hide();return a1;};ax[aY].attr=function(){if(this.removed){return this;}if(arguments[m]==0){var R={};for(var E in this.attrs){if(this.attrs[Q](E)){R[E]=this.attrs[E];}}this._.rt.deg&&(R.rotation=this.rotate());(this._.sx!=1||this._.sy!=1)&&(R.scale=this.scale());R.gradient&&R.fill=="none"&&(R.fill=R.gradient)&&delete R.gradient;return R;}if(arguments[m]==1&&an.is(arguments[0],"string")){if(arguments[0]=="translation"){return t.call(this);}if(arguments[0]=="rotation"){return this.rotate();}if(arguments[0]=="scale"){return this.scale();}if(arguments[0]=="fill"&&this.attrs.fill=="none"&&this.attrs.gradient){return this.attrs.gradient;}return this.attrs[arguments[0]];}if(arguments[m]==1&&an.is(arguments[0],"array")){var d={};for(var e in arguments[0]){if(arguments[0][Q](e)){d[arguments[0][e]]=this.attrs[arguments[0][e]];}}return d;}if(arguments[m]==2){var S={};S[arguments[0]]=arguments[1];aa(this,S);}else{if(arguments[m]==1&&an.is(arguments[0],"object")){aa(this,arguments[0]);}}return this;};ax[aY].toFront=function(){if(this.removed){return this;}this.node.parentNode[aL](this.node);var d=this.paper;d.top!=this&&Y(this,d);return this;};ax[aY].toBack=function(){if(this.removed){return this;}if(this.node.parentNode.firstChild!=this.node){this.node.parentNode.insertBefore(this.node,this.node.parentNode.firstChild);k(this,this.paper);var d=this.paper;}return this;};ax[aY].insertAfter=function(d){if(this.removed){return this;}var e=d.node;if(e.nextSibling){e.parentNode.insertBefore(this.node,e.nextSibling);}else{e.parentNode[aL](this.node);}A(this,d,this.paper);return this;};ax[aY].insertBefore=function(d){if(this.removed){return this;}var e=d.node;e.parentNode.insertBefore(this.node,e);aq(this,d,this.paper);return this;};var P=function(e,d,S,R){d=O(d);S=O(S);var E=aJ("circle");e.canvas&&e.canvas[aL](E);var i=new ax(E,e);i.attrs={cx:d,cy:S,r:R,fill:"none",stroke:"#000"};i.type="circle";aJ(E,i.attrs);return i;};var aF=function(i,d,a1,e,S,a0){d=O(d);a1=O(a1);var R=aJ("rect");i.canvas&&i.canvas[aL](R);var E=new ax(R,i);E.attrs={x:d,y:a1,width:e,height:S,r:a0||0,rx:a0||0,ry:a0||0,fill:"none",stroke:"#000"};E.type="rect";aJ(R,E.attrs);return E;};var ai=function(e,d,a0,S,R){d=O(d);a0=O(a0);var E=aJ("ellipse");e.canvas&&e.canvas[aL](E);var i=new ax(E,e);i.attrs={cx:d,cy:a0,rx:S,ry:R,fill:"none",stroke:"#000"};i.type="ellipse";aJ(E,i.attrs);return i;};var o=function(i,a0,d,a1,e,S){var R=aJ("image");aJ(R,{x:d,y:a1,width:e,height:S,preserveAspectRatio:"none"});R.setAttributeNS(i.xlink,"href",a0);i.canvas&&i.canvas[aL](R);var E=new ax(R,i);E.attrs={x:d,y:a1,width:e,height:S,src:a0};E.type="image";return E;};var X=function(e,d,S,R){var E=aJ("text");aJ(E,{x:d,y:S,"text-anchor":"middle"});e.canvas&&e.canvas[aL](E);var i=new ax(E,e);i.attrs={x:d,y:S,"text-anchor":"middle",text:R,font:j.font,stroke:"none",fill:"#000"};i.type="text";aa(i,i.attrs);return i;};var aV=function(e,d){this.width=e||this.width;this.height=d||this.height;this.canvas[v]("width",this.width);this.canvas[v]("height",this.height);return this;};var w=function(){var E=ao[aW](null,arguments),i=E&&E.container,e=E.x,a0=E.y,R=E.width,d=E.height;if(!i){throw new Error("SVG container not found.");}var S=aJ("svg");R=R||512;d=d||342;aJ(S,{xmlns:"http://www.w3.org/2000/svg",version:1.1,width:R,height:d});if(i==1){S.style.cssText="position:absolute;left:"+e+"px;top:"+a0+"px";L.body[aL](S);}else{if(i.firstChild){i.insertBefore(S,i.firstChild);}else{i[aL](S);}}i=new aT;i.width=R;i.height=d;i.canvas=S;aG.call(i,i,an.fn);i.clear();return i;};aT[aY].clear=function(){var d=this.canvas;while(d.firstChild){d.removeChild(d.firstChild);}this.bottom=this.top=null;(this.desc=aJ("desc"))[aL](L.createTextNode("Created with Rapha\xebl"));d[aL](this.desc);d[aL](this.defs=aJ("defs"));};aT[aY].remove=function(){this.canvas.parentNode&&this.canvas.parentNode.removeChild(this.canvas);for(var d in this){this[d]=s(d);}};}if(an.vml){var aH=function(a8){var a5=/[ahqstv]/ig,a0=r;(a8+at).match(a5)&&(a0=H);a5=/[clmz]/g;if(a0==r&&!(a8+at).match(a5)){var e={M:"m",L:"l",C:"c",Z:"x",m:"t",l:"r",c:"v",z:"x"},R=/([clmz]),?([^clmz]*)/gi,S=/-?[^,\s-]+/g;var a4=(a8+at)[aP](R,function(a9,bb,i){var ba=[];i[aP](S,function(bc){ba[f](O(bc));});return e[bb]+ba;});return a4;}var a6=a0(a8),E,a4=[],d;for(var a2=0,a7=a6[m];a21&&(e=1);a7.opacity=e;}a8.fill&&(a7.on=true);if(a7.on==null||a8.fill=="none"){a7.on=false;}if(a7.on&&a8.fill){var i=a8.fill.match(c);if(i){a7.src=i[1];a7.type="tile";}else{a7.color=an.getRGB(a8.fill).hex;a7.src=at;a7.type="solid";if(an.getRGB(a8.fill).error&&(bd.type in {circle:1,ellipse:1}||(a8.fill+at).charAt()!="r")&&b(bd,a8.fill)){a9.fill="none";a9.gradient=a8.fill;}}}ba&&a6[aL](a7);var R=(a6.getElementsByTagName("stroke")&&a6.getElementsByTagName("stroke")[0]),bb=false;!R&&(bb=R=ah("stroke"));if((a8.stroke&&a8.stroke!="none")||a8["stroke-width"]||a8["stroke-opacity"]!=null||a8["stroke-dasharray"]||a8["stroke-miterlimit"]||a8["stroke-linejoin"]||a8["stroke-linecap"]){R.on=true;}(a8.stroke=="none"||R.on==null||a8.stroke==0||a8["stroke-width"]==0)&&(R.on=false);R.on&&a8.stroke&&(R.color=an.getRGB(a8.stroke).hex);var e=((+a9["stroke-opacity"]+1||2)-1)*((+a9.opacity+1||2)-1),a4=(W(a8["stroke-width"])||1)*0.75;e<0&&(e=0);e>1&&(e=1);a8["stroke-width"]==null&&(a4=a9["stroke-width"]);a8["stroke-width"]&&(R.weight=a4);a4&&a4<1&&(e*=a4)&&(R.weight=1);R.opacity=e;a8["stroke-linejoin"]&&(R.joinstyle=a8["stroke-linejoin"]||"miter");R.miterlimit=a8["stroke-miterlimit"]||8;a8["stroke-linecap"]&&(R.endcap=a8["stroke-linecap"]=="butt"?"flat":a8["stroke-linecap"]=="square"?"square":"round");if(a8["stroke-dasharray"]){var a5={"-":"shortdash",".":"shortdot","-.":"shortdashdot","-..":"shortdashdotdot",". ":"dot","- ":"dash","--":"longdash","- .":"dashdot","--.":"longdashdot","--..":"longdashdotdot"};R.dashstyle=a5[Q](a8["stroke-dasharray"])?a5[a8["stroke-dasharray"]]:at;}bb&&a6[aL](R);}if(bd.type=="text"){var a0=bd.paper.span.style;a9.font&&(a0.font=a9.font);a9["font-family"]&&(a0.fontFamily=a9["font-family"]);a9["font-size"]&&(a0.fontSize=a9["font-size"]);a9["font-weight"]&&(a0.fontWeight=a9["font-weight"]);a9["font-style"]&&(a0.fontStyle=a9["font-style"]);bd.node.string&&(bd.paper.span.innerHTML=(bd.node.string+at)[aP](/"));bd.W=a9.w=bd.paper.span.offsetWidth;bd.H=a9.h=bd.paper.span.offsetHeight;bd.X=a9.x;bd.Y=a9.y+O(bd.H/2);switch(a9["text-anchor"]){case"start":bd.node.style["v-text-align"]="left";bd.bbx=O(bd.W/2);break;case"end":bd.node.style["v-text-align"]="right";bd.bbx=-O(bd.W/2);break;default:bd.node.style["v-text-align"]="center";break;}}};var b=function(d,a1){d.attrs=d.attrs||{};var a2=d.attrs,a4=d.node.getElementsByTagName("fill"),S="linear",a0=".5 .5";d.attrs.gradient=a1;a1=(a1+at)[aP](ar,function(a6,a7,i){S="radial";if(a7&&i){a7=W(a7);i=W(i);aM(a7-0.5,2)+aM(i-0.5,2)>0.25&&(i=ab.sqrt(0.25-aM(a7-0.5,2))*((i>0.5)*2-1)+0.5);a0=a7+am+i;}return at;});a1=a1[z](/\s*\-\s*/);if(S=="linear"){var e=a1.shift();e=-W(e);if(isNaN(e)){return null;}}var R=p(a1);if(!R){return null;}d=d.shape||d.node;a4=a4[0]||ah("fill");if(R[m]){a4.on=true;a4.method="none";a4.type=(S=="radial")?"gradientradial":"gradient";a4.color=R[0].color;a4.color2=R[R[m]-1].color;var a5=[];for(var E=0,a3=R[m];E');};}catch(af){ah=function(d){return L.createElement("<"+d+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">');};}var w=function(){var i=ao[aW](null,arguments),d=i.container,a2=i.height,a3,e=i.width,a1=i.x,a0=i.y;if(!d){throw new Error("VML container not found.");}var R=new aT,S=R.canvas=L.createElement("div"),E=S.style;e=e||512;a2=a2||342;e==+e&&(e+="px");a2==+a2&&(a2+="px");R.width=1000;R.height=1000;R.coordsize="1000 1000";R.coordorigin="0 0";R.span=L.createElement("span");R.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;display:inline;";S[aL](R.span);E.cssText=an.format("width:{0};height:{1};position:absolute;clip:rect(0 {0} {1} 0);overflow:hidden",e,a2);if(d==1){L.body[aL](S);E.left=a1+"px";E.top=a0+"px";}else{d.style.width=e;d.style.height=a2;if(d.firstChild){d.insertBefore(S,d.firstChild);}else{d[aL](S);}}aG.call(R,R,an.fn);return R;};aT[aY].clear=function(){this.canvas.innerHTML=at;this.span=L.createElement("span");this.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;display:inline;";this.canvas[aL](this.span);this.bottom=this.top=null;};aT[aY].remove=function(){this.canvas.parentNode.removeChild(this.canvas);for(var d in this){this[d]=s(d);}};}if((/^Apple|^Google/).test(navigator.vendor)&&!(navigator.userAgent.indexOf("Version/4.0")+1)){aT[aY].safari=function(){var d=this.rect(-99,-99,this.width+99,this.height+99);setTimeout(function(){d.remove();});};}else{aT[aY].safari=function(){};}var ae=(function(){if(L.addEventListener){return function(R,i,e,d){var E=function(S){return e.call(d,S);};R.addEventListener(i,E,false);return function(){R.removeEventListener(i,E,false);return true;};};}else{if(L.attachEvent){return function(S,E,i,e){var R=function(a0){return i.call(e,a0||au.event);};S.attachEvent("on"+E,R);var d=function(){S.detachEvent("on"+E,R);return true;};return d;};}}})();for(var ac=F[m];ac--;){(function(d){ax[aY][d]=function(e){if(an.is(e,"function")){this.events=this.events||[];this.events.push({name:d,f:e,unbind:ae(this.shape||this.node,d,e,this)});}return this;};ax[aY]["un"+d]=function(E){var i=this.events,e=i[m];while(e--){if(i[e].name==d&&i[e].f==E){i[e].unbind();i.splice(e,1);!i.length&&delete this.events;return this;}}return this;};})(F[ac]);}ax[aY].hover=function(e,d){return this.mouseover(e).mouseout(d);};ax[aY].unhover=function(e,d){return this.unmouseover(e).unmouseout(d);};aT[aY].circle=function(d,i,e){return P(this,d||0,i||0,e||0);};aT[aY].rect=function(d,R,e,i,E){return aF(this,d||0,R||0,e||0,i||0,E||0);};aT[aY].ellipse=function(d,E,i,e){return ai(this,d||0,E||0,i||0,e||0);};aT[aY].path=function(d){d&&!an.is(d,"string")&&!an.is(d[0],"array")&&(d+=at);return q(an.format[aW](an,arguments),this);};aT[aY].image=function(E,d,R,e,i){return o(this,E||"about:blank",d||0,R||0,e||0,i||0);};aT[aY].text=function(d,i,e){return X(this,d||0,i||0,e||at);};aT[aY].set=function(d){arguments[m]>1&&(d=Array[aY].splice.call(arguments,0,arguments[m]));return new T(d);};aT[aY].setSize=aV;aT[aY].top=aT[aY].bottom=null;aT[aY].raphael=an;function u(){return this.x+am+this.y;}ax[aY].scale=function(a6,a5,E,e){if(a6==null&&a5==null){return{x:this._.sx,y:this._.sy,toString:u};}a5=a5||a6;!+a5&&(a5=a6);var ba,a8,a9,a7,bm=this.attrs;if(a6!=0){var a4=this.getBBox(),a1=a4.x+a4.width/2,R=a4.y+a4.height/2,bl=a6/this._.sx,bk=a5/this._.sy;E=(+E||E==0)?E:a1;e=(+e||e==0)?e:R;var a3=~~(a6/ab.abs(a6)),a0=~~(a5/ab.abs(a5)),be=this.node.style,bo=E+(a1-E)*bl,bn=e+(R-e)*bk;switch(this.type){case"rect":case"image":var a2=bm.width*a3*bl,bd=bm.height*a0*bk;this.attr({height:bd,r:bm.r*aI(a3*bl,a0*bk),width:a2,x:bo-a2/2,y:bn-bd/2});break;case"circle":case"ellipse":this.attr({rx:bm.rx*a3*bl,ry:bm.ry*a0*bk,r:bm.r*aI(a3*bl,a0*bk),cx:bo,cy:bn});break;case"path":var bg=ad(bm.path),bh=true;for(var bj=0,bc=bg[m];bjS){if(e&&!a8.start){a6=an.findDotsAtSegment(a5,a4,E[1],E[2],E[3],E[4],E[5],E[6],(S-a3)/a1);R+=["C",a6.start.x,a6.start.y,a6.m.x,a6.m.y,a6.x,a6.y];if(a0){return R;}a8.start=R;R=["M",a6.x,a6.y+"C",a6.n.x,a6.n.y,a6.end.x,a6.end.y,E[5],E[6]][az]();a3+=a1;a5=+E[5];a4=+E[6];continue;}if(!d&&!e){a6=an.findDotsAtSegment(a5,a4,E[1],E[2],E[3],E[4],E[5],E[6],(S-a3)/a1);return{x:a6.x,y:a6.y,alpha:a6.alpha};}}a3+=a1;a5=+E[5];a4=+E[6];}R+=E;}a8.end=R;a6=d?a3:e?a8:an.findDotsAtSegment(a5,a4,E[1],E[2],E[3],E[4],E[5],E[6],1);a6.alpha&&(a6={x:a6.x,y:a6.y,alpha:a6.alpha});return a6;};},n=aj(function(E,d,a0,S,a6,a5,a4,a3){var R={x:0,y:0},a2=0;for(var a1=0;a1<1.01;a1+=0.01){var e=M(E,d,a0,S,a6,a5,a4,a3,a1);a1&&(a2+=ab.sqrt(aM(R.x-e.x,2)+aM(R.y-e.y,2)));R=e;}return a2;});var ap=aB(1),C=aB(),J=aB(0,1);ax[aY].getTotalLength=function(){if(this.type!="path"){return;}return ap(this.attrs.path);};ax[aY].getPointAtLength=function(d){if(this.type!="path"){return;}return C(this.attrs.path,d);};ax[aY].getSubpath=function(i,e){if(this.type!="path"){return;}if(ab.abs(this.getTotalLength()-e)<0.000001){return J(this.attrs.path,i).end;}var d=J(this.attrs.path,e,1);return i?J(d,i).end:d;};an.easing_formulas={linear:function(d){return d;},"<":function(d){return aM(d,3);},">":function(d){return aM(d-1,3)+1;},"<>":function(d){d=d*2;if(d<1){return aM(d,3)/2;}d-=2;return(aM(d,3)+2)/2;},backIn:function(e){var d=1.70158;return e*e*((d+1)*e-d);},backOut:function(e){e=e-1;var d=1.70158;return e*e*((d+1)*e+d)+1;},elastic:function(i){if(i==0||i==1){return i;}var e=0.3,d=e/4;return aM(2,-10*i)*ab.sin((i-d)*(2*ab.PI)/e)+1;},bounce:function(E){var e=7.5625,i=2.75,d;if(E<(1/i)){d=e*E*E;}else{if(E<(2/i)){E-=(1.5/i);d=e*E*E+0.75;}else{if(E<(2.5/i)){E-=(2.25/i);d=e*E*E+0.9375;}else{E-=(2.625/i);d=e*E*E+0.984375;}}}return d;}};var I={length:0},aR=function(){var a2=+new Date;for(var be in I){if(be!="length"&&I[Q](be)){var bj=I[be];if(bj.stop){delete I[be];I[m]--;continue;}var a0=a2-bj.start,bb=bj.ms,ba=bj.easing,bf=bj.from,a7=bj.diff,E=bj.to,a6=bj.t,a9=bj.prev||0,a1=bj.el,R=bj.callback,a8={},d;if(a0255?255:(d<0?0:d);},t=function(d,i){if(d==null){return{x:this._.tx,y:this._.ty,toString:u};}this._.tx+=+d;this._.ty+=+i;switch(this.type){case"circle":case"ellipse":this.attr({cx:+d+this.attrs.cx,cy:+i+this.attrs.cy});break;case"rect":case"image":case"text":this.attr({x:+d+this.attrs.x,y:+i+this.attrs.y});break;case"path":var e=ad(this.attrs.path);e[0][1]+=+d;e[0][2]+=+i;this.attr({path:e});break;}return this;};ax[aY].animateWith=function(e,i,d,R,E){I[e.id]&&(i.start=I[e.id].start);return this.animate(i,d,R,E);};ax[aY].animateAlong=ay();ax[aY].animateAlongBack=ay(1);function ay(d){return function(E,i,e,S){var R={back:d};an.is(e,"function")?(S=e):(R.rot=e);E&&E.constructor==ax&&(E=E.attrs.path);E&&(R.along=E);return this.animate(R,i,S);};}ax[aY].onAnimation=function(d){this._run=d||0;return this;};ax[aY].animate=function(be,a5,a4,E){if(an.is(a4,"function")||!a4){E=a4||null;}var a9={},e={},a2={};for(var a6 in be){if(be[Q](a6)){if(Z[Q](a6)){a9[a6]=this.attr(a6);(a9[a6]==null)&&(a9[a6]=j[a6]);e[a6]=be[a6];switch(Z[a6]){case"along":var bc=ap(be[a6]),a7=C(be[a6],bc*!!be.back),R=this.getBBox();a2[a6]=bc/a5;a2.tx=R.x;a2.ty=R.y;a2.sx=a7.x;a2.sy=a7.y;e.rot=be.rot;e.back=be.back;e.len=bc;be.rot&&(a2.r=W(this.rotate())||0);break;case"number":a2[a6]=(e[a6]-a9[a6])/a5;break;case"colour":a9[a6]=an.getRGB(a9[a6]);var a8=an.getRGB(e[a6]);a2[a6]={r:(a8.r-a9[a6].r)/a5,g:(a8.g-a9[a6].g)/a5,b:(a8.b-a9[a6].b)/a5};break;case"path":var S=H(a9[a6],e[a6]);a9[a6]=S[0];var a3=S[1];a2[a6]=[];for(var bb=0,a1=a9[a6][m];bbf*b.top){e=b.percents[y],p=b.percents[y-1]||0,t=t/b.top*(e-p),o=b.percents[y+1],j=b.anim[e];break}f&&d.attr(b.anim[b.percents[y]])}if(!!j){if(!k){for(attr in j)if(j[g](attr))if(U[g](attr)||d.paper.customAttributes[g](attr)){u[attr]=d.attr(attr),u[attr]==null&&(u[attr]=T[attr]),v[attr]=j[attr];switch(U[attr]){case C:w[attr]=(v[attr]-u[attr])/t;break;case"colour":u[attr]=a.getRGB(u[attr]);var A=a.getRGB(v[attr]);w[attr]={r:(A.r-u[attr].r)/t,g:(A.g-u[attr].g)/t,b:(A.b-u[attr].b)/t};break;case"path":var B=bG(u[attr],v[attr]),D=B[1];u[attr]=B[0],w[attr]=[];for(y=0,z=u[attr].length;yd)return d;while(cf?c=e:d=e,e=(d-c)/2+c}return e}function n(a,b){var c=o(a,b);return((l*c+k)*c+j)*c}function m(a){return((i*a+h)*a+g)*a}var g=3*b,h=3*(d-b)-g,i=1-g-h,j=3*c,k=3*(e-c)-j,l=1-j-k;return n(a,1/(200*f))}function cd(){return this.x+q+this.y+q+this.width+" × "+this.height}function cc(){return this.x+q+this.y}function bR(a,b,c,d,e,f){a!=null?(this.a=+a,this.b=+b,this.c=+c,this.d=+d,this.e=+e,this.f=+f):(this.a=1,this.b=0,this.c=0,this.d=1,this.e=0,this.f=0)}function bw(a){var b=[];for(var c=0,d=a.length;d-2>c;c+=2){var e=[{x:+a[c],y:+a[c+1]},{x:+a[c],y:+a[c+1]},{x:+a[c+2],y:+a[c+3]},{x:+a[c+4],y:+a[c+5]}];d-4==c?(e[0]={x:+a[c-2],y:+a[c-1]},e[3]=e[2]):c&&(e[0]={x:+a[c-2],y:+a[c-1]}),b.push(["C",(-e[0].x+6*e[1].x+e[2].x)/6,(-e[0].y+6*e[1].y+e[2].y)/6,(e[1].x+6*e[2].x-e[3].x)/6,(e[1].y+6*e[2].y-e[3].y)/6,e[2].x,e[2].y])}return b}function bv(){return this.hex}function bt(a,b,c){function d(){var e=Array.prototype.slice.call(arguments,0),f=e.join("␀"),h=d.cache=d.cache||{},i=d.count=d.count||[];if(h[g](f)){bs(i,f);return c?c(h[f]):h[f]}i.length>=1e3&&delete h[i.shift()],i.push(f),h[f]=a[m](b,e);return c?c(h[f]):h[f]}return d}function bs(a,b){for(var c=0,d=a.length;c',bk=bj.firstChild,bk.style.behavior="url(#default#VML)";if(!bk||typeof bk.adj!="object")return a.type=p;bj=null}a.svg=!(a.vml=a.type=="VML"),a._Paper=j,a.fn=k=j.prototype=a.prototype,a._id=0,a._oid=0,a.is=function(a,b){b=v.call(b);if(b=="finite")return!M[g](+a);if(b=="array")return a instanceof Array;return b=="null"&&a===null||b==typeof a&&a!==null||b=="object"&&a===Object(a)||b=="array"&&Array.isArray&&Array.isArray(a)||H.call(a).slice(8,-1).toLowerCase()==b},a.angle=function(b,c,d,e,f,g){if(f==null){var h=b-d,i=c-e;if(!h&&!i)return 0;return(180+w.atan2(-i,-h)*180/B+360)%360}return a.angle(b,c,f,g)-a.angle(d,e,f,g)},a.rad=function(a){return a%360*B/180},a.deg=function(a){return a*180/B%360},a.snapTo=function(b,c,d){d=a.is(d,"finite")?d:10;if(a.is(b,E)){var e=b.length;while(e--)if(z(b[e]-c)<=d)return b[e]}else{b=+b;var f=c%b;if(fb-d)return c-f+b}return c};var bl=a.createUUID=function(a,b){return function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(a,b).toUpperCase()}}(/[xy]/g,function(a){var b=w.random()*16|0,c=a=="x"?b:b&3|8;return c.toString(16)});a.setWindow=function(b){eve("setWindow",a,h.win,b),h.win=b,h.doc=h.win.document,initWin&&initWin(h.win)};var bm=function(b){if(a.vml){var c=/^\s+|\s+$/g,d;try{var e=new ActiveXObject("htmlfile");e.write(""),e.close(),d=e.body}catch(f){d=createPopup().document.body}var g=d.createTextRange();bm=bt(function(a){try{d.style.color=r(a).replace(c,p);var b=g.queryCommandValue("ForeColor");b=(b&255)<<16|b&65280|(b&16711680)>>>16;return"#"+("000000"+b.toString(16)).slice(-6)}catch(e){return"none"}})}else{var i=h.doc.createElement("i");i.title="Raphaël Colour Picker",i.style.display="none",h.doc.body.appendChild(i),bm=bt(function(a){i.style.color=a;return h.doc.defaultView.getComputedStyle(i,p).getPropertyValue("color")})}return bm(b)},bn=function(){return"hsb("+[this.h,this.s,this.b]+")"},bo=function(){return"hsl("+[this.h,this.s,this.l]+")"},bp=function(){return this.hex},bq=function(b,c,d){c==null&&a.is(b,"object")&&"r"in b&&"g"in b&&"b"in b&&(d=b.b,c=b.g,b=b.r);if(c==null&&a.is(b,D)){var e=a.getRGB(b);b=e.r,c=e.g,d=e.b}if(b>1||c>1||d>1)b/=255,c/=255,d/=255;return[b,c,d]},br=function(b,c,d,e){b*=255,c*=255,d*=255;var f={r:b,g:c,b:d,hex:a.rgb(b,c,d),toString:bp};a.is(e,"finite")&&(f.opacity=e);return f};a.color=function(b){var c;a.is(b,"object")&&"h"in b&&"s"in b&&"b"in b?(c=a.hsb2rgb(b),b.r=c.r,b.g=c.g,b.b=c.b,b.hex=c.hex):a.is(b,"object")&&"h"in b&&"s"in b&&"l"in b?(c=a.hsl2rgb(b),b.r=c.r,b.g=c.g,b.b=c.b,b.hex=c.hex):(a.is(b,"string")&&(b=a.getRGB(b)),a.is(b,"object")&&"r"in b&&"g"in b&&"b"in b?(c=a.rgb2hsl(b),b.h=c.h,b.s=c.s,b.l=c.l,c=a.rgb2hsb(b),b.v=c.b):(b={hex:"none"},crl.r=b.g=b.b=b.h=b.s=b.v=b.l=-1)),b.toString=bp;return b},a.hsb2rgb=function(a,b,c,d){this.is(a,"object")&&"h"in a&&"s"in a&&"b"in a&&(c=a.b,b=a.s,a=a.h,d=a.o),a*=360;var e,f,g,h,i;a=a%360/60,i=c*b,h=i*(1-z(a%2-1)),e=f=g=c-i,a=~~a,e+=[i,h,0,0,h,i][a],f+=[h,i,i,h,0,0][a],g+=[0,0,h,i,i,h][a];return br(e,f,g,d)},a.hsl2rgb=function(a,b,c,d){this.is(a,"object")&&"h"in a&&"s"in a&&"l"in a&&(c=a.l,b=a.s,a=a.h);if(a>1||b>1||c>1)a/=360,b/=100,c/=100;a*=360;var e,f,g,h,i;a=a%360/60,i=2*b*(c<.5?c:1-c),h=i*(1-z(a%2-1)),e=f=g=c-i/2,a=~~a,e+=[i,h,0,0,h,i][a],f+=[h,i,i,h,0,0][a],g+=[0,0,h,i,i,h][a];return br(e,f,g,d)},a.rgb2hsb=function(a,b,c){c=bq(a,b,c),a=c[0],b=c[1],c=c[2];var d,e,f,g;f=x(a,b,c),g=f-y(a,b,c),d=g==0?null:f==a?(b-c)/g:f==b?(c-a)/g+2:(a-b)/g+4,d=(d+360)%6*60/360,e=g==0?0:g/f;return{h:d,s:e,b:f,toString:bn}},a.rgb2hsl=function(a,b,c){c=bq(a,b,c),a=c[0],b=c[1],c=c[2];var d,e,f,g,h,i;g=x(a,b,c),h=y(a,b,c),i=g-h,d=i==0?null:g==a?(b-c)/i:g==b?(c-a)/i+2:(a-b)/i+4,d=(d+360)%6*60/360,f=(g+h)/2,e=i==0?0:f<.5?i/(2*f):i/(2-2*f);return{h:d,s:e,l:f,toString:bo}},a._path2string=function(){return this.join(",").replace(X,"$1")};var bu=a._preload=function(a,b){var c=h.doc.createElement("img");c.style.cssText="position:absolute;left:-9999em;top-9999em",c.onload=function(){b.call(this),this.onload=null,h.doc.body.removeChild(this)},c.onerror=function(){h.doc.body.removeChild(this)},h.doc.body.appendChild(c),c.src=a};a.getRGB=bt(function(b){if(!b||!!((b=r(b)).indexOf("-")+1))return{r:-1,g:-1,b:-1,hex:"none",error:1,toString:bv};if(b=="none")return{r:-1,g:-1,b:-1,hex:"none",toString:bv};!W[g](b.toLowerCase().substring(0,2))&&b.charAt()!="#"&&(b=bm(b));var c,d,e,f,h,i,j,k=b.match(L);if(k){k[2]&&(f=R(k[2].substring(5),16),e=R(k[2].substring(3,5),16),d=R(k[2].substring(1,3),16)),k[3]&&(f=R((i=k[3].charAt(3))+i,16),e=R((i=k[3].charAt(2))+i,16),d=R((i=k[3].charAt(1))+i,16)),k[4]&&(j=k[4][s](V),d=Q(j[0]),j[0].slice(-1)=="%"&&(d*=2.55),e=Q(j[1]),j[1].slice(-1)=="%"&&(e*=2.55),f=Q(j[2]),j[2].slice(-1)=="%"&&(f*=2.55),k[1].toLowerCase().slice(0,4)=="rgba"&&(h=Q(j[3])),j[3]&&j[3].slice(-1)=="%"&&(h/=100));if(k[5]){j=k[5][s](V),d=Q(j[0]),j[0].slice(-1)=="%"&&(d*=2.55),e=Q(j[1]),j[1].slice(-1)=="%"&&(e*=2.55),f=Q(j[2]),j[2].slice(-1)=="%"&&(f*=2.55),(j[0].slice(-3)=="deg"||j[0].slice(-1)=="°")&&(d/=360),k[1].toLowerCase().slice(0,4)=="hsba"&&(h=Q(j[3])),j[3]&&j[3].slice(-1)=="%"&&(h/=100);return a.hsb2rgb(d,e,f,h)}if(k[6]){j=k[6][s](V),d=Q(j[0]),j[0].slice(-1)=="%"&&(d*=2.55),e=Q(j[1]),j[1].slice(-1)=="%"&&(e*=2.55),f=Q(j[2]),j[2].slice(-1)=="%"&&(f*=2.55),(j[0].slice(-3)=="deg"||j[0].slice(-1)=="°")&&(d/=360),k[1].toLowerCase().slice(0,4)=="hsla"&&(h=Q(j[3])),j[3]&&j[3].slice(-1)=="%"&&(h/=100);return a.hsl2rgb(d,e,f,h)}k={r:d,g:e,b:f,toString:bv},k.hex="#"+(16777216|f|e<<8|d<<16).toString(16).slice(1),a.is(h,"finite")&&(k.opacity=h);return k}return{r:-1,g:-1,b:-1,hex:"none",error:1,toString:bv}},a),a.hsb=bt(function(b,c,d){return a.hsb2rgb(b,c,d).hex}),a.hsl=bt(function(b,c,d){return a.hsl2rgb(b,c,d).hex}),a.rgb=bt(function(a,b,c){return"#"+(16777216|c|b<<8|a<<16).toString(16).slice(1)}),a.getColor=function(a){var b=this.getColor.start=this.getColor.start||{h:0,s:1,b:a||.75},c=this.hsb2rgb(b.h,b.s,b.b);b.h+=.075,b.h>1&&(b.h=0,b.s-=.2,b.s<=0&&(this.getColor.start={h:0,s:1,b:b.b}));return c.hex},a.getColor.reset=function(){delete this.start},a.parsePathString=bt(function(b){if(!b)return null;var c={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0},d=[];a.is(b,E)&&a.is(b[0],E)&&(d=by(b)),d.length||r(b).replace(Y,function(a,b,e){var f=[],g=b.toLowerCase();e.replace($,function(a,b){b&&f.push(+b)}),g=="m"&&f.length>2&&(d.push([b][n](f.splice(0,2))),g="l",b=b=="m"?"l":"L");if(g=="r")d.push([b][n](f));else while(f.length>=c[g]){d.push([b][n](f.splice(0,c[g])));if(!c[g])break}}),d.toString=a._path2string;return d}),a.parseTransformString=bt(function(b){if(!b)return null;var c={r:3,s:4,t:2,m:6},d=[];a.is(b,E)&&a.is(b[0],E)&&(d=by(b)),d.length||r(b).replace(Z,function(a,b,c){var e=[],f=v.call(b);c.replace($,function(a,b){b&&e.push(+b)}),d.push([b][n](e))}),d.toString=a._path2string;return d}),a.findDotsAtSegment=function(a,b,c,d,e,f,g,h,i){var j=1-i,k=A(j,3),l=A(j,2),m=i*i,n=m*i,o=k*a+l*3*i*c+j*3*i*i*e+n*g,p=k*b+l*3*i*d+j*3*i*i*f+n*h,q=a+2*i*(c-a)+m*(e-2*c+a),r=b+2*i*(d-b)+m*(f-2*d+b),s=c+2*i*(e-c)+m*(g-2*e+c),t=d+2*i*(f-d)+m*(h-2*f+d),u=j*a+i*c,v=j*b+i*d,x=j*e+i*g,y=j*f+i*h,z=90-w.atan2(q-s,r-t)*180/B;(q>s||r1&&(v=w.sqrt(v),c=v*c,d=v*d);var x=c*c,y=d*d,A=(f==g?-1:1)*w.sqrt(z((x*y-x*u*u-y*t*t)/(x*u*u+y*t*t))),C=A*c*u/d+(a+h)/2,D=A*-d*t/c+(b+i)/2,E=w.asin(((b-D)/d).toFixed(9)),F=w.asin(((i-D)/d).toFixed(9));E=aF&&(E=E-B*2),!g&&F>E&&(F=F-B*2)}else E=j[0],F=j[1],C=j[2],D=j[3];var G=F-E;if(z(G)>k){var H=F,I=h,J=i;F=E+k*(g&&F>E?1:-1),h=C+c*w.cos(F),i=D+d*w.sin(F),m=bD(h,i,c,d,e,0,g,I,J,[F,H,C,D])}G=F-E;var K=w.cos(E),L=w.sin(E),M=w.cos(F),N=w.sin(F),O=w.tan(G/4),P=4/3*c*O,Q=4/3*d*O,R=[a,b],S=[a+P*L,b-Q*K],T=[h+P*N,i-Q*M],U=[h,i];S[0]=2*R[0]-S[0],S[1]=2*R[1]-S[1];if(j)return[S,T,U][n](m);m=[S,T,U][n](m).join()[s](",");var V=[];for(var W=0,X=m.length;W"1e12"&&(l=.5),z(n)>"1e12"&&(n=.5),l>0&&l<1&&(q=bE(a,b,c,d,e,f,g,h,l),p.push(q.x),o.push(q.y)),n>0&&n<1&&(q=bE(a,b,c,d,e,f,g,h,n),p.push(q.x),o.push(q.y)),i=f-2*d+b-(h-2*f+d),j=2*(d-b)-2*(f-d),k=b-d,l=(-j+w.sqrt(j*j-4*i*k))/2/i,n=(-j-w.sqrt(j*j-4*i*k))/2/i,z(l)>"1e12"&&(l=.5),z(n)>"1e12"&&(n=.5),l>0&&l<1&&(q=bE(a,b,c,d,e,f,g,h,l),p.push(q.x),o.push(q.y)),n>0&&n<1&&(q=bE(a,b,c,d,e,f,g,h,n),p.push(q.x),o.push(q.y));return{min:{x:y[m](0,p),y:y[m](0,o)},max:{x:x[m](0,p),y:x[m](0,o)}}}),bG=a._path2curve=bt(function(a,b){var c=bA(a),d=b&&bA(b),e={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},f={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},g=function(a,b){var c,d;if(!a)return["C",b.x,b.y,b.x,b.y,b.x,b.y];!(a[0]in{T:1,Q:1})&&(b.qx=b.qy=null);switch(a[0]){case"M":b.X=a[1],b.Y=a[2];break;case"A":a=["C"][n](bD[m](0,[b.x,b.y][n](a.slice(1))));break;case"S":c=b.x+(b.x-(b.bx||b.x)),d=b.y+(b.y-(b.by||b.y)),a=["C",c,d][n](a.slice(1));break;case"T":b.qx=b.x+(b.x-(b.qx||b.x)),b.qy=b.y+(b.y-(b.qy||b.y)),a=["C"][n](bC(b.x,b.y,b.qx,b.qy,a[1],a[2]));break;case"Q":b.qx=a[1],b.qy=a[2],a=["C"][n](bC(b.x,b.y,a[1],a[2],a[3],a[4]));break;case"L":a=["C"][n](bB(b.x,b.y,a[1],a[2]));break;case"H":a=["C"][n](bB(b.x,b.y,a[1],b.y));break;case"V":a=["C"][n](bB(b.x,b.y,b.x,a[1]));break;case"Z":a=["C"][n](bB(b.x,b.y,b.X,b.Y))}return a},h=function(a,b){if(a[b].length>7){a[b].shift();var e=a[b];while(e.length)a.splice(b++,0,["C"][n](e.splice(0,6)));a.splice(b,1),k=x(c.length,d&&d.length||0)}},i=function(a,b,e,f,g){a&&b&&a[g][0]=="M"&&b[g][0]!="M"&&(b.splice(g,0,["M",f.x,f.y]),e.bx=0,e.by=0,e.x=a[g][1],e.y=a[g][2],k=x(c.length,d&&d.length||0))};for(var j=0,k=x(c.length,d&&d.length||0);j=j)return p;o=p}if(j==null)return k},cg=function(b,c){return function(d,e,f){d=bG(d);var g,h,i,j,k="",l={},m,n=0;for(var o=0,p=d.length;oe){if(c&&!l.start){m=cf(g,h,i[1],i[2],i[3],i[4],i[5],i[6],e-n),k+=["C"+m.start.x,m.start.y,m.m.x,m.m.y,m.x,m.y];if(f)return k;l.start=k,k=["M"+m.x,m.y+"C"+m.n.x,m.n.y,m.end.x,m.end.y,i[5],i[6]].join(),n+=j,g=+i[5],h=+i[6];continue}if(!b&&!c){m=cf(g,h,i[1],i[2],i[3],i[4],i[5],i[6],e-n);return{x:m.x,y:m.y,alpha:m.alpha}}}n+=j,g=+i[5],h=+i[6]}k+=i.shift()+i}l.end=k,m=b?n:c?l:a.findDotsAtSegment(g,h,i[0],i[1],i[2],i[3],i[4],i[5],1),m.alpha&&(m={x:m.x,y:m.y,alpha:m.alpha});return m}},ch=cg(1),ci=cg(),cj=cg(0,1);a.getTotalLength=ch,a.getPointAtLength=ci,a.getSubpath=function(a,b,c){if(this.getTotalLength(a)-c<1e-6)return cj(a,b).end;var d=cj(a,c,1);return b?cj(d,b).end:d},b_.getTotalLength=function(){if(this.type=="path"){if(this.node.getTotalLength)return this.node.getTotalLength();return ch(this.attrs.path)}},b_.getPointAtLength=function(a){if(this.type=="path")return ci(this.attrs.path,a)},b_.getSubpath=function(b,c){if(this.type=="path")return a.getSubpath(this.attrs.path,b,c)};var ck=a.easing_formulas={linear:function(a){return a},"<":function(a){return A(a,1.7)},">":function(a){return A(a,.48)},"<>":function(a){var b=.48-a/1.04,c=w.sqrt(.1734+b*b),d=c-b,e=A(z(d),1/3)*(d<0?-1:1),f=-c-b,g=A(z(f),1/3)*(f<0?-1:1),h=e+g+.5;return(1-h)*3*h*h+h*h*h},backIn:function(a){var b=1.70158;return a*a*((b+1)*a-b)},backOut:function(a){a=a-1;var b=1.70158;return a*a*((b+1)*a+b)+1},elastic:function(a){if(a==!!a)return a;return A(2,-10*a)*w.sin((a-.075)*2*B/.3)+1},bounce:function(a){var b=7.5625,c=2.75,d;a<1/c?d=b*a*a:a<2/c?(a-=1.5/c,d=b*a*a+.75):a<2.5/c?(a-=2.25/c,d=b*a*a+.9375):(a-=2.625/c,d=b*a*a+.984375);return d}};ck.easeIn=ck["ease-in"]=ck["<"],ck.easeOut=ck["ease-out"]=ck[">"],ck.easeInOut=ck["ease-in-out"]=ck["<>"],ck["back-in"]=ck.backIn,ck["back-out"]=ck.backOut;var cl=[],cm=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(a){setTimeout(a,16)},cn=function(){var b=+(new Date),c=0;for(;c1&&!d.next){for(s in k)k[g](s)&&(r[s]=d.totalOrigin[s]);d.el.attr(r),cr(d.anim,d.el,d.anim.percents[0],null,d.totalOrigin,d.repeat-1)}d.next&&!d.stop&&cr(d.anim,d.el,d.next,null,d.totalOrigin,d.repeat)}}a.svg&&m&&m.paper&&m.paper.safari(),cl.length&&cm(cn)},co=function(a){return a>255?255:a<0?0:a};b_.animateWith=function(b,c,d,e,f,g){var h=d?a.animation(d,e,f,g):c;status=b.status(c);return this.animate(h).status(h,status*c.ms/h.ms)},b_.onAnimation=function(a){a?eve.on("anim.frame."+this.id,a):eve.unbind("anim.frame."+this.id);return this},cq.prototype.delay=function(a){var b=new cq(this.anim,this.ms);b.times=this.times,b.del=+a||0;return b},cq.prototype.repeat=function(a){var b=new cq(this.anim,this.ms);b.del=this.del,b.times=w.floor(x(a,0))||1;return b},a.animation=function(b,c,d,e){if(b instanceof cq)return b;if(a.is(d,"function")||!d)e=e||d||null,d=null;b=Object(b),c=+c||0;var f={},h,i;for(i in b)b[g](i)&&Q(i)!=i&&Q(i)+"%"!=i&&(h=!0,f[i]=b[i]);if(!h)return new cq(b,c);d&&(f.easing=d),e&&(f.callback=e);return new cq({100:f},c)},b_.animate=function(b,c,d,e){var f=this;if(f.removed){e&&e.call(f);return f}var g=b instanceof cq?b:a.animation(b,c,d,e);cr(g,f,g.percents[0],null,f.attr());return f},b_.setTime=function(a,b){a&&b!=null&&this.status(a,y(b,a.ms)/a.ms);return this},b_.status=function(a,b){var c=[],d=0,e,f;if(b!=null){cr(a,this,-1,y(b,1));return this}e=cl.length;for(;d.5)*2-1;i(m-.5,2)+i(n-.5,2)>.25&&(n=f.sqrt(.25-i(m-.5,2))*e+.5)&&n!=.5&&(n=n.toFixed(5)-1e-5*e)}return l}),e=e.split(/\s*\-\s*/);if(j=="linear"){var t=e.shift();t=-d(t);if(isNaN(t))return null;var u=[0,0,f.cos(a.rad(t)),f.sin(a.rad(t))],v=1/(g(h(u[2]),h(u[3]))||1);u[2]*=v,u[3]*=v,u[2]<0&&(u[0]=-u[2],u[2]=0),u[3]<0&&(u[1]=-u[3],u[3]=0)}var w=a._parseDots(e);if(!w)return null;b.gradient&&(p.defs.removeChild(b.gradient),delete b.gradient),k=k.replace(/[\(\)\s,\xb0#]/g,"-"),s=q(j+"Gradient",{id:k}),b.gradient=s,q(s,j=="radial"?{fx:m,fy:n}:{x1:u[0],y1:u[1],x2:u[2],y2:u[3],gradientTransform:b.matrix.invert()}),p.defs.appendChild(s);for(var x=0,y=w.length;x1?E.opacity/100:E.opacity});case"stroke":E=a.getRGB(p),i.setAttribute(o,E.hex),o=="stroke"&&E[b]("opacity")&&q(i,{"stroke-opacity":E.opacity>1?E.opacity/100:E.opacity}),o=="stroke"&&d._.arrows&&("startString"in d._.arrows&&w(d,d._.arrows.startString),"endString"in d._.arrows&&w(d,d._.arrows.endString,1));break;case"gradient":(d.type=="circle"||d.type=="ellipse"||c(p).charAt()!="r")&&u(d,p);break;case"opacity":k.gradient&&!k[b]("stroke-opacity")&&q(i,{"stroke-opacity":p>1?p/100:p});case"fill-opacity":if(k.gradient){F=a._g.doc.getElementById(i.getAttribute("fill").replace(/^url\(#|\)$/g,l)),F&&(G=F.getElementsByTagName("stop"),q(G[G.length-1],{"stop-opacity":p}));break};default:o=="font-size"&&(p=e(p,10)+"px");var H=o.replace(/(\-.)/g,function(a){return a.substring(1).toUpperCase()});i.style[H]=p,d._.dirty=1,i.setAttribute(o,p)}}B(d,f),i.style.visibility=m},A=1.2,B=function(d,f){if(d.type=="text"&&!!(f[b]("text")||f[b]("font")||f[b]("font-size")||f[b]("x")||f[b]("y"))){var g=d.attrs,h=d.node,i=h.firstChild?e(a._g.doc.defaultView.getComputedStyle(h.firstChild,l).getPropertyValue("font-size"),10):10;if(f[b]("text")){g.text=f.text;while(h.firstChild)h.removeChild(h.firstChild);var j=c(f.text).split("\n"),k=[],m;for(var n=0,o=j.length;n"));var Y=V.getBoundingClientRect();t.W=m.w=(Y.right-Y.left)/W,t.H=m.h=(Y.bottom-Y.top)/W,t.X=m.x,t.Y=m.y+t.H/2,("x"in i||"y"in i)&&(t.path.v=a.format("m{0},{1}l{2},{1}",f(m.x*u),f(m.y*u),f(m.x*u)+1));var Z=["x","y","text","font","font-family","font-weight","font-style","font-size"];for(var $=0,_=Z.length;$<_;$++)if(Z[$]in i){t._.dirty=1;break}switch(m["text-anchor"]){case"start":t.textpath.style["v-text-align"]="left",t.bbx=t.W/2;break;case"end":t.textpath.style["v-text-align"]="right",t.bbx=-t.W/2;break;default:t.textpath.style["v-text-align"]="center",t.bbx=0}t.textpath.style["v-text-kern"]=!0}},addGradientFill=function(b,f,g){b.attrs=b.attrs||{};var h=b.attrs,i=Math.pow,j,k,l="linear",m=".5 .5";b.attrs.gradient=f,f=c(f).replace(a._radial_gradient,function(a,b,c){l="radial",b&&c&&(b=d(b),c=d(c),i(b-.5,2)+i(c-.5,2)>.25&&(c=e.sqrt(.25-i(b-.5,2))*((c>.5)*2-1)+.5),m=b+n+c);return o}),f=f.split(/\s*\-\s*/);if(l=="linear"){var p=f.shift();p=-d(p);if(isNaN(p))return null}var q=a._parseDots(f);if(!q)return null;b=b.shape||b.node;if(q.length){b.removeChild(g),g.on=!0,g.method="none",g.color=q[0].color,g.color2=q[q.length-1].color;var r=[];for(var s=0,t=q.length;s')}}catch(c){B=function(a){return b.createElement("<"+a+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}};C(a._g.win),a._engine.create=function(){var b=a._getContainer.apply(0,arguments),c=b.container,d=b.height,e,f=b.width,g=b.x,h=b.y;if(!c)throw new Error("VML container not found.");var i=new a._Paper,j=i.canvas=a._g.doc.createElement("div"),k=j.style;g=g||0,h=h||0,f=f||512,d=d||342,i.width=f,i.height=d,f==+f&&(f+="px"),d==+d&&(d+="px"),i.coordsize=u*1e3+n+u*1e3,i.coordorigin="0 0",i.span=a._g.doc.createElement("span"),i.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;",j.appendChild(i.span),k.cssText=a.format("top:0;left:0;width:{0};height:{1};display:inline-block;position:relative;clip:rect(0 {0} {1} 0);overflow:hidden",f,d),c==1?(a._g.doc.body.appendChild(j),k.left=g+"px",k.top=h+"px",k.position="absolute"):c.firstChild?c.insertBefore(j,c.firstChild):c.appendChild(j),i.renderfix=function(){};return i},a.prototype.clear=function(){a.eve("clear",this),this.canvas.innerHTML=o,this.span=a._g.doc.createElement("span"),this.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;display:inline;",this.canvas.appendChild(this.span),this.bottom=this.top=null},a.prototype.remove=function(){a.eve("remove",this),this.canvas.parentNode.removeChild(this.canvas);for(var b in this)this[b]=removed(b);return!0};var D=a.st;for(var E in A)A[b](E)&&!D[b](E)&&(D[E]=function(a){return function(){var b=arguments;return this.forEach(function(c){c[a].apply(c,b)})}}(E))}(window.Raphael) \ No newline at end of file From 534da7c07b23ee800aed4c5495aaa9caf7276973 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 14:18:56 +0200 Subject: [PATCH 106/163] [MERGE] upstream fixes bzr revid: xmo@openerp.com-20111026121856-q9cso26sh2mp6b3s --- addons/web_diagram/static/lib/js/dracula_graph.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/web_diagram/static/lib/js/dracula_graph.js b/addons/web_diagram/static/lib/js/dracula_graph.js index ff8ba3a423d..46096e0acb1 100644 --- a/addons/web_diagram/static/lib/js/dracula_graph.js +++ b/addons/web_diagram/static/lib/js/dracula_graph.js @@ -378,6 +378,8 @@ Graph.Layout.Spring.prototype = { }, layoutRepulsive: function(node1, node2) { + if (typeof node1 == 'undefined' || typeof node2 == 'undefined') + return; var dx = node2.layoutPosX - node1.layoutPosX; var dy = node2.layoutPosY - node1.layoutPosY; var d2 = dx * dx + dy * dy; From e8bc3209ae61ea5f25e5ff52eae1713d2f1a8186 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 14:20:59 +0200 Subject: [PATCH 107/163] [REM] doubleclick workaround for webkit since underlying onclick breakage was worked around in revision xmo@openerp.com-20111026120509-wmj3onhkrnps6xee bzr revid: xmo@openerp.com-20111026122059-w7ak1cvkyfkyrqug --- addons/web_diagram/static/lib/js/dracula_graph.js | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/addons/web_diagram/static/lib/js/dracula_graph.js b/addons/web_diagram/static/lib/js/dracula_graph.js index 46096e0acb1..28269986e78 100644 --- a/addons/web_diagram/static/lib/js/dracula_graph.js +++ b/addons/web_diagram/static/lib/js/dracula_graph.js @@ -160,13 +160,11 @@ Graph.Renderer.Raphael = function(element, graph, width, height) { */ this.isDrag = false; this.dragger = function (e) { - if(e.detail < 2) { - this.dx = e.clientX; - this.dy = e.clientY; - selfRef.isDrag = this; - this.set && this.set.animate({"fill-opacity": .1}, 200); - e.preventDefault && e.preventDefault(); - } + this.dx = e.clientX; + this.dy = e.clientY; + selfRef.isDrag = this; + this.set && this.set.animate({"fill-opacity": .1}, 200); + e.preventDefault && e.preventDefault(); }; var d = document.getElementById(element); From a45785d2f872a76b9b3becd403706a4091f9d0fa Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 14:49:28 +0200 Subject: [PATCH 108/163] [IMP] propagate click events from labels to the corresponding nodes in order to avoid implementing all handlers twice bzr revid: xmo@openerp.com-20111026124928-a5yq78p1cejg2uzx --- addons/web_diagram/static/src/js/diagram.js | 26 ++++++++++----------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/addons/web_diagram/static/src/js/diagram.js b/addons/web_diagram/static/src/js/diagram.js index 3e426dc946f..24da19a952f 100644 --- a/addons/web_diagram/static/src/js/diagram.js +++ b/addons/web_diagram/static/src/js/diagram.js @@ -121,26 +121,23 @@ openerp.web.DiagramView = openerp.web.View.extend({ //Custom logic var self = this; var renderer = function(r, n) { - var node; - var set; var shape = n.node.shape; if(shape == 'rectangle') shape = 'rect'; - node = r[shape](n.node.x, n.node.y).attr({ + var node = r[shape](n.node.x, n.node.y).attr({ "fill": n.node.color }).dblclick(function() { self.add_edit_node(n.node.id, self.node); }); - set = r.set() - .push(node) - .push( - r.text(n.node.x, n.node.y, (n.label || n.id)) - .attr({"cursor":"pointer"}) - .dblclick(function() { - self.add_edit_node(n.node.id, self.node); - }) - ); - node.attr({cursor: "pointer"}); + + var propagate_to_previous_sibling = function (e) { + $(this).prev().trigger(e.type); + }; + var nodes = r.set() + .push(node, r.text(n.node.x, n.node.y, (n.label || n.id)) + .click(propagate_to_previous_sibling) + .dblclick(propagate_to_previous_sibling) + ).attr("cursor", "pointer"); if(shape == "ellipse") node.attr({rx: "40", ry: "20"}); @@ -148,7 +145,8 @@ openerp.web.DiagramView = openerp.web.View.extend({ node.attr({width: "60", height: "44"}); node.next.attr({"text-anchor": "middle", x: n.node.x + 20, y: n.node.y + 20}); } - return set; + + return nodes; }; _.each(res_nodes, function(res_node) { From 9a48657a45d132761f0c2ef8e62d964b55e3b8d7 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 14:55:24 +0200 Subject: [PATCH 109/163] [imp] made o2m reload when readonly property is changed bzr revid: nicolas.vanhoren@openerp.com-20111026125524-c77rmzd6gq9u9oke --- addons/web/static/src/js/view_form.js | 28 ++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index cf5d98bb3e6..0c8ee47ff66 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1939,6 +1939,13 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ self.on_ui_change(); }); + this.is_setted.then(function() { + self.load_views(); + }); + }, + load_views: function() { + var self = this; + var modes = this.node.attrs.mode; modes = !!modes ? modes.split(",") : ["tree"]; var views = []; @@ -1959,7 +1966,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ views.push(view); }); this.views = views; - + this.viewmanager = new openerp.web.ViewManager(this, this.dataset, views); this.viewmanager.registry = openerp.web.views.clone({ list: 'openerp.web.form.One2ManyListView', @@ -1968,6 +1975,9 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ var once = $.Deferred().then(function() { self.init_form_last_update.resolve(); }); + var def = $.Deferred().then(function() { + self.is_started.resolve(); + }); this.viewmanager.on_controller_inited.add_last(function(view_type, controller) { if (view_type == "list") { controller.o2m = self; @@ -1982,7 +1992,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ } else if (view_type == "graph") { self.reload_current_view() } - self.is_started.resolve(); + def.resolve(); }); this.viewmanager.on_mode_switch.add_first(function() { self.save_form_view(); @@ -1992,6 +2002,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ self.viewmanager.appendTo(self.$element); }, 0); }); + return def; }, reload_current_view: function() { var self = this; @@ -2131,7 +2142,18 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ }, update_dom: function() { this._super.apply(this, arguments); - this.$element.toggleClass('disabled', this.readonly); + var self = this; + if (this.previous_readonly !== this.readonly) { + this.previous_readonly = this.readonly; + if (this.viewmanager) { + $.when(this.is_started).then(function() { + self.viewmanager.stop(); + $.when(self.load_views()).then(function() { + self.reload_current_view(); + }); + }); + } + } } }); From 4ba8ac9d3e8338fe9d2e94308ebfc2cfb30f7469 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 14:57:42 +0200 Subject: [PATCH 110/163] [IMP] node shapes handling bzr revid: xmo@openerp.com-20111026125742-7xpcn0jo75xrfuy1 --- addons/web_diagram/controllers/main.py | 1 - addons/web_diagram/static/src/js/diagram.js | 11 +++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/addons/web_diagram/controllers/main.py b/addons/web_diagram/controllers/main.py index 8556a0381f6..55047804725 100644 --- a/addons/web_diagram/controllers/main.py +++ b/addons/web_diagram/controllers/main.py @@ -93,7 +93,6 @@ class DiagramView(View): n.update( id=act['id'], color='white', - shape='ellipse', options={} ) for color, expr in bgcolors.items(): diff --git a/addons/web_diagram/static/src/js/diagram.js b/addons/web_diagram/static/src/js/diagram.js index 24da19a952f..8fce48462a5 100644 --- a/addons/web_diagram/static/src/js/diagram.js +++ b/addons/web_diagram/static/src/js/diagram.js @@ -121,9 +121,8 @@ openerp.web.DiagramView = openerp.web.View.extend({ //Custom logic var self = this; var renderer = function(r, n) { - var shape = n.node.shape; - if(shape == 'rectangle') - shape = 'rect'; + var shape = (n.node.shape === 'rectangle') ? 'rect' : 'ellipse'; + var node = r[shape](n.node.x, n.node.y).attr({ "fill": n.node.color }).dblclick(function() { @@ -139,11 +138,11 @@ openerp.web.DiagramView = openerp.web.View.extend({ .dblclick(propagate_to_previous_sibling) ).attr("cursor", "pointer"); - if(shape == "ellipse") - node.attr({rx: "40", ry: "20"}); - else if(shape == 'rect') { + if (shape === 'rect') { node.attr({width: "60", height: "44"}); node.next.attr({"text-anchor": "middle", x: n.node.x + 20, y: n.node.y + 20}); + } else { + node.attr({rx: "40", ry: "20"}); } return nodes; From d143acddf837cd505eb41f66d75445253473048f Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 15:00:03 +0200 Subject: [PATCH 111/163] [IMP] simplify cleanup of the canvas drawing area bzr revid: xmo@openerp.com-20111026130003-chs489cimhxom35c --- addons/web_diagram/static/src/js/diagram.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/addons/web_diagram/static/src/js/diagram.js b/addons/web_diagram/static/src/js/diagram.js index 8fce48462a5..70e7ad55d1f 100644 --- a/addons/web_diagram/static/src/js/diagram.js +++ b/addons/web_diagram/static/src/js/diagram.js @@ -160,10 +160,7 @@ openerp.web.DiagramView = openerp.web.View.extend({ diagram.addEdge(connector['source'], connector['destination'], {directed : true, label: connector['signal']}); }); - - if ($('div#dia-canvas').children().length > 0) { - $('div#dia-canvas').children().remove(); - } + self.$element.find('.diagram').empty(); var layouter = new Graph.Layout.Ordered(diagram); var render_diagram = new Graph.Renderer.Raphael('dia-canvas', diagram, $('div#dia-canvas').width(), $('div#dia-canvas').height()); From 7ba5602f719f7d22359bed14534241ea49bc434f Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 15:15:56 +0200 Subject: [PATCH 112/163] [FIX] turns out raphael's event system looks like jquery's but behaves *nothing like it*. Correctly fix deduplication of event handlers: add events on the nodes collection directly bzr revid: xmo@openerp.com-20111026131556-v7a0bbkhk633r6i9 --- addons/web_diagram/static/src/js/diagram.js | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/addons/web_diagram/static/src/js/diagram.js b/addons/web_diagram/static/src/js/diagram.js index 70e7ad55d1f..4867d778b13 100644 --- a/addons/web_diagram/static/src/js/diagram.js +++ b/addons/web_diagram/static/src/js/diagram.js @@ -125,18 +125,13 @@ openerp.web.DiagramView = openerp.web.View.extend({ var node = r[shape](n.node.x, n.node.y).attr({ "fill": n.node.color - }).dblclick(function() { - self.add_edit_node(n.node.id, self.node); }); - var propagate_to_previous_sibling = function (e) { - $(this).prev().trigger(e.type); - }; - var nodes = r.set() - .push(node, r.text(n.node.x, n.node.y, (n.label || n.id)) - .click(propagate_to_previous_sibling) - .dblclick(propagate_to_previous_sibling) - ).attr("cursor", "pointer"); + var nodes = r.set(node, r.text(n.node.x, n.node.y, (n.label || n.id))) + .attr("cursor", "pointer") + .dblclick(function() { + self.add_edit_node(n.node.id, self.node); + }); if (shape === 'rect') { node.attr({width: "60", height: "44"}); From 68d27bd87036545fb66aa39cf5423029e36c1b4f Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Wed, 26 Oct 2011 15:35:14 +0200 Subject: [PATCH 113/163] [IMP] Improved kanban view bzr revid: fme@openerp.com-20111026133514-fpqwsanb1ujv81tn --- addons/web_kanban/static/src/css/kanban.css | 15 ++++++++------- addons/web_kanban/static/src/js/kanban.js | 11 +++++++++-- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/addons/web_kanban/static/src/css/kanban.css b/addons/web_kanban/static/src/css/kanban.css index 35ab36a0188..712ebf1fa1c 100644 --- a/addons/web_kanban/static/src/css/kanban.css +++ b/addons/web_kanban/static/src/css/kanban.css @@ -25,7 +25,7 @@ .openerp .oe_kanban_view .oe_column_heading { color: #000000; - font-size: 1.5em; + font-size: 130%; font-weight: bold; } .openerp .oe_kanban_view .fold-columns-icon { @@ -51,17 +51,17 @@ border-bottom: 1px solid #CCC; } .openerp .oe_kanban_title1 { - font-size: 130%; - font-weight: bold; - padding: 0 4px 0 4px; -} -.openerp .oe_kanban_title2 { font-size: 120%; font-weight: bold; padding: 0 4px 0 4px; } -.openerp .oe_kanban_title3 { +.openerp .oe_kanban_title2 { font-size: 110%; + font-weight: bold; + padding: 0 4px 0 4px; +} +.openerp .oe_kanban_title3 { + font-size: 100%; font-weight: normal; padding: 0 4px 0 4px; } @@ -88,6 +88,7 @@ white-space: nowrap; padding-top: 2px; position: relative; + clear: both; } .openerp .oe_kanban_buttons_set a { padding: 2px; diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index b0ec9f26b82..adc259894c5 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -56,6 +56,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ kanban_color: _.bind(this.kanban_color, this), kanban_gravatar: _.bind(this.kanban_gravatar, this), kanban_image: _.bind(this.kanban_image, this), + kanban_text_ellipsis: _.bind(this.kanban_text_ellipsis, this), '_' : _ } }, @@ -85,6 +86,13 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ id = id || ''; return '/web/binary/image?session_id=' + this.session.session_id + '&model=' + model + '&field=' + field + '&id=' + id; }, + kanban_text_ellipsis: function(s, size) { + size = size || 160; + if (!s) { + return ''; + } + return s.substr(0, size) + '...'; + }, transform_qweb_template: function(node) { var qweb_prefix = QWeb.prefix; switch (node.tag) { @@ -104,7 +112,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ }); if (node.attrs['data-states']) { var states = _.map(node.attrs['data-states'].split(','), function(state) { - return "record.state.value == '" + _.trim(state) + "'"; + return "record.state.raw_value == '" + _.trim(state) + "'"; }); node.attrs['t-if'] = states.join(' or '); } @@ -161,7 +169,6 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ stop: self.on_receive_record, scroll: false }); - this.$element.find(".oe_column").disableSelection() this.$element.find('button.oe_kanban_button_new').click(this.do_add_record); this.$element.find(".fold-columns-icon").click(function(event) { self.do_fold_unfold_columns(event, this.id); From 5d754afde4ac383c31f072134eac145673d8b910 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 15:49:29 +0200 Subject: [PATCH 114/163] [ADD] Creation of new edges via clicketyclick bzr revid: xmo@openerp.com-20111026134929-ze1jl0efq7o07lr5 --- addons/web_diagram/static/src/js/diagram.js | 38 +++++++++++++++++-- .../static/src/xml/base_diagram.xml | 1 - 2 files changed, 35 insertions(+), 4 deletions(-) diff --git a/addons/web_diagram/static/src/js/diagram.js b/addons/web_diagram/static/src/js/diagram.js index 4867d778b13..77c5a8512bb 100644 --- a/addons/web_diagram/static/src/js/diagram.js +++ b/addons/web_diagram/static/src/js/diagram.js @@ -54,7 +54,6 @@ openerp.web.DiagramView = openerp.web.View.extend({ // New Node,Edge this.$element.find('#new_node.oe_diagram_button_new').click(function(){self.add_edit_node(null, self.node);}); - this.$element.find('#new_edge.oe_diagram_button_new').click(function(){self.add_edit_node(null, self.connector);}); if(this.id) { self.get_diagram_info(); @@ -109,7 +108,23 @@ openerp.web.DiagramView = openerp.web.View.extend({ this.get_diagram_info(); } }, - + select_node: function (node, element) { + if (!this.selected_node) { + this.selected_node = node; + element.attr('stroke', 'red'); + return; + } + // Re-click selected node, deselect it + if (node.id === this.selected_node.id) { + this.selected_node = null; + element.attr('stroke', 'black'); + return; + } + this.add_edit_node(null, this.connector, { + act_from: this.selected_node.id, + act_to: node.id + }); + }, draw_diagram: function(result) { var diagram = new Graph(); @@ -131,6 +146,13 @@ openerp.web.DiagramView = openerp.web.View.extend({ .attr("cursor", "pointer") .dblclick(function() { self.add_edit_node(n.node.id, self.node); + }) + .mousedown(function () { node.moved = false; }) + .mousemove(function () { node.moved = true; }) + .click(function () { + // Ignore click from move event + if (node.moved) { return; } + self.select_node(n.node, node); }); if (shape === 'rect') { @@ -169,7 +191,8 @@ openerp.web.DiagramView = openerp.web.View.extend({ }); }, - add_edit_node: function(id, model) { + add_edit_node: function(id, model, defaults) { + defaults = defaults || {}; var self = this; if(!model) @@ -238,6 +261,15 @@ openerp.web.DiagramView = openerp.web.View.extend({ }); }); } + if (!_.isEmpty(defaults)) { + form_controller.on_record_loaded.add_last(function () { + _(form_fields).each(function (field) { + if (!defaults[field]) { return; } + form_controller.fields[field].set_value(defaults[field]); + form_controller.fields[field].dirty = true; + }); + }); + } }, on_pager_action: function(action) { diff --git a/addons/web_diagram/static/src/xml/base_diagram.xml b/addons/web_diagram/static/src/xml/base_diagram.xml index de34aefe739..20613c7b079 100644 --- a/addons/web_diagram/static/src/xml/base_diagram.xml +++ b/addons/web_diagram/static/src/xml/base_diagram.xml @@ -3,7 +3,6 @@
      -
      From 5ef63c30a68abd6df8a3e691bb493fad199ff907 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Wed, 26 Oct 2011 15:51:02 +0200 Subject: [PATCH 115/163] [IMP] project.task kanban view (with al !) bzr revid: fme@openerp.com-20111026135102-ozm4g0l8l3snoki1 --- addons/project/project.py | 2 +- addons/project/project_view.xml | 43 ++++++++++++++------------------- 2 files changed, 19 insertions(+), 26 deletions(-) diff --git a/addons/project/project.py b/addons/project/project.py index 3431aaec229..a5cd8928dfc 100644 --- a/addons/project/project.py +++ b/addons/project/project.py @@ -485,7 +485,7 @@ class task(osv.osv): 'company_id': lambda self, cr, uid, c: self.pool.get('res.company')._company_default_get(cr, uid, 'project.task', context=c) } - _order = "sequence,priority, date_start, name, id" + _order = "priority, sequence, date_start, name, id" def set_priority(self, cr, uid, ids, priority): """Set task priority diff --git a/addons/project/project_view.xml b/addons/project/project_view.xml index 02a8212838c..18ff634f796 100644 --- a/addons/project/project_view.xml +++ b/addons/project/project_view.xml @@ -323,14 +323,14 @@ - + + http://pad.openerp.com/ - -
      +
      - + +
      - , + ,
      - , + ,
      - , + ,
      @@ -340,38 +340,31 @@
      - +
      -
      - +
      + +
      + - + +
      -
      - -
      -
      - -
      -
      - +
      +
      +
      @@ -467,8 +460,8 @@ - - + + tree,form,calendar,gantt,graph,kanban - {"search_default_user_id":uid, "search_default_current": 1} + {"search_default_user_id":uid, "search_default_draft": 1, "search_default_open":1 } A task represents a work that has to be done. Each user works in his own list of tasks where he can record his task work in hours. He can work and close the task itself or delegate it to another user. If you delegate a task to another user, you get a new task in pending state, which will be reopened when you have to review the work achieved. If you install the project_timesheet module, task work can be invoiced based on the project configuration. With the project_mrp module, sales orders can create tasks automatically when they are confirmed. From edbd53da7b1202aa1d3503f3189d2019a1d6e600 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 26 Oct 2011 15:52:20 +0200 Subject: [PATCH 116/163] [FIX] diagram should not remember selected nodes across workflows bzr revid: xmo@openerp.com-20111026135220-j4dnns7q1ugnz70k --- addons/web_diagram/static/src/js/diagram.js | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/web_diagram/static/src/js/diagram.js b/addons/web_diagram/static/src/js/diagram.js index 77c5a8512bb..ffa27734769 100644 --- a/addons/web_diagram/static/src/js/diagram.js +++ b/addons/web_diagram/static/src/js/diagram.js @@ -126,6 +126,7 @@ openerp.web.DiagramView = openerp.web.View.extend({ }); }, draw_diagram: function(result) { + this.selected_node = null; var diagram = new Graph(); this.active_model = result['id_model']; From 9988d503b193afb44855149bf3b8c7a3e76893ba Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 16:11:48 +0200 Subject: [PATCH 117/163] [imp] implemented readonly in o2m in list view only bzr revid: nicolas.vanhoren@openerp.com-20111026141148-kl37triimsivvh9n --- addons/web/static/src/js/view_form.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 0c8ee47ff66..fd40f038e78 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1960,6 +1960,10 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ } if(view.view_type === "list") { view.options.selectable = self.multi_selection; + if (self.readonly) { + view.options.addable = null; + view.options.deletable = null; + } } else if (view.view_type === "form") { view.options.not_interactible_on_create = true; } @@ -1981,6 +1985,8 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ this.viewmanager.on_controller_inited.add_last(function(view_type, controller) { if (view_type == "list") { controller.o2m = self; + if (self.readonly) + controller.set_editable(false); } else if (view_type == "form") { controller.on_record_loaded.add_last(function() { once.resolve(); @@ -2197,6 +2203,8 @@ openerp.web.form.One2ManyListView = openerp.web.ListView.extend({ }, do_activate_record: function(index, id) { var self = this; + if (self.o2m.readonly) + return; var pop = new openerp.web.form.FormOpenPopup(self.o2m.view); pop.show_element(self.o2m.field.relation, id, self.o2m.build_context(),{ auto_write: false, From 08ef807c3b2e500544357c9d3daf1363f5df83fe Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 16:42:18 +0200 Subject: [PATCH 118/163] [imp] implemented readonly in o2m in form view too bzr revid: nicolas.vanhoren@openerp.com-20111026144218-vn44rlkzo7vo0umq --- addons/web/static/src/js/view_form.js | 33 +++++++++++++++------------ 1 file changed, 18 insertions(+), 15 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index fd40f038e78..2bc4cd50766 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -105,17 +105,7 @@ openerp.web.FormView = openerp.web.View.extend( /** @lends openerp.web.FormView# this.$form_header.find('button.oe_form_button_cancel').click(this.do_cancel); this.$form_header.find('button.oe_form_button_new').click(this.on_button_new); this.$form_header.find('button.oe_form_button_duplicate').click(this.on_button_duplicate); - this.$form_header.find('button.oe_form_button_toggle').click(function () { - self.translatable_fields = []; - self.widgets = {}; - self.fields = {}; - self.$form_header.find('button').unbind('click'); - self.registry = self.registry === openerp.web.form.widgets - ? openerp.web.form.readonly - : openerp.web.form.widgets; - self.on_loaded(self.fields_view); - self.reload(); - }); + this.$form_header.find('button.oe_form_button_toggle').click(this.on_toggle_readonly); if (this.options.sidebar && this.options.sidebar_id) { this.sidebar = new openerp.web.Sidebar(this, this.options.sidebar_id); @@ -127,6 +117,18 @@ openerp.web.FormView = openerp.web.View.extend( /** @lends openerp.web.FormView# } this.has_been_loaded.resolve(); }, + on_toggle_readonly: function() { + var self = this; + self.translatable_fields = []; + self.widgets = {}; + self.fields = {}; + self.$form_header.find('button').unbind('click'); + self.registry = self.registry === openerp.web.form.widgets + ? openerp.web.form.readonly + : openerp.web.form.widgets; + self.on_loaded(self.fields_view); + self.reload(); + }, do_show: function () { var promise; if (this.dataset.index === null) { @@ -1974,7 +1976,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ this.viewmanager = new openerp.web.ViewManager(this, this.dataset, views); this.viewmanager.registry = openerp.web.views.clone({ list: 'openerp.web.form.One2ManyListView', - form: 'openerp.web.form.One2ManyFormView' + form: 'openerp.web.FormView' }); var once = $.Deferred().then(function() { self.init_form_last_update.resolve(); @@ -1988,6 +1990,10 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ if (self.readonly) controller.set_editable(false); } else if (view_type == "form") { + if (self.readonly) { + controller.on_toggle_readonly(); + $(controller.$element.find(".oe_form_buttons")[0]).children().remove(); + } controller.on_record_loaded.add_last(function() { once.resolve(); }); @@ -2170,9 +2176,6 @@ openerp.web.form.One2ManyDataSet = openerp.web.BufferedDataSet.extend({ } }); -openerp.web.form.One2ManyFormView = openerp.web.FormView.extend({ -}); - openerp.web.form.One2ManyListView = openerp.web.ListView.extend({ do_add_record: function () { if (this.options.editable) { From 5bc7011b52f824878891a98c90f4d87ad5941a15 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 17:23:05 +0200 Subject: [PATCH 119/163] [fix] race condition in m2m bzr revid: nicolas.vanhoren@openerp.com-20111026152305-t7rg7mn37h91swra --- addons/web/static/src/js/view_form.js | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 2bc4cd50766..29d7e70b6ed 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2232,7 +2232,8 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ init: function(view, node) { this._super(view, node); this.list_id = _.uniqueId("many2many"); - this.is_started = $.Deferred(); + this.is_loaded = $.Deferred(); + this.initial_is_loaded = this.is_loaded; this.is_setted = $.Deferred(); }, start: function() { @@ -2258,9 +2259,7 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this._super(value); this.dataset.set_ids(value); var self = this; - $.when(this.is_started).then(function() { - self.list_view.reload_content(); - }); + self.reload_content(); this.is_setted.resolve(); }, get_value: function() { @@ -2279,7 +2278,7 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ this.list_view.m2m_field = this; var loaded = $.Deferred(); this.list_view.on_loaded.add_last(function() { - self.is_started.resolve(); + self.initial_is_loaded.resolve(); loaded.resolve(); }); setTimeout(function () { @@ -2287,16 +2286,22 @@ openerp.web.form.FieldMany2Many = openerp.web.form.Field.extend({ }, 0); return loaded; }, + reload_content: function() { + var self = this; + this.is_loaded = this.is_loaded.pipe(function() { + return self.list_view.reload_content(); + }); + }, update_dom: function() { this._super.apply(this, arguments); var self = this; if (this.previous_readonly !== this.readonly) { this.previous_readonly = this.readonly; if (this.list_view) { - $.when(this.is_started).then(function() { + this.is_loaded = this.is_loaded.pipe(function() { self.list_view.stop(); - $.when(self.load_view()).then(function() { - self.list_view.reload_content(); + return $.when(self.load_view()).then(function() { + self.reload_content(); }); }); } From 5329b9273ade63e8dd7da67108361dfc8b21c731 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 17:31:09 +0200 Subject: [PATCH 120/163] [fix] potential race condition in o2m bzr revid: nicolas.vanhoren@openerp.com-20111026153109-8pcjlo7c5ud6bkko --- addons/web/static/src/js/view_form.js | 42 ++++++++++++++------------- 1 file changed, 22 insertions(+), 20 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 29d7e70b6ed..78bacfd37d0 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -1923,7 +1923,8 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ multi_selection: false, init: function(view, node) { this._super(view, node); - this.is_started = $.Deferred(); + this.is_loaded = $.Deferred(); + this.initial_is_loaded = this.is_loaded; this.is_setted = $.Deferred(); this.form_last_update = $.Deferred(); this.init_form_last_update = this.form_last_update; @@ -1982,7 +1983,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ self.init_form_last_update.resolve(); }); var def = $.Deferred().then(function() { - self.is_started.resolve(); + self.initial_is_loaded.resolve(); }); this.viewmanager.on_controller_inited.add_last(function(view_type, controller) { if (view_type == "list") { @@ -2018,20 +2019,23 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ }, reload_current_view: function() { var self = this; - var view = self.viewmanager.views[self.viewmanager.active_view].controller; - if(self.viewmanager.active_view === "list") { - view.reload_content(); - } else if (self.viewmanager.active_view === "form") { - if (this.dataset.index === null && this.dataset.ids.length >= 1) { - this.dataset.index = 0; + self.is_loaded = self.is_loaded.pipe(function() { + var view = self.viewmanager.views[self.viewmanager.active_view].controller; + if(self.viewmanager.active_view === "list") { + return view.reload_content(); + } else if (self.viewmanager.active_view === "form") { + if (self.dataset.index === null && self.dataset.ids.length >= 1) { + self.dataset.index = 0; + } + var act = function() { + return view.do_show(); + } + self.form_last_update = self.form_last_update.pipe(act, act); + return self.form_last_update; + } else if (self.viewmanager.active_view === "graph") { + return view.do_search(self.build_domain(), self.dataset.get_context(), []); } - var act = function() { - return view.do_show(); - } - this.form_last_update = this.form_last_update.pipe(act, act);; - } else if (self.viewmanager.active_view === "graph") { - view.do_search(this.build_domain(), this.dataset.get_context(), []); - } + }); }, set_value: function(value) { value = value || []; @@ -2088,9 +2092,7 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ if (this.dataset.index === null && this.dataset.ids.length > 0) { this.dataset.index = 0; } - $.when(this.is_started).then(function() { - self.reload_current_view(); - }); + self.reload_current_view(); this.is_setted.resolve(); }, get_value: function() { @@ -2158,9 +2160,9 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ if (this.previous_readonly !== this.readonly) { this.previous_readonly = this.readonly; if (this.viewmanager) { - $.when(this.is_started).then(function() { + this.is_loaded = this.is_loaded.pipe(function() { self.viewmanager.stop(); - $.when(self.load_views()).then(function() { + return $.when(self.load_views()).then(function() { self.reload_current_view(); }); }); From 33c4580c039a5597f817baefb296c20d8e41e2d3 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Wed, 26 Oct 2011 17:39:44 +0200 Subject: [PATCH 121/163] [fix] problem when switching from form view to list view in o2m bzr revid: nicolas.vanhoren@openerp.com-20111026153944-bdk335em06dxxi2p --- addons/web/static/src/js/view_form.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 78bacfd37d0..796f577017f 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2007,8 +2007,11 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({ } def.resolve(); }); - this.viewmanager.on_mode_switch.add_first(function() { - self.save_form_view(); + this.viewmanager.on_mode_switch.add_first(function(n_mode, b, c, d, e) { + $.when(self.save_form_view()).then(function() { + if(n_mode === "list") + setTimeout(function() {self.reload_current_view();}, 0); + }); }); this.is_setted.then(function() { setTimeout(function () { From 0d7b80ac44867a5b9fbc5a8ec449976989ab21fd Mon Sep 17 00:00:00 2001 From: Bogdan Stanciu Date: Wed, 26 Oct 2011 19:38:57 +0200 Subject: [PATCH 122/163] [FIX] some English fixes for 'openerp-web' file, no code changed. bzr revid: bogdanovidiu.stanciu@gmail.com-20111026173857-j4zuouips1ab6a7o --- openerp-web | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openerp-web b/openerp-web index 1493a84abac..a3b3d2fa1d5 100755 --- a/openerp-web +++ b/openerp-web @@ -13,17 +13,17 @@ import werkzeug.contrib.fixers optparser = optparse.OptionParser() optparser.add_option("-s", "--session-path", dest="session_storage", default=os.path.join(tempfile.gettempdir(), "oe-sessions"), - help="directory used for session storage", metavar="DIR") + help="Directory used for session storage", metavar="DIR") optparser.add_option("--server-host", dest="server_host", default='127.0.0.1', help="OpenERP server hostname", metavar="HOST") optparser.add_option("--server-port", dest="server_port", default=8069, help="OpenERP server port", type="int", metavar="NUMBER") optparser.add_option("--db-filter", dest="dbfilter", default='.*', - help="Filter listed database", metavar="REGEXP") + help="Filter listed databases", metavar="REGEXP") optparser.add_option('--addons-path', dest='addons_path', default=[], action='append', - help="Path do addons directory", metavar="PATH") + help="Path to addons directory", metavar="PATH") optparser.add_option('--load', dest='server_wide_modules', default=['web'], action='append', - help="Load a additional module before login (by default only 'web' is loaded)", metavar="MODULE") + help="Load an additional module before login (by default only 'web' is loaded)", metavar="MODULE") server_options = optparse.OptionGroup(optparser, "Server configuration") server_options.add_option("-p", "--port", dest="socket_port", default=8002, From 226ca06039425056725cb9336c58c58603292afa Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Wed, 26 Oct 2011 23:06:51 +0200 Subject: [PATCH 123/163] [IMP] Improved pad module Generate Pad urls server side instead of client side. Use a template for pad urls. bzr revid: fme@openerp.com-20111026210651-fnosw5xhc9ncuqfo --- addons/pad/__init__.py | 1 + addons/pad/ir_attachment.py | 35 ++++++++ addons/pad/res_company.py | 7 +- addons/pad/res_company.xml | 2 +- .../static/src/img/pad-icon.png} | Bin addons/pad/static/src/js/pad.js | 75 +++++------------- 6 files changed, 58 insertions(+), 62 deletions(-) create mode 100644 addons/pad/ir_attachment.py rename addons/{project/static/src/img/kanban-pad-openerp.png => pad/static/src/img/pad-icon.png} (100%) diff --git a/addons/pad/__init__.py b/addons/pad/__init__.py index df35bc32106..445f0f9dd9f 100644 --- a/addons/pad/__init__.py +++ b/addons/pad/__init__.py @@ -1,2 +1,3 @@ # -*- coding: utf-8 -*- import res_company +import ir_attachment diff --git a/addons/pad/ir_attachment.py b/addons/pad/ir_attachment.py new file mode 100644 index 00000000000..efcf1817289 --- /dev/null +++ b/addons/pad/ir_attachment.py @@ -0,0 +1,35 @@ +# -*- coding: utf-8 -*- +from osv import fields, osv +import random +import string + +class ir_attachment(osv.osv): + _inherit = 'ir.attachment' + + def pad_generate_url(self, cr, uid, model, id): + pad_url_template = self.pool.get('res.users').browse(cr,uid,[uid])[0].company_id.pad_url_template + s = string.ascii_uppercase + string.digits + salt = ''.join([s[random.randint(0, len(s) - 1)] for i in range(8)]) + template_vars = { + 'db' : cr.dbname, + 'model' : model, + 'id' : id, + 'salt' : salt, + 'name' : '', + } + return pad_url_template % template_vars + + def pad_get(self, cr, uid, model, id): + attachment = self.search(cr, uid, [('res_model', '=', model), ('res_id', '=', id), ('type', '=', 'url'), ('name', '=', 'Pad')]) + if attachment: + return self.read(cr, uid, attachment)[0]['url'] + else: + url = self.pad_generate_url(cr, uid, model, id) + self.create(cr, uid, { + 'res_model' : model, + 'res_id' : id, + 'type' : 'url', + 'name' : 'Pad', + 'url' : url, + }) + return url diff --git a/addons/pad/res_company.py b/addons/pad/res_company.py index 29fd759c8a6..fe822e213c2 100644 --- a/addons/pad/res_company.py +++ b/addons/pad/res_company.py @@ -4,11 +4,10 @@ from osv import fields, osv class company_pad(osv.osv): _inherit = 'res.company' _columns = { - 'pad_index': fields.char('Pad root URL', size=64, required=True, - help="The root URL of the company's pad " - "instance"), + 'pad_url_template': fields.char('Pad URL Template', size=128, required=True, + help="Template used to generate pad URL."), } _defaults = { - 'pad_index': 'http://ietherpad.com/' + 'pad_url_template': 'http://ietherpad.com/%(db)s-%(model)s-%(id)d-%(salt)s-%(name)s' } diff --git a/addons/pad/res_company.xml b/addons/pad/res_company.xml index 754776715d7..20b6f52d853 100644 --- a/addons/pad/res_company.xml +++ b/addons/pad/res_company.xml @@ -8,7 +8,7 @@ - + diff --git a/addons/project/static/src/img/kanban-pad-openerp.png b/addons/pad/static/src/img/pad-icon.png similarity index 100% rename from addons/project/static/src/img/kanban-pad-openerp.png rename to addons/pad/static/src/img/pad-icon.png diff --git a/addons/pad/static/src/js/pad.js b/addons/pad/static/src/js/pad.js index c6b977b0f78..635c86a48dd 100644 --- a/addons/pad/static/src/js/pad.js +++ b/addons/pad/static/src/js/pad.js @@ -1,71 +1,32 @@ - openerp.pad = function(instance) { var QWeb = instance.web.qweb; QWeb.add_template('/pad/static/src/xml/pad.xml'); instance.web.form.SidebarAttachments = instance.web.form.SidebarAttachments.extend({ - - pad_prefix: undefined, - + on_attachments_loaded: function(attachments) { + this._super(attachments); + var self = this; + var $padbtn = self.$element.find('button.pad'); + var is_pad = function(a) { + return a.type == 'url' && _(a.url).startsWith(self.pad_prefix); + }; + if (_.any(attachments, is_pad)) { + $padbtn.hide(); + } else { + $padbtn.show().click(self.on_add_pad); + } + }, on_add_pad: function() { var self = this; var $padbtn = this.$element.find('button.pad'); $padbtn.attr('disabled', 'true').find('img, span').toggle(); - - this.do_load_pad_prefix(function() { - var attachment = new instance.web.DataSet(self, 'ir.attachment', self.view.dataset.get_context()); - var r = (((1+Math.random())*0x10000)|0).toString(16).substring(1); - attachment.create({ - res_model: self.view.dataset.model, - res_id: self.view.datarecord.id, - type: 'url', - name: 'Pad', - url: self.pad_prefix + r, - }, function() { - self.do_update(); - }); + this.view.dataset.call_button('pad_get', [[this.view.datarecord.id], this.view.dataset.get_context()], function(r) { + $padbtn.hide(); + self.do_update(); + self.do_action(r.result); }); - - }, - - do_load_pad_prefix: function(continuation) { - var self = this; - if (this.pad_prefix === undefined) { - var user = new instance.web.DataSet(this, 'res.users', this.view.dataset.get_context()); - var company = new instance.web.DataSet(this, 'res.company', this.view.dataset.get_context()); - user.read_ids([this.session.uid], ['company_id'], function(result) { - company.read_ids([result[0].company_id[0]], ['pad_index'], function(result) { - var pad_index = _(result[0].pad_index).strip().replace(/\/$/, "");; - if (pad_index) { - self.pad_prefix = _('%s/%s-%s-%d-').sprintf(pad_index, self.session.db, self.view.dataset.model, self.view.datarecord.id); - } else { - self.pad_prefix = null; - } - continuation(); - }); - }); - } else { - continuation(); - } - }, - - on_attachments_loaded: function(attachments) { - this._super(attachments); - var self = this; - this.do_load_pad_prefix(function() { - var $padbtn = self.$element.find('button.pad'); - var is_pad = function(a) { - return a.type == 'url' && _(a.url).startsWith(self.pad_prefix); - }; - if (!self.pad_prefix || _.any(attachments, is_pad)) { - $padbtn.hide(); - } else { - $padbtn.show().click(self.on_add_pad); - } - }); - - }, + } }); }; From 44fc0f6855eab762350c66adfb3d1d2bc0384d58 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Wed, 26 Oct 2011 23:11:23 +0200 Subject: [PATCH 124/163] [ADD] Add pad_project module. (Adds a PAD button in all project kanban views) bzr revid: fme@openerp.com-20111026211123-m4tjc4xl35m2pfnu --- addons/pad_project/__init__.py | 24 +++++++++++++ addons/pad_project/__openerp__.py | 40 ++++++++++++++++++++++ addons/pad_project/models/__init__.py | 24 +++++++++++++ addons/pad_project/models/project_task.py | 17 +++++++++ addons/pad_project/models/project_task.xml | 17 +++++++++ 5 files changed, 122 insertions(+) create mode 100644 addons/pad_project/__init__.py create mode 100644 addons/pad_project/__openerp__.py create mode 100644 addons/pad_project/models/__init__.py create mode 100644 addons/pad_project/models/project_task.py create mode 100644 addons/pad_project/models/project_task.xml diff --git a/addons/pad_project/__init__.py b/addons/pad_project/__init__.py new file mode 100644 index 00000000000..d6bf9f9551c --- /dev/null +++ b/addons/pad_project/__init__.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# Copyright (C) 2004-2010 Tiny SPRL (). +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +import models + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/pad_project/__openerp__.py b/addons/pad_project/__openerp__.py new file mode 100644 index 00000000000..a9ec6282ab7 --- /dev/null +++ b/addons/pad_project/__openerp__.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# Copyright (C) 2004-2010 Tiny SPRL (). +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +{ + 'name': 'Project PAD', + 'version': '1.0', + 'category': 'Hidden/Link', + 'complexity': "easy", + 'description': """ +This module adds a PAD in all project kanban views +================================================== + """, + 'author': 'OpenERP SA', + 'website': 'http://www.openerp.com', + 'depends': ['project', 'pad'], + 'init_xml': [], + 'update_xml': ['models/project_task.xml'], + 'demo_xml': [], + 'installable': True, + 'active': False, +} +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/pad_project/models/__init__.py b/addons/pad_project/models/__init__.py new file mode 100644 index 00000000000..098de31a5a4 --- /dev/null +++ b/addons/pad_project/models/__init__.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# Copyright (C) 2004-2010 Tiny SPRL (). +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +import project_task + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/pad_project/models/project_task.py b/addons/pad_project/models/project_task.py new file mode 100644 index 00000000000..c215aed1325 --- /dev/null +++ b/addons/pad_project/models/project_task.py @@ -0,0 +1,17 @@ +# -*- coding: utf-8 -*- +from tools.translate import _ +from osv import fields, osv + +class task(osv.osv): + _inherit = "project.task" + + def pad_get(self, cr, uid, ids, context=None): + """Get pad action + """ + url = self.pool.get("ir.attachment").pad_get(cr, uid, self._name, ids[0]) + return { + 'type': 'ir.actions.act_url', + 'url': url + } + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/pad_project/models/project_task.xml b/addons/pad_project/models/project_task.xml new file mode 100644 index 00000000000..de944b603b5 --- /dev/null +++ b/addons/pad_project/models/project_task.xml @@ -0,0 +1,17 @@ + + + + project.task.kanban.pad + project.task + kanban + + + + + + + + + + + From d75616ea8e9433a55bef7f2e0c46d6219f4aa1df Mon Sep 17 00:00:00 2001 From: Maxime Chambreuil Date: Wed, 26 Oct 2011 18:24:15 -0400 Subject: [PATCH 125/163] [IMP] Simplify chart bzr revid: maxime.chambreuil@savoirfairelinux.com-20111026222415-enra31qmf5w1rw6d --- addons/l10n_ca/account_chart_fr.xml | 1704 ++++-------------- addons/l10n_ca/account_chart_template_fr.xml | 10 +- addons/l10n_ca/account_tax_fr.xml | 52 +- addons/l10n_ca/fiscal_templates_fr.xml | 77 +- 4 files changed, 460 insertions(+), 1383 deletions(-) diff --git a/addons/l10n_ca/account_chart_fr.xml b/addons/l10n_ca/account_chart_fr.xml index 846c9ba47d5..1e606a0b803 100644 --- a/addons/l10n_ca/account_chart_fr.xml +++ b/addons/l10n_ca/account_chart_fr.xml @@ -12,1577 +12,653 @@ - - 100000 + + 1 view ACTIF - - 110000 - + + 11 + view - ACTIFS FINANCIERS + ACTIFS COURANTS - - 111000 - + + 111 + view - ENCAISSE, DÉPÔTS ET RÉSERVES INTERNATIONALES OFFICIELLES + ENCAISSE - - 111100 - - view - - ENCAISSE EN MONNAIE CANADIENNE - - - - 111160 - + + 1111 + liquidity Compte chèque - - 111170 - + + 1112 + liquidity Petite caisse - - 111200 - + + 112 + view - DÉPÔTS À VUE/DÉPÔTS À PRÉAVIS DANS LES INSTITUTIONS DE DÉPÔTS + TRÉSORERIE OU ÉQUIVALENTS DE TRÉSORERIE - - 111300 - + + 113 + view - DÉPÔTS À TERME - MOINS DE 90 JOURS + CERTIFICATS DE DÉPÔTS - - 111400 - - view - - AUTRES ÉQUIVALENTS DE TRÉSORERIE - - - - 111500 - - view - - AUTRES COMPTES DE TRÉSORERIE - - - - 112000 - - view - - COMPTES DÉBITEURS - NET - - - - 112100 - - view - - COMPTES DÉBITEURS ET REVENUS COURUS - BRUT - - - - 112110 - - receivable - - Comptes clients - - - - 112200 - - view - - PROVISION POUR CRÉANCES DOUTEUSES - - - - 113000 - - view - - PLACEMENTS DANS DES SOCIÉTÉS AFFILIÉES - - - - 113100 - - view - - PLACEMENTS DANS DES SOCIÉTÉS AFFILIÉES CANADIENNES - - - - 113200 - - view - - PLACEMENTS DANS DES SOCIÉTÉS AFFILIÉES ÉTRANGÈRES - - - - 113300 - - view - - PRÊTS, BILLETS, COMPTES DÉBITEURS, OBLIGATIONS, HYPOTHÈQUES ET AUTRES PLACEMENTS - - - - 114000 - - view - - PLACEMENTS DANS DES ENTREPRISES NON AFFILIÉES - - - - 114100 - - view - - PLACEMENTS EN TITRES D'EMPRUNT CANADIENS - - - - 114200 - - view - - PLACEMENTS EN INSTRUMENTS DE CAPITAUX PROPRES CANADIENS - - - - 114300 - - view - - PLACEMENTS DANS DES SOCIÉTÉS NON AFFILIÉES ÉTRANGÈRES - - - - 115000 - - view - - PRÊTS HYPOTHÉCAIRES AUX SOCIÉTÉS NON AFFILIÉES - - - - 115100 - - view - - PRÊTS HYPOTHÉCAIRES AUX SOCIÉTÉS NON AFFILIÉES GARANTIS PAR DES PROPRIÉTÉS AU CANADA - - - - 115200 - - view - - PRÊTS HYPOTHÉCAIRES AUX SOCIÉTÉS NON AFFILIÉES GARANTIS PAR UNE PROPRIÉTÉ À L'EXTÉRIEUR DU CANADA - - - - 116000 - - view - - PRÊTS NON HYPOTHÉCAIRES AUX SOCIÉTÉS NON AFFILIÉES - - - - 116100 - - view - - PRÊTS NON HYPOTHÉCAIRES CONSENTIS PAR DES ENTREPRISES NON FINANCIÈRES - - - - 116200 - - view - - PROVISION POUR PERTES SUR PRÊTS NON HYPOTHÉCAIRES - - - - 117000 - - view - - ACTIFS DÉRIVÉS - - - - 117100 - - view - - ACTIFS DÉRIVÉS - CONTREPARTIES RÉSIDENTES - - - - 117200 - - view - - ACTIFS DÉRIVÉS - CONTREPARTIES NON RÉSIDENTES - - - - 120000 - - view - - ACTIFS CORPORELS - - - - 121000 - + + 114 + view STOCKS - - 121100 - + + 115 + view - STOCKS DE BIENS + COMPTES CLIENTS - - 121200 - - view - - STOCKS DE PIÈCES ET FOURNITURES + + 1151 + + receivable + + Comptes clients - - 121300 - + + 1152 + view - BIENS IMMOBILIERS DÉTENUS OU EN COURS D'AMÉNAGEMENT EN VUE DE LA VENTE + PROVISION POUR CRÉANCES DOUTEUSES - - 122000 - - view - - PROVISION POUR OBSOLESCENCE ET DÉVALUATION - - - - 123000 - - view - - ANIMAUX DE REPRODUCTION - - - - 124000 - - view - - ACTIFS IMMOBILISÉS - - - - 124100 - - view - - IMMOBILISATIONS CORPORELLES - NETS - - - - 124200 - - view - - ACTIFS NON RENOUVELABLES - NETS - - - - 124300 - - view - - REPRISE DE POSSESSION D'IMMOBILISATIONS DESTINÉES À LA VENTE - - - - 130000 - - view - - FRAIS REPORTÉS ET ACTIFS INCORPORELS - - - - 131000 - - view - - FRAIS REPORTÉS ET CHARGES PAYÉES D'AVANCE - - - - 131100 - - view - - FRAIS REPORTÉS - NETS - - - - 131200 - + + 116 + view FRAIS PAYÉS D'AVANCE - - 132000 - + + 117 + view - ACTIFS INCORPORELS - NETS + PLACEMENTS DÉTENUS À DES FINS DE TRANSACTION - - 132100 - + + 118 + view - ACHALANDAGE - NET + IMPÔTS À RECEVOIR - - 132200 - - view - - LOGICIELS + + 1181 + + receivable + + TPS à recevoir - - 132300 - - view - - BASES DE DONNÉES + + 1182 + + receivable + + TVP/TVQ à recevoir - - 132400 - - view - - EXCÉDENT DU PRIX D'ACHAT D'ACTIONS D'UNE FILIALE CONSOLIDÉE + + 1183 + + receivable + + TVH à recevoir - - 132500 - + + 15 + view - BREVETS, MARQUES DE COMMERCE ET DROITS D'AUTEURS - NETS + ACTIFS NON-COURANTS - - 132600 - + + 151 + view - AUTRES ACTIFS INCORPORELS + PLACEMENTS DISPONIBLES À LA VENTE - - 140000 - + + 152 + view - AUTRES ÉLÉMENTS D'ACTIF + IMMOBILISATIONS CORPORELLES - - 141000 - + + 1527 + view - RÉGIMES DE RETRAITE + AMORTISSEMENTS CUMULÉS - - 142000 - + + 153 + view - TOUT AUTRE ÉLÉMENT D'ACTIF + IMMOBILISATIONS INCORPORELLES - - 142100 - + + 1531 + view - AUTRES DÉPÔTS - - - - 142200 - - view - - TOUT AUTRE ACTIF, SAUF AUTRES DÉPÔTS + BREVETS, MARQUES DE COMMERCE ET DROITS D'AUTEURS - - 200000 + + 2 view PASSIF - - 210000 - + + 21 + view - INSTRUMENTS FINANCIERS ET EMPRUNTS + PASSIFS COURANTS - - 211000 - + + 211 + view - PRÊTS HYPOTHÉCAIRES + FOURNISSEURS ET COMPTES RATTACHÉS - - 211100 - - view - - PRÊTS HYPOTHÉCAIRES RÉSIDENTIELS - - - - 211200 - - view - - PRÊTS HYPOTHÉCAIRES NON RÉSIDENTIELS - - - - 212000 - - view - - PRÊTS NON HYPOTHÉCAIRES - - - - 212100 - - view - - PRÊTS NON HYPOTHÉCAIRES ET PRÊTS DE BANQUE - - - - 212200 - - view - - PRÊTS NON HYPOTHÉCAIRES, PRÊTS AUPRÈS D'AUTRES SOCIÉTÉS DE FINANCEMENT CANADIENNES - - - - 212300 - - view - - PRÊTS NON HYPOTHÉCAIRES, PRÊTS AUPRÈS D"AUTRES ENTITÉS - - - - 212400 - - view - - PRÊTS NON HYPOTHÉCAIRES, BILLETS PORTANT PRIVILÈGE À PAYER - - - - 212500 - - view - - OBLIGATIONS - CONTRATS DE LOCATION-ACQUISITION OU CRÉDIT-BAIL - - - - 213000 - - view - - TITRES DE CRÉANCE - - - - 213100 - - view - - TITRES DE CRÉANCE, EFFETS À COURT TERME, EFFETS DE COMMERCE, EFFETS DE SOCIÉTÉ DE FINANCEMENT ET ACCEPTATIONS BANCAIRES - - - - 213200 - - view - - TITRES DE CRÉANCE, OBLIGATIONS, DÉBENTURES ET BILLETS - - - - 214000 - - view - - PASSIFS DÉRIVÉS - - - - 214100 - - view - - PASSIFS DÉRIVÉS AVEC CONTREPARTIES RÉSIDENTES - - - - 214200 - - view - - PASSIFS DÉRIVÉS AVEC CONTREPARTIES NON RÉSIDENTES - - - - 220000 - - view - - CRÉANCES - - - - 221000 - - view - - COMPTES CRÉDITEURS ET CHARGES À PAYER - - - - 221100 - - view - - COMPTES CRÉDITEURS, COMMERCES - - - - 221110 - + + 2111 + payable Comptes fournisseurs - - 221200 - + + 212 + view - AUTRES COMPTES CRÉDITEURS ET CHARGES À PAYER + AUTRES COMPTES CRÉDITEURS - - 222000 - + + 213 + view - CRÉANCES DE SOCIÉTÉS AFFILIÉES + IMPÔTS À PAYER - - 222100 - - view - - SOMMES DUES AUX ACTIONNAIRES, AUX ADMINISTRATEURS ET AUX DIRIGEANTS - - - - 222200 - - view - - SOMMES DUES À LA SOCIÉTÉ MÈRE, AUX FILIALES, AUX SOCIÉTÉS LIÉES, AUX COENTREPRISES ET AUX SOCIÉTÉS DE PERSONNES - - - - 240000 - - view - - PASSIFS D'IMPÔTS FUTURS - - - - 241000 - - view - - TAXES À PAYER - - - - 241100 - + + 2131 + payable TPS à payer - - 241200 - + + 2132 + payable TVP/TVQ à payer - - 241300 - + + 2133 + payable TVH à payer - - 242000 - + + 214 + view - TAXES À RECEVOIR + DETTES FINANCIÈRES COURANTES - - 242100 - - receivable - - TPS à recevoir - - - - 242200 - - receivable - - TVP/TVQ à recevoir - - - - 242300 - - receivable - - TVH à recevoir - - - - 245000 - - payable - - Indemnités de vacances à payer - - - - 246000 - - payable - - CSST à payer - - - - 247000 - + + 215 + view - RETENUES SUR SALAIRE + PASSIFS LIÉS AUX ACTIFS DÉTENUS EN VUE DE LEUR CESSION - - 247100 - - payable - - Assurance-emploi à payer - - - - 247200 - - payable - - RRQ à payer - - - - 247300 - - payable - - Impôt sur le revenu à payer - - - - 250000 - + + 25 + view - INTÉRÊTS MINORITAIRES DANS LES FILIALES CONSOLIDÉES + PASSIFS NON-COURANTS - - 260000 - + + 251 + view - RÉGIMES DE RETRAITE ET RÉGIME DE PARTICIPATION DIFFÉRÉE AUX BÉNÉFICES + DETTES FINANCIÈRES NON-COURANTES - - 270000 - + + 252 + view - PROVISION POUR OBLIGATIONS FUTURES + PROVISIONS POUR RETRAITES ET AUTRES AVANTAGES POSTÉRIEURS À L'EMPLOI - - 280000 - + + 253 + view - DÉPÔTS DE CLIENTS, REVENUS REPORTÉS + IMPÔTS DIFFÉRÉS - - 290000 - + + 254 + view - AUTRES ÉLÉMENTS DE PASSIF + AUTRES PASSIFS NON-COURANTS - - 300000 + + 3 view CAPITAUX PROPRES - - 310000 - + + 31 + view CAPITAL-ACTIONS - - 311000 - + + 32 + view - ACTIONS PRIVILÉGIÉES + PRIMES - - 311100 - + + 33 + view - ACTIONS PRIVILÉGIÉES - NOUVELLES ÉMISSIONS + BÉNÉFICES NON RÉPARTIS - - 311200 - - view - - ACTIONS PRIVILÉGIÉES - NOUVELLES ÉMISSIONS (PLANS DE RÉINVESTISSEMENT DES DIVIDENDES) - - - - 311300 - - view - - ACTIONS PRIVILÉGIÉES - RACHATS ET REMBOURSEMENTS - - - - 312000 - - view - - ACTIONS ORDINAIRES - - - - 312100 - - view - - ACTIONS ORDINAIRES - NOUVELLES ÉMISSIONS - - - - 312200 - - view - - ACTIONS ORDINAIRES - NOUVELLES ÉMISSIONS (PLANS DE RÉINVESTISSEMENT DES DIVIDENDES) - - - - 312300 - - view - - ACTIONS ORDINAIRES - RACHATS ET REMBOURSEMENTS - - - - 313000 - - view - - AVOIR PROPRE - - - - 314000 - - view - - AUTRES ACTIONS - - - - 320000 - - view - - BÉNÉFICES NON RÉPARTIS / DÉFICITS - - - - 321000 - - view - - BÉNÉFICES NON RÉPARTIS / DÉFICITS, AFFECTÉS - - - - 322000 - - view - - BÉNÉFICES NON RÉPARTIS / DÉFICITS, NON AFFECTÉS - - - - 330000 - - view - - SURPLUS D'APPORT - - - - 340000 - - view - - AUTRES SURPLUS - - - - - - 400000 - - view - - REVENUS - - - - 410000 - - view - - REVENUS D'EXPLOITATION - - - - 411000 - - view - - VENTES DE BIENS ET DE SERVICES - - - - 411100 - - view - - VENTES DE BIENS - - - - 411110 - - other - - Ventes au Québec - - - - 411120 - - other - - Ventes avec des provinces harmonisées - - - - 411130 - - other - - Ventes avec des provinces non-harmonisées - - - - 411140 - - other - - Ventes à l'étranger - - - - 411200 - - view - - VENTES DE SERVICES - - - - 411210 - - other - - Ventes au Québec - - - - 411220 - - other - - Ventes avec des provinces harmonisées - - - - 411230 - - other - - Ventes avec des provinces non-harmonisées - - - - 411240 - - other - - Ventes à l'étranger - - - - 413000 - - view - - AUTRES REVENUS D'EXPLOITATION - - - - 413100 - - view - - SUBVENTIONS ET OCTROIS - - - - 413200 - - view - - REDEVANCES DE FRANCHISAGE ET AUTRES REDEVANCES - - - - 413300 - - view - - AUTRES REVENUS D'EXPLOITATION - - - - 420000 - - view - - REVENUS NON LIÉS À L'EXPLOITATION - - - - 421000 - + + 34 + view DIVIDENDES - - 421100 - + + 35 + view - DIVIDENDES DE SOCIÉTÉS CANADIENNES + ÉCARTS DE CONVERSION - - 421200 - + + 36 + view - DIVIDENDES DE SOCIÉTÉS ÉTRANGÈRES + SURPLUS D'APPORT - - 422000 - + + 39 + + view + + AUTRES ÉLÉMENTS DU RÉSULTAT GLOBAL + + + + + + 4 + + view + + PRODUITS + + + + 41 + + view + + PRODUITS D'EXPLOITATION + + + + 411 + + other + + Ventes + + + + 412 + + other + + Ventes avec des provinces harmonisées + + + + 413 + + other + + Ventes avec des provinces non-harmonisées + + + + 414 + + other + + Ventes à l'étranger + + + + 419 + + view + + AUTRES PRODUITS D'EXPLOITATION + + + + 42 + + view + + PRODUITS NON LIÉS À L'EXPLOITATION + + + + 425 + view INTÉRÊTS - - 422100 - + + 429 + view - INTÉRÊTS DE SOURCE CANADIENNE + AUTRES PRODUITS NON LIÉS À L'EXPLOITATION - - 422200 - - view - - INTÉRÊTS DE SOURCES ÉTRANGÈRES - + - - 423000 - - view - - AUTRES REVENUS NON LIÉS À L'EXPLOITATION - - - - - - 500000 + + 5 view - DÉPENSES + CHARGES - - 510000 - + + 51 + view - DÉPENSES D'EXPLOITATION + CHARGES D'EXPLOITATION - - 511000 - + + 511 + view - COÛT DES BIENS VENDUS + COÛT DES PRODUITS VENDUS - - - 511100 - - view - - STOCKS D'OUVERTURE - - - - 511110 - + + + 5111 + other - Dépenses + Achats - - 511200 - + + 5112 + + other + + Achats dans des provinces harmonisées + + + + 513 + + other + + Achats dans des provinces non-harmonisées + + + + 5114 + + other + + Achats à l'étranger + + + + 512 + view - ACHATS ET COÛTS IMPUTABLES AU COÛT DES BIENS VENDUS + SALAIRES ET CHARGES SOCIALES - - 511300 - + + 51201 + + other + + Salaires + + + + 51202 + + other + + Vacances + + + + 51203 + + other + + Assurance Emploi + + + + 51204 + + other + + Fonds des services de santé + + + + 51205 + + other + + Rentes + + + + 51206 + + other + + Assurance parental + + + + 51207 + + other + + Santé et sécurité au travail + + + + 51208 + + other + + Normes du travail + + + + 513 + view - STOCKS DE CLOTÛRE + FRAIS SUR VENTE - - 512000 - + + 514 + view - FRAIS D'EXPLOITATION NON COMPRIS DANS LE COÛT DES BIENS VENDUS + FRAIS GÉNÉRAUX - - 512100 - + + 515 + view - FRAIS DE MAIN D'OEUVRE + FRAIS DE RECHERCHE ET DÉVELOPPEMENT - - 512110 - - view - - SALAIRES, TRAITEMENTS ET COMMISSIONS - - - - 512120 - - view - - AVANTAGES SOCIAUX DES EMPLOYÉS - - - - 512200 - - view - - CHARGES AUTRES QUES LES FRAIS DE MAIN-D'OEUVRE - - - - 512210 - - view - - AMORTISSEMENT, Y COMPRIS POUR DÉPRÉCIATION ET ÉPUISEMENT - - - - 512220 - - view - - FRAIS D'ÉNERGIE, D'EAU, DE TÉLÉPHONE ET DE TÉLÉCOMMUNICATIONS - - - - 512230 - - view - - IMPÔTS INDIRECTS, LICENCES ET PERMIS - - - - 512240 - - view - - CONTRATS DE SOUS-TRAITANCE - - - - 512250 - - view - - FRAIS D'EXPLORATION ET D'AMÉNAGEMENT - - - - 512260 - - view - - REDEVANCES DE FRANCHISAGE ET AUTRES REDEVANCES - - - - 512270 - - view - - ACHATS DE MATÉRIAUX, DE FOURNITURES ET DE SERVICES - - - - 512290 - + + 519 + view AUTRES FRAIS D'EXPLOITATION - - 520000 - + + 52 + view FRAIS NON LIÉS À L'EXPLOITATION - - 521000 - + + 521 + view INTÉRÊTS DÉBITEURS - - 521100 - - view - - INTÉRÊTS DÉBITEURS SUR DETTES À COURT TERME - - - - 521200 - - view - - INTÉRÊTS DÉBITEURS SUR DETTES À LONG TERME - - - - 522000 - + + 529 + view AUTRES FRAIS NON LIÉS À L'EXPLOITATION - - - - 600000 - - view - - GAINS OU PERTES, IMPÔTS DES SOCIÉTÉS ET AUTRES ÉLÉMENTS - - - - 610000 - - view - - GAINS OU PERTES - - - - 611000 - - view - - GAINS OU PERTES SUR LA VENTE D'ACTIFS - - - - 611100 - - view - - GAINS OU PERTES RÉALISÉS - ACTIFS IMMOBILISÉS - - - - 611200 - - view - - GAINS OU PERTES RÉALISÉS - PLACEMENTS - - - - 611300 - - view - - GAINS OU PERTES RÉALISÉS - AUTRES ACTIFS - - - - 612000 - - view - - GAINS OU PERTES SUR LA CONVERSION DE DEVISES - - - - 613000 - - view - - PERTES NON RÉALISÉES SUR LA RÉÉVALUATION D'ACTIF - - - - 613100 - - view - - PERTES NON RÉALISÉS - ACTIFS IMMOBILISÉS - - - - 613200 - - view - - PERTES NON RÉALISÉS - PLACEMENTS - - - - 613300 - - view - - PERTES NON RÉALISÉS - AUTRES ACTIFS - - - - 614000 - - view - - GAINS SUR RÈGLEMENT D'OBLIGATIONS AU TITRE DE RÉGIMES DE RETRAITE - - - - 615000 - - view - - GAINS OU PERTES LIÉS AUX RÈGLEMENTS DE LITIGES - - - - 616000 - - view - - GAINS OU PERTES SUR INSTRUMENTS DÉRIVÉS - - - - 620000 - - view - - IMPÔTS SUR LES BÉNÉFICES DES SOCIÉTÉS - - - - 621000 - - view - - IMPÔTS EXIGIBLES DE L'EXERCICE - - - - 622000 - - view - - IMPÔTS REPORTÉS - - - - 623000 - - view - - IMPÔT PROVINCIAL SUR L'EXPLOITATION MINIÈRE ET FORESTIÈRE - - - - 630000 - - view - - AUTRES ÉLÉMENTS - - - - - - 700000 - - view - - GAINS OU PERTES EXTRAORDINAIRES, ÉLÉMENTS NON RÉCURRENTS ET REDRESSEMENTS - - - - 710000 - - view - - GAINS OU PERTES EXTRAORDINAIRES - - - - 711000 - - view - - ÉLÉMENTS EXTRAORDINAIRES - BRUTS - - - - 712000 - - view - - IMPÔTS SUR LES ÉLÉMENTS EXTRAORDINAIRES - - - - 720000 - - view - - ÉLÉMENTS NON RÉCURRENTS - - - - 730000 - - view - - REDRESSEMENTS REPRÉSENTANT L'EFFET CUMULATIF DES CHANGEMENTS DE PRINCIPES COMPTABLES - - diff --git a/addons/l10n_ca/account_chart_template_fr.xml b/addons/l10n_ca/account_chart_template_fr.xml index 8f5238e33bb..ff8113fca29 100644 --- a/addons/l10n_ca/account_chart_template_fr.xml +++ b/addons/l10n_ca/account_chart_template_fr.xml @@ -7,11 +7,11 @@ Canada - Plan comptable pour les provinces francophones - - - - - + + + + + diff --git a/addons/l10n_ca/account_tax_fr.xml b/addons/l10n_ca/account_tax_fr.xml index 6ae3c08c893..ac4984006df 100644 --- a/addons/l10n_ca/account_tax_fr.xml +++ b/addons/l10n_ca/account_tax_fr.xml @@ -21,8 +21,8 @@ percent 1 - - + + @@ -37,8 +37,8 @@ 0.700000 percent 1 - - + + @@ -65,8 +65,8 @@ percent 1 - - + + @@ -81,8 +81,8 @@ 0.100000 percent 1 - - + + @@ -109,8 +109,8 @@ percent 1 - - + + @@ -125,8 +125,8 @@ 0.085000 percent 1 - - + + @@ -153,8 +153,8 @@ percent 1 - - + + @@ -169,8 +169,8 @@ 0.050000 percent 1 - - + + @@ -186,8 +186,8 @@ TVH12 0.120000 percent - - + + @@ -200,8 +200,8 @@ TVH13 0.130000 percent - - + + @@ -214,8 +214,8 @@ TVH135 0.135000 percent - - + + @@ -228,8 +228,8 @@ TVH15 0.150000 percent - - + + @@ -244,8 +244,8 @@ TPS 0.050000 percent - - + + diff --git a/addons/l10n_ca/fiscal_templates_fr.xml b/addons/l10n_ca/fiscal_templates_fr.xml index 476e5116213..2ce50e5d6e1 100644 --- a/addons/l10n_ca/fiscal_templates_fr.xml +++ b/addons/l10n_ca/fiscal_templates_fr.xml @@ -313,80 +313,81 @@ - + - + - - + + - + - - + + - + - - + + - + - - + + - + - - + + - + - - + + - + - + - - + + - + - - + + - + - - + + - + - - + + - + - - + + - + - - + + + From a0ae570cbd2bc5339b983bc7fc8f583b2b78c99a Mon Sep 17 00:00:00 2001 From: Antony Lesuisse Date: Thu, 27 Oct 2011 00:55:15 +0200 Subject: [PATCH 126/163] [FIX] pad condition on name of attachement instead of url bzr revid: al@openerp.com-20111026225515-rdfxvgk8vv9j055m --- addons/pad/static/src/js/pad.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/pad/static/src/js/pad.js b/addons/pad/static/src/js/pad.js index 635c86a48dd..d6f2c1de26b 100644 --- a/addons/pad/static/src/js/pad.js +++ b/addons/pad/static/src/js/pad.js @@ -9,7 +9,7 @@ instance.web.form.SidebarAttachments = instance.web.form.SidebarAttachments.exte var self = this; var $padbtn = self.$element.find('button.pad'); var is_pad = function(a) { - return a.type == 'url' && _(a.url).startsWith(self.pad_prefix); + return a.type == 'url' && a.name == 'Pad'; }; if (_.any(attachments, is_pad)) { $padbtn.hide(); From b415b7266f62e5adf0dffccd0b9a15c71a447f64 Mon Sep 17 00:00:00 2001 From: Antony Lesuisse Date: Thu, 27 Oct 2011 02:13:13 +0200 Subject: [PATCH 127/163] [FIX] project kaban open pending button states bzr revid: al@openerp.com-20111027001313-ralqmm5c7b807lt2 --- addons/project/project_view.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/project/project_view.xml b/addons/project/project_view.xml index 18ff634f796..5f5a36157ef 100644 --- a/addons/project/project_view.xml +++ b/addons/project/project_view.xml @@ -363,8 +363,8 @@

      From 7fd2f34625820793e4bf726c742fb60f684b8236 Mon Sep 17 00:00:00 2001 From: Launchpad Translations on behalf of openerp <> Date: Thu, 27 Oct 2011 05:22:19 +0000 Subject: [PATCH 128/163] Launchpad automatic translations update. bzr revid: launchpad_translations_on_behalf_of_openerp-20111027052151-iq59w01y3570qp2r bzr revid: launchpad_translations_on_behalf_of_openerp-20111027052219-al2lmoforak20zt4 --- addons/association/i18n/fi.po | 4 ++-- addons/crm/i18n/da.po | 11 ++++++----- addons/hr_attendance/i18n/es_CL.po | 4 ++-- addons/share/i18n/fi.po | 4 ++-- addons/stock/i18n/nl.po | 12 ++++++------ openerp/addons/base/i18n/af.po | 4 ++-- openerp/addons/base/i18n/am.po | 4 ++-- openerp/addons/base/i18n/ar.po | 4 ++-- openerp/addons/base/i18n/bg.po | 4 ++-- openerp/addons/base/i18n/bs.po | 4 ++-- openerp/addons/base/i18n/ca.po | 4 ++-- openerp/addons/base/i18n/cs.po | 4 ++-- openerp/addons/base/i18n/da.po | 4 ++-- openerp/addons/base/i18n/de.po | 8 ++++---- openerp/addons/base/i18n/el.po | 4 ++-- openerp/addons/base/i18n/en_GB.po | 4 ++-- openerp/addons/base/i18n/es.po | 4 ++-- openerp/addons/base/i18n/es_CL.po | 4 ++-- openerp/addons/base/i18n/es_EC.po | 4 ++-- openerp/addons/base/i18n/et.po | 4 ++-- openerp/addons/base/i18n/eu.po | 4 ++-- openerp/addons/base/i18n/fa.po | 4 ++-- openerp/addons/base/i18n/fa_AF.po | 4 ++-- openerp/addons/base/i18n/fi.po | 4 ++-- openerp/addons/base/i18n/fr.po | 4 ++-- openerp/addons/base/i18n/gl.po | 4 ++-- openerp/addons/base/i18n/he.po | 4 ++-- openerp/addons/base/i18n/hr.po | 4 ++-- openerp/addons/base/i18n/hu.po | 4 ++-- openerp/addons/base/i18n/hy.po | 4 ++-- openerp/addons/base/i18n/id.po | 4 ++-- openerp/addons/base/i18n/is.po | 4 ++-- openerp/addons/base/i18n/it.po | 4 ++-- openerp/addons/base/i18n/ja.po | 4 ++-- openerp/addons/base/i18n/kk.po | 4 ++-- openerp/addons/base/i18n/ko.po | 4 ++-- openerp/addons/base/i18n/lt.po | 4 ++-- openerp/addons/base/i18n/lv.po | 4 ++-- openerp/addons/base/i18n/mk.po | 4 ++-- openerp/addons/base/i18n/mn.po | 4 ++-- openerp/addons/base/i18n/nb.po | 4 ++-- openerp/addons/base/i18n/nl.po | 14 +++++++------- openerp/addons/base/i18n/nl_BE.po | 4 ++-- openerp/addons/base/i18n/pl.po | 4 ++-- openerp/addons/base/i18n/pt.po | 4 ++-- openerp/addons/base/i18n/pt_BR.po | 4 ++-- openerp/addons/base/i18n/ro.po | 4 ++-- openerp/addons/base/i18n/ru.po | 4 ++-- openerp/addons/base/i18n/sk.po | 4 ++-- openerp/addons/base/i18n/sl.po | 4 ++-- openerp/addons/base/i18n/sq.po | 4 ++-- openerp/addons/base/i18n/sr.po | 4 ++-- openerp/addons/base/i18n/sr@latin.po | 4 ++-- openerp/addons/base/i18n/sv.po | 4 ++-- openerp/addons/base/i18n/th.po | 4 ++-- openerp/addons/base/i18n/tlh.po | 4 ++-- openerp/addons/base/i18n/tr.po | 4 ++-- openerp/addons/base/i18n/uk.po | 4 ++-- openerp/addons/base/i18n/ur.po | 4 ++-- openerp/addons/base/i18n/vi.po | 4 ++-- openerp/addons/base/i18n/zh_CN.po | 4 ++-- openerp/addons/base/i18n/zh_HK.po | 4 ++-- openerp/addons/base/i18n/zh_TW.po | 4 ++-- 63 files changed, 141 insertions(+), 140 deletions(-) diff --git a/addons/association/i18n/fi.po b/addons/association/i18n/fi.po index 8afb5b06028..d6868670383 100644 --- a/addons/association/i18n/fi.po +++ b/addons/association/i18n/fi.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-26 05:13+0000\n" -"X-Generator: Launchpad (build 14189)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:22+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: association #: field:profile.association.config.install_modules_wizard,wiki:0 diff --git a/addons/crm/i18n/da.po b/addons/crm/i18n/da.po index f59398b7580..4542d1c0d52 100644 --- a/addons/crm/i18n/da.po +++ b/addons/crm/i18n/da.po @@ -8,14 +8,15 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2011-01-11 11:15+0000\n" -"PO-Revision-Date: 2011-09-22 20:38+0000\n" -"Last-Translator: FULL NAME \n" +"PO-Revision-Date: 2011-10-26 14:18+0000\n" +"Last-Translator: Nicholas Christian Langkjær Ipsen " +"\n" "Language-Team: Danish \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:59+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:22+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: crm #: view:crm.lead.report:0 @@ -74,7 +75,7 @@ msgstr "" #: view:crm.lead:0 #: view:crm.phonecall:0 msgid "Today" -msgstr "Idag" +msgstr "I dag" #. module: crm #: view:crm.merge.opportunity:0 diff --git a/addons/hr_attendance/i18n/es_CL.po b/addons/hr_attendance/i18n/es_CL.po index 59fdf185066..b532d6c3819 100644 --- a/addons/hr_attendance/i18n/es_CL.po +++ b/addons/hr_attendance/i18n/es_CL.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-26 05:13+0000\n" -"X-Generator: Launchpad (build 14189)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:22+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: hr_attendance #: model:ir.ui.menu,name:hr_attendance.menu_hr_time_tracking diff --git a/addons/share/i18n/fi.po b/addons/share/i18n/fi.po index 25e6a026d54..c18cfc6d139 100644 --- a/addons/share/i18n/fi.po +++ b/addons/share/i18n/fi.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-26 05:13+0000\n" -"X-Generator: Launchpad (build 14189)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:22+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: share #: code:addons/share/web/editors.py:15 diff --git a/addons/stock/i18n/nl.po b/addons/stock/i18n/nl.po index 76be8efd450..ff7b953e8b9 100644 --- a/addons/stock/i18n/nl.po +++ b/addons/stock/i18n/nl.po @@ -7,14 +7,14 @@ msgstr "" "Project-Id-Version: OpenERP Server 6.0dev\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2011-01-11 11:16+0000\n" -"PO-Revision-Date: 2010-10-30 14:44+0000\n" -"Last-Translator: OpenERP Administrators \n" +"PO-Revision-Date: 2011-10-26 15:25+0000\n" +"Last-Translator: Thomas \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:48+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:22+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: stock #: field:product.product,track_outgoing:0 @@ -850,7 +850,7 @@ msgstr "" #: code:addons/stock/stock.py:1315 #, python-format msgid "is scheduled %s." -msgstr "" +msgstr "is gepland %s" #. module: stock #: help:stock.picking,location_id:0 @@ -926,7 +926,7 @@ msgstr "Levering informatie" #: code:addons/stock/wizard/stock_fill_inventory.py:48 #, python-format msgid "Stock Inventory is done" -msgstr "" +msgstr "Stock inventaris is voltooid" #. module: stock #: constraint:product.product:0 diff --git a/openerp/addons/base/i18n/af.po b/openerp/addons/base/i18n/af.po index 4fa9cee01ab..7d741b81dd2 100644 --- a/openerp/addons/base/i18n/af.po +++ b/openerp/addons/base/i18n/af.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:38+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:14+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/am.po b/openerp/addons/base/i18n/am.po index 6a66c96ef29..e34811ede36 100644 --- a/openerp/addons/base/i18n/am.po +++ b/openerp/addons/base/i18n/am.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:14+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ar.po b/openerp/addons/base/i18n/ar.po index 0536c144785..6a4007c5061 100644 --- a/openerp/addons/base/i18n/ar.po +++ b/openerp/addons/base/i18n/ar.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/bg.po b/openerp/addons/base/i18n/bg.po index 64393bb1ba4..32648201b9c 100644 --- a/openerp/addons/base/i18n/bg.po +++ b/openerp/addons/base/i18n/bg.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/bs.po b/openerp/addons/base/i18n/bs.po index fc1599342ea..46e3ed6563b 100644 --- a/openerp/addons/base/i18n/bs.po +++ b/openerp/addons/base/i18n/bs.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ca.po b/openerp/addons/base/i18n/ca.po index 9bda7e533e8..9047d051322 100644 --- a/openerp/addons/base/i18n/ca.po +++ b/openerp/addons/base/i18n/ca.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/cs.po b/openerp/addons/base/i18n/cs.po index 5987fd7a7c2..b48228fe23c 100644 --- a/openerp/addons/base/i18n/cs.po +++ b/openerp/addons/base/i18n/cs.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" "X-Poedit-Language: Czech\n" #. module: base diff --git a/openerp/addons/base/i18n/da.po b/openerp/addons/base/i18n/da.po index 85b40249d0b..7063330a760 100644 --- a/openerp/addons/base/i18n/da.po +++ b/openerp/addons/base/i18n/da.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/de.po b/openerp/addons/base/i18n/de.po index 6d4e411b851..bf74255aac9 100644 --- a/openerp/addons/base/i18n/de.po +++ b/openerp/addons/base/i18n/de.po @@ -15,8 +15,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 @@ -6604,8 +6604,8 @@ msgid "" "You can not read this document (%s) ! Be sure your user belongs to one of " "these groups: %s." msgstr "" -"Sie haben kein Leserecht für diesen Beleg (%s) ! Stellen Sie sicher, dass " -"der Benutzer Mitglied der folgenden Gruppe ist: %s." +"Sie haben kein Leserecht für diesen Satz (%s) ! Stellen Sie sicher, dass der " +"Benutzer Mitglied der folgenden Gruppe ist: %s." #. module: base #: view:res.bank:0 diff --git a/openerp/addons/base/i18n/el.po b/openerp/addons/base/i18n/el.po index e31491fd4de..ea09ca74b29 100644 --- a/openerp/addons/base/i18n/el.po +++ b/openerp/addons/base/i18n/el.po @@ -12,8 +12,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" "X-Poedit-Country: GREECE\n" "X-Poedit-Language: Greek\n" "X-Poedit-SourceCharset: utf-8\n" diff --git a/openerp/addons/base/i18n/en_GB.po b/openerp/addons/base/i18n/en_GB.po index b7928166d19..537d4414d65 100644 --- a/openerp/addons/base/i18n/en_GB.po +++ b/openerp/addons/base/i18n/en_GB.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/es.po b/openerp/addons/base/i18n/es.po index 7eb9547d48e..171bdce1944 100644 --- a/openerp/addons/base/i18n/es.po +++ b/openerp/addons/base/i18n/es.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/es_CL.po b/openerp/addons/base/i18n/es_CL.po index 4e634674226..c9ca5314368 100644 --- a/openerp/addons/base/i18n/es_CL.po +++ b/openerp/addons/base/i18n/es_CL.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/es_EC.po b/openerp/addons/base/i18n/es_EC.po index fb39355861a..c1c6753a333 100644 --- a/openerp/addons/base/i18n/es_EC.po +++ b/openerp/addons/base/i18n/es_EC.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/et.po b/openerp/addons/base/i18n/et.po index 5b7cf017e33..d7358b7bcd6 100644 --- a/openerp/addons/base/i18n/et.po +++ b/openerp/addons/base/i18n/et.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/eu.po b/openerp/addons/base/i18n/eu.po index 59e62ebb7dc..31ba4d2e7da 100644 --- a/openerp/addons/base/i18n/eu.po +++ b/openerp/addons/base/i18n/eu.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/fa.po b/openerp/addons/base/i18n/fa.po index 35549242cba..b2d224acb0b 100644 --- a/openerp/addons/base/i18n/fa.po +++ b/openerp/addons/base/i18n/fa.po @@ -9,8 +9,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" "X-Poedit-Country: IRAN, ISLAMIC REPUBLIC OF\n" "X-Poedit-Language: Persian\n" diff --git a/openerp/addons/base/i18n/fa_AF.po b/openerp/addons/base/i18n/fa_AF.po index bd4a5f6bf49..66fe8430458 100644 --- a/openerp/addons/base/i18n/fa_AF.po +++ b/openerp/addons/base/i18n/fa_AF.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:46+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/fi.po b/openerp/addons/base/i18n/fi.po index f11cc74e3d3..a3a947d4ac1 100644 --- a/openerp/addons/base/i18n/fi.po +++ b/openerp/addons/base/i18n/fi.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/fr.po b/openerp/addons/base/i18n/fr.po index 6f4aacf3915..4ff9787da6c 100644 --- a/openerp/addons/base/i18n/fr.po +++ b/openerp/addons/base/i18n/fr.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/gl.po b/openerp/addons/base/i18n/gl.po index 8c97d631787..f3e324f35f8 100644 --- a/openerp/addons/base/i18n/gl.po +++ b/openerp/addons/base/i18n/gl.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/he.po b/openerp/addons/base/i18n/he.po index 7767c726971..bcea8e871d8 100644 --- a/openerp/addons/base/i18n/he.po +++ b/openerp/addons/base/i18n/he.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/hr.po b/openerp/addons/base/i18n/hr.po index ee968664661..dd4fa3ecc61 100644 --- a/openerp/addons/base/i18n/hr.po +++ b/openerp/addons/base/i18n/hr.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" "Language: hr\n" #. module: base diff --git a/openerp/addons/base/i18n/hu.po b/openerp/addons/base/i18n/hu.po index 7d90bc95ce4..19f7b36d76f 100644 --- a/openerp/addons/base/i18n/hu.po +++ b/openerp/addons/base/i18n/hu.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/hy.po b/openerp/addons/base/i18n/hy.po index c587a3816e3..11e977ee9ce 100644 --- a/openerp/addons/base/i18n/hy.po +++ b/openerp/addons/base/i18n/hy.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:39+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:15+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/id.po b/openerp/addons/base/i18n/id.po index b03c205125a..9a8955a84fc 100644 --- a/openerp/addons/base/i18n/id.po +++ b/openerp/addons/base/i18n/id.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/is.po b/openerp/addons/base/i18n/is.po index 670904486cd..366769db8de 100644 --- a/openerp/addons/base/i18n/is.po +++ b/openerp/addons/base/i18n/is.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/it.po b/openerp/addons/base/i18n/it.po index aa0ea13b92b..bbadf783fcb 100644 --- a/openerp/addons/base/i18n/it.po +++ b/openerp/addons/base/i18n/it.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ja.po b/openerp/addons/base/i18n/ja.po index c38bf6cec34..4f3575bc04d 100644 --- a/openerp/addons/base/i18n/ja.po +++ b/openerp/addons/base/i18n/ja.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/kk.po b/openerp/addons/base/i18n/kk.po index b744a1b334b..cb9b2bc2e04 100644 --- a/openerp/addons/base/i18n/kk.po +++ b/openerp/addons/base/i18n/kk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:41+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ko.po b/openerp/addons/base/i18n/ko.po index 61bfd591942..bb753f559cd 100644 --- a/openerp/addons/base/i18n/ko.po +++ b/openerp/addons/base/i18n/ko.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:17+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/lt.po b/openerp/addons/base/i18n/lt.po index c18b2026717..5cd202d5deb 100644 --- a/openerp/addons/base/i18n/lt.po +++ b/openerp/addons/base/i18n/lt.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/lv.po b/openerp/addons/base/i18n/lv.po index b8a223511a9..8ecd210b584 100644 --- a/openerp/addons/base/i18n/lv.po +++ b/openerp/addons/base/i18n/lv.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/mk.po b/openerp/addons/base/i18n/mk.po index 604cf7210f6..c49a8bb4aba 100644 --- a/openerp/addons/base/i18n/mk.po +++ b/openerp/addons/base/i18n/mk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/mn.po b/openerp/addons/base/i18n/mn.po index 950ca929447..0c31e4d9961 100644 --- a/openerp/addons/base/i18n/mn.po +++ b/openerp/addons/base/i18n/mn.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/nb.po b/openerp/addons/base/i18n/nb.po index 952c245fc85..42da587afc6 100644 --- a/openerp/addons/base/i18n/nb.po +++ b/openerp/addons/base/i18n/nb.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/nl.po b/openerp/addons/base/i18n/nl.po index 004db064193..631c500cb3e 100644 --- a/openerp/addons/base/i18n/nl.po +++ b/openerp/addons/base/i18n/nl.po @@ -7,14 +7,14 @@ msgstr "" "Project-Id-Version: OpenERP Server 5.0.0\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2011-01-11 11:14+0000\n" -"PO-Revision-Date: 2011-09-30 20:44+0000\n" -"Last-Translator: Antony Lesuisse (OpenERP) \n" +"PO-Revision-Date: 2011-10-26 15:29+0000\n" +"Last-Translator: Michel Vorenhout \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:40+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:16+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 @@ -8107,9 +8107,9 @@ msgid "" "loading a new language it becomes available as default interface language " "for users and partners." msgstr "" -"Deze assitent helpt u een nieuwe taal toe te voegen aan uw OpenERP systeem. " -"Na het laden van de nieuwe taal komt het beschikbaar als standaard interface " -"taal voor gebruikers en relaties." +"Deze assistent helpt u een nieuwe taal toe te voegen aan uw OpenERP systeem. " +"Na het laden van de nieuwe taal komt deze beschikbaar als standaard " +"interface taal voor gebruikers en relaties." #. module: base #: field:ir.actions.server,subject:0 diff --git a/openerp/addons/base/i18n/nl_BE.po b/openerp/addons/base/i18n/nl_BE.po index ea3d5f932a3..11473bfd222 100644 --- a/openerp/addons/base/i18n/nl_BE.po +++ b/openerp/addons/base/i18n/nl_BE.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/pl.po b/openerp/addons/base/i18n/pl.po index f3a4d8629cf..f9d37b9d342 100644 --- a/openerp/addons/base/i18n/pl.po +++ b/openerp/addons/base/i18n/pl.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:42+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/pt.po b/openerp/addons/base/i18n/pt.po index 6a690c9c940..60f0452a5a3 100644 --- a/openerp/addons/base/i18n/pt.po +++ b/openerp/addons/base/i18n/pt.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/pt_BR.po b/openerp/addons/base/i18n/pt_BR.po index 290e7505401..3420a64a449 100644 --- a/openerp/addons/base/i18n/pt_BR.po +++ b/openerp/addons/base/i18n/pt_BR.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ro.po b/openerp/addons/base/i18n/ro.po index 1140b6e2439..9be5dfca609 100644 --- a/openerp/addons/base/i18n/ro.po +++ b/openerp/addons/base/i18n/ro.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:18+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ru.po b/openerp/addons/base/i18n/ru.po index 09565c4356f..8c61abeb5dc 100644 --- a/openerp/addons/base/i18n/ru.po +++ b/openerp/addons/base/i18n/ru.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/sk.po b/openerp/addons/base/i18n/sk.po index 325786dca9b..1fb0ab85bda 100644 --- a/openerp/addons/base/i18n/sk.po +++ b/openerp/addons/base/i18n/sk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/sl.po b/openerp/addons/base/i18n/sl.po index f490c50499e..2f11d4edf08 100644 --- a/openerp/addons/base/i18n/sl.po +++ b/openerp/addons/base/i18n/sl.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/sq.po b/openerp/addons/base/i18n/sq.po index dc66f7803e5..ffe4bfa4539 100644 --- a/openerp/addons/base/i18n/sq.po +++ b/openerp/addons/base/i18n/sq.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:38+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:14+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/sr.po b/openerp/addons/base/i18n/sr.po index b2976ec25ab..8706c455702 100644 --- a/openerp/addons/base/i18n/sr.po +++ b/openerp/addons/base/i18n/sr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:43+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/sr@latin.po b/openerp/addons/base/i18n/sr@latin.po index 31a1f7e500b..64079819056 100644 --- a/openerp/addons/base/i18n/sr@latin.po +++ b/openerp/addons/base/i18n/sr@latin.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:46+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/sv.po b/openerp/addons/base/i18n/sv.po index 66bb8b12b51..582e01e54e5 100644 --- a/openerp/addons/base/i18n/sv.po +++ b/openerp/addons/base/i18n/sv.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/th.po b/openerp/addons/base/i18n/th.po index 83f6ee5a7f8..7e8e6eb3127 100644 --- a/openerp/addons/base/i18n/th.po +++ b/openerp/addons/base/i18n/th.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:19+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/tlh.po b/openerp/addons/base/i18n/tlh.po index 5b94f4372e0..a82f3a1b2ac 100644 --- a/openerp/addons/base/i18n/tlh.po +++ b/openerp/addons/base/i18n/tlh.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/tr.po b/openerp/addons/base/i18n/tr.po index 29571c55075..f9b54f321b6 100644 --- a/openerp/addons/base/i18n/tr.po +++ b/openerp/addons/base/i18n/tr.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/uk.po b/openerp/addons/base/i18n/uk.po index e801f7b4b11..eca2e2449f7 100644 --- a/openerp/addons/base/i18n/uk.po +++ b/openerp/addons/base/i18n/uk.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/ur.po b/openerp/addons/base/i18n/ur.po index e20b317cc9f..b28fd1319a2 100644 --- a/openerp/addons/base/i18n/ur.po +++ b/openerp/addons/base/i18n/ur.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/vi.po b/openerp/addons/base/i18n/vi.po index c5f02076c89..ea8df05cb28 100644 --- a/openerp/addons/base/i18n/vi.po +++ b/openerp/addons/base/i18n/vi.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:44+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/zh_CN.po b/openerp/addons/base/i18n/zh_CN.po index 015b6ff3643..622db5a4d4d 100644 --- a/openerp/addons/base/i18n/zh_CN.po +++ b/openerp/addons/base/i18n/zh_CN.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/zh_HK.po b/openerp/addons/base/i18n/zh_HK.po index 9ae6740925d..da310b384a4 100644 --- a/openerp/addons/base/i18n/zh_HK.po +++ b/openerp/addons/base/i18n/zh_HK.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:20+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 diff --git a/openerp/addons/base/i18n/zh_TW.po b/openerp/addons/base/i18n/zh_TW.po index 26435f89bb2..09fd12c95e2 100644 --- a/openerp/addons/base/i18n/zh_TW.po +++ b/openerp/addons/base/i18n/zh_TW.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-10-19 04:45+0000\n" -"X-Generator: Launchpad (build 14157)\n" +"X-Launchpad-Export-Date: 2011-10-27 05:21+0000\n" +"X-Generator: Launchpad (build 14197)\n" #. module: base #: view:ir.filters:0 From e2896c50f7181357f0267ebea9fe15397646b919 Mon Sep 17 00:00:00 2001 From: Antony Lesuisse Date: Thu, 27 Oct 2011 09:04:20 +0200 Subject: [PATCH 129/163] [REM] Useless configure outgoing email server bzr revid: al@openerp.com-20111027070420-6vgma0q33l3ij4ja --- addons/mail/__openerp__.py | 1 - addons/mail/mail_installer.xml | 17 ----------------- 2 files changed, 18 deletions(-) delete mode 100644 addons/mail/mail_installer.xml diff --git a/addons/mail/__openerp__.py b/addons/mail/__openerp__.py index 47d731aa4e5..1cb97ce182e 100644 --- a/addons/mail/__openerp__.py +++ b/addons/mail/__openerp__.py @@ -62,7 +62,6 @@ The main features are: "res_partner_view.xml", 'security/ir.model.access.csv', 'mail_data.xml', - 'mail_installer.xml', ], 'installable': True, 'active': False, diff --git a/addons/mail/mail_installer.xml b/addons/mail/mail_installer.xml deleted file mode 100644 index 022bff6e53b..00000000000 --- a/addons/mail/mail_installer.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - Configure Email Servers - ir.actions.act_window - ir.mail_server - form - tree,form - - - - - - - - From 01dce90eb40405e1a6462e899e53623f15574230 Mon Sep 17 00:00:00 2001 From: Antony Lesuisse Date: Thu, 27 Oct 2011 09:10:00 +0200 Subject: [PATCH 130/163] [IMP] Create Setting->Email root menu item bzr revid: al@openerp.com-20111027071000-cwfpk7wd7r82sw2c --- openerp/addons/base/ir/ir.xml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/openerp/addons/base/ir/ir.xml b/openerp/addons/base/ir/ir.xml index 7989bf6e180..da6f1e167f9 100644 --- a/openerp/addons/base/ir/ir.xml +++ b/openerp/addons/base/ir/ir.xml @@ -2043,7 +2043,9 @@
      - - + + + + From 6acbb08aa786b4a890f2cc89ec4a5ec7888c41a9 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Thu, 27 Oct 2011 10:24:36 +0200 Subject: [PATCH 131/163] [ADD] method forcing the saving of a listview if it's being edited (and not doing anything if it's not) bzr revid: xmo@openerp.com-20111027082436-46zcjurzxtg5n9zt --- .../web/static/src/js/view_list_editable.js | 83 ++++++++++++++----- 1 file changed, 61 insertions(+), 22 deletions(-) diff --git a/addons/web/static/src/js/view_list_editable.js b/addons/web/static/src/js/view_list_editable.js index 4cc081a6266..94da157a866 100644 --- a/addons/web/static/src/js/view_list_editable.js +++ b/addons/web/static/src/js/view_list_editable.js @@ -78,6 +78,17 @@ openerp.web.list_editable = function (openerp) { // tree/@editable takes priority on everything else if present. this.options.editable = data.arch.attrs.editable || this.options.editable; return this._super(data, grouped); + }, + /** + * Ensures the editable list is saved (saves any pending edition if + * needed, or tries to) + * + * Returns a deferred to the end of the saving. + * + * @returns {$.Deferred} + */ + ensure_saved: function () { + return this.groups.ensure_saved(); } }); @@ -86,6 +97,18 @@ openerp.web.list_editable = function (openerp) { new_record: function () { // TODO: handle multiple children this.children[null].new_record(); + }, + /** + * Ensures descendant editable List instances are all saved if they have + * pending editions. + * + * @returns {$.Deferred} + */ + ensure_saved: function () { + return $.when.apply(null, + _.invoke( + _.values(this.children), + 'ensure_saved')); } }); @@ -254,9 +277,11 @@ openerp.web.list_editable = function (openerp) { * sibling if asked. * * @param {Boolean} [edit_next=false] should the next row become editable + * @returns {$.Deferred} */ save_row: function (edit_next) { - var self = this; + //noinspection JSPotentiallyInvalidConstructorUsage + var self = this, done = $.Deferred(); this.edition_form.do_save(function (result) { if (result.created && !self.edition_id) { self.records.add({id: result.result}, @@ -267,28 +292,42 @@ openerp.web.list_editable = function (openerp) { next_record = self.records.at( self.records.indexOf(edited_record) + 1); - self.handle_onwrite(self.edition_id); - self.cancel_pending_edition().then(function () { - $(self).trigger('saved', [self.dataset]); - if (!edit_next) { - return; - } - if (result.created) { - self.new_record(); - return; - } - var next_record_id; - if (next_record) { - next_record_id = next_record.get('id'); - self.dataset.index = _(self.dataset.ids) - .indexOf(next_record_id); - } else { - self.dataset.index = 0; - next_record_id = self.records.at(0).get('id'); - } - self.edit_record(next_record_id); - }); + $.when( + self.handle_onwrite(self.edition_id), + self.cancel_pending_edition().then(function () { + $(self).trigger('saved', [self.dataset]); + if (!edit_next) { + return; + } + if (result.created) { + self.new_record(); + return; + } + var next_record_id; + if (next_record) { + next_record_id = next_record.get('id'); + self.dataset.index = _(self.dataset.ids) + .indexOf(next_record_id); + } else { + self.dataset.index = 0; + next_record_id = self.records.at(0).get('id'); + } + self.edit_record(next_record_id); + })).then(function () { + done.resolve(); + }); }, this.options.editable === 'top'); + return done.promise(); + }, + /** + * If the current list is being edited, ensures it's saved + */ + ensure_saved: function () { + if (this.edition) { + return this.save_row(); + } + //noinspection JSPotentiallyInvalidConstructorUsage + return $.Deferred().resolve().promise(); }, /** * Cancels the edition of the row for the current dataset index From 8290deff05b0ffb4855f3232fd1b320633d86e4d Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Thu, 27 Oct 2011 10:36:17 +0200 Subject: [PATCH 132/163] [ADD] handle failure to save in ListView#ensure_saved: reject the deferred bzr revid: xmo@openerp.com-20111027083617-medipetfasqvfacq --- addons/web/static/src/js/view_list_editable.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/js/view_list_editable.js b/addons/web/static/src/js/view_list_editable.js index 94da157a866..dba0a1abba4 100644 --- a/addons/web/static/src/js/view_list_editable.js +++ b/addons/web/static/src/js/view_list_editable.js @@ -316,7 +316,9 @@ openerp.web.list_editable = function (openerp) { })).then(function () { done.resolve(); }); - }, this.options.editable === 'top'); + }, this.options.editable === 'top').fail(function () { + done.reject(); + }); return done.promise(); }, /** From d52a8f3f2080781489c85dfb9f1038c658d158eb Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Thu, 27 Oct 2011 11:57:07 +0200 Subject: [PATCH 133/163] [FIX] states-based row colors failing to apply on o2ms due to overly precise rule lp bug: https://launchpad.net/bugs/882175 fixed bzr revid: xmo@openerp.com-20111027095707-22brxk7fyg3w4svj --- addons/web/static/src/css/base.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index 744d218a83b..e8f1ff9c3bb 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -846,7 +846,7 @@ label.error { .openerp .oe_frame.oe_forms { clear: both; } -.openerp table.oe_frame td { +.openerp table.oe_frame { color: #4c4c4c; } .openerp td.oe_form_frame_cell { From 2403f027c7de93184548f6c74b6fb7328cbadca9 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Thu, 27 Oct 2011 12:33:01 +0200 Subject: [PATCH 134/163] [FIX] Kanban: can't edit some records after a search bzr revid: fme@openerp.com-20111027103301-kzyztkq8gbjqqm6x --- addons/web_kanban/static/src/js/kanban.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index adc259894c5..8e222ebe8d9 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -438,6 +438,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ self.datagroup.list( _.keys(self.fields_view.fields), function (groups) { + self.dataset.ids = []; self.groups = groups; if (groups.length) { self.do_render_group(groups); @@ -481,6 +482,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ var dataset = new openerp.web.DataSetSearch(self, self.dataset.model, group.context, group.domain); self.$element.find(".oe_kanban_view").remove(); dataset.read_slice(_.keys(self.fields_view.fields), {'domain': group.domain, 'context': group.context}, function(records) { + self.dataset.ids.push.apply(self.dataset.ids, dataset.ids); self.all_display_data[index] = {"value" : group_value, "records" : records, 'header' : group_name, 'ids' : dataset.ids, 'aggregates' : group_aggregates}; if (!remaining--) { self.on_show_data(); From ecfa2d532e90e70dd5166a9a40ec105bb8791ec1 Mon Sep 17 00:00:00 2001 From: Olivier Dony Date: Thu, 27 Oct 2011 14:13:15 +0200 Subject: [PATCH 135/163] [IMP] crm: improved/cleaned up CRM Lead/Opp Analysis bzr revid: odo@openerp.com-20111027121315-xiuin0sbzoyvr8hk --- addons/crm/report/crm_lead_report.py | 51 +++++++++++++++------- addons/crm/report/crm_lead_report_view.xml | 24 ++++++---- 2 files changed, 50 insertions(+), 25 deletions(-) diff --git a/addons/crm/report/crm_lead_report.py b/addons/crm/report/crm_lead_report.py index 18615bdf344..24f48e7de86 100644 --- a/addons/crm/report/crm_lead_report.py +++ b/addons/crm/report/crm_lead_report.py @@ -47,28 +47,41 @@ MONTHS = [ ] class crm_lead_report(osv.osv): - """ CRM Lead Report """ + """ CRM Lead Analysis """ _name = "crm.lead.report" _auto = False - _description = "CRM Lead Report" + _description = "CRM Lead Analysis" + _rec_name = 'deadline_day' _columns = { - 'name': fields.char('Year', size=64, required=False, readonly=True), + # grouping fields based on Deadline Date + 'deadline_year': fields.char('Ex. Closing Year', size=10, readonly=True, help="Expected closing year"), + 'deadline_month':fields.selection(MONTHS, 'Exp. Closing Month', readonly=True, help="Expected closing month"), + 'deadline_day': fields.char('Exp. Closing Day', size=10, readonly=True, help="Expected closing day"), + + # grouping fields based on Create Date + 'creation_year': fields.char('Creation Year', size=10, readonly=True, help="Creation year"), + 'creation_month': fields.selection(MONTHS, 'Creation Month', readonly=True, help="Creation month"), + 'creation_day': fields.char('Creation Day', size=10, readonly=True, help="Creation day"), + + # other date fields + 'create_date': fields.datetime('Create Date', readonly=True), + 'opening_date': fields.date('Opening Date', readonly=True), + 'date_closed': fields.date('Close Date', readonly=True), + + # durations + 'delay_open': fields.float('Delay to Open',digits=(16,2),readonly=True, group_operator="avg",help="Number of Days to open the case"), + 'delay_close': fields.float('Delay to Close',digits=(16,2),readonly=True, group_operator="avg",help="Number of Days to close the case"), + 'delay_expected': fields.float('Overpassed Deadline',digits=(16,2),readonly=True, group_operator="avg"), + 'user_id':fields.many2one('res.users', 'User', readonly=True), 'country_id':fields.many2one('res.country', 'Country', readonly=True), 'section_id':fields.many2one('crm.case.section', 'Sales Team', readonly=True), 'channel_id':fields.many2one('crm.case.channel', 'Channel', readonly=True), 'type_id':fields.many2one('crm.case.resource.type', 'Campaign', readonly=True), 'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True), - 'creation_month':fields.selection(MONTHS, 'Creation Date', readonly=True), - 'deadline_month':fields.selection(MONTHS, 'Exp. Closing', readonly=True), 'company_id': fields.many2one('res.company', 'Company', readonly=True), - 'create_date': fields.datetime('Create Date', readonly=True, select=True), - 'day': fields.char('Day', size=128, readonly=True), 'email': fields.integer('# Emails', size=128, readonly=True), - 'delay_open': fields.float('Delay to Open',digits=(16,2),readonly=True, group_operator="avg",help="Number of Days to open the case"), - 'delay_close': fields.float('Delay to Close',digits=(16,2),readonly=True, group_operator="avg",help="Number of Days to close the case"), - 'delay_expected': fields.float('Overpassed Deadline',digits=(16,2),readonly=True, group_operator="avg"), 'probability': fields.float('Probability',digits=(16,2),readonly=True, group_operator="avg"), 'planned_revenue': fields.float('Planned Revenue',digits=(16,2),readonly=True), 'probable_revenue': fields.float('Probable Revenue', digits=(16,2),readonly=True), @@ -76,9 +89,6 @@ class crm_lead_report(osv.osv): domain="['|',('section_id','=',False),('section_id','=',section_id)]" , readonly=True), 'stage_id': fields.many2one ('crm.case.stage', 'Stage', readonly=True, domain="[('section_ids', '=', section_id)]"), 'partner_id': fields.many2one('res.partner', 'Partner' , readonly=True), - 'opening_date': fields.date('Opening Date', readonly=True, select=True), - 'creation_date': fields.date('Creation Date', readonly=True, select=True), - 'date_closed': fields.date('Close Date', readonly=True, select=True), 'nbr': fields.integer('# of Cases', readonly=True), 'company_id': fields.many2one('res.company', 'Company', readonly=True), 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'), @@ -87,6 +97,10 @@ class crm_lead_report(osv.osv): ('opportunity','Opportunity'), ],'Type', help="Type is used to separate Leads and Opportunities"), } + + + + def init(self, cr): """ @@ -98,13 +112,18 @@ class crm_lead_report(osv.osv): CREATE OR REPLACE VIEW crm_lead_report AS ( SELECT id, - to_char(c.date_deadline, 'YYYY') as name, + + to_char(c.date_deadline, 'YYYY') as deadline_year, to_char(c.date_deadline, 'MM') as deadline_month, - to_char(c.date_deadline, 'YYYY-MM-DD') as day, + to_char(c.date_deadline, 'YYYY-MM-DD') as deadline_day, + + to_char(c.create_date, 'YYYY') as creation_year, to_char(c.create_date, 'MM') as creation_month, - to_char(c.create_date, 'YYYY-MM-DD') as creation_date, + to_char(c.create_date, 'YYYY-MM-DD') as creation_day, + to_char(c.date_open, 'YYYY-MM-DD') as opening_date, to_char(c.date_closed, 'YYYY-mm-dd') as date_closed, + c.state, c.user_id, c.probability, diff --git a/addons/crm/report/crm_lead_report_view.xml b/addons/crm/report/crm_lead_report_view.xml index 4c165d5aa81..bf3917863cd 100644 --- a/addons/crm/report/crm_lead_report_view.xml +++ b/addons/crm/report/crm_lead_report_view.xml @@ -10,7 +10,10 @@ tree - + + + + @@ -18,14 +21,11 @@ - - - @@ -86,6 +86,7 @@ + @@ -101,7 +102,7 @@ + help="Leads/Opportunities which are in open state"/> - + @@ -164,8 +165,13 @@ - + + + @@ -181,14 +187,14 @@ tree - + + - From 66ea5439741704346a45441b009240797628636f Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Thu, 27 Oct 2011 14:43:25 +0200 Subject: [PATCH 136/163] [FIX] Add support for @align attribute in form views lp bug: https://launchpad.net/bugs/844625 fixed bzr revid: fme@openerp.com-20111027124325-ckd8kuujbb591nqu --- addons/web/static/src/css/base.css | 13 ++++++++++++- addons/web/static/src/js/view_form.js | 13 +++++++++++-- addons/web/static/src/xml/base.xml | 4 ++-- 3 files changed, 25 insertions(+), 5 deletions(-) diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index e8f1ff9c3bb..ae73607aab0 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -874,7 +874,6 @@ label.error { } .openerp .oe_forms label.oe_label, .openerp .oe_forms label.oe_label_help { - text-align: right; margin: 3px 0 0 10px; } .openerp label.oe_label_help span { @@ -885,6 +884,18 @@ label.error { top: -4px; padding: 0 2px; } +.openerp .oe_align_left { + text-align: left; +} +.openerp .oe_align_right { + text-align: right; +} +.openerp .oe_align_center { + text-align: center; +} +.openerp .oe_forms .oe_form_paragraph { + margin: 3px 0 0 0; +} /* Inputs */ .openerp .oe_forms input[type="text"], .openerp .oe_forms input[type="password"], .openerp .oe_forms select, .openerp .oe_forms textarea { diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index b864365df99..6f499a0adf7 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -717,6 +717,16 @@ openerp.web.form.Widget = openerp.web.Widget.extend(/** @lends openerp.web.form. this.invisible = this.modifiers['invisible'] === true; this.classname = 'oe_form_' + this.type; + this.align = parseFloat(this.node.attrs.align); + if (isNaN(this.align) || this.align === 1) { + this.align = 'right'; + } else if (this.align === 0) { + this.align = 'left'; + } else { + this.align = 'center'; + } + + this.width = this.node.attrs.width; }, start: function() { @@ -1046,8 +1056,7 @@ openerp.web.form.WidgetLabel = openerp.web.form.Widget.extend({ this._super(view, node); - // TODO fme: support for attrs.align - if (this.node.tag == 'label' && (this.node.attrs.colspan || (this.string && this.string.length > 32))) { + if (this.node.tag == 'label' && (this.align === 'left' || this.node.attrs.colspan || (this.string && this.string.length > 32))) { this.template = "WidgetParagraph"; this.colspan = parseInt(this.node.attrs.colspan || 1, 10); } else { diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml index dbee68fdb83..8984daffeb3 100644 --- a/addons/web/static/src/xml/base.xml +++ b/addons/web/static/src/xml/base.xml @@ -752,7 +752,7 @@ -

      +

      Date: Thu, 27 Oct 2011 14:45:03 +0200 Subject: [PATCH 137/163] [IMP] blockUI defaults configuration * Set throbber image as the default message * Ensure blockUI is on top of dialogs bzr revid: xmo@openerp.com-20111027124503-i4u0fmqij3o80sy3 --- addons/web/static/src/js/chrome.js | 6 +++--- addons/web/static/src/js/core.js | 4 ++++ addons/web_dashboard/static/src/js/dashboard.js | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index bdb8e23c20b..38923d268cf 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -343,7 +343,7 @@ openerp.web.Database = openerp.web.Widget.extend(/** @lends openerp.web.Database self.$option_id.find("form[name=create_db_form]").validate({ submitHandler: function (form) { var fields = $(form).serializeArray(); - $.blockUI({message:''}); + $.blockUI(); self.rpc("/web/database/create", {'fields': fields}, function(result) { if (result.error) { $.unblockUI(); @@ -392,7 +392,7 @@ openerp.web.Database = openerp.web.Widget.extend(/** @lends openerp.web.Database .html(QWeb.render("BackupDB", self)) .find("form[name=backup_db_form]").validate({ submitHandler: function (form) { - $.blockUI({message:''}); + $.blockUI(); self.session.get_file({ form: form, error: function (body) { @@ -413,7 +413,7 @@ openerp.web.Database = openerp.web.Widget.extend(/** @lends openerp.web.Database self.$option_id.find("form[name=restore_db_form]").validate({ submitHandler: function (form) { - $.blockUI({message:''}); + $.blockUI(); $(form).ajaxSubmit({ url: '/web/database/restore', type: 'POST', diff --git a/addons/web/static/src/js/core.js b/addons/web/static/src/js/core.js index ab0247e81b4..9563abea49a 100644 --- a/addons/web/static/src/js/core.js +++ b/addons/web/static/src/js/core.js @@ -1043,6 +1043,10 @@ openerp.web.TranslationDataBase = openerp.web.Class.extend(/** @lends openerp.we } }); +if ($.blockUI) { + $.blockUI.defaults.baseZ = 1100; + $.blockUI.defaults.message = ''; +} openerp.web._t = new openerp.web.TranslationDataBase().build_translation_function(); openerp.web.qweb = new QWeb2.Engine(); openerp.web.qweb.debug = (window.location.search.indexOf('?debug') !== -1); diff --git a/addons/web_dashboard/static/src/js/dashboard.js b/addons/web_dashboard/static/src/js/dashboard.js index 923b43ce034..b5f3b606d71 100644 --- a/addons/web_dashboard/static/src/js/dashboard.js +++ b/addons/web_dashboard/static/src/js/dashboard.js @@ -468,7 +468,7 @@ openerp.web_dashboard.ApplicationTiles = openerp.web.View.extend({ [['name', '=', module_name], ['state', '=', 'uninstalled']]); var Upgrade = new openerp.web.DataSet(this, 'base.module.upgrade'); - $.blockUI({message:''}); + $.blockUI(); Modules.read_slice(['id'], {}, function (records) { if (!(records.length === 1)) { $.unblockUI(); return; } Modules.call('state_update', From 9d4602fcb83c0499583b24feb11908ef3ea8c3cf Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Thu, 27 Oct 2011 14:54:48 +0200 Subject: [PATCH 138/163] [FIX] unfuck formatting of negative floats bzr revid: xmo@openerp.com-20111027125448-3wkk61xpt8uwjgt1 --- addons/web/static/src/js/formats.js | 10 ++-------- addons/web/static/test/formats.js | 2 ++ 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/addons/web/static/src/js/formats.js b/addons/web/static/src/js/formats.js index 3ab972f7a86..ca540844b7f 100644 --- a/addons/web/static/src/js/formats.js +++ b/addons/web/static/src/js/formats.js @@ -27,14 +27,8 @@ openerp.web.format_value = function (value, descriptor, value_if_empty) { return _.sprintf('%d', value); case 'float': var precision = descriptor.digits ? descriptor.digits[1] : 2; - var int_part = Math.floor(value); - var dec_part = _.sprintf( - '%.' + precision + 'f', - Math.abs(value) % 1).substring(2); - return _.sprintf('%d%s%s', - int_part, - openerp.web._t.database.parameters.decimal_point, - dec_part); + return _.sprintf('%.' + precision + 'f', value) + .replace('.', openerp.web._t.database.parameters.decimal_point); case 'float_time': return _.sprintf("%02d:%02d", Math.floor(value), diff --git a/addons/web/static/test/formats.js b/addons/web/static/test/formats.js index 3c3c6b06e72..8fc5abed42e 100644 --- a/addons/web/static/test/formats.js +++ b/addons/web/static/test/formats.js @@ -39,6 +39,8 @@ $(document).ready(function () { '1.000000'); equal(openerp.web.format_value(1, {type: 'float'}), '1.00'); + equal(openerp.web.format_value(-11.25, {type: 'float'}), + "-11.25"); }); test("parse_datetime", function () { var val = openerp.web.str_to_datetime("2009-05-04 12:34:23"); From 680f93f745e87f0e86946345d869cfaf9910be3b Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Thu, 27 Oct 2011 15:58:28 +0200 Subject: [PATCH 139/163] [IMP] display wait throbber/blockUI for network operations taking more than ~3s (aggregated) lp bug: https://launchpad.net/bugs/854017 fixed bzr revid: xmo@openerp.com-20111027135828-y1q85e8pq2uh3frz --- addons/web/static/src/js/chrome.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index 38923d268cf..484c58ef2c4 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -195,10 +195,20 @@ openerp.web.Loading = openerp.web.Widget.extend(/** @lends openerp.web.Loading# init: function(parent, element_id) { this._super(parent, element_id); this.count = 0; + this.blocked_ui = false; this.session.on_rpc_request.add_first(this.on_rpc_event, 1); this.session.on_rpc_response.add_last(this.on_rpc_event, -1); }, on_rpc_event : function(increment) { + var self = this; + if (!this.count && increment === 1) { + // Block UI after 3s + this.long_running_timer = setTimeout(function () { + self.blocked_ui = true; + $.blockUI(); + }, 3000); + } + this.count += increment; if (this.count) { //this.$element.html(QWeb.render("Loading", {})); @@ -206,6 +216,12 @@ openerp.web.Loading = openerp.web.Widget.extend(/** @lends openerp.web.Loading# this.$element.show(); this.widget_parent.$element.addClass('loading'); } else { + clearTimeout(this.long_running_timer); + // Don't unblock if blocked by somebody else + if (self.blocked_ui) { + this.blocked_ui = false; + $.unblockUI(); + } this.$element.fadeOut(); this.widget_parent.$element.removeClass('loading'); } From 5136b887714393231d0f8ce724e714f9e42247df Mon Sep 17 00:00:00 2001 From: Olivier Dony Date: Thu, 27 Oct 2011 16:45:30 +0200 Subject: [PATCH 140/163] [IMP] report_webkit: usability/views improvements bzr revid: odo@openerp.com-20111027144530-g0moe49ek3q3qf7e --- addons/report_webkit/header.py | 8 +++--- addons/report_webkit/header_view.xml | 39 ++++++++++++++-------------- addons/report_webkit/ir_report.py | 2 +- 3 files changed, 24 insertions(+), 25 deletions(-) diff --git a/addons/report_webkit/header.py b/addons/report_webkit/header.py index b8ff6fb2956..53252c5e245 100644 --- a/addons/report_webkit/header.py +++ b/addons/report_webkit/header.py @@ -33,7 +33,7 @@ from osv import fields, osv class HeaderHTML(osv.osv): """HTML Header allows you to define HTML CSS and Page format""" - + _name = "ir.header_webkit" _columns = { 'company_id' : fields.many2one('res.company', 'Company'), @@ -86,7 +86,7 @@ class HeaderHTML(osv.osv): required=True, help="Select Proper Paper size" ) - } + } HeaderHTML() class HeaderImage(osv.osv): @@ -97,5 +97,5 @@ class HeaderImage(osv.osv): 'img' : fields.binary('Image'), 'name' : fields.char('Name', size=128, required =True, help="Name of Image"), 'type' : fields.char('Type', size=32, required =True, help="Image type(png,gif,jpeg)") - } -HeaderImage() \ No newline at end of file + } +HeaderImage() diff --git a/addons/report_webkit/header_view.xml b/addons/report_webkit/header_view.xml index bc643a0a28c..267bc7cb0a4 100644 --- a/addons/report_webkit/header_view.xml +++ b/addons/report_webkit/header_view.xml @@ -6,24 +6,24 @@ form - - - - + + + + + - + res.company.header.html ir.header_webkit form
      - - - + + @@ -33,36 +33,35 @@ - - + + - - + + - - + +
      - + - Header IMG + Webkit Logos ir.header_img form tree,form - + - Header HTML + Webkit Headers/Footers ir.header_webkit form tree,form - - + diff --git a/addons/report_webkit/ir_report.py b/addons/report_webkit/ir_report.py index e5b4156a348..bca10b0d1d8 100644 --- a/addons/report_webkit/ir_report.py +++ b/addons/report_webkit/ir_report.py @@ -123,7 +123,7 @@ class ReportXML(osv.osv): 'ir.header_webkit', type='many2one', relation='ir.header_webkit', - string='WebKit Header', + string='Webkit Header', help="The header linked to the report", view_load=True, required=True From 8490a55722f4a3bd0658162539bc8283a2b5026a Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Thu, 27 Oct 2011 16:48:15 +0200 Subject: [PATCH 141/163] [IMP] procurement: faster computation by the scheduler. Original idea from Omar (Pexego) bzr revid: qdp-launchpad@openerp.com-20111027144815-l2m1jmkfpubh8g1q --- addons/procurement/schedulers.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/addons/procurement/schedulers.py b/addons/procurement/schedulers.py index 26abbc9868f..2aa47f69393 100644 --- a/addons/procurement/schedulers.py +++ b/addons/procurement/schedulers.py @@ -53,7 +53,7 @@ class procurement_order(osv.osv): procurement_obj = self.pool.get('procurement.order') if not ids: - ids = procurement_obj.search(cr, uid, [], order="date_planned") + ids = procurement_obj.search(cr, uid, [('state', '=', 'exception')], order="date_planned") for id in ids: wf_service.trg_validate(uid, 'procurement.order', id, 'button_restart', cr) if use_new_cursor: @@ -74,7 +74,7 @@ class procurement_order(osv.osv): else: offset += 1 report_later += 1 - for proc in procurement_obj.browse(cr, uid, ids, context=context): + if proc.state == 'exception': report.append(_('PROC %d: on order - %3.2f %-5s - %s') % \ (proc.id, proc.product_qty, proc.product_uom.name, @@ -97,12 +97,13 @@ class procurement_order(osv.osv): else: report_later += 1 report_total += 1 - for proc in procurement_obj.browse(cr, uid, report_ids, context=context): + if proc.state == 'exception': report.append(_('PROC %d: from stock - %3.2f %-5s - %s') % \ (proc.id, proc.product_qty, proc.product_uom.name, proc.product_id.name,)) report_except += 1 + if use_new_cursor: cr.commit() offset += len(ids) From 4223622f1f1c45d1cf2d2f97c457f489cd97675e Mon Sep 17 00:00:00 2001 From: Olivier Dony Date: Thu, 27 Oct 2011 17:08:09 +0200 Subject: [PATCH 142/163] [IMP] report_webkit: improved description and added hint about static lib on Linux bzr revid: odo@openerp.com-20111027150809-kynbj1ycwbzbfalg --- addons/report_webkit/__openerp__.py | 56 +++++++++++++++++------------ addons/report_webkit/company.py | 28 ++++++++------- 2 files changed, 49 insertions(+), 35 deletions(-) diff --git a/addons/report_webkit/__openerp__.py b/addons/report_webkit/__openerp__.py index bc67c78d628..52f03efaff7 100644 --- a/addons/report_webkit/__openerp__.py +++ b/addons/report_webkit/__openerp__.py @@ -38,38 +38,48 @@ This module adds a new Report Engine based on WebKit library (wkhtmltopdf) to su The module structure and some code is inspired by the report_openoffice module. The module allows: - -HTML report definition - -Multi header support - -Multi logo - -Multi company support - -HTML and CSS-3 support (In the limit of the actual WebKIT version) - -JavaScript support - -Raw HTML debugger - -Book printing capabilities - -Margins definition - -Paper size definition + + - HTML report definition + - Multi header support + - Multi logo + - Multi company support + - HTML and CSS-3 support (In the limit of the actual WebKIT version) + - JavaScript support + - Raw HTML debugger + - Book printing capabilities + - Margins definition + - Paper size definition ... and much more Multiple headers and logos can be defined per company. -CSS style, header and footer body are defined per company - -The library to install can be found here -http://code.google.com/p/wkhtmltopdf/ -The system libraries are available for Linux, Mac OS X i386 and Windows 32. - -After installing the wkhtmltopdf library on the OpenERP Server machine, you need to set the -path to the wkthtmltopdf executable file on the Company. +CSS style, header and footer body are defined per company. For a sample report see also the webkit_report_sample module, and this video: http://files.me.com/nbessi/06n92k.mov +Requirements and Installation +----------------------------- +This module requires the ``wkthtmltopdf`` library to render HTML documents as +PDF. Version 0.9.9 or later is necessary, and can be found at http://code.google.com/p/wkhtmltopdf/ +for Linux, Mac OS X (i386) and Windows (32bits). + +After installing the library on the OpenERP Server machine, you need to set the +path to the ``wkthtmltopdf`` executable file on each Company. + +If you are experiencing missing header/footer problems on Linux, be sure to +install a "static" version of the library. The default ``wkhtmltopdf`` on +Ubuntu is known to have this issue. + + +TODO +---- + + * JavaScript support activation deactivation + * Collated and book format support + * Zip return for separated PDF + * Web client WYSIWYG -TODO : -JavaScript support activation deactivation -Collated and book format support -Zip return for separated PDF -Web client WYSIWYG """, "version" : "0.9", "depends" : ["base"], diff --git a/addons/report_webkit/company.py b/addons/report_webkit/company.py index 82e9f406567..5b826617417 100644 --- a/addons/report_webkit/company.py +++ b/addons/report_webkit/company.py @@ -33,24 +33,28 @@ from osv import fields, osv class ResCompany(osv.osv): """Override company to add Header object link a company can have many header and logos""" - + _inherit = "res.company" _columns = { 'header_image' : fields.many2many( - 'ir.header_img', - 'company_img_rel', - 'company_id', - 'img_id', + 'ir.header_img', + 'company_img_rel', + 'company_id', + 'img_id', 'Available Images', ), 'header_webkit' : fields.many2many( - 'ir.header_webkit', - 'company_html_rel', - 'company_id', - 'html_id', + 'ir.header_webkit', + 'company_html_rel', + 'company_id', + 'html_id', 'Available html', ), - 'lib_path' : fields.char('Webkit Executable Path', size=264, help="Complete (Absolute) path to the wkhtmltopdf executable."), + 'lib_path' : fields.char('Webkit Executable Path', size=264, + help="Full path to the wkhtmltopdf executable file. " + "Version 0.9.9 is required. Install a static version " + "of the library if you experience missing header/footers " + "on Linux."), - } -ResCompany() \ No newline at end of file + } +ResCompany() From 2944108e6e94de72b22b0fb73f85bf2a5c9810f0 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Thu, 27 Oct 2011 17:41:41 +0200 Subject: [PATCH 143/163] [FIX] Kanban: restore dataset index after search bzr revid: fme@openerp.com-20111027154141-j58em72ngc8pt1hq --- addons/web_kanban/static/src/js/kanban.js | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index 8e222ebe8d9..a58a94fc6c7 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -485,6 +485,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ self.dataset.ids.push.apply(self.dataset.ids, dataset.ids); self.all_display_data[index] = {"value" : group_value, "records" : records, 'header' : group_name, 'ids' : dataset.ids, 'aggregates' : group_aggregates}; if (!remaining--) { + self.dataset.index = self.dataset.ids.length ? 0 : null; self.on_show_data(); } }); From 0e6a72cb8db2fad7ff661ca16cac424a0a0ad4a1 Mon Sep 17 00:00:00 2001 From: Fabien Meghazi Date: Thu, 27 Oct 2011 18:01:51 +0200 Subject: [PATCH 144/163] [IMP] Kanban: Added white and gray colors. Color#0 (white) is the default color bzr revid: fme@openerp.com-20111027160151-2yet6p62l1xsb99c --- addons/web_kanban/static/src/css/kanban.css | 68 ++++++++++++------- addons/web_kanban/static/src/js/kanban.js | 7 +- .../web_kanban/static/src/xml/web_kanban.xml | 2 +- 3 files changed, 50 insertions(+), 27 deletions(-) diff --git a/addons/web_kanban/static/src/css/kanban.css b/addons/web_kanban/static/src/css/kanban.css index 712ebf1fa1c..d7c27510f4d 100644 --- a/addons/web_kanban/static/src/css/kanban.css +++ b/addons/web_kanban/static/src/css/kanban.css @@ -134,91 +134,113 @@ } /* Custom colors are also present in kanban.js */ +/* Custom color#0 */ +.openerp .oe_kanban_color_0 .oe_kanban_color_bglight { + background: #FFFFFF; +} +.openerp .oe_kanban_color_0 .oe_kanban_color_bgdark { + background: #EEEEEE; +} +.openerp .oe_kanban_color_0 .oe_kanban_color_border { + border-color: #CCCCCC; +} + /* Custom color#1 */ .openerp .oe_kanban_color_1 .oe_kanban_color_bglight { - background: #FFC7C7; + background: #CCCCCC; } .openerp .oe_kanban_color_1 .oe_kanban_color_bgdark { - background: #FF8F8F; + background: #999999; } .openerp .oe_kanban_color_1 .oe_kanban_color_border { - border-color: #D97979; + border-color: #666666; } /* Custom color#2 */ .openerp .oe_kanban_color_2 .oe_kanban_color_bglight { - background: #FFF1C7; + background: #FFC7C7; } .openerp .oe_kanban_color_2 .oe_kanban_color_bgdark { - background: #FFE38F; + background: #FF8F8F; } .openerp .oe_kanban_color_2 .oe_kanban_color_border { - border-color: #D9C179; + border-color: #D97979; } /* Custom color#3 */ .openerp .oe_kanban_color_3 .oe_kanban_color_bglight { - background: #E3FFC7; + background: #FFF1C7; } .openerp .oe_kanban_color_3 .oe_kanban_color_bgdark { - background: #C7FF8F; + background: #FFE38F; } .openerp .oe_kanban_color_3 .oe_kanban_color_border { - border-color: #A9D979; + border-color: #D9C179; } /* Custom color#4 */ .openerp .oe_kanban_color_4 .oe_kanban_color_bglight { - background: #C7FFD5; + background: #E3FFC7; } .openerp .oe_kanban_color_4 .oe_kanban_color_bgdark { - background: #8FFFAB; + background: #C7FF8F; } .openerp .oe_kanban_color_4 .oe_kanban_color_border { - border-color: #79D991; + border-color: #A9D979; } /* Custom color#5 */ .openerp .oe_kanban_color_5 .oe_kanban_color_bglight { - background: #C7FFFF; + background: #C7FFD5; } .openerp .oe_kanban_color_5 .oe_kanban_color_bgdark { - background: #8FFFFF; + background: #8FFFAB; } .openerp .oe_kanban_color_5 .oe_kanban_color_border { - border-color: #79D9D9; + border-color: #79D991; } /* Custom color#6 */ .openerp .oe_kanban_color_6 .oe_kanban_color_bglight { - background: #C7D5FF; + background: #C7FFFF; } .openerp .oe_kanban_color_6 .oe_kanban_color_bgdark { - background: #8FABFF; + background: #8FFFFF; } .openerp .oe_kanban_color_6 .oe_kanban_color_border { - border-color: #8FABFF; + border-color: #79D9D9; } /* Custom color#7 */ .openerp .oe_kanban_color_7 .oe_kanban_color_bglight { - background: #E3C7FF; + background: #C7D5FF; } .openerp .oe_kanban_color_7 .oe_kanban_color_bgdark { - background: #C78FFF; + background: #8FABFF; } .openerp .oe_kanban_color_7 .oe_kanban_color_border { - border-color: #A979D9; + border-color: #8FABFF; } /* Custom color#8 */ .openerp .oe_kanban_color_8 .oe_kanban_color_bglight { - background: #FFC7F1; + background: #E3C7FF; } .openerp .oe_kanban_color_8 .oe_kanban_color_bgdark { - background: #FF8FE3; + background: #C78FFF; } .openerp .oe_kanban_color_8 .oe_kanban_color_border { + border-color: #A979D9; +} + +/* Custom color#9 */ +.openerp .oe_kanban_color_9 .oe_kanban_color_bglight { + background: #FFC7F1; +} +.openerp .oe_kanban_color_9 .oe_kanban_color_bgdark { + background: #FF8FE3; +} +.openerp .oe_kanban_color_9 .oe_kanban_color_border { border-color: #D979C1; } diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index a58a94fc6c7..13d3c9203fc 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -61,7 +61,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ } }, kanban_color: function(variable) { - var number_of_color_schemes = 8, + var number_of_color_schemes = 10, index = 0; switch (typeof(variable)) { case 'string': @@ -75,7 +75,8 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ default: return ''; } - return 'oe_kanban_color_' + ((index % number_of_color_schemes) || number_of_color_schemes); + var color = (index % number_of_color_schemes); + return 'oe_kanban_color_' + color; }, kanban_gravatar: function(email, size) { size = size || 22; @@ -222,7 +223,7 @@ openerp.web_kanban.KanbanView = openerp.web.View.extend({ do_change_color: function(record_id, $e) { var self = this, id = record_id, - colors = '#FFC7C7,#FFF1C7,#E3FFC7,#C7FFD5,#C7FFFF,#C7D5FF,#E3C7FF,#FFC7F1'.split(','), + colors = '#FFFFFF,#CCCCCC,#FFC7C7,#FFF1C7,#E3FFC7,#C7FFD5,#C7FFFF,#C7D5FF,#E3C7FF,#FFC7F1'.split(','), $cpicker = $(QWeb.render('KanbanColorPicker', { colors : colors, columns: 2 })); $e.after($cpicker); $cpicker.mouseenter(function() { diff --git a/addons/web_kanban/static/src/xml/web_kanban.xml b/addons/web_kanban/static/src/xml/web_kanban.xml index 8f3aaf457e9..8281352cc15 100644 --- a/addons/web_kanban/static/src/xml/web_kanban.xml +++ b/addons/web_kanban/static/src/xml/web_kanban.xml @@ -34,7 +34,7 @@
      - +