| | |
| | | /// 文件上传 |
| | | /// </summary> |
| | | /// <param name="file"></param> |
| | | /// <param name="entityName"></param> |
| | | /// <returns></returns> |
| | | [HttpPost] |
| | | public async Task<IActionResult> Upload(IFormFile file) |
| | | public async Task<IActionResult> Upload([FromForm]string entityName, IFormFile file) |
| | | { |
| | | if (file == null || file.Length == 0) |
| | | return BadRequest("No file uploaded."); |
| | | |
| | | var path = Path.Combine($@"{BizConfig.Configuration["UploadAddress"]}", "upload", file.FileName); |
| | | var folderName = entityName == "BAS_LABEL_TEMP" ? "upload/Template": "upload"; |
| | | var path = Path.Combine($@"{BizConfig.Configuration["UploadAddress"]}", folderName, file.FileName); |
| | | |
| | | using (var stream = new FileStream(path, FileMode.Create)) |
| | | { |
| | |
| | | "CorsPaths": { |
| | | "OriginOne": "http://192.168.1.26", |
| | | "OriginThree": "http://47.115.28.255:8080", |
| | | "Origin4": "http://47.115.28.255:8800", |
| | | "Local": "http://localhost:10591", |
| | | "Debug": "http://localhost:55038", |
| | | "Vue3": "http://localhost:3100", |
| | | "Vue31": "https://localhost:3100", |
| | | "Vue32": "http://localhost:10591", |
| | | "Vue33": "http://localhost:3101", |
| | | "Vue4": "http://127.0.0.1:5173", |
| | | "Vue5": "http://localhost:5173", |
| | | "Vue5": "http://192.168.124.7:3100", |
| | | "Vue6": "http://localhost:5173", |
| | | "Vue3108": "http://localhost:3108", |
| | | "Vue3118": "http://localhost:3118" |
| | | "Vue3118": "http://localhost:8800" |
| | | }, |
| | | "MQTT": { |
| | | "Enable": true, |
| | |
| | | "WillMsgDelay": 5, |
| | | "WillMsgExpiry": 300 |
| | | }, |
| | | "RunInterface": false |
| | | "RunInterface": true |
| | | } |