Merge lp:~unifield-team/unifield-server/uf_1075_usability_requirements into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 3406
Proposed branch: lp:~unifield-team/unifield-server/uf_1075_usability_requirements
Merge into: lp:unifield-server
Diff against target: 93 lines (+13/-6)
4 files modified
bin/addons/__init__.py (+4/-1)
bin/addons/base/ir/ir_values.py (+5/-3)
bin/osv/orm.py (+0/-1)
bin/tools/config.py (+4/-1)
To merge this branch: bzr merge lp:~unifield-team/unifield-server/uf_1075_usability_requirements
Reviewer Review Type Date Requested Status
UniField Dev Team Pending
Review via email: mp+114847@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'bin/addons/__init__.py'
--- bin/addons/__init__.py 2011-01-27 09:56:54 +0000
+++ bin/addons/__init__.py 2012-07-13 12:06:07 +0000
@@ -665,7 +665,7 @@
665665
666 def load_test(cr, module_name, id_map, mode):666 def load_test(cr, module_name, id_map, mode):
667 cr.commit()667 cr.commit()
668 if not tools.config.options['test_disable']:668 if not tools.config.options['test_disable'] and (not tools.config.options['test_module'] or module_name in tools.config.options['test_module'].split(',')):
669 try:669 try:
670 _load_data(cr, module_name, id_map, mode, 'test')670 _load_data(cr, module_name, id_map, mode, 'test')
671 except Exception, e:671 except Exception, e:
@@ -776,6 +776,9 @@
776 for kind in ('init', 'demo', 'update'):776 for kind in ('init', 'demo', 'update'):
777 if hasattr(package, kind):777 if hasattr(package, kind):
778 delattr(package, kind)778 delattr(package, kind)
779
780 elif (hasattr(package, 'demo') or package.dbdemo) and tools.config.options['test_module'] and m in tools.config.options['test_module'].split(','):
781 load_test(cr, m, idref, mode)
779782
780 statusi += 1783 statusi += 1
781784
782785
=== modified file 'bin/addons/base/ir/ir_values.py'
--- bin/addons/base/ir/ir_values.py 2010-12-06 13:19:28 +0000
+++ bin/addons/base/ir/ir_values.py 2012-07-13 12:06:07 +0000
@@ -85,12 +85,14 @@
85 method=True, type='text', string='Metadata'),85 method=True, type='text', string='Metadata'),
86 'res_id': fields.integer('Object ID', help="Keep 0 if the action must appear on all resources.", select=True),86 'res_id': fields.integer('Object ID', help="Keep 0 if the action must appear on all resources.", select=True),
87 'user_id': fields.many2one('res.users', 'User', ondelete='cascade', select=True),87 'user_id': fields.many2one('res.users', 'User', ondelete='cascade', select=True),
88 'company_id': fields.many2one('res.company', 'Company', select=True)88 'company_id': fields.many2one('res.company', 'Company', select=True),
89 'sequence': fields.integer('Sequence'),
89 }90 }
90 _defaults = {91 _defaults = {
91 'key': lambda *a: 'action',92 'key': lambda *a: 'action',
92 'key2': lambda *a: 'tree_but_open',93 'key2': lambda *a: 'tree_but_open',
93 'company_id': lambda *a: False94 'company_id': lambda *a: False,
95 'sequence': lambda *a: 100,
94 }96 }
9597
96 def _auto_init(self, cr, context=None):98 def _auto_init(self, cr, context=None):
@@ -173,7 +175,7 @@
173 where.append('res_id=%s')175 where.append('res_id=%s')
174 params.append(res_id)176 params.append(res_id)
175177
176 where.append('(user_id=%s or (user_id IS NULL)) order by id')178 where.append('(user_id=%s or (user_id IS NULL)) order by sequence,id')
177 params.append(uid)179 params.append(uid)
178 clause = ' and '.join(where)180 clause = ' and '.join(where)
179 cr.execute('select id,name,value,object,meta, key from ir_values where ' + clause, params)181 cr.execute('select id,name,value,object,meta, key from ir_values where ' + clause, params)
180182
=== modified file 'bin/osv/orm.py'
--- bin/osv/orm.py 2012-07-13 06:02:27 +0000
+++ bin/osv/orm.py 2012-07-13 12:06:07 +0000
@@ -1703,7 +1703,6 @@
1703 resaction = ir_values_obj.get(cr, user, 'action',1703 resaction = ir_values_obj.get(cr, user, 'action',
1704 'client_action_multi', [(self._name, False)], False,1704 'client_action_multi', [(self._name, False)], False,
1705 context)1705 context)
1706
1707 resrelate = ir_values_obj.get(cr, user, 'action',1706 resrelate = ir_values_obj.get(cr, user, 'action',
1708 'client_action_relate', [(self._name, False)], False,1707 'client_action_relate', [(self._name, False)], False,
1709 context)1708 context)
17101709
=== modified file 'bin/tools/config.py'
--- bin/tools/config.py 2012-06-20 08:49:14 +0000
+++ bin/tools/config.py 2012-07-13 12:06:07 +0000
@@ -88,6 +88,7 @@
88 'test_file' : False,88 'test_file' : False,
89 'test_report_directory' : False,89 'test_report_directory' : False,
90 'test_disable' : False,90 'test_disable' : False,
91 'test_module' : False,
91 'test_commit' : False,92 'test_commit' : False,
92 'static_http_enable': False,93 'static_http_enable': False,
93 'static_http_document_root': None,94 'static_http_document_root': None,
@@ -171,6 +172,8 @@
171 group.add_option("--test-report-directory", dest="test_report_directory", help="If set, will save sample of all reports in this directory.")172 group.add_option("--test-report-directory", dest="test_report_directory", help="If set, will save sample of all reports in this directory.")
172 group.add_option("--test-disable", action="store_true", dest="test_disable",173 group.add_option("--test-disable", action="store_true", dest="test_disable",
173 default=False, help="Disable loading test files.")174 default=False, help="Disable loading test files.")
175 group.add_option("--test-module", dest="test_module",
176 default=False, help="module to test")
174 group.add_option("--test-commit", action="store_true", dest="test_commit",177 group.add_option("--test-commit", action="store_true", dest="test_commit",
175 default=False, help="Commit database changes performed by tests.")178 default=False, help="Commit database changes performed by tests.")
176 parser.add_option_group(group)179 parser.add_option_group(group)
@@ -315,7 +318,7 @@
315 'debug_mode', 'smtp_ssl', 'load_language',318 'debug_mode', 'smtp_ssl', 'load_language',
316 'stop_after_init', 'logrotate', 'without_demo', 'netrpc', 'xmlrpc', 'syslog',319 'stop_after_init', 'logrotate', 'without_demo', 'netrpc', 'xmlrpc', 'syslog',
317 'list_db', 'xmlrpcs',320 'list_db', 'xmlrpcs',
318 'test_file', 'test_disable', 'test_commit', 'test_report_directory',321 'test_file', 'test_disable', 'test_commit', 'test_module', 'test_report_directory',
319 'osv_memory_count_limit', 'osv_memory_age_limit',322 'osv_memory_count_limit', 'osv_memory_age_limit',
320 ]323 ]
321324

Subscribers

People subscribed via source and target branches

to all changes: