You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mohemm_moe/Mohem/src/app/profile/service/profile.service.ts

26 lines
909 B
TypeScript

import { Injectable } from '@angular/core';
import { Observable } from "rxjs";
import { ConnectorService } from 'src/app/hmg-common/services/connector/connector.service';
import { AuthenticationService } from "src/app/hmg-common/services/authentication/authentication.service";
@Injectable({
providedIn: 'root'
})
export class ProfileService {
public static updateEmpImage ="Services/ERP.svc/REST/UPDATE_EMPLOYEE_IMAGE";
constructor(
public api: ConnectorService,
public authService: AuthenticationService
) {}
public updateImageProfile( updateImgRequest: any,onError?: any,errorLabel?: string
): Observable<any> {
const request = updateImgRequest;
this.authService.authenticateRequest(request);
return this.api.post(
ProfileService.updateEmpImage,
request,
onError,
errorLabel
);
}
}