import{L as d}from"./index-DlNZgIG9.js";const o="stock-transfer-received-note",i=t=>{const e=new URLSearchParams;return e.append("page",String(t.page??0)),e.append("size",String(t.size??20)),t.transferId&&e.append("transferId",String(t.transferId)),t.searchText&&e.append("searchText",t.searchText),t.dateFrom&&e.append("dateFrom",t.dateFrom),t.dateTo&&e.append("dateTo",t.dateTo),t.sort&&e.append("sort",t.sort),e.toString()},n=d.injectEndpoints({endpoints:t=>({listReceivedNotes:t.query({query:e=>({url:`${o}?${i(e)}`,method:"GET"})}),listReceivedNotesByTransfer:t.query({query:e=>({url:`${o}/by-transfer/${e}`,method:"GET"})}),getReceivedNoteById:t.query({query:e=>({url:`${o}/${e}`,method:"GET"})}),createReceivedNote:t.mutation({query:({body:e,idempotencyKey:r})=>({url:o,method:"POST",body:e,headers:r?{"Idempotency-Key":r}:void 0})}),updateReceivedNote:t.mutation({query:({body:e})=>({url:o,method:"PUT",body:e})}),deleteReceivedNote:t.mutation({query:e=>({url:`${o}/${e}`,method:"DELETE"})})}),overrideExisting:!1}),{useListReceivedNotesQuery:u,useListReceivedNotesByTransferQuery:c,useGetReceivedNoteByIdQuery:a,useCreateReceivedNoteMutation:y,useUpdateReceivedNoteMutation:v,useDeleteReceivedNoteMutation:f}=n;export{y as a,a as b,u};
