This commit is contained in:
Peter Maquiran
2022-04-22 16:42:37 +01:00
parent b613c19415
commit 9823e58938
4 changed files with 9 additions and 14 deletions
@@ -106,9 +106,6 @@ export class NewActionPage implements OnInit {
if(new Date(this.folder.DateBegin).toISOString() > new Date(this.folder.DateEnd).toISOString()){ if(new Date(this.folder.DateBegin).toISOString() > new Date(this.folder.DateEnd).toISOString()){
this.toastService.badRequest("A data de início não pode ser superior a data de fim"); this.toastService.badRequest("A data de início não pode ser superior a data de fim");
} }
else if(this.folder.DateBegin > new Date().toISOString()){
this.toastService.badRequest("A data de início não pode ser superior a data actual");
}
} }
injectValidation() { injectValidation() {
+2
View File
@@ -198,9 +198,11 @@ export class AuthService {
this.WsChatService.setStatus('online') this.WsChatService.setStatus('online')
// alert('wsLogin')
}).catch((message) => { }).catch((message) => {
console.log('rocket chat login failed', message) console.log('rocket chat login failed', message)
// alert('ws login failed')
}) })
@@ -79,12 +79,9 @@ export class NewActionPage implements OnInit {
runValidation() { runValidation() {
this.validateFrom = true; this.validateFrom = true;
if((new Date(this.folder.DateBegin).getTime()) > (new Date(this.folder.DateEnd).getTime())){ if((new Date(this.folder.DateBegin).getTime()) > (new Date(this.folder.DateEnd).getTime())) {
this.toastService._badRequest("A data de início não pode ser superior a data de fim"); this.toastService._badRequest("A data de início não pode ser superior a data de fim");
} }
else if(new Date(this.folder.DateBegin).getTime() > new Date().getTime()){
this.toastService._badRequest("A data de início não pode ser superior a data actual");
}
} }
injectValidation() { injectValidation() {
@@ -142,7 +139,7 @@ export class NewActionPage implements OnInit {
} }
close(){ close() {
this.closeDesktopComponent.emit(); this.closeDesktopComponent.emit();
} }
+5 -6
View File
@@ -21,13 +21,12 @@
export const environment = { export const environment = {
production: false, production: false,
apiURL: 'https://equilibrium.dyndns.info/GabineteDigital.Services/V5/api/', apiURL: 'https://gabinetedigital.dyndns.info/GabineteDigital.Services/V5/api/',
//apiURL: 'http://gpr-dev-01.gabinetedigital.local/GabineteDigital.Services/V5/api/', //apiURL: 'http://gpr-dev-01.gabinetedigital.local/GabineteDigital.Services/V5/api/',
/* apiChatUrl: 'https://gabinetedigitalchat.dyndns.info/api/v1/', apiChatUrl: 'https://gabinetedigitalchat.dyndns.info/api/v1/',
apiWsChatUrl: 'wss://gabinetedigitalchat.dyndns.info/websocket', */ apiWsChatUrl: 'wss://gabinetedigitalchat.dyndns.info/websocket',
apiChatUrl: 'https://www.tabularium.pt/api/v1/', //apiChatUrl: 'https://www.tabularium.pt/api/v1/',
apiWsChatUrl: 'wss://www.tabularium.pt/websocket', //apiWsChatUrl: 'wss://www.tabularium.pt/websocket',
/* apiChatUrl: 'http://chat.gabinetedigital.local:3000/api/v1/', */
domain: 'gabinetedigital.local', //gabinetedigital.local domain: 'gabinetedigital.local', //gabinetedigital.local
defaultuser: 'paulo.pinto@gabinetedigital.local',//paulo.pinto paulo.pinto@gabinetedigital.local defaultuser: 'paulo.pinto@gabinetedigital.local',//paulo.pinto paulo.pinto@gabinetedigital.local
defaultuserpwd: 'tabteste@006', //tabteste@006, defaultuserpwd: 'tabteste@006', //tabteste@006,