Merge branch 'master' into Bulbasaur
This commit is contained in:
@@ -7,7 +7,7 @@ import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.utils.StringUtils;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.system.entity.dos.AppVersionDO;
|
||||
import cn.lili.modules.system.entity.dos.AppVersion;
|
||||
import cn.lili.modules.system.service.AppVersionService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
@@ -34,34 +34,40 @@ public class AppVersionManagerController {
|
||||
private AppVersionService appVersionService;
|
||||
|
||||
|
||||
@ApiOperation(value = "查询app升级消息", response = AppVersionDO.class)
|
||||
@ApiOperation(value = "查询app升级消息", response = AppVersion.class)
|
||||
@GetMapping
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "APP类型", required = true, dataType = "type", paramType = "query")
|
||||
})
|
||||
public ResultMessage<IPage<AppVersionDO>> getByPage(PageVO page, String type) {
|
||||
public ResultMessage<IPage<AppVersion>> getByPage(PageVO page, String type) {
|
||||
return ResultUtil.data(this.appVersionService.page(PageUtil.initPage(page),
|
||||
new QueryWrapper<AppVersionDO>().eq(StringUtils.isNotEmpty(type), "type", type).orderByDesc("create_time")));
|
||||
new QueryWrapper<AppVersion>().eq(StringUtils.isNotEmpty(type), "type", type).orderByDesc("create_time")));
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation(value = "添加app版本信息", response = AppVersionDO.class)
|
||||
@ApiOperation(value = "添加app版本信息", response = AppVersion.class)
|
||||
@PostMapping
|
||||
public ResultMessage<Object> add(@Valid AppVersionDO appVersionDO) {
|
||||
if(this.appVersionService.save(appVersionDO)){
|
||||
return ResultUtil.success();
|
||||
public ResultMessage<Object> add(@Valid AppVersion appVersion) {
|
||||
|
||||
if(this.appVersionService.checkAppVersion(appVersion)){
|
||||
if(this.appVersionService.save(appVersion)){
|
||||
return ResultUtil.success();
|
||||
}
|
||||
}
|
||||
throw new ServiceException(ResultCode.ERROR);
|
||||
}
|
||||
|
||||
@PutMapping(value = "/{id}")
|
||||
@ApiOperation(value = "修改app版本信息", response = AppVersionDO.class)
|
||||
@ApiOperation(value = "修改app版本信息", response = AppVersion.class)
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "主键", required = true, dataType = "String", paramType = "path")
|
||||
})
|
||||
public ResultMessage<Boolean> edit(@Valid AppVersionDO appVersionDO, @PathVariable String id) {
|
||||
if(this.appVersionService.updateById(appVersionDO)){
|
||||
return ResultUtil.success();
|
||||
public ResultMessage<Object> edit(@Valid AppVersion appVersion, @PathVariable String id) {
|
||||
|
||||
if(this.appVersionService.checkAppVersion(appVersion)){
|
||||
if(this.appVersionService.updateById(appVersion)){
|
||||
return ResultUtil.success();
|
||||
}
|
||||
}
|
||||
throw new ServiceException(ResultCode.ERROR);
|
||||
}
|
||||
|
||||
@@ -132,22 +132,6 @@ ignored:
|
||||
- /MP_verify_qSyvBPhDsPdxvOhC.txt
|
||||
- /weixin/**
|
||||
- /source/**
|
||||
- /buyer/mini-program/**
|
||||
- /buyer/cashier/**
|
||||
- /buyer/pageData/**
|
||||
- /buyer/article/**
|
||||
- /buyer/goods/**
|
||||
- /buyer/category/**
|
||||
- /buyer/shop/**
|
||||
- /buyer/connect/**
|
||||
- /buyer/members/smsLogin
|
||||
- /buyer/members/refresh/*
|
||||
- /buyer/members/refresh**
|
||||
- /buyer/promotion/pintuan
|
||||
- /buyer/promotion/seckill
|
||||
- /buyer/memberEvaluation/**/goodsEvaluation
|
||||
- /buyer/memberEvaluation/**/evaluationNumber
|
||||
- /store/login/**
|
||||
- /manager/user/login
|
||||
- /manager/user/refresh/**
|
||||
- /manager/elasticsearch
|
||||
|
||||
Reference in New Issue
Block a user