import axios from "axios"; import ListModule from "./index"; export const https = ListModule.http({ loadLocal(localFile: any) { return axios(localFile, { method: "GET", }); }, getAssetDetail(id: string) { return this.request(`/share/pack/detail/${id}`, { method: "GET", }); }, loadAsset(dbId: string, defineId: string, baseURL: string) { return this.request(`/list/${dbId}/${defineId}`, { method: "GET", baseURL, }); }, createArtifact(data: any) { return this.request("/antique/create", { method: "POST", data: data, }); }, updateArtifact(data: any) { return this.request(`/antique/update`, { method: "POST", data }); }, getArtifactDtl(id: string) { return this.request(`/antique/detail/${id}`, { method: "GET", }); }, deleteArtifact(id: string) { return this.request(`/antique/delete/${id}`, { method: "POST", }); }, exportArtifact(data: any) { return this.request("/antique/export", { method: "POST", data, }); }, importArtifact() { return this.request("/antique/import", { method: "POST", }); }, getExport(id: string) { return this.request(`/anitique/file/${id}`, { method: "GET", }); }, });