1
lzhe
2024-09-26 7d59e8e2c727dd49d9552a8febc2af47c5b95a69
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/*
 * @Date: 2024-03-23 09:49:06
 * @LastEditors: Sneed
 * @LastEditTime: 2024-04-13 20:20:48
 * @FilePath: /belleson-frontend/Users/mache/Documents/demo/cps-web/src/config/upload.js
 */
import API from "@/api";
 
//上传配置
 
export default {
    apiObj: API.common.upload,            //上传请求API对象
    filename: "file",                    //form请求时文件的key
    successCode: 200,                    //请求完成代码
    maxSize: 10,                        //最大文件大小 默认10MB
    parseData: function (res) {
        return {
            code: res.code,                //分析状态字段结构
            fileName: res.data.name,//分析文件名称
            src: res.data.name,            //分析图片远程地址结构
            msg: res.msg            //分析描述字段结构
        }
    },
    apiObjFile: API.common.uploadFile,    //附件上传请求API对象
    maxSizeFile: 10                        //最大文件大小 默认10MB
}