parent
40c2da9d96
commit
4d60ca38aa
|
@ -141,6 +141,9 @@ public class SysRoleController extends AbstractController {
|
|||
//ValidatorUtils.validateEntity(role);
|
||||
role.setCreateBy(getUser().getNickName());
|
||||
role.setCreateTime(new Date());
|
||||
if(role.getRoleName().length()>32){
|
||||
return R.error("角色名称太长");
|
||||
}
|
||||
sysRoleService.saveRole(role);
|
||||
|
||||
return R.ok();
|
||||
|
|
|
@ -433,7 +433,11 @@ public class TenPersonController extends AbstractController {
|
|||
return R.error("卡号已录入");
|
||||
}
|
||||
}
|
||||
}else{
|
||||
}
|
||||
else if(tenPerson.getDoorCardEntity().getDoorCard().trim().equals("")){
|
||||
|
||||
}
|
||||
else{
|
||||
tenPerson.setDoorCardEntity(null);
|
||||
}
|
||||
|
||||
|
|
|
@ -1099,6 +1099,7 @@ public class TenPersonServiceImpl implements TenPersonService {
|
|||
}
|
||||
|
||||
if (entity.getDoorCardEntity() != null) {
|
||||
if(entity.getDoorCardEntity().getDoorCard().trim().length()>0){
|
||||
// TenDoorCardEntity oldCard = tenDoorCardService.getOne(new QueryWrapper<TenDoorCardEntity>()
|
||||
// .eq("person_id", entity.getPersonId()));
|
||||
|
||||
|
@ -1143,6 +1144,10 @@ public class TenPersonServiceImpl implements TenPersonService {
|
|||
}else{
|
||||
|
||||
}
|
||||
}else{
|
||||
//删除卡号
|
||||
tenDoorCardService.removeById(entity.getDoorCardEntity().getDoorCardId());
|
||||
}
|
||||
|
||||
// if (oldCard != null) {
|
||||
// //修改 ,卡号为空,删除记录
|
||||
|
|
Loading…
Reference in New Issue