fix un true and false
This commit is contained in:
Ronald Q
2016-03-23 18:23:20 -04:00
parent f24844c182
commit b50f5d6144
2 changed files with 7 additions and 0 deletions

View File

@@ -1,7 +1,12 @@
PM.Sessions = (function () {
var Sessions = function () {
if (this.getCookie('singleSignOn') === '1') {
this.register();
this.eraseCookie('singleSignOn');
}
if (window.location.pathname.indexOf("login") === -1 &&
window.location.pathname.indexOf("sysLogin") === -1 &&
window.location.pathname.indexOf("authentication") === -1 &&
this.getCookie('PM-TabPrimary') !== '101010010') {
this.isClose = (this.getLabel('mainWindowClose') === "true");
if (this.isClose && parent.parent.parent.window.name === "") {

View File

@@ -34,6 +34,7 @@ try {
}
if (!$RBAC->singleSignOn) {
setcookie("singleSignOn", '0', time() + (24 * 60 * 60), '/');
if (!isset($_POST['form']) ) {
G::SendTemporalMessage ('ID_USER_HAVENT_RIGHTS_SYSTEM', 'error');
G::header('Location: login');
@@ -175,6 +176,7 @@ try {
$_SESSION['USER_LOGGED'] = $uid;
$_SESSION['USR_USERNAME'] = $usr;
} else {
setcookie("singleSignOn", '1', time() + (24 * 60 * 60), '/');
$uid = $RBAC->userObj->fields['USR_UID'];
$usr = $RBAC->userObj->fields['USR_USERNAME'];
$_SESSION['USER_LOGGED'] = $uid;