Géry Debongnie 0c28dbf969 [FIX] web: ActionManager: protect set/get scrolltop methods
Here is what could happen before this commit: open a record (let's say
project.task) in form view.  Then, on the sidebar (actions), choose
Merge Selected Tasks), choose a task, and click on Merge. What happens
next is a traceback.

Here is a more precise description of what happened:
- the formview dialog for the merge action closes, which triggers a
  reload for the main formview
- the merge action returned an action description for an act_window
- the action manager instantiated a new viewmanager and prepare the form
  view, which is an async operation (need to load some data to display
  the form)
- the previous view manager (initial one) completes its reload, which
  makes it rerender the view, which triggers a DOM_updated event
- the new view manager see this event, and tries to call getScrollTop on
  the current view controller, but there are no controller yet, it is
  not ready.

We could argue that some of these events should not happen (for example,
if we will open a new view manager action, why do we reload the current
view manager?).  But solving these issues is a more deep architectural
problem (we probably will rewrite the actionmanager/view manager layer
at some point).

It could also be argued that in any case, the method getScrollTop should
not crash (same for setScrollTop).  Sadly, these methods are fragile,
because some changes in the loading behaviour of a view may break them.
So, in any case, protecting them against unexpected traceback is a
worthwile investment.
2017-05-24 17:26:39 +02:00
2017-04-11 19:44:38 +02:00
2015-09-08 15:45:09 +02:00
2015-09-08 17:58:38 +02:00
…

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, Purchase Management, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

If you are a developer you may type the following command at your terminal:

wget -O- https://raw.githubusercontent.com/odoo/odoo/master/setup/setup_dev.py | python

Then follow the developer tutorials

For Odoo employees

To add the odoo-dev remote use this command:

$ ./setup/setup_dev.py setup_git_dev

To fetch odoo merge pull requests refs use this command:

$ ./setup/setup_dev.py setup_git_review
S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%