mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
save
This commit is contained in:
+1
-1
@@ -1,4 +1,4 @@
|
||||
#Mon Jan 25 12:43:34 WAT 2021
|
||||
#Tue Jan 26 15:33:16 WAT 2021
|
||||
path.3=classes_1.dex
|
||||
path.2=classes_0.dex
|
||||
path.1=classes.dex
|
||||
|
||||
@@ -639,7 +639,7 @@ const environment = {
|
||||
apiChatUrl: 'https://www.tabularium.pt/api/v1/',
|
||||
/* apiChatUrl: 'http://chat.gabinetedigital.local:3000/api/v1/', */
|
||||
domain: 'gabinetedigital.local',
|
||||
defaultuser: '',
|
||||
defaultuser: 'tiago.kayaya',
|
||||
defaultuserpwd: 'tabteste@006'
|
||||
};
|
||||
/*
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -782,7 +782,7 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
||||
|
||||
/* apiChatUrl: 'http://chat.gabinetedigital.local:3000/api/v1/', */
|
||||
domain: 'gabinetedigital.local',
|
||||
defaultuser: '',
|
||||
defaultuser: 'tiago.kayaya',
|
||||
defaultuserpwd: 'tabteste@006'
|
||||
};
|
||||
/*
|
||||
|
||||
File diff suppressed because one or more lines are too long
+32
-26
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
+88
-73
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
+7
-4
@@ -146,8 +146,6 @@ let LoginPage = class LoginPage {
|
||||
this.alertController = alertController;
|
||||
this.username = src_environments_environment__WEBPACK_IMPORTED_MODULE_5__["environment"].defaultuser;
|
||||
this.password = src_environments_environment__WEBPACK_IMPORTED_MODULE_5__["environment"].defaultuserpwd;
|
||||
this.body = { "user": this.username, "password": this.password };
|
||||
this.postData = { "user": this.username, "password": this.password };
|
||||
}
|
||||
ngOnInit() {
|
||||
}
|
||||
@@ -168,10 +166,14 @@ let LoginPage = class LoginPage {
|
||||
});
|
||||
}
|
||||
loginRocketChat() {
|
||||
this.authService.loginChat(this.postData).subscribe((res) => {
|
||||
let postData = {
|
||||
"user": this.username,
|
||||
"password": this.password
|
||||
};
|
||||
this.authService.loginChat(postData).subscribe((res) => {
|
||||
this.storageService.store(src_app_config_auth_constants__WEBPACK_IMPORTED_MODULE_8__["AuthConnstants"].AUTH, res.data);
|
||||
console.log('Logged user \n' + res.data);
|
||||
console.log('Login to Rocket chat OK');
|
||||
this.presentAlert('Login to Rocket chat OK');
|
||||
}, (error) => {
|
||||
console.log('Network error');
|
||||
this.presentAlert('Network error ' + error);
|
||||
@@ -190,6 +192,7 @@ let LoginPage = class LoginPage {
|
||||
BasicAuthKey: ""
|
||||
};
|
||||
if (yield this.authService.login(this.userattempt)) {
|
||||
console.log(this.userattempt);
|
||||
this.loginRocketChat();
|
||||
this.router.navigate(['/home/events']);
|
||||
}
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
+20
-24
@@ -271,14 +271,6 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
||||
this.alertController = alertController;
|
||||
this.username = src_environments_environment__WEBPACK_IMPORTED_MODULE_5__["environment"].defaultuser;
|
||||
this.password = src_environments_environment__WEBPACK_IMPORTED_MODULE_5__["environment"].defaultuserpwd;
|
||||
this.body = {
|
||||
"user": this.username,
|
||||
"password": this.password
|
||||
};
|
||||
this.postData = {
|
||||
"user": this.username,
|
||||
"password": this.password
|
||||
};
|
||||
}
|
||||
|
||||
_createClass(LoginPage, [{
|
||||
@@ -325,12 +317,15 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
||||
value: function loginRocketChat() {
|
||||
var _this = this;
|
||||
|
||||
this.authService.loginChat(this.postData).subscribe(function (res) {
|
||||
var postData = {
|
||||
"user": this.username,
|
||||
"password": this.password
|
||||
};
|
||||
this.authService.loginChat(postData).subscribe(function (res) {
|
||||
_this.storageService.store(src_app_config_auth_constants__WEBPACK_IMPORTED_MODULE_8__["AuthConnstants"].AUTH, res.data);
|
||||
|
||||
console.log('Logged user \n' + res.data);
|
||||
console.log('Login to Rocket chat OK');
|
||||
|
||||
_this.presentAlert('Login to Rocket chat OK');
|
||||
}, function (error) {
|
||||
console.log('Network error');
|
||||
|
||||
@@ -348,7 +343,7 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
||||
_context2.prev = 0;
|
||||
|
||||
if (!this.validateInput()) {
|
||||
_context2.next = 13;
|
||||
_context2.next = 14;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -363,43 +358,44 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
||||
|
||||
case 5:
|
||||
if (!_context2.sent) {
|
||||
_context2.next = 10;
|
||||
_context2.next = 11;
|
||||
break;
|
||||
}
|
||||
|
||||
console.log(this.userattempt);
|
||||
this.loginRocketChat();
|
||||
this.router.navigate(['/home/events']);
|
||||
_context2.next = 11;
|
||||
_context2.next = 12;
|
||||
break;
|
||||
|
||||
case 10:
|
||||
case 11:
|
||||
//this.toastService.presentToast('Não foi possível fazer login"');
|
||||
this.presentAlert('O nome de utilizador e palavra-passe estão incorretas ou verifique a sua conexão com a internet e volte a tentar.');
|
||||
|
||||
case 11:
|
||||
_context2.next = 14;
|
||||
case 12:
|
||||
_context2.next = 15;
|
||||
break;
|
||||
|
||||
case 13:
|
||||
case 14:
|
||||
//this.toastService.presentToast('Preencha todos campos');
|
||||
this.presentAlert('Por favor, insira o seu nome de utilizador e palavra-passe.');
|
||||
|
||||
case 14:
|
||||
_context2.next = 20;
|
||||
case 15:
|
||||
_context2.next = 21;
|
||||
break;
|
||||
|
||||
case 16:
|
||||
_context2.prev = 16;
|
||||
case 17:
|
||||
_context2.prev = 17;
|
||||
_context2.t0 = _context2["catch"](0);
|
||||
_context2.t0;
|
||||
this.presentAlert('Ocorreu um erro ao fazer login. Contacte o administrador de sistema. ');
|
||||
|
||||
case 20:
|
||||
case 21:
|
||||
case "end":
|
||||
return _context2.stop();
|
||||
}
|
||||
}
|
||||
}, _callee2, this, [[0, 16]]);
|
||||
}, _callee2, this, [[0, 17]]);
|
||||
}));
|
||||
}
|
||||
}]);
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
Binary file not shown.
Reference in New Issue
Block a user