Commit 9f5914ec authored by 李丛阳's avatar 李丛阳

逻辑删除

parent a8bfaf25
......@@ -38,7 +38,7 @@ public class ${table.entityName}Controller extends PaginationController<${table.
@ApiOperation(value="添加${table.tableRemark!}", notes="添加${table.tableRemark!}")
//@ApiImplicitParams({@ApiImplicitParam(name = "businessId", value = "businessId", required = false, dataType = "varchar")})
@PostMapping
@PostMapping(value = "/add")
public Result add(@Valid ${table.entityName} ${table.entityName?uncap_first}, BindingResult bindingResult) {
if (bindingResult.hasErrors()) {
throw new ServiceException(ResultServiceEnums.PARAMETER_ERROR.getCode(),
......
......@@ -56,6 +56,7 @@ public class ${table.entityName}ServiceImpl implements ${table.entityName}Servic
@Override
public PersistModel remove(${table.entityName} ${table.entityName?uncap_first}){
UserUtil.setCurrentMergeOperation(${table.entityName?uncap_first});
${table.entityName?uncap_first}.setDeleted();
int line = ${table.entityName?uncap_first}Repository.logicalDelete(${table.entityName?uncap_first});
log.info(UserUtil.getUserInfoProp(${table.entityName?uncap_first}.getToken(),UserUtil.USER_USERNAME)+"逻辑删除了ID为"+
${table.entityName?uncap_first}.getBusinessId()+"的信息");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment