import httpClient from "./httpClient";
const regeneratorRuntime = require("./regeneratorRuntime.js");
//const { uploadImageUrl } = seller
class media {
async uploadImage(data = {}) {
console.log("uploadImageUrl=");
return await httpClient.uploadFile({ url: "upload/file",isToken:false, data });
}
chooseImage(callback = (res) => { }, count = 1) {
console.log('count='+count)
uni.chooseImage({
count:count ,
sizeType: ['original', 'compressed'],
sourceType: ['album', 'camera'],
success(res) {
callback(res)
}
})
}
}
export default new media();
const uploadResult = await media.uploadImage({
filePath: tempPathUrl
});