website_quote: cannot edit Big Message button link at chrome

Bug #1316949 reported by Ivan Yelizariev
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
New
Undecided
Unassigned

Bug Description

My browser is chrome:
Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.132 Safari/537.36

Steps:
* install trunk OpenERP
* install website_quote
* create quote
* edit website quotation,
* add Big Message block
* click "change" on "contact us" button

Link editor will be opened, but all fields are empty. If you edit fields and click save nothing is changed.

At browser console I have warngings:

event.returnValue is deprecated. Please use the standard event.preventDefault() instead. website.assets_frontend:372
Attr.specified is deprecated. Its value is always true. website.assets_editor:132

Revision history for this message
Ivan Yelizariev (yelizariev) wrote :

Behaviour is correct at Opera browser

Revision history for this message
Ivan Yelizariev (yelizariev) wrote :

I figure out the problem.

Difference between Opera and Crome at function get_selected_link of file addons/website/static/src/js/website.editor.js

    function get_selected_link(editor) {
        var sel = editor.getSelection(),
            el = sel.getSelectedElement();

At chrome:
el is null

At Opera:
el is not null

My suggestion is to use getStartElement of CKEDITOR:

    function get_selected_link(editor) {
        var sel = editor.getSelection(),
            el = sel.getSelectedElement();
+ el = el || sel.getStartElement();

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.