|
|
|
|
@ -25,6 +25,14 @@ import { DomSanitizer } from '@angular/platform-browser';
|
|
|
|
|
import {FileUploderProfileComponent} from '../hmg-common/ui/file-uploder-profile/file-uploder-profile.component'
|
|
|
|
|
import { SharedDataService } from '../hmg-common/services/shared-data-service/shared-data.service';
|
|
|
|
|
import { DevicePermissionsService } from '../hmg-common/services/device-permissions/device-permissions.service';
|
|
|
|
|
import {DashboredService} from '../hmg-common/services/dashbored/dashbored.service'
|
|
|
|
|
import { OpenPeriodDatesResponse } from '../hmg-common/services/dashbored/models/openPeriodDatesResponse';
|
|
|
|
|
import {GetSubordinatesAttdStatusRequest} from '../hmg-common/services/dashbored/models/GetSubordinatesAttdStatusRequest';
|
|
|
|
|
import {GetSubordinatesLeavesRequest} from '../hmg-common/services/dashbored/models/GetSubordinatesLeavesRequest'
|
|
|
|
|
import {GetOpenNotificationsResponse}from '../hmg-common/services/dashbored/models/GetOpenNotificationsResponse'
|
|
|
|
|
import {GetSubordinatesAttdStatusResponse}from '../hmg-common/services/dashbored/models/GetSubordinatesAttdStatusResponse'
|
|
|
|
|
import {GetSubordinatesLeavesResponse}from '../hmg-common/services/dashbored/models/GetSubordinatesLeavesResponse'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Component({
|
|
|
|
|
selector: "app-home",
|
|
|
|
|
@ -63,6 +71,7 @@ export class HomePage implements OnInit {
|
|
|
|
|
private cameraController: Camera,
|
|
|
|
|
public sharedData: SharedDataService,
|
|
|
|
|
private sanitizer: DomSanitizer,
|
|
|
|
|
public dashboredService:DashboredService,
|
|
|
|
|
//private transfer: Transfer,
|
|
|
|
|
private file: File,
|
|
|
|
|
//private filePath: FilePath
|
|
|
|
|
@ -377,4 +386,59 @@ export class HomePage implements OnInit {
|
|
|
|
|
openPersonalInfo() {
|
|
|
|
|
this.common.openProfile();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
openPeriodDateDashbored(){
|
|
|
|
|
this.dashboredService.getOpenPeriodDates( ()=> {console.log("Error ");} ).subscribe((result:OpenPeriodDatesResponse)=>{
|
|
|
|
|
if (this.common.validResponse(result)) {
|
|
|
|
|
console.log("response");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
openNotificationsDashbored(){
|
|
|
|
|
this.dashboredService.getOpenNotifications( ()=> {console.log("Error ");} ).subscribe((result:GetOpenNotificationsResponse)=>{
|
|
|
|
|
if (this.common.validResponse(result)) {
|
|
|
|
|
console.log("response");
|
|
|
|
|
console.log(result);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
getSubordinatesLeaves(){
|
|
|
|
|
let request:GetSubordinatesLeavesRequest=new GetSubordinatesLeavesRequest();
|
|
|
|
|
request.P_DATE_FROM="/Date(1578603600000+0300)/"; //test
|
|
|
|
|
request.P_DATE_TO="/Date(1576011600000+0300)/"; //test
|
|
|
|
|
|
|
|
|
|
this.dashboredService.getSubordinatesLeaves( request,()=> {console.log("Error ");} ).subscribe((result:GetSubordinatesLeavesResponse)=>{
|
|
|
|
|
if (this.common.validResponse(result)) {
|
|
|
|
|
console.log("response");
|
|
|
|
|
console.log(result);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
getSubordinatesAttStatus(){
|
|
|
|
|
let request: GetSubordinatesAttdStatusRequest = new GetSubordinatesAttdStatusRequest();
|
|
|
|
|
request.P_SCHEDULE_DATE_FROM="/Date(1578603600000+0300)/"; //test
|
|
|
|
|
request.P_SCHEDULE_DATE_TO="/Date(1576011600000+0300)/";//test
|
|
|
|
|
|
|
|
|
|
this.dashboredService.getSubordinatesAttStatus( request,()=> {console.log("Error ");} ).subscribe((result:GetSubordinatesAttdStatusResponse)=>{
|
|
|
|
|
if (this.common.validResponse(result)) {
|
|
|
|
|
console.log("response");
|
|
|
|
|
console.log(result);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|