修改样式,修改不能输入负数的问题
This commit is contained in:
@@ -22,6 +22,28 @@ export const uploadFile = (filePath) => {
|
||||
})
|
||||
}
|
||||
|
||||
export const uploadOcrFile = (filePath) => {
|
||||
const { api } = getConfigByEnv();
|
||||
return new Promise((resolve, reject) => {
|
||||
wx.uploadFile({
|
||||
|
||||
filePath: filePath,
|
||||
name: 'data',
|
||||
url: `${api}/image/to/meter/reading`,
|
||||
header: {
|
||||
authorization: 'Bearer ' + wx.getStorageSync("token")
|
||||
},
|
||||
success: (res) => {
|
||||
console.log("res", 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) => {
|
||||
|
Reference in New Issue
Block a user