联调拆表

This commit is contained in:
2025-11-10 16:09:38 +08:00
parent 639f92540f
commit 07add88856
6 changed files with 43 additions and 12 deletions

View File

@@ -70,6 +70,6 @@ export const installMeter = async function(data) {
}
// 拆表
export const uninstallMeter = async function(sn) {
return await DELETE(`/flow/doMeterRemoveApproval?sn=${sn}`);
export const uninstallMeter = async function({sn, reason, images}) {
return await DELETE(`/flow/doMeterRemoveApproval`, { sn, reason, images });
}

View File

@@ -63,6 +63,26 @@ export const uploadInstallMeter = (filePath) => {
})
}
export const uploadUninstallMeter = (filePath) => {
const { api } = getConfigByEnv();
return new Promise((resolve, reject) => {
wx.uploadFile({
filePath: filePath,
name: 'data',
url: `${api}/image/meter/delete`,
header: {
authorization: 'Bearer ' + wx.getStorageSync("token")
},
success: (res) => {
resolve(res?.data ? JSON.parse(res?.data) : res?.data);
},
fail: (err) => {
reject(err);
}
})
})
}
export const uploadPublicFile = (filePath) => {
const { api } = getConfigByEnv();
return new Promise((resolve, reject) => {