|
|
|
@ -152,6 +152,8 @@ export class ServeManager {
|
|
|
|
|
//#region 文件上传
|
|
|
|
|
//队列性,批量上传
|
|
|
|
|
uploadFile(index: number, files: File[], resPath_out, onOneSuccess: (name: string, path: string, file: File) => void, onEnd: () => void) { |
|
|
|
|
|
|
|
|
|
console.log("上传路径", resPath_out); |
|
|
|
|
if (index < files.length) { |
|
|
|
|
ServeManager.instance.openFileSelect(files[index], resPath_out, (name: string, path: string, file: File) => { |
|
|
|
|
onOneSuccess(name, path, file); |
|
|
|
@ -197,6 +199,7 @@ export class ServeManager {
|
|
|
|
|
let fileName = dataObj.fileName; |
|
|
|
|
let filePath: string = dataObj.objectName;//此路径不全,前面缺少ObjectsService.baseUrl,这部分不可序列化,要在运行时拼接
|
|
|
|
|
filePath = filePath.replace(fileName, "");//去掉结尾的文件名
|
|
|
|
|
console.log("上传完成,地址为", filePath); |
|
|
|
|
//filePath = ObjectsService.baseUrl + filePath;
|
|
|
|
|
ServeManager.instance.onGetPostFileResult(fileName, filePath, file); |
|
|
|
|
resolve('success') |
|
|
|
|