← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 677422] Re: Error on the web client to save and javascript

 

Hello Marcile,

Can you please provide more information with proper example about this
error.

Thanks.

** Changed in: openobject-client-web
       Status: New => Incomplete

-- 
Error on the web client to save and javascript
https://bugs.launchpad.net/bugs/677422
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.

Status in OpenObject Web Client: Incomplete

Bug description:
When I save a record any of the following errors occur:

jQuery is not defined
[Break on this error] jQuery(document).ready(function() {
view?c...k_tab=0 (linha 11)

jQuery is not defined
[Break on this error] jQuery.extend({
search.js (linha 269)

jQuery is not defined
[Break on this error] <butto...ove_filter_row(this); return false;">
view?c...k_tab=0 (linha 347)

jQuery is not defined
[Break on this error] </tr>
view?c...k_tab=0 (linha 424)

jQuery is not defined
[Break on this error] ...tle="Create new record.">New</button>
view?c...k_tab=0 (linha 881)

jQuery is not defined
[Break on this error] <th width="1" class="grid-cell selector">
view?c...k_tab=0 (linha 943)

jQuery is not defined
[Break on this error] <td class="grid-cell integer"
view?c...k_tab=0 (linha 1020)

jQuery is not defined
[Break on this error] </span>
view?c...k_tab=0 (linha 1030)

jQuery is not defined
[Break on this error] <td class="grid-cell char"
view?c...k_tab=0 (linha 1038)

xhr.getResponseHeader is not a function
[Break on this error] var action_url = xhr.getResponseHeader('Location');
openerp.base.js (line 74)
------------------------------------------------------------
To solve the problem realized the following changes:

When I change to:

/**
 * Creates a LoadingSuccess execution for the providing app element
 * @param app the element to insert successful content in
 */
function doLoadingSuccess(app) {
    return function (data, status, xhr) {
        var action_url = xhr.getResponseHeader('Location');
        var target = xhr.getResponseHeader('X-Target');
        if(target) {
            window.top.openAction(action_url, target);
            return;
        }
        jQuery(window).trigger('before-appcontent-change');
        jQuery(app).html(xhr.responseText || data);
        jQuery(window).trigger('after-appcontent-change');
    }
}

To:

function doLoadingSuccess(app) {
    return function (data, status, xhr) {
        }
        jQuery(window).trigger('before-appcontent-change');
        jQuery(app).html(xhr.responseText || data);
        jQuery(window).trigger('after-appcontent-change');
    }
}

Data is loaded without generating any exception.

Reviews:
Web client - 3916
server-3029

Thanks.







References