The proposal to merge lp:~openerp-dev/openobject-server/trunk-cleanup-ir-values into lp:openobject-server has been updated.
Description changed to: = Summary = While looking for a fix for bug 817430, we figured it was time to start improving our ir.values internal model. This internal model has always been a mess. Lately it is still used for two things: storing user-defined default values, and binding actions to certain 'action slots' in the UI (mostly wizards, reports, and related links visible in the sidebar for each model). The model definition is totally opaque and cryptic (column names like key2, key, object, ..), and their API is not better, with two generic methods (get/set), just as opaque and cryptic. This branch is a first step towards a clean refactoring, requiring minimal backend and API change while at the same time providing an implicit fix for 817430 and preparing for a better future == Proposed fix == Ideally, we should have separate models with their own clean and specific API: one for storing user defaults, and one for storing action bindings (for example: ir.user.defaults and ir.actions.bindings) This could be the next step. Until then, this branch attempts to preserve the current API for perfect backwards-compatibility, does not require any migration, but introduces two separate APIs and underlying implementations for the two aspects: default vs. action bindings, and fixes bug 817430 in the process. == Implementation notes == The main changes are: - obsolete columns have been removed totally from ir.values (the meta* stuff, and the object column) - existing columns have been documented, but preserved - the set() and get() methods are deprecated, and internally delegate their tasks to the new set_action/get_actions and set_default/get_defaults. - the API is now documented - the administration UI for ir.values has been split in 2: defaults and action bindings now have their own menus and views == Tests == - the existing YAML tests for ir.values have been extended to cover smoke-testing for both defaults and action bindings - the tests do not use the newer API directly yet, but they do so indirectly because the old API relies on the new implementation now == Next steps == 1. The rest of the server code (and clients) should be adapted progressively to use the new API, but that does not need to happen immediately. 2. For next version we should split everything properly into separate models. There is already an rudimentary and unused "ir.defaults" model lying around, but it's not clean enough - should be removed/refactored in the process. For more details, see: https://code.launchpad.net/~openerp-dev/openobject-server/trunk-cleanup-ir-values/+merge/73809 -- https://code.launchpad.net/~openerp-dev/openobject-server/trunk-cleanup-ir-values/+merge/73809 Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-server/trunk-cleanup-ir-values. _______________________________________________ Mailing list: https://launchpad.net/~openerp-dev-gtk Post to : [email protected] Unsubscribe : https://launchpad.net/~openerp-dev-gtk More help : https://help.launchpad.net/ListHelp

