Simon Lejeune 01409c1d7b [FIX] web: openerpframework: replaceElement on multiple roots nodeset
jquery's `replaceWith` function behaves differently between 1.8 and 1.9.
This function is used by `renderElement` of the Odoo widget API and, when
called on a template with multiple root nodes, will fail to replace the
whole original nodeset by the new but instead will replace every node
by the new nodeset.

Sample:
1) Suppose a DOM containing
    <div>1</div>
    <div>2</div>
and a jquery nodeset [<div>1</div>, <div>2</div>] referring to the
previous DOM part in a var named $oldel.;
2) suppose another jquery nodeset [<div>3</div>, <div>4</div>] in $el;

$oldel.replaceWith($el) will result in
"3434" in jquery 1.9.1
"34" in jquery 1.8.3

This issue particulary concerns us when the dom of a widget is not wrapped
into single tag and when re-calling renderElement (triggering replaceElement).

The fix is to wrap the element to be replaced ($oldel in the example) behind
a div before calling replaceWith.
2014-12-19 17:49:13 +01:00
2014-10-13 11:09:08 +02:00
2014-05-15 10:43:02 +02:00
2014-12-12 12:07:39 +01:00
2014-11-23 21:08:36 +01:00

Build Status

Odoo

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

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, 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 development

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

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

Then follow the developer tutorial

Packages, tarballs and installers

  • Debian packages

    Add this apt repository to your /etc/apt/sources.list file

      deb http://nightly.odoo.com/master/nightly/deb/ ./
    

    Then type:

      $ sudo apt-get update
      $ sudo apt-get install odoo
    

    If you plan to use Odoo with a local database, please make sure to install PostgreSQL before installing the Odoo Debian package.

  • Source tarballs

  • Windows installer

  • RPM package

For Odoo employees

To add the odoo-dev remote use this command:

$ ./odoo.py setup_git_dev

To fetch odoo merge pull requests refs use this command:

$ ./odoo.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%