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:
@@ -8,6 +8,7 @@ export class DailyWorkTask{
|
||||
DocumentsQty:any;
|
||||
WorkflowName:string;
|
||||
activityInstanceName: string;
|
||||
Status: string;
|
||||
}
|
||||
|
||||
export class tasksList{
|
||||
@@ -55,4 +56,4 @@ export class tasksList{
|
||||
workflowInstanceFolio: string
|
||||
workflowInstanceID: number
|
||||
workflowName: string
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,10 +38,10 @@ export class ViewEventPage implements OnInit {
|
||||
caller:string;
|
||||
customDate:any;
|
||||
today:any;
|
||||
|
||||
|
||||
months = ["Janeiro", "Fevereiro", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"];
|
||||
days = ["Domingo", "Segunda-feira", "Terça-feira", "Quarta-feira", "Quinta-feira", "Sexta-feira", "Sábado"];
|
||||
|
||||
|
||||
dicIndex = 0;
|
||||
|
||||
constructor(
|
||||
@@ -56,7 +56,7 @@ export class ViewEventPage implements OnInit {
|
||||
private activatedRoute: ActivatedRoute,
|
||||
private router: Router,
|
||||
private toastService: ToastService,
|
||||
)
|
||||
)
|
||||
{
|
||||
this.isEventEdited = false;
|
||||
this.loadedEvent = new Event();
|
||||
@@ -75,11 +75,11 @@ export class ViewEventPage implements OnInit {
|
||||
console.log(params["eventId"]);
|
||||
}
|
||||
}); */
|
||||
|
||||
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
|
||||
this.loadEvent();
|
||||
this.getAttachments();
|
||||
|
||||
@@ -90,11 +90,11 @@ export class ViewEventPage implements OnInit {
|
||||
this.modalController.dismiss(this.isEventEdited);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
}
|
||||
|
||||
close(){
|
||||
|
||||
|
||||
this.modalController.dismiss(this.isEventEdited);
|
||||
}
|
||||
|
||||
@@ -110,31 +110,33 @@ export class ViewEventPage implements OnInit {
|
||||
}
|
||||
|
||||
loadEvent(){
|
||||
const loader = this.toastService.loading();
|
||||
this.eventsService.getEvent(this.eventId).subscribe(res => {
|
||||
this.loadedEvent = res;
|
||||
|
||||
console.log(res);
|
||||
|
||||
|
||||
/* this.today = new Date(res.StartDate);
|
||||
this.customDate = this.days[this.today.getDay()]+ ", " + this.today.getDate() +" de " + ( this.months[this.today.getMonth()]); */
|
||||
loader.remove()
|
||||
});
|
||||
}
|
||||
|
||||
deleteEvent(){
|
||||
this.eventsService.deleteEvent(this.loadedEvent.EventId, 0).subscribe(async () =>
|
||||
this.eventsService.deleteEvent(this.loadedEvent.EventId, 0).subscribe(async () =>
|
||||
{
|
||||
const alert = await this.alertController.create({
|
||||
cssClass: 'my-custom-class',
|
||||
header: 'Evento removido',
|
||||
buttons: ['OK']
|
||||
});
|
||||
|
||||
|
||||
setTimeout(()=>{
|
||||
alert.dismiss();
|
||||
}, 1500);
|
||||
this.goBack();
|
||||
this.toastService.successMessage('Evento apagado');
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
getAttachments() {
|
||||
@@ -146,18 +148,18 @@ export class ViewEventPage implements OnInit {
|
||||
console.log(res);
|
||||
});
|
||||
} catch (error) {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
finally {
|
||||
loader.remove()
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
async editEventDetail() {
|
||||
|
||||
console.log(this.caller);
|
||||
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: EditEventPage,
|
||||
@@ -171,7 +173,7 @@ export class ViewEventPage implements OnInit {
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then((res) => {
|
||||
console.log(res);
|
||||
|
||||
|
||||
if(res){
|
||||
setTimeout(() => {
|
||||
/* this.loadEvent(); */
|
||||
@@ -183,7 +185,7 @@ export class ViewEventPage implements OnInit {
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
async editEvent() {
|
||||
console.log(this.loadedEvent);
|
||||
|
||||
@@ -193,7 +195,7 @@ export class ViewEventPage implements OnInit {
|
||||
} else {
|
||||
classs = 'modal modal-desktop showAsideOptions'
|
||||
}
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: EditEventPage,
|
||||
componentProps:{
|
||||
@@ -205,7 +207,7 @@ export class ViewEventPage implements OnInit {
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then((res) => {
|
||||
console.log(res);
|
||||
|
||||
|
||||
if(res){
|
||||
setTimeout(() => {
|
||||
/* this.loadEvent(); */
|
||||
@@ -223,7 +225,7 @@ export class ViewEventPage implements OnInit {
|
||||
const url: string = res.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1");
|
||||
const browser = this.iab.create(url,"_blank");
|
||||
browser.show();
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
@@ -236,9 +238,9 @@ export class ViewEventPage implements OnInit {
|
||||
taskStartDate: doc.CreateDate,
|
||||
isEvent: true,
|
||||
workflowInstanceDataFields: {
|
||||
FsId: doc.ApplicationId,
|
||||
FsId: doc.ApplicationId,
|
||||
FolderID: null,
|
||||
DocId: doc.SourceId,
|
||||
DocId: doc.SourceId,
|
||||
Subject: doc.SourceName
|
||||
},
|
||||
}
|
||||
|
||||
@@ -84,6 +84,7 @@ export class DiplomasAssinarPage implements OnInit {
|
||||
"DocId": element.workflowInstanceDataFields.DocId,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
},
|
||||
@@ -99,6 +100,7 @@ export class DiplomasAssinarPage implements OnInit {
|
||||
"DocId": element.workflowInstanceDataFields.DocId,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
});
|
||||
|
||||
@@ -25,6 +25,10 @@ constructor(
|
||||
private activatedRoute: ActivatedRoute,
|
||||
) {
|
||||
this.diplomasList = [];
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
this.segment = 'validar';
|
||||
this.activatedRoute.queryParams.subscribe(params => {
|
||||
console.log('Cria');
|
||||
@@ -35,13 +39,9 @@ constructor(
|
||||
this.segment = 'assinados';
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
const pathname = window.location.pathname
|
||||
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if(event instanceof NavigationEnd && event.url == pathname) {
|
||||
this.refreshing();
|
||||
@@ -51,13 +51,13 @@ constructor(
|
||||
|
||||
/* async loadDiplomas(){
|
||||
console.log('Load');
|
||||
|
||||
|
||||
this.activatedRoute.data.subscribe(data => {
|
||||
console.log(data['diplomas']);
|
||||
|
||||
|
||||
switch (this.segment) {
|
||||
case 'validar':
|
||||
|
||||
|
||||
let diplomasValidar = data['diplomas'].filter(data => data.activityInstanceName == "Revisar Diploma");
|
||||
diplomasValidar.forEach(async element => {
|
||||
let DocId = element.workflowInstanceDataFields.FolderID;
|
||||
@@ -68,7 +68,7 @@ constructor(
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
|
||||
|
||||
let task = {
|
||||
"SerialNumber": element.serialNumber,
|
||||
"Folio": element.workflowInstanceDataFields.Subject,
|
||||
@@ -83,7 +83,7 @@ constructor(
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
this.diplomasList = removeDuplicate( this.diplomasList)
|
||||
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
break;
|
||||
@@ -100,7 +100,7 @@ constructor(
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
|
||||
|
||||
let task = {
|
||||
"SerialNumber": element.serialNumber,
|
||||
"Folio": element.workflowInstanceDataFields.Subject,
|
||||
@@ -115,7 +115,7 @@ constructor(
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
this.diplomasList = removeDuplicate( this.diplomasList)
|
||||
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
break;
|
||||
@@ -132,7 +132,7 @@ constructor(
|
||||
ngOnDestroy(): void {
|
||||
console.log('8. on destroy called');
|
||||
}
|
||||
|
||||
|
||||
segmentChanged(ev: any) {
|
||||
this.LoadList();
|
||||
}
|
||||
@@ -144,14 +144,14 @@ constructor(
|
||||
async LoadList(){
|
||||
this.diplomasList = [];
|
||||
console.log(this.diplomasList);
|
||||
|
||||
|
||||
let diplomas = await this.processes.GetTasksList("Despacho do Presidente da República", false).toPromise();
|
||||
|
||||
|
||||
switch (this.segment) {
|
||||
case 'validar':
|
||||
let diplomasValidar = diplomas.filter(data => data.activityInstanceName == "Revisar Diploma");
|
||||
console.log(diplomasValidar);
|
||||
|
||||
|
||||
diplomasValidar.forEach(async element => {
|
||||
let DocId = element.workflowInstanceDataFields.FolderID;
|
||||
let ApplicationId = element.workflowInstanceDataFields.ApplicationId;
|
||||
@@ -160,7 +160,7 @@ constructor(
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
|
||||
|
||||
let task = {
|
||||
"SerialNumber": element.serialNumber,
|
||||
"Folio": element.workflowInstanceDataFields.Subject,
|
||||
@@ -172,11 +172,12 @@ constructor(
|
||||
"DocId": element.workflowInstanceDataFields.DocIdDiferimento,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
this.diplomasList = removeDuplicate(this.diplomasList);
|
||||
this.diplomasList = this.sortArrayISODate(this.diplomasList).reverse();
|
||||
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
break;
|
||||
@@ -203,11 +204,12 @@ constructor(
|
||||
"DocId": element.workflowInstanceDataFields.DocIdDiferimento,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
this.diplomasList = removeDuplicate(this.diplomasList);
|
||||
this.diplomasList = this.sortArrayISODate(this.diplomasList).reverse();
|
||||
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
break;
|
||||
@@ -229,7 +231,7 @@ constructor(
|
||||
|
||||
async doRefresh(event) {
|
||||
console.log('refresh');
|
||||
|
||||
|
||||
//this.loadDiplomas();
|
||||
this.LoadList();
|
||||
setTimeout(() => {
|
||||
@@ -242,4 +244,4 @@ constructor(
|
||||
// window.history.back()
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ export class ApproveEventPage implements OnInit {
|
||||
customDate:any;
|
||||
today:any;
|
||||
show: boolean = false;
|
||||
|
||||
|
||||
months = ["Janeiro", "Fevereiro", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"];
|
||||
days = ["Domingo", "Segunda-feira", "Terça-feira", "Quarta-feira", "Quinta-feira", "Sexta-feira", "Sábado"];
|
||||
|
||||
@@ -47,10 +47,10 @@ export class ApproveEventPage implements OnInit {
|
||||
private iab: InAppBrowser,
|
||||
private animationController: AnimationController,
|
||||
private toastService: ToastService,
|
||||
) {
|
||||
) {
|
||||
this.activatedRoute.paramMap.subscribe(params => {
|
||||
console.log(params["params"]);
|
||||
|
||||
|
||||
if(params["params"].serialNumber) {
|
||||
this.serialNumber = params["params"].serialNumber;
|
||||
}
|
||||
@@ -63,7 +63,7 @@ export class ApproveEventPage implements OnInit {
|
||||
ngOnInit() {
|
||||
console.log(this.serialNumber);
|
||||
console.log(this.caller);
|
||||
|
||||
|
||||
this.getTask();
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ export class ApproveEventPage implements OnInit {
|
||||
this.today = new Date(this.loadedEvent.workflowInstanceDataFields.StartDate);
|
||||
|
||||
this.customDate = this.days[this.today.getDay()]+ ", " + this.today.getDate() +" de " + ( this.months[this.today.getMonth()]);
|
||||
|
||||
|
||||
let instanceId = this.loadedEvent.workflowInstanceDataFields.InstanceId;
|
||||
this.getAttachments(instanceId);
|
||||
}
|
||||
@@ -96,14 +96,14 @@ export class ApproveEventPage implements OnInit {
|
||||
async approveTask(serialNumber:string) {
|
||||
let body = { "serialNumber": serialNumber, "action": "Aprovar" }
|
||||
console.log(body);
|
||||
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise()
|
||||
this.toastService.successMessage();
|
||||
this.goBack();
|
||||
|
||||
|
||||
} catch (error) {
|
||||
this.toastService.badRequest()
|
||||
}
|
||||
@@ -112,9 +112,9 @@ export class ApproveEventPage implements OnInit {
|
||||
}
|
||||
|
||||
|
||||
/* this.approveEventDismiss.emit({
|
||||
/* this.approveEventDismiss.emit({
|
||||
"serialNumber": serialNumber,
|
||||
"action": "Aprovar",
|
||||
"action": "Aprovar",
|
||||
"saveData": {
|
||||
loadedEvent: this.loadedEvent,
|
||||
today: this.today,
|
||||
@@ -139,9 +139,9 @@ export class ApproveEventPage implements OnInit {
|
||||
modal.onDidDismiss()
|
||||
.then( async (res) => {
|
||||
console.log(res.data);
|
||||
|
||||
|
||||
if(res.data !== ''){
|
||||
let body = { "serialNumber": serialNumber,
|
||||
let body = { "serialNumber": serialNumber,
|
||||
"action": "Emendar",
|
||||
"dataFields": {
|
||||
"ReviewUserComment": res.data,
|
||||
@@ -150,8 +150,8 @@ export class ApproveEventPage implements OnInit {
|
||||
console.log(body);
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise();
|
||||
this.toastService.successMessage('Pedido enviado');
|
||||
this.goBack();
|
||||
@@ -166,7 +166,7 @@ export class ApproveEventPage implements OnInit {
|
||||
//this.alertService.presentAlert('Operação cancelada!');
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
//this.openEmendMessageModal(serialNumber);
|
||||
//this.goBack();
|
||||
}
|
||||
@@ -175,7 +175,7 @@ export class ApproveEventPage implements OnInit {
|
||||
let body = { "serialNumber": serialNumber, "action": "Rejeitar" }
|
||||
console.log(body);
|
||||
const loader = this.toastService.loading()
|
||||
try {
|
||||
try {
|
||||
this.processes.PostTaskAction(body).toPromise();
|
||||
await this.toastService.successMessage('Processo rejeitado');
|
||||
this.goBack();
|
||||
@@ -186,17 +186,17 @@ export class ApproveEventPage implements OnInit {
|
||||
loader.remove()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
async getAttachments(instanceId:string){
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
this.loadedAttachments = await this.attachmentsService.getAttachmentsById(instanceId).toPromise();
|
||||
|
||||
|
||||
} catch (error) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
viewDocument(sourceId){
|
||||
@@ -205,7 +205,7 @@ export class ApproveEventPage implements OnInit {
|
||||
const url: string = res.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1");
|
||||
const browser = this.iab.create(url,"_blank");
|
||||
browser.show();
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
@@ -222,7 +222,7 @@ export class ApproveEventPage implements OnInit {
|
||||
});
|
||||
return await popover.present();
|
||||
}
|
||||
|
||||
|
||||
openMenu() {
|
||||
this.menu.open();
|
||||
}
|
||||
@@ -239,9 +239,9 @@ export class ApproveEventPage implements OnInit {
|
||||
|
||||
modal.onDidDismiss().then( async (res) => {
|
||||
console.log(res.data);
|
||||
|
||||
|
||||
if(res.data !== ''){
|
||||
let body = { "serialNumber": serialNumber,
|
||||
let body = { "serialNumber": serialNumber,
|
||||
"action": "Emendar",
|
||||
"dataFields": {
|
||||
"ReviewUserComment": res.data,
|
||||
@@ -250,7 +250,7 @@ export class ApproveEventPage implements OnInit {
|
||||
console.log(body);
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
|
||||
try {
|
||||
await this.processes.PostTaskAction(body).toPromise();
|
||||
this.toastService.successMessage();
|
||||
@@ -295,6 +295,6 @@ export class ApproveEventPage implements OnInit {
|
||||
this.getTask();
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -72,6 +72,7 @@ export class ExpedientePage implements OnInit {
|
||||
"DocumentsQty": 0,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.taskslist.push(task);
|
||||
});
|
||||
|
||||
@@ -42,7 +42,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
profile: string;
|
||||
intervenientes: any;
|
||||
cc: any = [];
|
||||
|
||||
|
||||
loggeduser: User;
|
||||
|
||||
constructor(
|
||||
@@ -74,7 +74,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
ngOnInit() {
|
||||
this.profile = "mdgpr";
|
||||
console.log(this.serialnumber);
|
||||
|
||||
|
||||
this.activatedRoute.paramMap.subscribe(paramMap => {
|
||||
if (!paramMap.has('SerialNumber')) {
|
||||
return;
|
||||
@@ -95,7 +95,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
if(this.task.Status == "Pending" && this.caller != 'events'){
|
||||
if (window.innerWidth <= 800) {
|
||||
this.router.navigate(['/home/gabinete-digital/pendentes']);
|
||||
}
|
||||
}
|
||||
else {
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
@@ -111,7 +111,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
case 'events':
|
||||
this.router.navigate(['/home',params["params"].caller]);
|
||||
break;
|
||||
|
||||
|
||||
case 'gabinete-digital':
|
||||
let navigationExtras: NavigationExtras = {
|
||||
queryParams: {
|
||||
@@ -161,6 +161,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
"DocId": res.workflowInstanceDataFields.DocIdD,
|
||||
"WorkflowName": res.workflowDisplayName,
|
||||
"activityInstanceName": res.activityInstanceName,
|
||||
"Status": res.workflowInstanceDataFields.Status,
|
||||
}
|
||||
|
||||
console.log('task', this.task);
|
||||
@@ -180,7 +181,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
return user.Type == 'CC';
|
||||
});
|
||||
console.log(users);
|
||||
|
||||
|
||||
})
|
||||
|
||||
});
|
||||
@@ -209,7 +210,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
const url: string = res.replace("webTRIX.Viewer","webTRIX.Viewer.Branch1");
|
||||
const browser = this.iab.create(url,"_blank");
|
||||
browser.show();
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
@@ -219,8 +220,8 @@ export class ExpedientePrPage implements OnInit {
|
||||
}
|
||||
|
||||
async approve(note:string, documents:any){
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
"action": "Aprovar",
|
||||
"ActionTypeId": 100000004 ,
|
||||
"dataFields": {
|
||||
@@ -230,7 +231,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
}
|
||||
|
||||
console.log(body);
|
||||
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
@@ -246,8 +247,8 @@ export class ExpedientePrPage implements OnInit {
|
||||
}
|
||||
|
||||
async sendToReview(note:string, documents:any){
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
let body = {
|
||||
"serialNumber": this.serialnumber,
|
||||
"action": "Retificar",
|
||||
"ActionTypeId": 99999877,
|
||||
"dataFields": {
|
||||
@@ -283,9 +284,9 @@ export class ExpedientePrPage implements OnInit {
|
||||
cssClass: classs,
|
||||
backdropDismiss: true
|
||||
});
|
||||
|
||||
|
||||
await modal.present();
|
||||
|
||||
|
||||
modal.onDidDismiss().then(res => {
|
||||
console.log(res);
|
||||
if(res.data){
|
||||
@@ -295,7 +296,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
SourceId: e.Id,
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
let docs = {
|
||||
ProcessInstanceID: "",
|
||||
Attachments: DocumentToSave,
|
||||
@@ -336,11 +337,11 @@ export class ExpedientePrPage implements OnInit {
|
||||
// alert('close '+ res['data'])
|
||||
if(res['data']){
|
||||
console.log('open discart');
|
||||
|
||||
|
||||
this.distartExpedientModal(body);
|
||||
}
|
||||
else{
|
||||
console.log('Not open');
|
||||
console.log('Not open');
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -353,7 +354,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
cssClass: 'discart-expedient-modal',
|
||||
backdropDismiss: false
|
||||
});
|
||||
|
||||
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then( async (res)=>{
|
||||
console.log(res['data']);
|
||||
@@ -371,7 +372,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
try {
|
||||
await this.processes.CompleteTask(otherbody).toPromise()
|
||||
this.toastService.successMessage('Processo descartado');
|
||||
this.goBack();
|
||||
@@ -391,7 +392,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
|
||||
const loader = this.toastService.loading()
|
||||
|
||||
try {
|
||||
try {
|
||||
await this.processes.CompleteTask(body).toPromise();
|
||||
this.toastService.successMessage('Processo descartado');
|
||||
this.goBack();
|
||||
@@ -433,7 +434,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
cssClass: 'discart-expedient-modal',
|
||||
backdropDismiss: false
|
||||
});
|
||||
|
||||
|
||||
await modal.present();
|
||||
modal.onDidDismiss();
|
||||
}
|
||||
@@ -475,7 +476,7 @@ export class ExpedientePrPage implements OnInit {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
async openOptions(taskAction?: any) {
|
||||
const popover = await this.popoverController.create({
|
||||
|
||||
@@ -71,6 +71,7 @@ export class ExpedientesPrPage implements OnInit {
|
||||
"DocumentsQty": 0,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.taskslist.push(task);
|
||||
});
|
||||
@@ -98,6 +99,7 @@ export class ExpedientesPrPage implements OnInit {
|
||||
"DocumentsQty": 0,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.taskslist.push(task);
|
||||
});
|
||||
|
||||
@@ -81,7 +81,7 @@ export class PendentesPage implements OnInit {
|
||||
"CreateDate": taskDate,
|
||||
"DocumentURL": element.workflowInstanceDataFields.ViewerRequest,
|
||||
"Remetente": element.workflowInstanceDataFields.Remetente,
|
||||
"DocumentsQty": 0,
|
||||
"DocumentsQty": element.totalDocuments,
|
||||
"DocId": element.workflowInstanceDataFields.DocIdDiferimento,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
@@ -90,6 +90,8 @@ export class PendentesPage implements OnInit {
|
||||
this.pendentesList.push(task);
|
||||
this.pendentesList = removeDuplicate( this.pendentesList)
|
||||
this.pendentesList = this.sortArrayISODate(this.pendentesList);
|
||||
console.log(this.pendentesList);
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
}
|
||||
|
||||
@@ -55,8 +55,8 @@ constructor (
|
||||
private alertService: AlertService,
|
||||
private authService: AuthService,
|
||||
private router: Router,
|
||||
|
||||
) {
|
||||
|
||||
) {
|
||||
this.profile = 'mdgpr';
|
||||
this.loggeduser = authService.ValidatedUser;
|
||||
}
|
||||
@@ -67,7 +67,6 @@ ngOnInit() {
|
||||
this.LoadList();
|
||||
|
||||
const pathname = window.location.pathname
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if(event instanceof NavigationEnd && event.url == pathname) {
|
||||
this.doRefresh();
|
||||
@@ -104,7 +103,7 @@ goToDespachoPr(serialNumber:any){
|
||||
|
||||
let result = await this.processes.GetTasksList("Despacho do Presidente da República", false).toPromise();
|
||||
console.log(result);
|
||||
|
||||
|
||||
let despachosPr;
|
||||
switch (this.loggeduser.Profile) {
|
||||
case 'MDGPR':
|
||||
@@ -115,9 +114,9 @@ goToDespachoPr(serialNumber:any){
|
||||
break;
|
||||
}
|
||||
console.log(despachosPr);
|
||||
|
||||
|
||||
despachosPr.forEach( (element, index) => {
|
||||
|
||||
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
@@ -134,6 +133,7 @@ goToDespachoPr(serialNumber:any){
|
||||
"FolderID": element.workflowInstanceDataFields.FolderID,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
|
||||
this.despachoList.push(task);
|
||||
@@ -223,9 +223,9 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
taskStartDate: doc.CreateDate,
|
||||
isEvent: true,
|
||||
workflowInstanceDataFields: {
|
||||
FsId: doc.ApplicationId,
|
||||
FsId: doc.ApplicationId,
|
||||
FolderID: null,
|
||||
DocId: doc.SourceId,
|
||||
DocId: doc.SourceId,
|
||||
Subject: doc.SourceName
|
||||
},
|
||||
}
|
||||
@@ -245,7 +245,7 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
this.LoadList();
|
||||
if(res['data']=='openDiscart'){
|
||||
console.log('open discart');
|
||||
|
||||
|
||||
// this.distartExpedientModal();
|
||||
|
||||
}
|
||||
@@ -262,13 +262,13 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
taskStartDate: doc.CreateDate,
|
||||
isEvent: true,
|
||||
workflowInstanceDataFields: {
|
||||
FsId: doc.ApplicationId,
|
||||
FsId: doc.ApplicationId,
|
||||
FolderID: null,
|
||||
DocId: doc.SourceId,
|
||||
DocId: doc.SourceId,
|
||||
Subject: doc.SourceName
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
let classs;
|
||||
if( window.innerWidth <= 800){
|
||||
classs = 'book-meeting-modal modal modal-desktop'
|
||||
@@ -292,7 +292,7 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
this.close();
|
||||
this.openMenu(); */
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
@@ -302,7 +302,7 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
const doc = this.taskList[ this.dicIndex];
|
||||
|
||||
console.log(doc, this.dicIndex, this.taskList)
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: DiscartExpedientModalPage,
|
||||
componentProps: {
|
||||
@@ -313,7 +313,7 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
cssClass: 'discart-expedient-modal',
|
||||
backdropDismiss: false
|
||||
});
|
||||
|
||||
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then(res=>{
|
||||
this.LoadList();
|
||||
@@ -323,12 +323,12 @@ async viewExpedientDetail(serialNumber:any) {
|
||||
this.close();
|
||||
this.openMenu(); */
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
docIndex(index: number) {
|
||||
this.dicIndex = index;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ export class DespachosPage implements OnInit {
|
||||
deferimentoList:DailyWorkTask[] = [];
|
||||
|
||||
taskList:tasksList[] = [];
|
||||
|
||||
|
||||
taskType: string;
|
||||
serialNumber:string;
|
||||
totalDocs:any;
|
||||
@@ -51,7 +51,7 @@ export class DespachosPage implements OnInit {
|
||||
private authService: AuthService,
|
||||
private router: Router,
|
||||
private activatedRoute: ActivatedRoute,
|
||||
) {
|
||||
) {
|
||||
this.profile = 'mdgpr';
|
||||
this.activatedRoute.queryParams.subscribe(params => {
|
||||
if(params["serialNumber"]) {
|
||||
@@ -72,7 +72,7 @@ export class DespachosPage implements OnInit {
|
||||
this.doRefresh();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
|
||||
segmentChanged(ev: any) {
|
||||
@@ -98,7 +98,7 @@ export class DespachosPage implements OnInit {
|
||||
this.despachoList = new Array();
|
||||
|
||||
await result.forEach( (element, index) => {
|
||||
|
||||
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
@@ -115,16 +115,17 @@ export class DespachosPage implements OnInit {
|
||||
"FolderID": element.workflowInstanceDataFields.FolderID,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
|
||||
|
||||
this.despachoList.push(task)
|
||||
|
||||
|
||||
});
|
||||
|
||||
this.despachoList = this.sortArrayISODate(this.despachoList).reverse()
|
||||
|
||||
this.despachoList.forEach( (element, index) => {
|
||||
|
||||
|
||||
// let aplicationId = element.workflowInstanceDataFields.SourceSecFsID;
|
||||
let FolderID = element['FolderID'];
|
||||
|
||||
@@ -167,9 +168,9 @@ export class DespachosPage implements OnInit {
|
||||
taskStartDate: doc.CreateDate,
|
||||
isEvent: true,
|
||||
workflowInstanceDataFields: {
|
||||
FsId: doc.ApplicationId,
|
||||
FsId: doc.ApplicationId,
|
||||
FolderID: null,
|
||||
DocId: doc.SourceId,
|
||||
DocId: doc.SourceId,
|
||||
Subject: doc.SourceName
|
||||
},
|
||||
}
|
||||
@@ -189,8 +190,8 @@ export class DespachosPage implements OnInit {
|
||||
this.LoadList();
|
||||
if(res['data']=='openDiscart'){
|
||||
console.log('open discart');
|
||||
|
||||
|
||||
|
||||
|
||||
// this.distartExpedientModal();
|
||||
|
||||
}
|
||||
@@ -207,13 +208,13 @@ export class DespachosPage implements OnInit {
|
||||
taskStartDate: doc.CreateDate,
|
||||
isEvent: true,
|
||||
workflowInstanceDataFields: {
|
||||
FsId: doc.ApplicationId,
|
||||
FsId: doc.ApplicationId,
|
||||
FolderID: null,
|
||||
DocId: doc.SourceId,
|
||||
DocId: doc.SourceId,
|
||||
Subject: doc.SourceName
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
let classs;
|
||||
if( window.innerWidth <= 800){
|
||||
classs = 'book-meeting-modal modal modal-desktop'
|
||||
@@ -241,7 +242,7 @@ export class DespachosPage implements OnInit {
|
||||
const doc = this.taskList[ this.dicIndex];
|
||||
|
||||
// console.log(doc, this.dicIndex, this.taskList)
|
||||
|
||||
|
||||
const modal = await this.modalController.create({
|
||||
component: DiscartExpedientModalPage,
|
||||
componentProps: {
|
||||
@@ -252,7 +253,7 @@ export class DespachosPage implements OnInit {
|
||||
cssClass: 'discart-expedient-modal',
|
||||
backdropDismiss: false
|
||||
});
|
||||
|
||||
|
||||
await modal.present();
|
||||
modal.onDidDismiss().then(res=>{
|
||||
this.LoadList();
|
||||
@@ -263,13 +264,12 @@ export class DespachosPage implements OnInit {
|
||||
this.close();
|
||||
this.openMenu(); */
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
docIndex(index: number) {
|
||||
this.dicIndex = index;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -58,7 +58,7 @@ serialNumber:string;
|
||||
}
|
||||
|
||||
async LoadList(){
|
||||
|
||||
|
||||
let diplomas = await this.processes.GetTasksList("Despacho do Presidente da República", false).toPromise();
|
||||
this.diplomasList = new Array();
|
||||
|
||||
@@ -87,6 +87,7 @@ serialNumber:string;
|
||||
"FolderID": element.workflowInstanceDataFields.FolderID,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
},
|
||||
@@ -107,6 +108,7 @@ serialNumber:string;
|
||||
"FolderID": element.workflowInstanceDataFields.FolderID,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
});
|
||||
|
||||
@@ -26,18 +26,12 @@ constructor(
|
||||
private alertService: AlertService,
|
||||
private router: Router,
|
||||
private activatedRoute: ActivatedRoute,
|
||||
) {
|
||||
) {
|
||||
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
const pathname = window.location.pathname
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if(event instanceof NavigationEnd && event.url == pathname) {
|
||||
this.refreshing();
|
||||
}
|
||||
});
|
||||
this.refreshing();
|
||||
}
|
||||
|
||||
segmentChanged(ev: any) {
|
||||
@@ -55,23 +49,22 @@ constructor(
|
||||
async LoadList(){
|
||||
this.diplomasList = [];
|
||||
console.log(this.diplomasList);
|
||||
|
||||
|
||||
console.log(this.segment);
|
||||
|
||||
let diplomas = await this.processes.GetTasksList("Despacho do Presidente da República", false).toPromise();
|
||||
|
||||
|
||||
switch (this.segment) {
|
||||
case 'validar':
|
||||
let diplomasValidar = diplomas.filter(data => data.activityInstanceName == "Revisar Diploma");
|
||||
console.log(diplomasValidar);
|
||||
|
||||
diplomasValidar.forEach(async element => {
|
||||
let DocId = element.workflowInstanceDataFields.FolderID;
|
||||
let ApplicationId = element.workflowInstanceDataFields.ApplicationId;
|
||||
this.totalDocs = await this.getTotalDocs(DocId);
|
||||
|
||||
diplomasValidar.forEach(element => {
|
||||
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
let taskDate = date.getFullYear()+"-"+ date.getMonth()+"-"+date.getDate()+" "+date.getHours()+":"+date.getMinutes()+ ":"+date.getSeconds();
|
||||
|
||||
|
||||
let task = {
|
||||
"SerialNumber": element.serialNumber,
|
||||
"Folio": element.workflowInstanceDataFields.Subject,
|
||||
@@ -79,15 +72,16 @@ constructor(
|
||||
"CreateDate": taskDate,
|
||||
"DocumentURL": element.workflowInstanceDataFields.ViewerRequest,
|
||||
"Remetente": element.workflowInstanceDataFields.Remetente,
|
||||
"DocumentsQty": this.totalDocs,
|
||||
"DocumentsQty": element.totalDocuments,
|
||||
"DocId": element.workflowInstanceDataFields.DocIdDiferimento,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
this.diplomasList = removeDuplicate(this.diplomasList);
|
||||
this.diplomasList = this.sortArrayISODate(this.diplomasList).reverse();
|
||||
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
break;
|
||||
@@ -95,9 +89,6 @@ constructor(
|
||||
this.diplomasList = new Array();
|
||||
let diplomasAssinados = diplomas.reverse().filter(data => data.activityInstanceName == "Diploma Assinado");
|
||||
diplomasAssinados.forEach(async element => {
|
||||
let DocId = element.workflowInstanceDataFields.FolderID;
|
||||
let ApplicationId = element.workflowInstanceDataFields.ApplicationId;
|
||||
this.totalDocs = await this.getTotalDocs(DocId);
|
||||
|
||||
let date = new Date(element.taskStartDate);
|
||||
date.setMonth(date.getMonth() + 1);
|
||||
@@ -110,25 +101,25 @@ constructor(
|
||||
"CreateDate": taskDate,
|
||||
"DocumentURL": element.workflowInstanceDataFields.ViewerRequest,
|
||||
"Remetente": element.workflowInstanceDataFields.Remetente,
|
||||
"DocumentsQty": this.totalDocs,
|
||||
"DocumentsQty": element.totalDocuments,
|
||||
"DocId": element.workflowInstanceDataFields.DocIdDiferimento,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.diplomasList.push(task);
|
||||
this.diplomasList = removeDuplicate(this.diplomasList);
|
||||
this.diplomasList = this.sortArrayISODate(this.diplomasList).reverse();
|
||||
|
||||
|
||||
});
|
||||
this.showLoader = false;
|
||||
break;
|
||||
default:
|
||||
console.log('No segment provided!');
|
||||
break;
|
||||
}
|
||||
}
|
||||
async getTotalDocs(DocId:any){
|
||||
let res = await this.processes.GetDocumentDetails(DocId, '361').toPromise();
|
||||
console.log(res.DocumentsTotal);
|
||||
return res.DocumentsTotal;
|
||||
}
|
||||
|
||||
sortArrayISODate(myArray: any) {
|
||||
return myArray.sort(function(a, b) {
|
||||
return (a.CreateDate < b.CreateDate) ? -1 : ((a.CreateDate > b.CreateDate) ? 1 : 0);
|
||||
|
||||
@@ -32,8 +32,8 @@ export class ExpedientesPrPage implements OnInit {
|
||||
private modalController: ModalController,
|
||||
private alertService: AlertService,
|
||||
private authService: AuthService,
|
||||
private router: Router,
|
||||
) {
|
||||
private router: Router,
|
||||
) {
|
||||
this.loggeduser = authService.ValidatedUser;
|
||||
this.LoadList();
|
||||
}
|
||||
@@ -41,7 +41,7 @@ export class ExpedientesPrPage implements OnInit {
|
||||
ngOnInit() {
|
||||
|
||||
const pathname = window.location.pathname
|
||||
|
||||
|
||||
this.router.events.forEach((event) => {
|
||||
if(event instanceof NavigationEnd && event.url == pathname) {
|
||||
this.refreshing();
|
||||
@@ -76,13 +76,14 @@ export class ExpedientesPrPage implements OnInit {
|
||||
"DocumentsQty": 0,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.taskslist.push(task);
|
||||
});
|
||||
console.log(this.taskslist);
|
||||
this.showLoader = false;
|
||||
});
|
||||
|
||||
|
||||
break;
|
||||
case 'PR':
|
||||
this.processes.GetTasksList("Expediente do Presidente", false).subscribe(result => {
|
||||
@@ -103,13 +104,14 @@ export class ExpedientesPrPage implements OnInit {
|
||||
"DocumentsQty": 0,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.taskslist.push(task);
|
||||
});
|
||||
console.log(this.taskslist);
|
||||
this.showLoader = false;
|
||||
});
|
||||
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -149,4 +151,3 @@ export class ExpedientesPrPage implements OnInit {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -31,9 +31,9 @@ export class ExpedientsPage implements OnInit {
|
||||
private processes:ProcessesService,
|
||||
private modalController: ModalController,
|
||||
private alertService: AlertService,
|
||||
private router: Router,
|
||||
private router: Router,
|
||||
private activatedRoute: ActivatedRoute,
|
||||
) {
|
||||
) {
|
||||
this.profile = 'mdgpr';
|
||||
|
||||
}
|
||||
@@ -42,7 +42,7 @@ export class ExpedientsPage implements OnInit {
|
||||
//Inicializar segment
|
||||
this.segment = "expedientes";
|
||||
this.LoadList();
|
||||
|
||||
|
||||
const pathname = window.location.pathname
|
||||
this.router.events.forEach((event) => {
|
||||
if(event instanceof NavigationEnd && event.url == pathname) {
|
||||
@@ -82,6 +82,7 @@ export class ExpedientsPage implements OnInit {
|
||||
"DocumentsQty": 0,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.taskslist.push(task);
|
||||
});
|
||||
@@ -97,4 +98,3 @@ export class ExpedientsPage implements OnInit {
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ import { PedidoPage } from 'src/app/pages/gabinete-digital/pedidos/pedido/pedido
|
||||
styleUrls: ['./pedidos.page.scss'],
|
||||
})
|
||||
export class PedidosPage implements OnInit {
|
||||
|
||||
|
||||
//profile:string;
|
||||
|
||||
@ViewChild(CalendarComponent) myCal: CalendarComponent;
|
||||
@@ -25,7 +25,7 @@ export class PedidosPage implements OnInit {
|
||||
taskslist:DailyWorkTask[];
|
||||
parecerList:any[];
|
||||
fulltask:any;
|
||||
|
||||
|
||||
parecerListResult:tasksList[] = [];
|
||||
deferimentoListResult:tasksList[] = [];
|
||||
|
||||
@@ -39,11 +39,11 @@ export class PedidosPage implements OnInit {
|
||||
@Output() openPedido:EventEmitter<any> = new EventEmitter<any>();
|
||||
|
||||
constructor(
|
||||
private router: Router,
|
||||
private router: Router,
|
||||
private processes:ProcessesService,
|
||||
private modalController: ModalController,
|
||||
private alertService: AlertService,
|
||||
) {
|
||||
) {
|
||||
this.profile = 'mdgpr';
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ export class PedidosPage implements OnInit {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
segmentChanged(ev: any) {
|
||||
this.LoadList();
|
||||
}
|
||||
@@ -101,16 +101,17 @@ export class PedidosPage implements OnInit {
|
||||
"FolderID": element.workflowInstanceDataFields.FolderID,
|
||||
"WorkflowName": element.workflowDisplayName,
|
||||
"activityInstanceName": element.activityInstanceName,
|
||||
"Status": element.workflowInstanceDataFields.Status,
|
||||
}
|
||||
this.parecerList.push(task);
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
else if(this.segment == 'deferimento') {
|
||||
this.taskType = "Pedido de Deferimento";
|
||||
this.processes.GetTasksList("Pedido de Deferimento", false).subscribe(result => {
|
||||
this.taskslist = result;
|
||||
|
||||
|
||||
this.deferimentoList = new Array();
|
||||
let res = result.reverse();
|
||||
res.forEach(element => {
|
||||
@@ -133,7 +134,7 @@ export class PedidosPage implements OnInit {
|
||||
}
|
||||
this.deferimentoList.push(task);
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -168,4 +169,3 @@ export class PedidosPage implements OnInit {
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user