PM-2381 "Randomicamente nos muestra el siguiente warning..." SOLVED

Issue:
    Randomicamente nos muestra el siguiente warning: Wrong login credentials
Cause:
    Doble submit en el login
Solution:
    Se a corregido a un solo submit en el login
This commit is contained in:
Victor Saisa Lopez
2015-04-29 14:57:39 -04:00
parent ca6c078661
commit 5f52385b58

View File

@@ -25,11 +25,11 @@ SELECT LANG_ID, LANG_NAME FROM langOptions
<en><![CDATA[Forgot Password]]></en> <en><![CDATA[Forgot Password]]></en>
</FORGOT_PASWORD_LINK> </FORGOT_PASWORD_LINK>
<JS type="javascript"><![CDATA[ <JS type="javascript"><![CDATA[
window.onload= function(){ window.onload= function(){
document.getElementById('form[USR_USERNAME]').placeholder = _('ID_USER'); document.getElementById('form[USR_USERNAME]').placeholder = _('ID_USER');
document.getElementById('form[USR_PASSWORD_MASK]').placeholder = _('ID_PASSWORD'); document.getElementById('form[USR_PASSWORD_MASK]').placeholder = _('ID_PASSWORD');
document.getElementById('form[BSUBMIT]').classList.remove('module_app_button___gray'); document.getElementById('form[BSUBMIT]').classList.remove('module_app_button___gray');
document.getElementById('form[BSUBMIT]').classList.add('button-login-success'); document.getElementById('form[BSUBMIT]').classList.add('button-login-success');
}; };
// enable/disable forgot password link // enable/disable forgot password link
@@ -108,20 +108,16 @@ leimnud.event.add(document.getElementById('form[USR_PASSWORD_MASK]'), 'keypress'
}); });
leimnud.event.add(document.getElementById('form[BSUBMIT]'), 'click', function() { leimnud.event.add(document.getElementById('form[BSUBMIT]'), 'click', function() {
setNestedProperty(this, Array('disabled'), 'true'); setNestedProperty(this, Array("disabled"), "true");
setNestedProperty(this, Array('value'), @@LOGIN_VERIFY_MSG); setNestedProperty(this, Array("value"), @@LOGIN_VERIFY_MSG);
var client = getBrowserClient(); document.getElementById("form[USR_PASSWORD]").value = document.getElementById("form[USR_PASSWORD_MASK]").value;
document.getElementById("form[USR_PASSWORD_MASK]").value = "";
document.getElementById("form[USR_PASSWORD_MASK]").setAttribute("type", "text");
if (client.browser != "firefox") {
document.login.submit(); document.login.submit();
}
document.getElementById('form[USR_PASSWORD]').value = document.getElementById('form[USR_PASSWORD_MASK]').value;
document.getElementById('form[USR_PASSWORD_MASK]').value = '';
document.getElementById('form[USR_PASSWORD_MASK]').setAttribute('type', 'text');
document.login.submit();
//return true;
}.extend(document.getElementById('form[BSUBMIT]'))); }.extend(document.getElementById('form[BSUBMIT]')));
]]></JS> ]]></JS>
</dynaForm> </dynaForm>