|
@@ -1,6 +1,7 @@
|
|
package com.fire.admin.rest;
|
|
package com.fire.admin.rest;
|
|
|
|
|
|
import com.fire.admin.util.AliyunOSSUtil;
|
|
import com.fire.admin.util.AliyunOSSUtil;
|
|
|
|
+import com.fire.dto.response.BaseRestResponse;
|
|
import io.swagger.annotations.Api;
|
|
import io.swagger.annotations.Api;
|
|
import io.swagger.annotations.ApiOperation;
|
|
import io.swagger.annotations.ApiOperation;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
@@ -28,8 +29,9 @@ public class PictureUpLoadController {
|
|
@CrossOrigin
|
|
@CrossOrigin
|
|
@ApiOperation("文件上传")
|
|
@ApiOperation("文件上传")
|
|
@PostMapping("/upload")
|
|
@PostMapping("/upload")
|
|
- public String testUpload(MultipartFile file) {
|
|
|
|
- return aliyunOSSUtil.upload(file);
|
|
|
|
|
|
+ public BaseRestResponse testUpload(MultipartFile file) {
|
|
|
|
+
|
|
|
|
+ return new BaseRestResponse( aliyunOSSUtil.upload(file));
|
|
}
|
|
}
|
|
|
|
|
|
}
|
|
}
|