mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 12:37:53 +00:00
clear agenda cache
This commit is contained in:
@@ -123,6 +123,7 @@ export class LoginPage implements OnInit {
|
|||||||
if (attempt.UserId == SessionStore.user.UserId) {
|
if (attempt.UserId == SessionStore.user.UserId) {
|
||||||
|
|
||||||
await this.authService.SetSession(attempt, this.userattempt);
|
await this.authService.SetSession(attempt, this.userattempt);
|
||||||
|
this.changeProfileService.run();
|
||||||
|
|
||||||
if(attempt.ChatData) {
|
if(attempt.ChatData) {
|
||||||
|
|
||||||
|
|||||||
@@ -317,8 +317,12 @@ export class ChatSystemService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.RochetChatConnectorService.streamNotifyLogged().then((subscription=>{
|
this.RochetChatConnectorService.streamNotifyLogged().then((subscription=>{
|
||||||
|
console.log(subscription)
|
||||||
}))
|
}))
|
||||||
|
|
||||||
|
// this.RochetChatConnectorService.subStreamNotifyUser().then((subscription=>{
|
||||||
|
// console.log(subscription)
|
||||||
|
// }))
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -406,7 +410,7 @@ export class ChatSystemService {
|
|||||||
|
|
||||||
let roomId = this.getRoomId(roomData);
|
let roomId = this.getRoomId(roomData);
|
||||||
|
|
||||||
if (setData.name != 'Rocket Cat') {
|
if (setData.name != 'Rocket Cat' && setData.name != 'general' ) {
|
||||||
// create room
|
// create room
|
||||||
if(!this.roomExist(roomId)) {
|
if(!this.roomExist(roomId)) {
|
||||||
let room:RoomService = new RoomService(this.RochetChatConnectorService, new MessageService(this.NfService, this.RochetChatConnectorService, this.ChatMethodsService, this.AESEncrypt, this.AttachmentsService, this.NetworkServiceService, this), this.storage, this.platform, this.sqlservice, this.NativeNotificationService, this.sortService, this.ChatService, this.NfService, this.ChatMethodsService, this.AESEncrypt, this.AttachmentsService, this.NetworkServiceService, this, this.ViewedMessageService)
|
let room:RoomService = new RoomService(this.RochetChatConnectorService, new MessageService(this.NfService, this.RochetChatConnectorService, this.ChatMethodsService, this.AESEncrypt, this.AttachmentsService, this.NetworkServiceService, this), this.storage, this.platform, this.sqlservice, this.NativeNotificationService, this.sortService, this.ChatService, this.NfService, this.ChatMethodsService, this.AESEncrypt, this.AttachmentsService, this.NetworkServiceService, this, this.ViewedMessageService)
|
||||||
|
|||||||
@@ -437,6 +437,35 @@ export class RochetChatConnectorService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
subStreamNotifyUser(param?: any) {
|
||||||
|
|
||||||
|
const requestId = uuidv4()
|
||||||
|
|
||||||
|
let message = {
|
||||||
|
msg: "sub",
|
||||||
|
id: requestId,
|
||||||
|
name: "stream-notify-user",
|
||||||
|
params:[
|
||||||
|
`${SessionStore.user.ChatData.data.userId}/notification`,
|
||||||
|
param
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
this.ws.send({message, requestId})
|
||||||
|
|
||||||
|
return new Promise((resolve, reject) => {
|
||||||
|
this.ws.registerCallback({type:'Onmessage', funx:(message)=>{
|
||||||
|
if(message.id == requestId ) { // same request send
|
||||||
|
resolve(message)
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}})
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
receiveStreamNotifyRoom(funx: Function) {
|
receiveStreamNotifyRoom(funx: Function) {
|
||||||
|
|
||||||
this.ws.registerCallback({
|
this.ws.registerCallback({
|
||||||
|
|||||||
@@ -20,7 +20,6 @@ import { SessionStore } from '../store/session.service';
|
|||||||
export class EventsService {
|
export class EventsService {
|
||||||
|
|
||||||
authheader = {};
|
authheader = {};
|
||||||
loggeduser: UserSession;
|
|
||||||
headers: HttpHeaders;
|
headers: HttpHeaders;
|
||||||
|
|
||||||
headersPrOficial: HttpHeaders;
|
headersPrOficial: HttpHeaders;
|
||||||
@@ -38,24 +37,16 @@ export class EventsService {
|
|||||||
headersSharedOficial: HttpHeaders;
|
headersSharedOficial: HttpHeaders;
|
||||||
headersSharedPessoal: HttpHeaders;
|
headersSharedPessoal: HttpHeaders;
|
||||||
|
|
||||||
hasSharedCalendar = false
|
|
||||||
hasOwnCalendar = false
|
|
||||||
|
|
||||||
|
|
||||||
calendarIds = []
|
calendarIds = []
|
||||||
usersCalendarIds = []
|
usersCalendarIds = []
|
||||||
|
|
||||||
|
hasSharedCalendar = false;
|
||||||
hasSharedOficial: boolean = false;
|
hasSharedOficial: boolean = false;
|
||||||
hasSharedPessoal: boolean = false;
|
hasSharedPessoal: boolean = false;
|
||||||
|
|
||||||
hasOwnOficial: boolean = false;
|
hasOwnOficial: boolean = false;
|
||||||
hasOwnPessoal: boolean = false;
|
hasOwnPessoal: boolean = false;
|
||||||
|
hasOwnCalendar = false
|
||||||
|
|
||||||
|
|
||||||
userCalendarNameSharedOficial = '';
|
|
||||||
userCalendarNameSharedPessoal = '';
|
|
||||||
userCalendarNameOwnOficial = '';
|
|
||||||
userCalendarNameOwnPessoal = '';
|
|
||||||
|
|
||||||
calendarNames = {}
|
calendarNames = {}
|
||||||
|
|
||||||
@@ -73,7 +64,14 @@ export class EventsService {
|
|||||||
private storage: Storage,
|
private storage: Storage,
|
||||||
private backgroundservice: BackgroundService) {
|
private backgroundservice: BackgroundService) {
|
||||||
|
|
||||||
this.loggeduser = SessionStore.user;
|
this.setHeader()
|
||||||
|
this.changeProfileService.registerCallback(() => {
|
||||||
|
this.setHeader()
|
||||||
|
})
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
async setHeader () {
|
||||||
|
|
||||||
this.headers = new HttpHeaders();
|
this.headers = new HttpHeaders();
|
||||||
this.headersMdOficial = new HttpHeaders();
|
this.headersMdOficial = new HttpHeaders();
|
||||||
@@ -92,16 +90,14 @@ export class EventsService {
|
|||||||
this.headerSharedOficial= new HttpHeaders();
|
this.headerSharedOficial= new HttpHeaders();
|
||||||
this.headerSharedPessoal= new HttpHeaders();
|
this.headerSharedPessoal= new HttpHeaders();
|
||||||
|
|
||||||
|
this.headers = this.headers.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
|
|
||||||
this.setHeader()
|
this.usersCalendarIds = [];
|
||||||
this.changeProfileService.registerCallback(() => {
|
this.calendarNames = {}
|
||||||
this.loggeduser = SessionStore.user;
|
this.calendarIds = []
|
||||||
this.setHeader()
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
this.calendarNamesAry = []
|
||||||
|
this.calendarNamesType = {}
|
||||||
async setHeader () {
|
|
||||||
|
|
||||||
this.hasSharedCalendar = false
|
this.hasSharedCalendar = false
|
||||||
this.hasSharedOficial = false
|
this.hasSharedOficial = false
|
||||||
@@ -111,31 +107,10 @@ export class EventsService {
|
|||||||
this.hasOwnOficial = false
|
this.hasOwnOficial = false
|
||||||
this.hasOwnPessoal = false
|
this.hasOwnPessoal = false
|
||||||
|
|
||||||
this.headers = new HttpHeaders();
|
if (SessionStore.user) {
|
||||||
|
if (SessionStore.user.Profile == 'MDGPR') {
|
||||||
|
|
||||||
this.headerOwnOficial= new HttpHeaders();
|
for (let calendar of SessionStore.user.OwnerCalendars) {
|
||||||
this.headerOwnPessoal= new HttpHeaders();
|
|
||||||
|
|
||||||
this.headerSharedOficial= new HttpHeaders();
|
|
||||||
this.headerSharedPessoal= new HttpHeaders();
|
|
||||||
|
|
||||||
this.headers = this.headers.set('Authorization', this.loggeduser.BasicAuthKey);
|
|
||||||
|
|
||||||
this.userCalendarNameSharedOficial = '';
|
|
||||||
this.userCalendarNameSharedPessoal = '';
|
|
||||||
this.userCalendarNameOwnOficial = '';
|
|
||||||
this.userCalendarNameOwnPessoal = '';
|
|
||||||
|
|
||||||
this.usersCalendarIds = [];
|
|
||||||
this.calendarNames = {}
|
|
||||||
|
|
||||||
this.calendarNamesAry = []
|
|
||||||
this.calendarNamesType = {}
|
|
||||||
|
|
||||||
if (this.loggeduser) {
|
|
||||||
if (this.loggeduser.Profile == 'MDGPR') {
|
|
||||||
|
|
||||||
for (let calendar of this.loggeduser.OwnerCalendars) {
|
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
|
|
||||||
if (calendar.CalendarName == 'Oficial') {
|
if (calendar.CalendarName == 'Oficial') {
|
||||||
@@ -143,7 +118,7 @@ export class EventsService {
|
|||||||
this.hasOwnOficial = true
|
this.hasOwnOficial = true
|
||||||
|
|
||||||
|
|
||||||
this.headersMdOficial = this.headersMdOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headersMdOficial = this.headersMdOficial.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headersMdOficial = this.headersMdOficial.set('CalendarId', calendar.CalendarId);
|
this.headersMdOficial = this.headersMdOficial.set('CalendarId', calendar.CalendarId);
|
||||||
this.headersMdOficial = this.headersMdOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
this.headersMdOficial = this.headersMdOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||||
}
|
}
|
||||||
@@ -151,21 +126,21 @@ export class EventsService {
|
|||||||
|
|
||||||
this.hasOwnPessoal = true
|
this.hasOwnPessoal = true
|
||||||
|
|
||||||
this.headersMdPessoal = this.headersMdPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headersMdPessoal = this.headersMdPessoal.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headersMdPessoal = this.headersMdPessoal.set('CalendarId', calendar.CalendarId);
|
this.headersMdPessoal = this.headersMdPessoal.set('CalendarId', calendar.CalendarId);
|
||||||
this.headersMdPessoal = this.headersMdPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
this.headersMdPessoal = this.headersMdPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let sharedCalendar of this.loggeduser.SharedCalendars) {
|
for (let sharedCalendar of SessionStore.user.SharedCalendars) {
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
|
|
||||||
if (sharedCalendar.CalendarName == 'Oficial') {
|
if (sharedCalendar.CalendarName == 'Oficial') {
|
||||||
|
|
||||||
this.hasSharedOficial = true
|
this.hasSharedOficial = true
|
||||||
|
|
||||||
this.headersSharedOficial = this.headersSharedOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headersSharedOficial = this.headersSharedOficial.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headersSharedOficial = this.headersSharedOficial.set('CalendarId', sharedCalendar.CalendarId);
|
this.headersSharedOficial = this.headersSharedOficial.set('CalendarId', sharedCalendar.CalendarId);
|
||||||
this.headersSharedOficial = this.headersSharedOficial.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
this.headersSharedOficial = this.headersSharedOficial.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||||
}
|
}
|
||||||
@@ -173,7 +148,7 @@ export class EventsService {
|
|||||||
|
|
||||||
this.hasSharedPessoal = true
|
this.hasSharedPessoal = true
|
||||||
|
|
||||||
this.headersSharedPessoal = this.headersSharedPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headersSharedPessoal = this.headersSharedPessoal.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarId', sharedCalendar.CalendarId);
|
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarId', sharedCalendar.CalendarId);
|
||||||
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
this.headersSharedPessoal = this.headersSharedPessoal.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||||
}
|
}
|
||||||
@@ -181,15 +156,15 @@ export class EventsService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
else if (this.loggeduser.Profile == 'PR') {
|
else if (SessionStore.user.Profile == 'PR') {
|
||||||
|
|
||||||
for (let calendar of this.loggeduser.OwnerCalendars) {
|
for (let calendar of SessionStore.user.OwnerCalendars) {
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
if (calendar.CalendarName == 'Oficial') {
|
if (calendar.CalendarName == 'Oficial') {
|
||||||
|
|
||||||
this.hasOwnOficial = true
|
this.hasOwnOficial = true
|
||||||
|
|
||||||
this.headersPrOficial = this.headersPrOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headersPrOficial = this.headersPrOficial.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headersPrOficial = this.headersPrOficial.set('CalendarId', calendar.CalendarId);
|
this.headersPrOficial = this.headersPrOficial.set('CalendarId', calendar.CalendarId);
|
||||||
this.headersPrOficial = this.headersPrOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
this.headersPrOficial = this.headersPrOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||||
}
|
}
|
||||||
@@ -197,7 +172,7 @@ export class EventsService {
|
|||||||
|
|
||||||
this.hasOwnPessoal = true
|
this.hasOwnPessoal = true
|
||||||
|
|
||||||
this.headersPrPessoal = this.headersPrPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headersPrPessoal = this.headersPrPessoal.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headersPrPessoal = this.headersPrPessoal.set('CalendarId', calendar.CalendarId);
|
this.headersPrPessoal = this.headersPrPessoal.set('CalendarId', calendar.CalendarId);
|
||||||
this.headersPrPessoal = this.headersPrPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
this.headersPrPessoal = this.headersPrPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||||
|
|
||||||
@@ -206,7 +181,7 @@ export class EventsService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let calendar of this.loggeduser.OwnerCalendars) {
|
for (let calendar of SessionStore.user.OwnerCalendars) {
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
if(!this.usersCalendarIds.includes(calendar.OwnerUserId)) {
|
if(!this.usersCalendarIds.includes(calendar.OwnerUserId)) {
|
||||||
this.usersCalendarIds.push(calendar.OwnerUserId)
|
this.usersCalendarIds.push(calendar.OwnerUserId)
|
||||||
@@ -222,7 +197,7 @@ export class EventsService {
|
|||||||
|
|
||||||
this.hasOwnOficial = true
|
this.hasOwnOficial = true
|
||||||
|
|
||||||
this.headerOwnOficial = this.headerOwnOficial.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headerOwnOficial = this.headerOwnOficial.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headerOwnOficial = this.headerOwnOficial.set('CalendarId', calendar.CalendarId);
|
this.headerOwnOficial = this.headerOwnOficial.set('CalendarId', calendar.CalendarId);
|
||||||
this.headerOwnOficial = this.headerOwnOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
this.headerOwnOficial = this.headerOwnOficial.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||||
this.headerOwnOficial = this.headerOwnOficial.set('CalendarName', calendar.CalendarName);
|
this.headerOwnOficial = this.headerOwnOficial.set('CalendarName', calendar.CalendarName);
|
||||||
@@ -231,14 +206,14 @@ export class EventsService {
|
|||||||
|
|
||||||
this.hasOwnPessoal = true
|
this.hasOwnPessoal = true
|
||||||
|
|
||||||
this.headerOwnPessoal = this.headerOwnPessoal.set('Authorization', this.loggeduser.BasicAuthKey);
|
this.headerOwnPessoal = this.headerOwnPessoal.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
this.headerOwnPessoal =this.headerOwnPessoal.set('CalendarId', calendar.CalendarId);
|
this.headerOwnPessoal =this.headerOwnPessoal.set('CalendarId', calendar.CalendarId);
|
||||||
this.headerOwnPessoal =this.headerOwnPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
this.headerOwnPessoal =this.headerOwnPessoal.set('CalendarRoleId', calendar.CalendarRoleId);
|
||||||
this.headerOwnPessoal = this.headerOwnPessoal.set('CalendarName', calendar.CalendarName);
|
this.headerOwnPessoal = this.headerOwnPessoal.set('CalendarName', calendar.CalendarName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let sharedCalendar of this.loggeduser.SharedCalendars) {
|
for (let sharedCalendar of SessionStore.user.SharedCalendars) {
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
|
|
||||||
if(!this.usersCalendarIds.includes(sharedCalendar.OwnerUserId)) {
|
if(!this.usersCalendarIds.includes(sharedCalendar.OwnerUserId)) {
|
||||||
@@ -254,7 +229,7 @@ export class EventsService {
|
|||||||
if (sharedCalendar.CalendarName == 'Oficial') {
|
if (sharedCalendar.CalendarName == 'Oficial') {
|
||||||
this.hasSharedOficial = true
|
this.hasSharedOficial = true
|
||||||
|
|
||||||
this.headerSharedOficial = this.headerSharedOficial.set('Authorization',this.loggeduser.BasicAuthKey);
|
this.headerSharedOficial = this.headerSharedOficial.set('Authorization',SessionStore.user.BasicAuthKey);
|
||||||
this.headerSharedOficial = this.headerSharedOficial.set('CalendarId', sharedCalendar.CalendarId);
|
this.headerSharedOficial = this.headerSharedOficial.set('CalendarId', sharedCalendar.CalendarId);
|
||||||
this.headerSharedOficial = this.headerSharedOficial.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
this.headerSharedOficial = this.headerSharedOficial.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||||
this.headerSharedOficial = this.headerSharedOficial.set('CalendarName', sharedCalendar.CalendarName);
|
this.headerSharedOficial = this.headerSharedOficial.set('CalendarName', sharedCalendar.CalendarName);
|
||||||
@@ -263,7 +238,7 @@ export class EventsService {
|
|||||||
|
|
||||||
this.hasSharedPessoal = true
|
this.hasSharedPessoal = true
|
||||||
|
|
||||||
this.headerSharedPessoal = this.headerSharedPessoal.set('Authorization',this.loggeduser.BasicAuthKey);
|
this.headerSharedPessoal = this.headerSharedPessoal.set('Authorization',SessionStore.user.BasicAuthKey);
|
||||||
this.headerSharedPessoal = this.headerSharedPessoal.set('CalendarId', sharedCalendar.CalendarId);
|
this.headerSharedPessoal = this.headerSharedPessoal.set('CalendarId', sharedCalendar.CalendarId);
|
||||||
this.headerSharedPessoal = this.headerSharedPessoal.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
this.headerSharedPessoal = this.headerSharedPessoal.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||||
this.headerSharedPessoal = this.headerSharedPessoal.set('CalendarName', sharedCalendar.CalendarName);
|
this.headerSharedPessoal = this.headerSharedPessoal.set('CalendarName', sharedCalendar.CalendarName);
|
||||||
@@ -271,7 +246,7 @@ export class EventsService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
for (let sharedCalendar of this.loggeduser.SharedCalendars) {
|
for (let sharedCalendar of SessionStore.user.SharedCalendars) {
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
if(sharedCalendar?.OwnerUserId) {
|
if(sharedCalendar?.OwnerUserId) {
|
||||||
this.GetCalendarName(sharedCalendar.OwnerUserId).subscribe((e)=> {
|
this.GetCalendarName(sharedCalendar.OwnerUserId).subscribe((e)=> {
|
||||||
@@ -291,7 +266,7 @@ export class EventsService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let sharedCalendar of this.loggeduser.OwnerCalendars) {
|
for (let sharedCalendar of SessionStore.user.OwnerCalendars) {
|
||||||
this.hasAnyCalendar = false
|
this.hasAnyCalendar = false
|
||||||
|
|
||||||
this.calendarNames[sharedCalendar.CalendarId] = 'Meu calendario'
|
this.calendarNames[sharedCalendar.CalendarId] = 'Meu calendario'
|
||||||
@@ -326,13 +301,13 @@ export class EventsService {
|
|||||||
|
|
||||||
isMyEvent(event: any) {
|
isMyEvent(event: any) {
|
||||||
|
|
||||||
for (let calendar of this.loggeduser.OwnerCalendars) {
|
for (let calendar of SessionStore.user.OwnerCalendars) {
|
||||||
if(event.CalendarId == calendar.CalendarId) {
|
if(event.CalendarId == calendar.CalendarId) {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (let sharedCalendar of this.loggeduser.SharedCalendars) {
|
for (let sharedCalendar of SessionStore.user.SharedCalendars) {
|
||||||
if(event.CalendarId == sharedCalendar.CalendarId) {
|
if(event.CalendarId == sharedCalendar.CalendarId) {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
@@ -438,7 +413,7 @@ export class EventsService {
|
|||||||
|
|
||||||
let prO = [], prP = [];
|
let prO = [], prP = [];
|
||||||
|
|
||||||
for (let calendar of this.loggeduser.OwnerCalendars) {
|
for (let calendar of SessionStore.user.OwnerCalendars) {
|
||||||
if (calendar.CalendarName == 'Oficial') {
|
if (calendar.CalendarName == 'Oficial') {
|
||||||
prO = await this.getAllMdOficialEvents(startdate, enddate).toPromise();
|
prO = await this.getAllMdOficialEvents(startdate, enddate).toPromise();
|
||||||
if(!Array.isArray(prO)) {
|
if(!Array.isArray(prO)) {
|
||||||
@@ -521,10 +496,10 @@ export class EventsService {
|
|||||||
|
|
||||||
let result = []
|
let result = []
|
||||||
|
|
||||||
for (let sharedCalendar of this.loggeduser.SharedCalendars) {
|
for (let sharedCalendar of SessionStore.user.SharedCalendars) {
|
||||||
|
|
||||||
var header = new HttpHeaders();
|
var header = new HttpHeaders();
|
||||||
header = header.set('Authorization', this.loggeduser.BasicAuthKey);
|
header = header.set('Authorization', SessionStore.user.BasicAuthKey);
|
||||||
header = header.set('CalendarId', sharedCalendar.CalendarId);
|
header = header.set('CalendarId', sharedCalendar.CalendarId);
|
||||||
header = header.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
header = header.set('CalendarRoleId', sharedCalendar.CalendarRoleId);
|
||||||
header = header.set('CalendarName', sharedCalendar.CalendarName);
|
header = header.set('CalendarName', sharedCalendar.CalendarName);
|
||||||
@@ -591,7 +566,7 @@ export class EventsService {
|
|||||||
|
|
||||||
let prO = [], prP = [];
|
let prO = [], prP = [];
|
||||||
|
|
||||||
for(let calendar of this.loggeduser.SharedCalendars) {
|
for(let calendar of SessionStore.user.SharedCalendars) {
|
||||||
if (calendar.CalendarName == 'Oficial') {
|
if (calendar.CalendarName == 'Oficial') {
|
||||||
prO = await this.getAllSharedOficialEvents(startdate, enddate).toPromise();
|
prO = await this.getAllSharedOficialEvents(startdate, enddate).toPromise();
|
||||||
}
|
}
|
||||||
@@ -745,10 +720,10 @@ export class EventsService {
|
|||||||
this.headers['CalendarName'] = event.CalendarName
|
this.headers['CalendarName'] = event.CalendarName
|
||||||
|
|
||||||
if (event.CalendarName == 'Oficial') {
|
if (event.CalendarName == 'Oficial') {
|
||||||
if (this.loggeduser.Profile == 'MDGPR') {
|
if (SessionStore.user.Profile == 'MDGPR') {
|
||||||
this.headers = this.headersMdOficial;
|
this.headers = this.headersMdOficial;
|
||||||
}
|
}
|
||||||
else if (this.loggeduser.Profile == 'PR') {
|
else if (SessionStore.user.Profile == 'PR') {
|
||||||
this.headers = this.headersPrOficial;
|
this.headers = this.headersPrOficial;
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
@@ -767,10 +742,10 @@ export class EventsService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (this.loggeduser.Profile == 'MDGPR') {
|
if (SessionStore.user.Profile == 'MDGPR') {
|
||||||
this.headers = this.headersMdPessoal;
|
this.headers = this.headersMdPessoal;
|
||||||
}
|
}
|
||||||
else if (this.loggeduser.Profile == 'PR') {
|
else if (SessionStore.user.Profile == 'PR') {
|
||||||
this.headers = this.headersPrPessoal;
|
this.headers = this.headersPrPessoal;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@@ -916,7 +891,7 @@ export class EventsService {
|
|||||||
|
|
||||||
let options;
|
let options;
|
||||||
|
|
||||||
switch (this.loggeduser.Profile) {
|
switch (SessionStore.user.Profile) {
|
||||||
case 'MDGPR':
|
case 'MDGPR':
|
||||||
if (calendarName == 'Pessoal') {
|
if (calendarName == 'Pessoal') {
|
||||||
options = {
|
options = {
|
||||||
@@ -974,7 +949,7 @@ export class EventsService {
|
|||||||
|
|
||||||
let options;
|
let options;
|
||||||
|
|
||||||
if(this.loggeduser.Profile == 'MDGPR') {
|
if(SessionStore.user.Profile == 'MDGPR') {
|
||||||
if (calendarName == 'Pessoal') {
|
if (calendarName == 'Pessoal') {
|
||||||
options = {
|
options = {
|
||||||
headers: this.headersMdPessoal,
|
headers: this.headersMdPessoal,
|
||||||
@@ -988,7 +963,7 @@ export class EventsService {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (this.loggeduser.Profile == 'PR') {
|
else if (SessionStore.user.Profile == 'PR') {
|
||||||
if (calendarName == 'Pessoal') {
|
if (calendarName == 'Pessoal') {
|
||||||
options = {
|
options = {
|
||||||
headers: this.headersPrPessoal,
|
headers: this.headersPrPessoal,
|
||||||
@@ -1050,7 +1025,7 @@ export class EventsService {
|
|||||||
params = params.set("SerialNumber", serialNumber);
|
params = params.set("SerialNumber", serialNumber);
|
||||||
params = params.set("applicationID", applicationID);
|
params = params.set("applicationID", applicationID);
|
||||||
|
|
||||||
switch (this.loggeduser.Profile) {
|
switch (SessionStore.user.Profile) {
|
||||||
case 'MDGPR':
|
case 'MDGPR':
|
||||||
if (body.CalendarName == 'Pessoal') {
|
if (body.CalendarName == 'Pessoal') {
|
||||||
options = {
|
options = {
|
||||||
@@ -1121,7 +1096,7 @@ export class EventsService {
|
|||||||
params = params.set("SerialNumber", serialNumber);
|
params = params.set("SerialNumber", serialNumber);
|
||||||
params = params.set("applicationID", applicationID);
|
params = params.set("applicationID", applicationID);
|
||||||
|
|
||||||
switch (this.loggeduser.Profile) {
|
switch (SessionStore.user.Profile) {
|
||||||
case 'MDGPR':
|
case 'MDGPR':
|
||||||
if (body.CalendarName == 'Pessoal') {
|
if (body.CalendarName == 'Pessoal') {
|
||||||
options = {
|
options = {
|
||||||
|
|||||||
@@ -1,22 +1,23 @@
|
|||||||
import { versionData } from '../../version/git-version'
|
import { versionData } from '../../version/git-version'
|
||||||
|
|
||||||
export const environment = {
|
export const environment = {
|
||||||
// apiURL: 'https://gabinetedigital.dyndns.info/GabineteDigital.Services/V5/api/',
|
// apiURL: 'https://gabinetedigital.dyndns.info/GabineteDigital.Services/V5/api/',
|
||||||
//apiURL: 'https://API.DONEIT.CO.AO/api/',
|
apiURL: 'https://API.DONEIT.CO.AO/api/',
|
||||||
apiURL: 'https://gd-api.oapr.gov.ao/api/',
|
//apiURL: 'https://gd-api.oapr.gov.ao/api/',
|
||||||
//apiURL: 'https://gdapi-dev.dyndns.info/GabineteDigital.Services/V5/api/',
|
//apiURL: 'https://gdapi-dev.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://gdchat-dev.dyndns.info/api/v1/',
|
//apiChatUrl: 'https://gdchat-dev.dyndns.info/api/v1/',
|
||||||
//apiWsChatUrl: 'wss://gdchat-dev.dyndns.info/websocket',
|
//apiWsChatUrl: 'wss://gdchat-dev.dyndns.info/websocket',
|
||||||
/* apiChatUrl: 'https://CHAT.DONEIT.CO.AO/api/v1/',
|
apiChatUrl: 'https://CHAT.DONEIT.CO.AO/api/v1/',
|
||||||
apiWsChatUrl: 'wss://CHAT.DONEIT.CO.AO/websocket', */
|
apiWsChatUrl: 'wss://CHAT.DONEIT.CO.AO/websocket',
|
||||||
apiChatUrl: 'https://gd-chat.oapr.gov.ao/api/v1/',
|
//apiChatUrl: 'https://gd-chat.oapr.gov.ao/api/v1/',
|
||||||
apiWsChatUrl: 'wss://gd-chat.oapr.gov.ao/websocket',
|
//apiWsChatUrl: 'wss://gd-chat.oapr.gov.ao/websocket',
|
||||||
// apiChatUrl: 'https://gdchat-dev.dyndns.info/api/v1/',
|
// apiChatUrl: 'https://gdchat-dev.dyndns.info/api/v1/',
|
||||||
// apiWsChatUrl: 'wss://gdchat-dev.dyndns.info/websocket',
|
// apiWsChatUrl: 'wss://gdchat-dev.dyndns.info/websocket',
|
||||||
production: true,
|
production: true,
|
||||||
domain: '',
|
domain: 'evandre.dasilva@equilibrium.co.ao',
|
||||||
defaultuser: '',//paulo.pinto@gabinetedigital.local
|
defaultuser: 'evandre.dasilva@equilibrium.co.ao',//paulo.pinto@gabinetedigital.local
|
||||||
defaultuserpwd: '', //tabteste@006,06,
|
defaultuserpwd: 'Luand@1219', //tabteste@006,
|
||||||
chatOffline: true,
|
chatOffline: true,
|
||||||
presidencia: false,
|
presidencia: false,
|
||||||
version: versionData,
|
version: versionData,
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { versionData } from '../../version/git-version'
|
import { versionData } from '../../version/git-version'
|
||||||
export const environment = {
|
export const environment = {
|
||||||
// apiURL: 'https://gabinetedigital.dyndns.info/GabineteDigital.Services/V5/api/',
|
// apiURL: 'https://gabinetedigital.dyndns.info/GabineteDigital.Services/V5/api/',
|
||||||
apiURL: 'https://gd-api.oapr.gov.ao/api/',
|
apiURL: 'https://API.DONEIT.CO.AO/api/',
|
||||||
//apiURL: 'https://API.DONEIT.CO.AO/api/',
|
//apiURL: 'https://API.DONEIT.CO.AO/api/',
|
||||||
//apiURL: 'https://gdapi-dev.dyndns.info/GabineteDigital.Services/V5/api/',
|
//apiURL: 'https://gdapi-dev.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/',
|
||||||
@@ -9,14 +9,14 @@ export const environment = {
|
|||||||
// apiWsChatUrl: 'wss://192.168.0.29:3000/websocket',
|
// apiWsChatUrl: 'wss://192.168.0.29:3000/websocket',
|
||||||
//apiChatUrl: 'https://gdchat-dev.dyndns.info/api/v1/',
|
//apiChatUrl: 'https://gdchat-dev.dyndns.info/api/v1/',
|
||||||
//apiWsChatUrl: 'wss://gdchat-dev.dyndns.info/websocket',
|
//apiWsChatUrl: 'wss://gdchat-dev.dyndns.info/websocket',
|
||||||
//apiChatUrl: 'https://CHAT.DONEIT.CO.AO/api/v1/',
|
apiChatUrl: 'https://CHAT.DONEIT.CO.AO/api/v1/',
|
||||||
//apiWsChatUrl: 'wss://CHAT.DONEIT.CO.AO/websocket',
|
apiWsChatUrl: 'wss://CHAT.DONEIT.CO.AO/websocket',
|
||||||
apiChatUrl: 'https://gd-chat.oapr.gov.ao/api/v1/',
|
//apiChatUrl: 'https://gd-chat.oapr.gov.ao/api/v1/',
|
||||||
apiWsChatUrl: 'wss://gd-chat.oapr.gov.ao/websocket',
|
//apiWsChatUrl: 'wss://gd-chat.oapr.gov.ao/websocket',
|
||||||
production: false,
|
production: false,
|
||||||
domain: 'evandre.dasilva@equilibrium.co.ao',
|
domain: 'equilibrium.co.ao',
|
||||||
defaultuser: 'ppinto@oapr.gov.ao',//paulo.pinto@gabinetedigital.local
|
defaultuser: 'evandre.dasilva@equilibrium.co.ao',//paulo.pinto@gabinetedigital.local
|
||||||
defaultuserpwd: 'M@p2022', //tabteste@006,
|
defaultuserpwd: 'Luand@1219', //tabteste@006,
|
||||||
chatOffline: true,
|
chatOffline: true,
|
||||||
presidencia: false,
|
presidencia: false,
|
||||||
version: versionData,
|
version: versionData,
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
export let versionData = {
|
export let versionData = {
|
||||||
"shortSHA": "b6a351421",
|
"shortSHA": "711e9fc64",
|
||||||
"SHA": "b6a3514215a666d62a2ded788463375c2b7ff7ee",
|
"SHA": "711e9fc640420029233c0aa0fad0151f26a5fb4a",
|
||||||
"branch": "no_bug_movemente",
|
"branch": "no_bug_movemente",
|
||||||
"lastCommitAuthor": "'Peter Maquiran'",
|
"lastCommitAuthor": "'Peter Maquiran'",
|
||||||
"lastCommitTime": "'Tue Jan 17 17:08:03 2023 +0100'",
|
"lastCommitTime": "'Tue Jan 17 17:12:01 2023 +0100'",
|
||||||
"lastCommitMessage": "improve search",
|
"lastCommitMessage": "fix",
|
||||||
"lastCommitNumber": "4647",
|
"lastCommitNumber": "4650",
|
||||||
"change": "",
|
"change": "",
|
||||||
"changeStatus": "On branch no_bug_movemente\nAll conflicts fixed but you are still merging.\n (use \"git commit\" to conclude merge)\n\nChanges to be committed:\n\tmodified: android/app/src/main/res/drawable-land-hdpi/splash.png\n\tnew file: android/app/src/main/res/drawable-land-ldpi/splash.png\n\tmodified: android/app/src/main/res/drawable-land-mdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-land-xhdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-land-xxhdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-land-xxxhdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-port-hdpi/splash.png\n\tnew file: android/app/src/main/res/drawable-port-ldpi/splash.png\n\tmodified: android/app/src/main/res/drawable-port-mdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-port-xhdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-port-xxhdpi/splash.png\n\tmodified: android/app/src/main/res/drawable-port-xxxhdpi/splash.png\n\tmodified: android/app/src/main/res/mipmap-hdpi/ic_launcher.png\n\tmodified: android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png\n\tmodified: android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png\n\tmodified: android/app/src/main/res/mipmap-mdpi/ic_launcher.png\n\tmodified: android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png\n\tmodified: android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png\n\tmodified: android/app/src/main/res/mipmap-xhdpi/ic_launcher.png\n\tmodified: android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png\n\tmodified: android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png\n\tmodified: android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png\n\tmodified: android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png\n\tmodified: android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png\n\tmodified: android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png\n\tmodified: android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png\n\tmodified: android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png\n\tmodified: src/app/modals/profile/profile.page.html\n\tmodified: src/app/pipes/expediente-task.pipe.ts\n\tmodified: version/git-version.ts",
|
"changeStatus": "On branch no_bug_movemente\nChanges to be committed:\n (use \"git restore --staged <file>...\" to unstage)\n\tmodified: src/app/pages/login/login.page.ts\n\tmodified: src/app/services/chat/chat-system.service.ts\n\tmodified: src/app/services/chat/rochet-chat-connector.service.ts\n\tmodified: src/app/services/events.service.ts\n\tmodified: src/environments/environment.prod.ts\n\tmodified: src/environments/environment.ts\n\tnew file: version/git-static-version.ts",
|
||||||
"changeAuthor": "peter.maquiran"
|
"changeAuthor": "peter.maquiran"
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user