{"version":3,"sources":["webpack:///./node_modules/@abaco/inspection-module/src/modules/inspection-module/api/VisitPhCorrectionApi.ts"],"names":["VisitPhCorrectionApi","httpClient","basePath","this","plan","post","response","data","correctionId","get","put","delete"],"mappings":"uMAGqBA,G,+BAInB,WAAYC,GAAsB,uBAF1B,KAAAC,SAAW,6BAGjBC,KAAKF,WAAaA,E,sGAGpB,WAAaG,GAAb,uGACyBD,KAAKF,WAAWI,KAAhB,UAAwBF,KAAKD,SAA7B,kBAAuDE,GADhF,cACQE,EADR,yBAESA,EAASC,MAFlB,gD,wIAKA,WAAcC,GAAd,uGACyBL,KAAKF,WAAWQ,IAAhB,UAAuBN,KAAKD,SAA5B,0BAAsDM,IAD/E,cACQF,EADR,yBAESA,EAASC,MAFlB,gD,uIAKA,WAAaC,EAAsBJ,GAAnC,uGACyBD,KAAKF,WAAWS,IAAhB,UAAuBP,KAAKD,SAA5B,0BAAsDM,GAAgBJ,GAD/F,cACQE,EADR,yBAESA,EAASC,MAFlB,gD,yIAKA,WAAaC,GAAb,iGACQL,KAAKF,WAAWU,OAAhB,UAA0BR,KAAKD,SAA/B,0BAAyDM,IADjE,gD","file":"js/chunk-2d20e87d.7cabf40a.js","sourcesContent":["import { HTTPClient } from \"@abaco/web-common/src/HTTP\";\nimport { VisitPhCorrectionGetDto, VisitPhCorrectionUpsertDto } from \"../models/VisitPhCorrectionModel\";\n\nexport default class VisitPhCorrectionApi {\n private httpClient: HTTPClient;\n private basePath = \"/pmi-inspection-api/api/v1\";\n\n constructor(httpClient: HTTPClient) {\n this.httpClient = httpClient;\n }\n\n async create(plan: VisitPhCorrectionUpsertDto): Promise {\n const response = await this.httpClient.post(`${this.basePath}/ph_correction`, plan);\n return response.data;\n }\n\n async getById(correctionId: number): Promise {\n const response = await this.httpClient.get(`${this.basePath}/ph_correction/${correctionId}`);\n return response.data;\n }\n\n async update(correctionId: number, plan: VisitPhCorrectionUpsertDto): Promise {\n const response = await this.httpClient.put(`${this.basePath}/ph_correction/${correctionId}`, plan);\n return response.data;\n }\n\n async delete(correctionId: number): Promise {\n await this.httpClient.delete(`${this.basePath}/ph_correction/${correctionId}`);\n }\n}\n"],"sourceRoot":""}