Supplant bugs solved
This commit is contained in:
parent
f20e2d65c3
commit
a6af942424
|
@ -1,4 +1,4 @@
|
|||
hedera-web (1.405.65) stable; urgency=low
|
||||
hedera-web (1.405.66) stable; urgency=low
|
||||
|
||||
* Initial Release.
|
||||
|
||||
|
|
|
@ -88,6 +88,8 @@ module.exports = new Class
|
|||
localStorage.setItem ('hederaCookies', true);
|
||||
Htk.Toast.showWarning (_('By using this site you accept cookies'));
|
||||
}
|
||||
|
||||
this.supplantInit ();
|
||||
}
|
||||
|
||||
,hide: function ()
|
||||
|
@ -512,17 +514,26 @@ module.exports = new Class
|
|||
|
||||
//++++++++++++++++++++++++++++++++++++++++++++++++++++++ Supplant
|
||||
|
||||
,supplantInit: function ()
|
||||
{
|
||||
var user = sessionStorage.getItem ('supplantUser');
|
||||
|
||||
if (user != null)
|
||||
this.supplantUser (user);
|
||||
}
|
||||
|
||||
,supplantUser: function (user, callback)
|
||||
{
|
||||
this._conn.supplantUser (user,
|
||||
this._onUserSupplant.bind (this, callback));
|
||||
this._onUserSupplant.bind (this, callback, user));
|
||||
}
|
||||
|
||||
,_onUserSupplant: function (callback, supplantOk)
|
||||
,_onUserSupplant: function (callback, user, supplantOk)
|
||||
{
|
||||
if (!supplantOk)
|
||||
return;
|
||||
|
||||
sessionStorage.setItem ('supplantUser', user);
|
||||
this.loadMenu ();
|
||||
|
||||
var sql = 'SELECT nickname FROM account.userView';
|
||||
|
@ -543,6 +554,8 @@ module.exports = new Class
|
|||
{
|
||||
Vn.Node.hide (this.$('supplant'));
|
||||
this._conn.supplantEnd ();
|
||||
sessionStorage.removeItem ('supplantUser',
|
||||
sessionStorage.getItem ('supplantUser'));
|
||||
this.loadMenu ();
|
||||
this._onFormChange ();
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "hedera-web",
|
||||
"version": "1.405.65",
|
||||
"version": "1.405.66",
|
||||
"description": "Verdnatura web page",
|
||||
"license": "GPL-3.0",
|
||||
"repository": {
|
||||
|
|
Loading…
Reference in New Issue