角色管理

This commit is contained in:
sjl
2024-11-14 11:34:25 +08:00
parent 44e7598b68
commit 39cbe0ff35
19 changed files with 873 additions and 359 deletions

View File

@@ -21,6 +21,7 @@ const config = {
withCredentials: true,
// post请求指定数据类型以及编码
headers: { 'Content-Type': 'application/json;charset=utf-8' }
//headers : {'Content-Type': 'multipart/form-data'}
};
class RequestHttp {
@@ -107,6 +108,16 @@ class RequestHttp {
download(url: string, params?: object, _object = {}): Promise<BlobPart> {
return this.service.post(url, params, { ..._object, responseType: "blob" });
}
/**
* @description 批量导入专用请求方法
*/
batchImport<T>(url: string, formData: FormData, _object = {}): Promise<ResultData<T>> {
return this.service.post(url, formData, {
..._object,
headers: { 'Content-Type': 'multipart/form-data' }
});
}
}
export default new RequestHttp(config);