This commit is contained in:
Peter Maquiran
2021-07-27 16:53:37 +01:00
parent 8eab9e67d7
commit 4fcafe1fd9
5 changed files with 56 additions and 91 deletions
@@ -168,100 +168,41 @@ export class ViewEventPage implements OnInit {
});
}
async openExpedientActionsModal(taskAction: any, task: any) {
let classs;
if( window.innerWidth <= 800){
classs = 'modal modal-desktop'
} else {
classs = 'modal modal-desktop showAsideOptions'
}
const doc = this.loadedAttachments[ this.dicIndex];
task = {
serialNumber: doc.SourceId,
taskStartDate: doc.CreateDate,
isEvent: true,
workflowInstanceDataFields: {
FsId: doc.ApplicationId,
FolderID: null,
DocId: doc.SourceId,
Subject: doc.SourceName
},
}
const modal = await this.modalController.create({
component: ExpedientTaskModalPage,
componentProps: {
taskAction: taskAction,
task: task,
profile: this.profile,
},
cssClass: classs,
});
await modal.present();
modal.onDidDismiss().then(res=>{
console.log(res['data']);
if(res['data']=='openDiscart'){
console.log('open discart');
// this.distartExpedientModal();
}
});
}
async openBookMeetingModal(task: any) {
const doc = this.loadedAttachments[ this.dicIndex];
const Customtask = {
serialNumber: doc.SourceId,
taskStartDate: doc.CreateDate,
isEvent: true,
workflowInstanceDataFields: {
FsId: doc.ApplicationId,
FolderID: null,
DocId: doc.SourceId,
Subject: doc.SourceName
},
}
let classs;
if( window.innerWidth <= 800){
classs = 'book-meeting-modal modal modal-desktop'
} else {
classs = 'modal modal-desktop showAsideOptions'
}
const modal = await this.modalController.create({
component: BookMeetingModalPage,
componentProps: {
task: task,
},
cssClass: classs,
backdropDismiss: false
});
await modal.present();
modal.onDidDismiss();
}
async openTaskOptions() {
const doc = this.loadedAttachments[ this.dicIndex];
let customTask = {
serialNumber: doc.SourceId,
taskStartDate: doc.CreateDate,
isEvent: true,
workflowInstanceDataFields: {
FsId: doc.ApplicationId,
FolderID: null,
DocId: doc.SourceId,
Subject: doc.SourceName
},
let customTask;
if(doc.ApplicationID == 361 || doc.ApplicationId == 361) {
customTask = {
serialNumber: doc.DispatchNumber,
taskStartDate: doc.DateDispatch,
isEvent: true,
workflowInstanceDataFields: {
FsId: doc.ApplicationID,
FolderID: null,
DocId: doc.DispatchNumber,
Subject: doc.Assunto
},
}
} else if (doc.ApplicationID == 8 || doc.ApplicationId == 8) {
customTask = {
serialNumber: doc.DocId,
taskStartDate: doc.DocDate,
isEvent: true,
workflowInstanceDataFields: {
FsId: doc.ApplicationID || doc.ApplicationId,
FolderID: null,
DocId: doc.DocId,
Subject: doc.Assunto
}
}
}
console.log(doc)
customTask.Status = ''
const popover = await this.modalController.create({
component: OptsExpedientePage,
cssClass: 'model aside-modal search-submodal',