From 9668e5735d12e6b5073ea059283c0587e00b4967 Mon Sep 17 00:00:00 2001 From: "mga@tinyerp.com" <> Date: Tue, 26 Aug 2008 16:07:28 +0530 Subject: [PATCH 01/10] change in the currency records assign company_id to all currency bzr revid: mga@tinyerp.com-20080826103728-rn1houo7h7tqqlu5 --- bin/addons/base/base_data.xml | 44 +++++++++++++++++++++++++---------- 1 file changed, 32 insertions(+), 12 deletions(-) diff --git a/bin/addons/base/base_data.xml b/bin/addons/base/base_data.xml index a087ad4d620..c77b6832179 100644 --- a/bin/addons/base/base_data.xml +++ b/bin/addons/base/base_data.xml @@ -1275,7 +1275,7 @@ default - + EUR @@ -1289,11 +1289,26 @@ + + + Tiny sprl + + Free Business Solutions + Web: http://tiny.be - Tel: (+32).81.81.37.00 - Bank: CPH 126-2013269-07 + IBAN: BE74 1262 0132 6907 - SWIFT: GKCCBEBB - VAT: BE0477.472.701 + + + + + + + USD USD 0.01 4 + 1.3785 @@ -1306,6 +1321,7 @@ VEB 2.95 4 + 1.0 @@ -1313,12 +1329,12 @@ - CAD CAD 0.01 4 + 1.451 @@ -1332,6 +1348,7 @@ CHF 0.01 4 + 1.644 @@ -1344,6 +1361,7 @@ BRL 0.01 4 + 2.588 @@ -1356,6 +1374,7 @@ CNY 0.01 4 + 10.4311 @@ -1370,6 +1389,7 @@ 0.01 4 + @@ -1378,6 +1398,7 @@ 0.01 4 + @@ -1385,6 +1406,7 @@ DKK 0.01 4 + 7.4416 @@ -1399,6 +1421,7 @@ 0.01 4 + @@ -1407,6 +1430,7 @@ 0.01 4 + @@ -1414,6 +1438,7 @@ LVL 0.01 4 + 0.71 @@ -1427,6 +1452,7 @@ NOK 0.01 4 + 7.93 @@ -1440,6 +1466,7 @@ PAB 0.01 4 + 1.3813 @@ -1462,6 +1489,7 @@ 0.01 4 + @@ -1469,6 +1497,7 @@ GBP 0.01 4 + 0.675 @@ -1482,16 +1511,7 @@ 0.01 4 - - - - - Tiny sprl - - Free Business Solutions - Web: http://tiny.be - Tel: (+32).81.81.37.00 - Bank: CPH 126-2013269-07 - IBAN: BE74 1262 0132 6907 - SWIFT: GKCCBEBB - VAT: BE0477.472.701 - + From 9dbb510f723def13d8e5cdcf2ea1c2c5f4455888 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Wed, 27 Aug 2008 00:18:07 +0200 Subject: [PATCH 02/10] Module View Improved bzr revid: fp@tinyerp.com-20080826221807-34tecagv6jq1c112 --- bin/addons/base/module/module_view.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/addons/base/module/module_view.xml b/bin/addons/base/module/module_view.xml index a482a8ee2e3..f3df21aa3af 100644 --- a/bin/addons/base/module/module_view.xml +++ b/bin/addons/base/module/module_view.xml @@ -104,7 +104,7 @@ ir.module.module tree - + From f6c6b99bca04777668b6a0380107c5e51c659344 Mon Sep 17 00:00:00 2001 From: "hda@tinyerp.com" <> Date: Wed, 27 Aug 2008 14:42:12 +0530 Subject: [PATCH 03/10] remove with reserve keyword warning bzr revid: hda@tinyerp.com-20080827091212-3wimc8s3l99ws8ll --- bin/reportlab/lib/PyFontify.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/reportlab/lib/PyFontify.py b/bin/reportlab/lib/PyFontify.py index 309f7740df9..27695c25620 100644 --- a/bin/reportlab/lib/PyFontify.py +++ b/bin/reportlab/lib/PyFontify.py @@ -32,8 +32,8 @@ import re # First a little helper, since I don't like to repeat things. (Tismer speaking) import string -def replace(where, what, with): - return string.join(string.split(where, what), with) +def replace(where, what, with_whom): + return string.join(string.split(where, what), with_whom) # This list of keywords is taken from ref/node13.html of the # Python 1.3 HTML documentation. ("access" is intentionally omitted.) From 3e58142a3ff2223b9148f49706d082fe271255d7 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Wed, 27 Aug 2008 22:52:29 +0200 Subject: [PATCH 04/10] Improved View bzr revid: fp@tinyerp.com-20080827205229-rrfglsnjfh5v3s9z --- bin/addons/base/res/partner/partner_view.xml | 30 ++++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/bin/addons/base/res/partner/partner_view.xml b/bin/addons/base/res/partner/partner_view.xml index 9f625f1c2f4..8fb50b1266e 100644 --- a/bin/addons/base/res/partner/partner_view.xml +++ b/bin/addons/base/res/partner/partner_view.xml @@ -203,11 +203,11 @@
- - - + + + @@ -249,6 +249,7 @@ + @@ -279,7 +280,11 @@ - + Customers Partners @@ -469,8 +474,8 @@ [('parent_id','=',False)] - - + + res.partner @@ -486,19 +491,14 @@ - - - - + - Partner categories + Partner Categories ir.actions.act_window res.partner.category form - - - - + + From 3db26f6faede48a2b3a4500bbaa4009ca5c57864 Mon Sep 17 00:00:00 2001 From: qdp Date: Thu, 28 Aug 2008 16:51:49 +0200 Subject: [PATCH 05/10] *bugfix bzr revid: qdp@tinyerp.com-20080828145149-dh19rsr6brb5w978 --- bin/osv/expression.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/osv/expression.py b/bin/osv/expression.py index d95852d4f35..01964196bd1 100644 --- a/bin/osv/expression.py +++ b/bin/osv/expression.py @@ -203,6 +203,8 @@ class expression(object): return self def __leaf_to_sql(self, leaf, table): + if leaf == self.__DUMMY_LEAF: + return ('(1=1)',[]) left, operator, right = leaf if operator == 'inselect': From a17c3d9a9215f5d0871dcd5c0a2d1faa4881885d Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Fri, 29 Aug 2008 01:46:26 +0200 Subject: [PATCH 06/10] Modifs bzr revid: fp@tinyerp.com-20080828234626-ivly8jjy3nveziqn --- bin/addons/base/base_update.xml | 47 ++++++++++++++++++--------------- 1 file changed, 26 insertions(+), 21 deletions(-) diff --git a/bin/addons/base/base_update.xml b/bin/addons/base/base_update.xml index acc9d9fd4cd..fbc24121f9c 100644 --- a/bin/addons/base/base_update.xml +++ b/bin/addons/base/base_update.xml @@ -38,17 +38,16 @@ form - - - - - + + + + - + - - + + @@ -59,7 +58,11 @@ - + + + + + @@ -94,12 +97,12 @@ form
- + + + + + - - - - @@ -108,9 +111,11 @@ - - - + + + + + @@ -139,11 +144,11 @@ form
- + + + + - - - From a28dfb7167b87b6ee106471b6bed1f6380dce8d3 Mon Sep 17 00:00:00 2001 From: "mga@tinyerp.com" <> Date: Fri, 29 Aug 2008 14:03:08 +0530 Subject: [PATCH 07/10] remove currency changes bzr revid: mga@tinyerp.com-20080829083308-ofvyxzc7av6dnp54 --- bin/addons/base/base_update.xml | 3 --- 1 file changed, 3 deletions(-) diff --git a/bin/addons/base/base_update.xml b/bin/addons/base/base_update.xml index 6aff96885c3..f47c75a247a 100644 --- a/bin/addons/base/base_update.xml +++ b/bin/addons/base/base_update.xml @@ -151,9 +151,6 @@ - - - From ad81b6b767b1936a2a1c6961e81347d4479ec89c Mon Sep 17 00:00:00 2001 From: "mga@tinyerp.com" <> Date: Fri, 29 Aug 2008 14:04:34 +0530 Subject: [PATCH 08/10] remove changes for the currency from the trunk bzr revid: mga@tinyerp.com-20080829083434-2qkjzheuwmg24rz5 --- bin/addons/base/res/res_company.py | 1 - bin/addons/base/res/res_currency.py | 1 - bin/addons/base/res/res_currency_view.xml | 3 +-- 3 files changed, 1 insertion(+), 4 deletions(-) diff --git a/bin/addons/base/res/res_company.py b/bin/addons/base/res/res_company.py index ca5daaf203e..f7e6f94c342 100644 --- a/bin/addons/base/res/res_company.py +++ b/bin/addons/base/res/res_company.py @@ -46,7 +46,6 @@ class res_company(osv.osv): 'rml_header2' : fields.text('RML Internal Header'), 'logo' : fields.binary('Logo'), 'currency_id': fields.many2one('res.currency', 'Currency', required=True), - 'currency_ids': fields.one2many('res.currency', 'company_id', 'Currency Rates'), } def _get_child_ids(self, cr, uid, uid2, context={}): diff --git a/bin/addons/base/res/res_currency.py b/bin/addons/base/res/res_currency.py index 7de0c9d769d..05541689154 100644 --- a/bin/addons/base/res/res_currency.py +++ b/bin/addons/base/res/res_currency.py @@ -64,7 +64,6 @@ class res_currency(osv.osv): 'accuracy': fields.integer('Computational Accuracy'), 'rounding': fields.float('Rounding factor', digits=(12,6)), 'active': fields.boolean('Active'), - 'company_id' : fields.many2one('res.company', 'Company'), } _defaults = { 'active': lambda *a: 1, diff --git a/bin/addons/base/res/res_currency_view.xml b/bin/addons/base/res/res_currency_view.xml index cc804d8b80e..ccd75eabf7f 100644 --- a/bin/addons/base/res/res_currency_view.xml +++ b/bin/addons/base/res/res_currency_view.xml @@ -23,8 +23,7 @@ form - - + From 99064200930c5fd6d46f2d6a44dbc7a0b879b8d3 Mon Sep 17 00:00:00 2001 From: "mga@tinyerp.com" <> Date: Mon, 1 Sep 2008 17:18:01 +0530 Subject: [PATCH 09/10] * small change in the implementation of the object_create method * change the condition in view bzr revid: mga@tinyerp.com-20080901114801-6fe3wxchh5rq1o8o --- bin/addons/base/ir/ir.xml | 8 ++++---- bin/addons/base/ir/ir_actions.py | 18 ++++++++++++------ 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/bin/addons/base/ir/ir.xml b/bin/addons/base/ir/ir.xml index 2492f70d37d..d16402f9bc7 100755 --- a/bin/addons/base/ir/ir.xml +++ b/bin/addons/base/ir/ir.xml @@ -1066,15 +1066,15 @@ - + - + - + - + diff --git a/bin/addons/base/ir/ir_actions.py b/bin/addons/base/ir/ir_actions.py index 38a30888929..78abfa54ed0 100755 --- a/bin/addons/base/ir/ir_actions.py +++ b/bin/addons/base/ir/ir_actions.py @@ -385,7 +385,7 @@ class actions_server(osv.osv): 'otype': fields.selection([ ('copy','Create in Same Model'), ('new','Create in Other Model') - ], 'Create Model', required=True, size=32, change_default=True), + ], 'Create Model', size=32, change_default=True), } _defaults = { 'state': lambda *a: 'dummy', @@ -399,7 +399,8 @@ class actions_server(osv.osv): # - uid # - ids # If you plan to return an action, assign: action = {...} -""" +""", + 'otype': lambda *a: 'copy', } def get_field_value(self, cr, uid, action, context): @@ -496,7 +497,6 @@ class actions_server(osv.osv): logger.notifyChannel('sms', netsvc.LOG_INFO, 'SMS successfully send to : %s' % (action.address)) else: logger.notifyChannel('sms', netsvc.LOG_ERROR, 'Failed to send SMS to : %s' % (action.address)) - if action.state == 'other': localdict = { 'self': self.pool.get(action.model_id.model), @@ -535,9 +535,15 @@ class actions_server(osv.osv): else: expr = exp.value res[exp.col1.name] = expr - obj_pool = self.pool.get(action.model_id.model) - id = context.get('active_id') - obj_pool.copy(cr, uid, id, res) + + obj_pool = None + if action.state == 'object_create' and action.otype == 'new': + obj_pool = self.pool.get(action.srcmodel_id.model) + obj_pool.create(cr, uid, res) + else: + obj_pool = self.pool.get(action.model_id.model) + id = context.get('active_id') + obj_pool.copy(cr, uid, id, res) return False actions_server() From 51fe0efd169cb022102f8734536f6075fce5a1b5 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Mon, 1 Sep 2008 21:29:02 +0200 Subject: [PATCH 10/10] Small bugfixes bzr revid: fp@tinyerp.com-20080901192902-zftoynk3cxktmbn9 --- bin/addons/base/module/module.py | 2 +- bin/addons/base/module/module_wizard.xml | 4 ++-- bin/osv/orm.py | 5 ++--- bin/tools/translate.py | 2 ++ 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/bin/addons/base/module/module.py b/bin/addons/base/module/module.py index ceb454d40fa..21ca01f9d1f 100644 --- a/bin/addons/base/module/module.py +++ b/bin/addons/base/module/module.py @@ -275,7 +275,7 @@ class module(osv.osv): mdemo = True for dep in module.dependencies_id: if dep.state == 'unknown': - raise orm.except_orm(_('Error'), _('Unmet dependency: %s') % (dep.name,)) + raise orm.except_orm(_('Error'), _('You try to install a module that depends on the module: %s.\nBut this module is not available in your system.') % (dep.name,)) if dep.state != newstate: ids2 = self.search(cr, uid, [('name','=',dep.name)]) mdemo = self.state_update(cr, uid, ids2, newstate, states_to_update, context, level-1,) and mdemo diff --git a/bin/addons/base/module/module_wizard.xml b/bin/addons/base/module/module_wizard.xml index 536b2f01648..7c091353f39 100644 --- a/bin/addons/base/module/module_wizard.xml +++ b/bin/addons/base/module/module_wizard.xml @@ -31,8 +31,8 @@ - - + +