import { Injectable } from '@angular/core';
import { Observable } from 'rxjs';
import { environment } from 'src/environments/environment';
import { HttpClient, HttpHeaders } from '@angular/common/http';
@Injectable({
    providedIn: 'root'
  })
  export class DownloaderService {
    baseUrl: string = environment.serviceUrl;
    constructor(private httpClient: HttpClient) { }

    Downloader(fileData: any): Observable<any> {
        return this.httpClient.post<any>(this.baseUrl + 'api/UploaderApi/Downloader',
        fileData, {observe: 'response' });
    }
    Nextstagecreate(userid,tranid,lotid): Observable<any> {
      return this.httpClient.post<any>(this.baseUrl + 'api/WorkAreaApi/nextstagecreate/'+ tranid+'/'+ userid+'/'+ lotid,{ observe: 'response' });
     }
     checkin(userid,tranid): Observable<any> {
      return this.httpClient.post<any>(this.baseUrl + 'api/WorkAreaApi/checkin/'+ tranid+'/'+ userid,{ observe: 'response' });
     }
  }