From e04ddeaa2282b9a2951b68f1c0d1493a33cc8a9c Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Tue, 22 Dec 2015 11:18:37 +0100 Subject: [FIX] web: client action change password 1. To change the page title, you now have to call `set_title` from `require('web.web_client')` 2. Without the `type="button"`, the `Change Password` button is regarded as a `type="submit"`, therefore submitting the form, on `web` on click, and `web` doesn't expect this POST request. The POST request must be done on `/web/session/change_password` only. opw-660567 --- addons/web/static/src/js/widgets/change_password.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'addons/web/static/src/js/widgets/change_password.js') diff --git a/addons/web/static/src/js/widgets/change_password.js b/addons/web/static/src/js/widgets/change_password.js index a3654e6d0a1..658c7ee8e7d 100644 --- a/addons/web/static/src/js/widgets/change_password.js +++ b/addons/web/static/src/js/widgets/change_password.js @@ -4,6 +4,7 @@ odoo.define('web.ChangePassword', function (require) { var core = require('web.core'); var Dialog = require('web.Dialog'); var Widget = require('web.Widget'); +var web_client = require('web.web_client'); var _t = core._t; @@ -11,7 +12,7 @@ var ChangePassword = Widget.extend({ // FIXME template: "ChangePassword", start: function() { var self = this; - this.getParent().set_title(_t("Change Password")); + web_client.set_title(_t("Change Password")); var $button = self.$el.find('.oe_form_button'); $button.appendTo(this.getParent().$footer); $button.eq(1).click(function(){ -- cgit v1.2.3