Commit 0eb73f41 authored by wzp's avatar wzp

修改bug

parent 67637971
......@@ -114,7 +114,9 @@ public class SystemOperationLogService extends ServiceImpl<SysLogMapper, SysLog>
TOperationLog operationLog = new TOperationLog();
operationLog.setCreateTime(LocalDateTime.now());
operationLog.setUserId(user.getId());
operationLog.setArea(user.getAreaName());
if (user.getAreaName()!=null) {
operationLog.setArea(user.getAreaName());
}
operationLog.setOperationType(methodLog.operType().getMsg());
operationLogService.save(operationLog);
return object;
......
......@@ -58,7 +58,6 @@ public class TOperationLog implements Serializable {
@ApiModelProperty("运维区域")
@TableField("area")
@NotBlank(message = "运维区域不能为空", groups = {Add.class, Update.class})
private String area;
@ApiModelProperty("操作内容")
......
......@@ -17,6 +17,7 @@ import cn.wisenergy.chnmuseum.party.service.TUserRoleService;
import cn.wisenergy.chnmuseum.party.service.TUserService;
import cn.wisenergy.chnmuseum.party.service.impl.AuditServiceImpl;
import cn.wisenergy.chnmuseum.party.service.impl.TBoxOperationServiceImpl;
import cn.wisenergy.chnmuseum.party.service.impl.TOrganServiceImpl;
import cn.wisenergy.chnmuseum.party.web.controller.base.BaseController;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
......@@ -55,6 +56,9 @@ public class TUserController extends BaseController {
@Resource
private TUserService userService;
@Resource
private TOrganServiceImpl organService;
@Resource
private TUserRoleService tUserRoleService;
......@@ -239,6 +243,8 @@ public class TUserController extends BaseController {
return resultMap;
}
}
TOrgan byId = organService.getById(user.getOrgId());
user.setAreaId(byId.getAreaId());
byte[] passwordSalt = SecureRandomSaltService.generateSalt();
byte[] passwordHash = SHA256PasswordEncryptionService
......@@ -651,6 +657,8 @@ public class TUserController extends BaseController {
return ResponseEntity.status(HttpStatus.BAD_REQUEST).body(resultMap);
}
}
TOrgan byId = organService.getById(user.getOrgId());
user.setAreaId(byId.getAreaId());
byte[] passwordSalt = SecureRandomSaltService.generateSalt();
byte[] passwordHash = SHA256PasswordEncryptionService
......
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