Merge branch 'MOHEMM-SFH-COLORS' into enad-SFH

enad-SFH
umasoodch 4 years ago
commit ac278e8051

@ -24,6 +24,7 @@ import { itgRequest } from '../models/itgFormDetailsRequest';
@Injectable()
export class WorklistMainService {
public static getEITNotificationBody = "Services/ERP.svc/REST/GET_EIT_NOTIFICATION_BODY";
public static getSITNotificationBody = "Services/ERP.svc/REST/GET_SIT_NOTIFICATION_BODY";
public static getAbsenceNotificationBody = "Services/ERP.svc/REST/GET_ABSENCE_NOTIFICATION_BODY";
public static getPoNotificationBody = "Services/ERP.svc/REST/GET_PO_NOTIFICATION_BODY";
public static getMONotificationBody = "Services/ERP.svc/REST/GET_MO_NOTIFICATION_BODY";
@ -64,6 +65,21 @@ export class WorklistMainService {
);
}
public getSITNotificationBody(
WorkListBodyRequest: any,
onError?: any,
errorLabel?: string
): Observable<EITNotificatonBodyResponse> {
const request = WorkListBodyRequest;
this.authService.authenticateRequest(request);
return this.api.post(
WorklistMainService.getSITNotificationBody,
request,
onError,
errorLabel
);
}
public getAbsencesNotificationBody(
WorkListBodyRequest: any,
onError?: any,

@ -49,6 +49,9 @@
<!-- NOT ADDRESS & BASIC_DETAILS -->
<ion-col
*ngIf="getPassNotificationDetails?.REQUEST_TYPE != 'ADDRESS' && getPassNotificationDetails?.REQUEST_TYPE != 'BASIC_DETAILS' ">
<div *ngIf="notificationBodyRes?.length == 0 ">
<p>{{'worklist, loading'| translate}} <img style="width: 3%;" src="../assets/icon/progress-loading.gif"/></p>
</div>
<div *ngIf="notificationBodyRes?.length > 0 ">
<ion-card *ngFor="let item of notificationBodyRes;let i=index; "
style="width: 91%;">

@ -264,8 +264,8 @@ export class WorklistMainComponent implements OnInit {
this.getAttachmentNotification(this.WorkListAttachObj);
this.getActionHistory(this.WorkListActionHistoryObj);
if (this.getPassNotificationDetails.REQUEST_TYPE == "EIT") {
this.getEITNotificationDetails(this.WorkListBodyObj);
if (this.getPassNotificationDetails.REQUEST_TYPE == "SIT") {
this.getSITNotificationDetails(this.WorkListBodyObj);
} else if (this.getPassNotificationDetails.REQUEST_TYPE == "ABSENCE") {
this.getAbsenceNotificationDetails(this.WorkListBodyObj);
} else if (this.getPassNotificationDetails.REQUEST_TYPE == "PO") {
@ -318,12 +318,12 @@ export class WorklistMainComponent implements OnInit {
});
}
getEITNotificationDetails(notificationBodyObj) {
getSITNotificationDetails(notificationBodyObj) {
this.notificationBodyRes = []
this.worklistMainService
.getEITNotificationBody(notificationBodyObj)
.getSITNotificationBody(notificationBodyObj)
.subscribe((result: EITNotificatonBodyResponse) => {
this.handleWorkListBodyResult(result, "EIT");
this.handleWorkListBodyResult(result, "SIT");
});
}
@ -341,10 +341,10 @@ export class WorklistMainComponent implements OnInit {
if (this.common.validResponse(result)) {
this.pInformation = result.P_INFORMATION;
this.pQuestion = result.P_QUESTION;
if (Type == "EIT") {
if (result.GetEITCollectionNotificationBodyList) {
if (Type == "SIT") {
if (result.GetSITCollectionNotificationBodyList) {
this.notificationBodyRes =
result.GetEITCollectionNotificationBodyList;
result.GetSITCollectionNotificationBodyList;
if (this.notificationBodyRes[0].Collection_Notification) {
console.log(this.notificationBodyRes[0].Collection_Notification);
}
@ -692,7 +692,7 @@ export class WorklistMainComponent implements OnInit {
ButtonAction == "UPDATE_ACTION" ||
ButtonAction == "CONTINUE_ACTION"
) {
if (this.getPassNotificationDetails.REQUEST_TYPE == "EIT") {
if (this.getPassNotificationDetails.REQUEST_TYPE == "SIT") {
this.common.sharedService.setSharedData(
this.notificationBodyRes,
EITNotificatonBodyResponse.SHARED_DATA
@ -804,7 +804,7 @@ export class WorklistMainComponent implements OnInit {
}
openNotificationBody() {
if (this.getPassNotificationDetails.REQUEST_TYPE == "EIT") {
if (this.getPassNotificationDetails.REQUEST_TYPE == "SIT") {
this.common.sharedService.setSharedData(
this.notificationBodyRes,
EITNotificatonBodyResponse.SHARED_DATA
@ -814,7 +814,7 @@ export class WorklistMainComponent implements OnInit {
EITNotificatonBodyResponse.NOT_WORKLIST
);
// this.navCtrl.push("WorkListDetailsPage", { NotBodyType: "EIT" });
this.common.sharedService.setSharedData("EIT", "NotBodyType");
this.common.sharedService.setSharedData("SIT", "NotBodyType");
this.common.openNotificationDetailsPage();
} else if (this.getPassNotificationDetails.REQUEST_TYPE == "ABSENCE") {
this.common.sharedService.setSharedData(

@ -2284,6 +2284,10 @@
},
"worklist": {
"loading":{
"en":"Loading",
"ar":"يتم التحميل"
},
"view": {
"en": "View",
"ar": "عرض"

Loading…
Cancel
Save