Commit Graph

20 Commits

Author SHA1 Message Date
Thibault Delavallée 54933118a4 [MERGE] Sync with trunk until revision 4957.
bzr revid: tde@openerp.com-20131002133820-8xomdumexexqp3pk
2013-10-02 15:38:20 +02:00
Christophe Simonis e9980e8725 [FIX] test_views: update matching error message
bzr revid: chs@openerp.com-20130918212216-libtu7zpsn2768j0
2013-09-18 23:22:16 +02:00
Christophe Simonis 7081038378 [IMP] validate custom views at the end of update of database
bzr revid: chs@openerp.com-20130912182926-3lectt8mvd9smwfb
2013-09-12 20:29:26 +02:00
Christophe Simonis 1d91378ce2 [FIX] ir.ui.view: properly validate newly created inheriting views
When a new inheriting view is imported during a module
    installation, it is validated thanks to the _constraints
    on the ir.ui.view model. However the validation uses
    a rather convoluted system for validating the whole
    view tree at once (root view + all inherited changes)
    while only taking into account the views that belong
    to modules that are currently loaded.

    This complicated system is necessary to be able to
    operate on-the-fly at any point during the registry
    loading/initialization.

    Now because _constraints are checked during create()
    this particular validation happens *before* the
    external ID (ir.model.data entry) of that new view
    can be created (it obviously needs to wait until
    the view record is inserted). As a consequence the
    view validation cannot determine the module to
    which that new view belongs, and was erroneously
    ignoring it.
    Changing the view filtering to also include views
    that have triggered this check.
    Manually created views are not check during registry
    update.

bzr revid: chs@openerp.com-20130912141018-qmcyase8zqov9d01
2013-09-12 16:10:18 +02:00
Xavier Morel 85a3d8eaeb [FIX] moved view.save to website, forgot to move tests
bzr revid: xmo@openerp.com-20130910132638-2v4ilmi5uuboazt9
2013-09-10 15:26:38 +02:00
Xavier Morel db5e36efa3 [FIX] rewrite ir_ui_view.save with new semantics, xpath fixes
since lxml provides built-in tools to generate the path for a node in a tree, don't reimplement it manually

bzr revid: xmo@openerp.com-20130812074509-yopeb4pxtsads4d9
2013-08-12 09:45:09 +02:00
Vo Minh Thu 7786d96095 [FIX] ir_ui_view: restore the inheritance mechanism for model-specific inheritance:
A view for a given model can inherit from a root view specified for
another model. When applying the modifying views to the root view,
only the views with the same model as the child view must be
considered. This patch restore that behavior.

bzr revid: vmt@openerp.com-20130701145334-ojp1plqjveym7cj7
2013-07-01 16:53:34 +02:00
Vo Minh Thu f42bcfa0f8 [FIX] ir_ui_view: does no longer provide root_ancestor(), so removed corresponding test.
bzr revid: vmt@openerp.com-20130701114129-03jtrx0g6abk6xev
2013-07-01 13:41:29 +02:00
Vo Minh Thu 3b4ecbf033 [FIX] ir_ui_view: it seems the iter() method is no longer there, removed the test..
bzr revid: vmt@openerp.com-20130701112930-k8rhlvgbaj1y1zl5
2013-07-01 13:29:30 +02:00
Vo Minh Thu aba5593f01 [FIX] ir_ui_view: get_inheriting_views_arch() does no longer take a model.
bzr revid: vmt@openerp.com-20130701112726-600dsa9udm0rt4uj
2013-07-01 13:27:26 +02:00
Vo Minh Thu bd4f503b9b [FIX] ir_ui_view: __view_look_dom_arch() was renamed into postprocess_and_fields().
bzr revid: vmt@openerp.com-20130701110521-muec7xyt7op7bhql
2013-07-01 13:05:21 +02:00
Vo Minh Thu 9ad26be680 [FIX] ir_ui_view: accomodate previously changed apply_inheritance_specs() signature.
bzr revid: vmt@openerp.com-20130701105107-thsi2o2pmeifo338
2013-07-01 12:51:07 +02:00
Xavier Morel a65419b042 [IMP] add tests for apply_inheritance_specs error reporting (to improve later, eg by removing cr, uid, context, ...)
bzr revid: xmo@openerp.com-20130625102800-qpw6m9m5cib1qvu8
2013-06-25 12:28:00 +02:00
Xavier Morel b3ade05f11 [ADD] basic tests on application of inheritance specs
bzr revid: xmo@openerp.com-20130625084857-k72kpvdrvejfragb
2013-06-25 10:48:57 +02:00
Xavier Morel 65e95dae49 [FIX] view inheritance tests: generate valid architectures
bzr revid: xmo@openerp.com-20130625060041-pfgdrnawfwuts2rj
2013-06-25 08:00:41 +02:00
Antony Lesuisse ca163b58db fix check_xml, disable wrong tests
bzr revid: al@openerp.com-20130624160910-zp898ew6va3lergk
2013-06-24 18:09:10 +02:00
Xavier Morel 282a7180ca [IMP] remove SQL definition of ir.ui.view, schema alterations
* Formally make model not required
* Remove idiotic default values on type and arch
* Make type not required (it's a function field!)

bzr revid: xmo@openerp.com-20130426145113-cf0t0xx24lk9mtgs
2013-04-26 16:51:13 +02:00
Xavier Morel 7883944c19 [FIX] restrict number of fields read in model-less view test
model_ids not filtered in regular read, so get semi-random list of ids

bzr revid: xmo@openerp.com-20130425100247-2v043bbgpvcj3pv9
2013-04-25 12:02:47 +02:00
Xavier Morel e30b6edb41 [ADD] model-less fields & views munging thing
bzr revid: xmo@openerp.com-20130425093739-v0kya956yzcy5wp3
2013-04-25 11:37:39 +02:00
Xavier Morel 4923d1b82d [MOVE] ir.ui.view tests inside base tests
bzr revid: xmo@openerp.com-20130424154310-vdygcckrz6jm578p
2013-04-24 17:43:10 +02:00