Browse Source

udpate 更新 OSS模块 适配新规范

疯狂的狮子li 3 years ago
parent
commit
a3f1a00078

+ 3 - 3
ruoyi-oss/src/main/java/com/ruoyi/system/controller/SysOssController.java

@@ -11,10 +11,10 @@ import com.ruoyi.common.core.page.TableDataInfo;
 import com.ruoyi.common.enums.BusinessType;
 import com.ruoyi.common.exception.CustomException;
 import com.ruoyi.common.utils.file.FileUtils;
-import com.ruoyi.system.bo.SysOssQueryBo;
+import com.ruoyi.system.domain.bo.SysOssBo;
 import com.ruoyi.system.domain.SysOss;
 import com.ruoyi.system.service.ISysOssService;
-import com.ruoyi.system.vo.SysOssVo;
+import com.ruoyi.system.domain.vo.SysOssVo;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiImplicitParam;
 import io.swagger.annotations.ApiImplicitParams;
@@ -56,7 +56,7 @@ public class SysOssController extends BaseController {
 	@ApiOperation("查询OSS云存储列表")
 	@PreAuthorize("@ss.hasPermi('system:oss:list')")
 	@GetMapping("/list")
-	public TableDataInfo<SysOssVo> list(@Validated SysOssQueryBo bo) {
+	public TableDataInfo<SysOssVo> list(@Validated SysOssBo bo) {
 		return iSysOssService.queryPageList(bo);
 	}
 

+ 2 - 2
ruoyi-oss/src/main/java/com/ruoyi/system/bo/SysOssQueryBo.java → ruoyi-oss/src/main/java/com/ruoyi/system/domain/bo/SysOssBo.java

@@ -1,4 +1,4 @@
-package com.ruoyi.system.bo;
+package com.ruoyi.system.domain.bo;
 
 import com.ruoyi.common.core.domain.BaseEntity;
 import io.swagger.annotations.ApiModel;
@@ -14,7 +14,7 @@ import lombok.EqualsAndHashCode;
 @Data
 @EqualsAndHashCode(callSuper = true)
 @ApiModel("OSS云存储分页查询对象")
-public class SysOssQueryBo extends BaseEntity {
+public class SysOssBo extends BaseEntity {
 
 	/**
 	 * 分页大小

+ 1 - 1
ruoyi-oss/src/main/java/com/ruoyi/system/vo/SysOssVo.java → ruoyi-oss/src/main/java/com/ruoyi/system/domain/vo/SysOssVo.java

@@ -1,4 +1,4 @@
-package com.ruoyi.system.vo;
+package com.ruoyi.system.domain.vo;
 
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;

+ 3 - 3
ruoyi-oss/src/main/java/com/ruoyi/system/service/ISysOssService.java

@@ -2,9 +2,9 @@ package com.ruoyi.system.service;
 
 import com.ruoyi.common.core.mybatisplus.core.IServicePlus;
 import com.ruoyi.common.core.page.TableDataInfo;
-import com.ruoyi.system.bo.SysOssQueryBo;
+import com.ruoyi.system.domain.bo.SysOssBo;
 import com.ruoyi.system.domain.SysOss;
-import com.ruoyi.system.vo.SysOssVo;
+import com.ruoyi.system.domain.vo.SysOssVo;
 import org.springframework.web.multipart.MultipartFile;
 
 import java.util.Collection;
@@ -16,7 +16,7 @@ import java.util.Collection;
  */
 public interface ISysOssService extends IServicePlus<SysOss, SysOssVo> {
 
-	TableDataInfo<SysOssVo> queryPageList(SysOssQueryBo sysOss);
+	TableDataInfo<SysOssVo> queryPageList(SysOssBo sysOss);
 
 	SysOss upload(MultipartFile file);
 

+ 4 - 4
ruoyi-oss/src/main/java/com/ruoyi/system/service/impl/SysOssServiceImpl.java

@@ -11,11 +11,11 @@ import com.ruoyi.common.utils.PageUtils;
 import com.ruoyi.oss.entity.UploadResult;
 import com.ruoyi.oss.factory.OssFactory;
 import com.ruoyi.oss.service.ICloudStorageService;
-import com.ruoyi.system.bo.SysOssQueryBo;
+import com.ruoyi.system.domain.bo.SysOssBo;
 import com.ruoyi.system.domain.SysOss;
 import com.ruoyi.system.mapper.SysOssMapper;
 import com.ruoyi.system.service.ISysOssService;
-import com.ruoyi.system.vo.SysOssVo;
+import com.ruoyi.system.domain.vo.SysOssVo;
 import org.springframework.stereotype.Service;
 import org.springframework.web.multipart.MultipartFile;
 
@@ -33,12 +33,12 @@ import java.util.Map;
 public class SysOssServiceImpl extends ServicePlusImpl<SysOssMapper, SysOss, SysOssVo> implements ISysOssService {
 
 	@Override
-	public TableDataInfo<SysOssVo> queryPageList(SysOssQueryBo bo) {
+	public TableDataInfo<SysOssVo> queryPageList(SysOssBo bo) {
 		PagePlus<SysOss, SysOssVo> result = pageVo(PageUtils.buildPagePlus(), buildQueryWrapper(bo));
 		return PageUtils.buildDataInfo(result);
 	}
 
-	private LambdaQueryWrapper<SysOss> buildQueryWrapper(SysOssQueryBo bo) {
+	private LambdaQueryWrapper<SysOss> buildQueryWrapper(SysOssBo bo) {
 		Map<String, Object> params = bo.getParams();
 		LambdaQueryWrapper<SysOss> lqw = Wrappers.lambdaQuery();
 		lqw.like(StrUtil.isNotBlank(bo.getFileName()), SysOss::getFileName, bo.getFileName());