You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
680 B
22 lines
680 B
import {
|
|
http,
|
|
uploadOne,
|
|
uploadImage
|
|
} from '@/api/request/index.js';
|
|
import {
|
|
url_config
|
|
} from '@/config/index.js'
|
|
const api = {
|
|
send(opts = {}){
|
|
const {url, method='GET',data={},auth = 'auth',loading = false} = opts
|
|
return http(loading)(url,method,data,auth);
|
|
},
|
|
sendOne(url, method='GET',data={},loading = false,auth = 'auth'){
|
|
return http(loading)(url,method,data,auth);
|
|
},
|
|
uploadPath: () => (url_config + "/oss/upload"),
|
|
uploadFile: (path, msg) => uploadImage("/oss/upload", path, msg),
|
|
uploadOne: (msg) => uploadOne("/oss/upload", msg),
|
|
|
|
homeInfo: (data, show = false, loadingText) => http(show, loadingText)(`/ums/api/v1/home/pageInfo`, 'GET', data),
|
|
}
|