import { HttpClient, HttpHeaders } from '@angular/common/http';
import { Observable } from 'rxjs';
import { environment } from '../../../environments/environment';
let header = new HttpHeaders();
import { Injectable } from '@angular/core';
import { ProjectFollowup } from './projectfollowup';
header = header.set('Content-Type', 'application/json; charset=utf-8');
@Injectable({
  providedIn: 'root'
})
export class ProjectfollowupService {
    baseUrl: string = environment.serviceUrl;
    constructor(private httpClient: HttpClient) { }
        GetProjectFolowup(): Observable<any> {
            return this.httpClient.get<any>(this.baseUrl + 'api/ProjectConfigurationApi/GetProjectFollowup');
          }
          PostProjectFollowup(data: ProjectFollowup): Observable<any> {
            return this.httpClient.post<any>(this.baseUrl + 'api/ProjectConfigurationApi/AddProjectFollowup',
              data, { headers: header, observe: 'response' });
          }
          PutProjectFollowup(data: ProjectFollowup): Observable<any> {
            return this.httpClient.post<any>(this.baseUrl + 'api/ProjectConfigurationApi/EditProjectFollowup',
              data, { headers: header, observe: 'response' });
          }  
          DeleteStageFollowup(department: ProjectFollowup) {
            let header = new HttpHeaders();
            header = header.set('Content-Type', 'application/json; charset=utf-8');
            return this.httpClient.post(this.baseUrl + 'api/ProjectConfigurationApi/DeleteProjectFollowup',
              department, { headers: header, observe: 'response' });
          }     
}