通讯录日志通过版本号查询新增
parent
abd9a66800
commit
d908354926
|
|
@ -27,7 +27,6 @@ public class VersionsController {
|
|||
private IVersionsService service;
|
||||
|
||||
|
||||
|
||||
// @ApiOperation(value = "查询所有")
|
||||
// @PostMapping(value = "find")
|
||||
public ResultJson<Versions> find(@RequestBody Versions dto) {
|
||||
|
|
@ -44,6 +43,16 @@ public class VersionsController {
|
|||
|
||||
}
|
||||
|
||||
@ApiOperation(value = "通过版本号查询")
|
||||
@GetMapping(value = "getByV/{abId}/{version}")
|
||||
public ResultJson<Versions> getByV(@PathVariable("abId") Integer abId, @PathVariable("version") Integer version) {
|
||||
if (version < 0) {
|
||||
return ResultJson.error("版本号不能小于0");
|
||||
}
|
||||
return ResultJson.ok(service.lambdaQuery().eq(Versions::getAbId, abId)
|
||||
.eq(Versions::getVersion, version).one());
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation(value = "删除")
|
||||
|
|
|
|||
|
|
@ -24,4 +24,7 @@ public class CommDto extends FindPageDto {
|
|||
@ApiModelProperty(value = "0:添加用户,1:修改用户,2:修改权限,3:删除用户")
|
||||
private String type;
|
||||
|
||||
@ApiModelProperty(value = "版本号")
|
||||
private Integer version;
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,7 +20,12 @@
|
|||
<if test="dto.type != null and dto.type != '' ">
|
||||
AND A.TYPE = #{dto.type}
|
||||
</if>
|
||||
<if test="dto.version != null and dto.version != '' ">
|
||||
AND A.TYPE = #{dto.version}
|
||||
</if>
|
||||
</where>
|
||||
|
||||
ORDER BY V.VERSION DESC
|
||||
</select>
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue