This commit is contained in:
Peter Maquiran
2023-08-14 11:00:35 +01:00
26 changed files with 274 additions and 139 deletions
@@ -3,6 +3,8 @@ import { EventPerson } from 'src/app/models/eventperson.model';
import { ModalController, NavParams } from '@ionic/angular';
import { ContactsService } from 'src/app/services/contacts.service';
import { ThemeService } from 'src/app/services/theme.service'
import { LoginUserRespose } from 'src/app/models/user.model';
import { SessionStore } from 'src/app/store/session.service';
@Component({
selector: 'app-attendees',
@@ -21,6 +23,8 @@ export class AttendeesPageModal implements OnInit {
taskParticipants:EventPerson[] = [];
taskParticipantsCc:EventPerson[] = [];
loggeduser: LoginUserRespose;
@Input() loggedAttendSon: boolean;
constructor(
private modalCtrl: ModalController,
@@ -32,6 +36,7 @@ export class AttendeesPageModal implements OnInit {
this.adding = this.navParams.get('adding');
this.taskParticipants = this.navParams.get('taskParticipants');
this.taskParticipantsCc = this.navParams.get('taskParticipantsCc');
this.loggeduser = SessionStore.user;
}
@@ -135,8 +140,20 @@ export class AttendeesPageModal implements OnInit {
});
}
this.contacts = result;
if(this.loggedAttendSon) {
this.contacts = result;
this.showLoader = false;
} else {
this.contacts = result;
console.log('Attendes Email',this.loggeduser.Email)
let filterLoggedUserEmail = this.contacts.filter(item => item.EmailAddress.toLocaleLowerCase() != this.loggeduser.Email.toLocaleLowerCase())
console.log('Attendes Email', filterLoggedUserEmail)
let filterEmptyEmail = filterLoggedUserEmail.filter(item => item.EmailAddress.toLocaleLowerCase() != "")
this.contacts = filterEmptyEmail;
console.log('Attendes Email', this.contacts)
this.showLoader = false;
}
}
);
}
+16
View File
@@ -222,6 +222,22 @@ export class NotificationsService {
}
}
sendNotificationWithSend(userID, title, bodymsg, roomId) {
const geturl = environment.apiURL + `notifications/send`;
const headers = { 'Authorization': SessionStore.user.BasicAuthKey };
const message = {
"Service": "chat",
"IdObject": roomId
}
let id = 437
this.http.post<Tokenn>(geturl + `?userId=${userID}&title=${title}&body=${bodymsg}`, message, { headers }).subscribe(data => {
this.active = true
}, (error) => {
})
}
ChatSendMessageNotification(userID, title, bodymsg, roomId) {
+3 -3
View File
@@ -42,7 +42,7 @@ export class SearchService {
}
basicSearch(subject:string, date:string = null, sender:string = null, organicEntity:string = null, docTypeId:string = null, applicationType:string): Observable<EventSearch>{
basicSearch(subject:string, date:string = null, sender:number = null, organicEntity:number = null, docTypeId:string = null, applicationType:string): Observable<EventSearch>{
// Endpoint
const geturl = environment.apiURL + 'search';
// store params
@@ -67,7 +67,7 @@ export class SearchService {
}
basicSearchPublication(subject:string, date:string = null, sender:string = null, organicEntity:string = null, docTypeId:string = null, applicationType:string): Observable<EventSearch>{
basicSearchPublication(subject:string, date:string = null, sender:number = null, organicEntity:number = null, docTypeId:string = null, applicationType:string): Observable<EventSearch>{
// Endpoint
const geturl = environment.apiURL + 'search';
// store params
@@ -113,7 +113,7 @@ export class SearchService {
return this.http.get<any>(`${geturl}`, options);
}
searchForDoc(subject:string, date:string, sender:string, organicEntity:string, docTypeId:string, applicationType:string): Observable<EventSearch> {
searchForDoc(subject:string, date:string, sender:number, organicEntity:number, docTypeId:string, applicationType:string): Observable<EventSearch> {
// Endpoint
const geturl = environment.apiURL + 'search/attachment?';
// store params