mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-14 02:55:07 +08:00
代码预览的功能,完成
This commit is contained in:
@ -42,8 +42,8 @@ public class ${table.className}Controller {
|
||||
return success(true);
|
||||
}
|
||||
|
||||
@ApiOperation("删除${table.classComment}")
|
||||
@DeleteMapping("/delete")
|
||||
@ApiOperation("删除${table.classComment}")
|
||||
@DeleteMapping("/delete")
|
||||
@ApiImplicitParam(name = "id", value = "编号", required = true)
|
||||
public CommonResult<Boolean> delete${simpleClassName}(@RequestParam("id") ${primaryColumn.javaType} id) {
|
||||
${classNameVar}Service.delete${simpleClassName}(id);
|
||||
@ -52,7 +52,7 @@ public class ${table.className}Controller {
|
||||
|
||||
@GetMapping("/get")
|
||||
@ApiOperation("获得${table.classComment}")
|
||||
@ApiImplicitParam(name = "id", value = "编号", required = true)
|
||||
@ApiImplicitParam(name = "id", value = "编号", required = true, dataTypeClass = ${primaryColumn.javaType}.class)
|
||||
public CommonResult<${table.className}RespVO> get${simpleClassName}(@RequestParam("id") ${primaryColumn.javaType} id) {
|
||||
${table.className}DO ${classNameVar} = ${classNameVar}Service.get${simpleClassName}(id);
|
||||
return success(${table.className}Convert.INSTANCE.convert(${classNameVar}));
|
||||
@ -60,7 +60,7 @@ public class ${table.className}Controller {
|
||||
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("获得${table.classComment}列表")
|
||||
@ApiImplicitParam(name = "ids", value = "编号列表", required = true)
|
||||
@ApiImplicitParam(name = "ids", value = "编号列表", required = true, dataTypeClass = List.class)
|
||||
public CommonResult<List<${table.className}RespVO>> get${simpleClassName}List(@RequestParam("ids") Collection<${primaryColumn.javaType}> ids) {
|
||||
List<${table.className}DO> list = ${classNameVar}Service.get${simpleClassName}List(ids);
|
||||
return success(${table.className}Convert.INSTANCE.convertList(list));
|
||||
|
@ -27,6 +27,6 @@ public interface ${table.className}Convert {
|
||||
|
||||
List<${table.className}RespVO> convertList(List<${table.className}DO> list);
|
||||
|
||||
PageResult<${table.className}RespVO> convertPage(PageResult<${table.className}DO> page);
|
||||
PageResult<${table.className}RespVO> convertPage(PageResult<${table.className}DO> page);
|
||||
|
||||
}
|
||||
|
@ -57,6 +57,6 @@ public interface ${table.className}Service {
|
||||
* @param pageReqVO 分页查询
|
||||
* @return ${table.classComment}分页
|
||||
*/
|
||||
PageResult<${table.className}DO> get${simpleClassName}Page(${table.className}PageReqVO pageReqVO);
|
||||
PageResult<${table.className}DO> get${simpleClassName}Page(${table.className}PageReqVO pageReqVO);
|
||||
|
||||
}
|
||||
|
@ -72,7 +72,7 @@ public class ${table.className}ServiceImpl implements ${table.className}Service
|
||||
return ${classNameVar}Mapper.selectBatchIds(ids);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Override
|
||||
public PageResult<${table.className}DO> get${simpleClassName}Page(${table.className}PageReqVO pageReqVO) {
|
||||
return ${classNameVar}Mapper.selectPage(pageReqVO);
|
||||
}
|
||||
|
Reference in New Issue
Block a user