|
@@ -37,6 +37,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
import org.springframework.validation.annotation.Validated;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
+import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
import java.util.*;
|
|
|
import java.util.stream.Collectors;
|
|
@@ -427,5 +428,10 @@ public class CompanyUserController extends BaseController
|
|
|
return AjaxResult.error("操作失败");
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+ @PostMapping("/common/uploadOSS")
|
|
|
+ public R uploadOSS(@RequestParam("file") MultipartFile file,
|
|
|
+ @RequestParam("userId") String userId) throws Exception {
|
|
|
+ String url = companyUserService.uploadQrCode(file, userId);
|
|
|
+ return R.ok().put("url", url);
|
|
|
+ }
|
|
|
}
|