替换opt
This commit is contained in:
@@ -18,11 +18,11 @@ public class BaseDTO implements Serializable {
|
||||
|
||||
private String createName;
|
||||
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
private String updateOptname;
|
||||
private String updateName;
|
||||
|
||||
private Long updateOptid;
|
||||
private String updateId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JSONField(format = "yyyy-MM-dd HH:mm:ss")
|
||||
|
||||
@@ -38,6 +38,12 @@ public class SysRoleController {
|
||||
return new ResponseEntity<>(TableDataInfo.build(roleService.query(param, page)), HttpStatus.OK);
|
||||
}
|
||||
|
||||
@ApiOperation("查询所有角色")
|
||||
@GetMapping("/all")
|
||||
public ResponseEntity<Object> queryAll() {
|
||||
return new ResponseEntity<>(roleService.list(), HttpStatus.OK);
|
||||
}
|
||||
|
||||
@Log("新增角色")
|
||||
@ApiOperation("新增角色")
|
||||
@PostMapping
|
||||
|
||||
@@ -54,19 +54,19 @@ public class SysDept implements Serializable {
|
||||
*/
|
||||
private String isUsed;
|
||||
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
*/
|
||||
private String createName;
|
||||
|
||||
private Long updateOptid;
|
||||
private String updateId;
|
||||
|
||||
/**
|
||||
* 更新者
|
||||
*/
|
||||
private String updateOptname;
|
||||
private String updateName;
|
||||
|
||||
/**
|
||||
* 创建日期
|
||||
|
||||
@@ -77,7 +77,7 @@ public class Dict implements Serializable {
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
@@ -92,12 +92,12 @@ public class Dict implements Serializable {
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
private Long updateOptid;
|
||||
private String updateId;
|
||||
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
private String updateOptname;
|
||||
private String updateName;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
|
||||
@@ -64,8 +64,8 @@ public class SysDictServiceImpl extends ServiceImpl<SysDictMapper, Dict> impleme
|
||||
dict.setCreateId(currentUserId);
|
||||
dict.setCreateName(nickName);
|
||||
dict.setCreateTime(date);
|
||||
dict.setUpdateOptid(currentUserId);
|
||||
dict.setUpdateOptname(nickName);
|
||||
dict.setupdateId(currentUserId);
|
||||
dict.setupdateName(nickName);
|
||||
dict.setUpdateTime(date);
|
||||
sysDictMapper.insert(dict);
|
||||
}
|
||||
@@ -83,8 +83,8 @@ public class SysDictServiceImpl extends ServiceImpl<SysDictMapper, Dict> impleme
|
||||
dicts.forEach(di -> {
|
||||
di.setCode(dto.getCode());
|
||||
di.setName(dto.getName());
|
||||
di.setUpdateOptid(currentUserId);
|
||||
di.setUpdateOptname(currentNickName);
|
||||
di.setupdateId(currentUserId);
|
||||
di.setupdateName(currentNickName);
|
||||
di.setUpdateTime(DateUtil.now());
|
||||
sysDictMapper.updateById(di);
|
||||
});
|
||||
@@ -139,8 +139,8 @@ public class SysDictServiceImpl extends ServiceImpl<SysDictMapper, Dict> impleme
|
||||
dict.setCreateId(SecurityUtils.getCurrentUserId());
|
||||
dict.setCreateName(SecurityUtils.getCurrentNickName());
|
||||
dict.setCreateTime(DateUtil.now());
|
||||
dict.setUpdateOptid(SecurityUtils.getCurrentUserId());
|
||||
dict.setUpdateOptname(SecurityUtils.getCurrentNickName());
|
||||
dict.setupdateId(SecurityUtils.getCurrentUserId());
|
||||
dict.setupdateName(SecurityUtils.getCurrentNickName());
|
||||
dict.setUpdateTime(DateUtil.now());
|
||||
sysDictMapper.insert(dict);
|
||||
}
|
||||
@@ -154,8 +154,8 @@ public class SysDictServiceImpl extends ServiceImpl<SysDictMapper, Dict> impleme
|
||||
Dict one = sysDictMapper.selectOne(new LambdaQueryWrapper<Dict>().eq(Dict::getLabel, dict.getLabel())
|
||||
.eq(Dict::getCode, dict.getCode()));
|
||||
if (ObjectUtil.isNotEmpty(one)) throw new BadRequestException("标签[" + dict.getLabel() + "]已存在");
|
||||
resources.setUpdateOptid(SecurityUtils.getCurrentUserId());
|
||||
resources.setUpdateOptname(SecurityUtils.getCurrentNickName());
|
||||
resources.setupdateId(SecurityUtils.getCurrentUserId());
|
||||
resources.setupdateName(SecurityUtils.getCurrentNickName());
|
||||
resources.setUpdateTime(DateUtil.now());
|
||||
sysDictMapper.updateById(resources);
|
||||
}
|
||||
|
||||
@@ -107,7 +107,7 @@ public class SysMenu implements Serializable {
|
||||
/**
|
||||
* 创建人标识
|
||||
*/
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
@@ -122,12 +122,12 @@ public class SysMenu implements Serializable {
|
||||
/**
|
||||
* 修改人标识
|
||||
*/
|
||||
private Long updateOptid;
|
||||
private String updateId;
|
||||
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
private String updateOptname;
|
||||
private String updateName;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
|
||||
@@ -58,7 +58,7 @@ public class Param implements Serializable {
|
||||
/**
|
||||
* 创建者ID
|
||||
*/
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
@@ -73,12 +73,12 @@ public class Param implements Serializable {
|
||||
/**
|
||||
* 修改者ID
|
||||
*/
|
||||
private Long updateOptid;
|
||||
private String updateId;
|
||||
|
||||
/**
|
||||
* 修改者
|
||||
*/
|
||||
private String updateOptname;
|
||||
private String updateName;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
|
||||
@@ -54,8 +54,8 @@ public class SysParamServiceImpl extends ServiceImpl<SysParamMapper, Param> impl
|
||||
param.setCreateId(currentUserId);
|
||||
param.setCreateName(nickName);
|
||||
param.setCreateTime(now);
|
||||
param.setUpdateOptid(currentUserId);
|
||||
param.setUpdateOptname(nickName);
|
||||
param.setupdateId(currentUserId);
|
||||
param.setupdateName(nickName);
|
||||
param.setUpdateTime(now);
|
||||
paramMapper.insert(param);
|
||||
}
|
||||
@@ -65,8 +65,8 @@ public class SysParamServiceImpl extends ServiceImpl<SysParamMapper, Param> impl
|
||||
public void update(Param param) {
|
||||
Param paramObj = paramMapper.selectById(param.getId());
|
||||
if (ObjectUtil.isEmpty(paramObj)) throw new BadRequestException("被删除或无权限,操作失败!");
|
||||
param.setUpdateOptid(SecurityUtils.getCurrentUserId());
|
||||
param.setUpdateOptname(SecurityUtils.getCurrentNickName());
|
||||
param.setupdateId(SecurityUtils.getCurrentUserId());
|
||||
param.setupdateName(SecurityUtils.getCurrentNickName());
|
||||
param.setUpdateTime(DateUtil.now());
|
||||
paramMapper.updateById(param);
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ public class SysRole implements Serializable {
|
||||
/**
|
||||
* 创建人标识
|
||||
*/
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
@@ -79,7 +79,7 @@ public class SysRole implements Serializable {
|
||||
/**
|
||||
* 修改人标识
|
||||
*/
|
||||
private Long updateId;
|
||||
private String updateId;
|
||||
|
||||
/**
|
||||
* 修改人
|
||||
|
||||
@@ -28,7 +28,7 @@ public class SysUser implements Serializable {
|
||||
* 用户标识
|
||||
*/
|
||||
@TableId(value = "user_id", type = IdType.INPUT)
|
||||
private Long userId;
|
||||
private String userId;
|
||||
|
||||
/**
|
||||
* 登录账号
|
||||
@@ -93,7 +93,7 @@ public class SysUser implements Serializable {
|
||||
/**
|
||||
* 创建人标识
|
||||
*/
|
||||
private Long createId;
|
||||
private String createId;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
@@ -108,12 +108,12 @@ public class SysUser implements Serializable {
|
||||
/**
|
||||
* 修改人标识
|
||||
*/
|
||||
private Long updateOptid;
|
||||
private String updateId;
|
||||
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
private String updateOptname;
|
||||
private String updateName;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
|
||||
@@ -18,8 +18,8 @@
|
||||
sys_user.create_id as createId,
|
||||
sys_user.create_name as createName,
|
||||
sys_user.create_time as createTime,
|
||||
sys_user.update_optid as updateOptid,
|
||||
sys_user.update_optname as updateOptname,
|
||||
sys_user.update_optid as updateId,
|
||||
sys_user.update_optname as updateName,
|
||||
sys_user.update_time as updateTime,
|
||||
sys_user.extperson_id as extpersonId,
|
||||
sys_user.extuser_id as extuserId
|
||||
@@ -41,8 +41,8 @@
|
||||
<result column="create_id" property="createId" />
|
||||
<result column="create_name" property="createName" />
|
||||
<result column="create_time" property="createTime" />
|
||||
<result column="update_optid" property="updateOptid" />
|
||||
<result column="update_optname" property="updateOptname" />
|
||||
<result column="update_optid" property="updateId" />
|
||||
<result column="update_optname" property="updateName" />
|
||||
<result column="update_tim" property="updateTime" />
|
||||
<result column="extperson_id" property="extpersonId" />
|
||||
<result column="extuser_i" property="extuserId" />
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package org.nl.system.service.user.dto;
|
||||
|
||||
import cn.hutool.core.util.IdUtil;
|
||||
import lombok.Data;
|
||||
import org.nl.system.service.dept.dao.SysDept;
|
||||
import org.nl.system.service.role.dao.SysRole;
|
||||
@@ -13,7 +14,6 @@ import java.util.List;
|
||||
*/
|
||||
@Data
|
||||
public class SysUserDetail extends SysUser {
|
||||
|
||||
private List<SysDept> depts;
|
||||
|
||||
private List<SysRole> roles;
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<el-input v-model.number="form.phone" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="姓名" prop="preson_name">
|
||||
<el-input v-model="form.person_name" style="width: 200px;" />
|
||||
<el-input v-model="form.personName" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="邮箱" prop="email">
|
||||
<el-input v-model="form.email" style="width: 200px;" />
|
||||
@@ -124,9 +124,9 @@
|
||||
<!--:disabled="level !== 1 && item.level <= level"-->
|
||||
<el-option
|
||||
v-for="item in roles"
|
||||
:key="item.role_id"
|
||||
:key="item.roleId"
|
||||
:label="item.name"
|
||||
:value="item.role_id"
|
||||
:value="item.roleId"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -147,11 +147,11 @@
|
||||
<el-table-column :selectable="checkboxT" type="selection" width="55" />
|
||||
<el-table-column prop="username" label="用户名" :min-width="flexWidth('username',crud.data,'用户名')" />
|
||||
<el-table-column
|
||||
prop="person_name"
|
||||
prop="personName"
|
||||
label="姓名"
|
||||
:min-width="flexWidth('personName',crud.data,'姓名')"
|
||||
/>
|
||||
<el-table-column prop="gender" label="性别" :min-width="flexWidth('person_name',crud.data,'性别')" />
|
||||
<el-table-column prop="gender" label="性别" :min-width="flexWidth('personName',crud.data,'性别')" />
|
||||
<el-table-column prop="phone" label="电话" :min-width="flexWidth('phone',crud.data,'电话')" />
|
||||
<el-table-column prop="email" label="邮箱" :min-width="flexWidth('email',crud.data,'邮箱')" />
|
||||
<el-table-column show-overflow-tooltip prop="deptnames" label="部门" />
|
||||
@@ -248,7 +248,7 @@
|
||||
<el-input v-model="dataDialog.username" disabled style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="姓名" prop="preson_name">
|
||||
<el-input v-model="dataDialog.person_name" disabled style="width: 200px;" />
|
||||
<el-input v-model="dataDialog.personName" disabled style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-table
|
||||
ref="dialogTable"
|
||||
@@ -309,7 +309,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column prop="permission_name" label="权限范围" min-width="100" show-overflow-tooltip />
|
||||
<el-table-column prop="dept_name" label="部门名称" min-width="100" show-overflow-tooltip />
|
||||
<el-table-column prop="person_name" label="用户名称" min-width="100" show-overflow-tooltip />
|
||||
<el-table-column prop="personName" label="用户名称" min-width="100" show-overflow-tooltip />
|
||||
</el-table>
|
||||
</el-dialog>
|
||||
<relevance-user-dialog :dialog-show.sync="relevanceUser" :is-single="false" :users="userIds" @selectUsers="selectUsers" />
|
||||
@@ -338,7 +338,7 @@ const defaultForm = {
|
||||
dept_id: null,
|
||||
depts: [],
|
||||
username: null,
|
||||
person_name: null,
|
||||
personName: null,
|
||||
gender: '男',
|
||||
email: null,
|
||||
isUsed: '1',
|
||||
@@ -368,15 +368,15 @@ export default {
|
||||
del: ['admin', 'user:del']
|
||||
},
|
||||
enabledTypeOptions: [
|
||||
{ key: '1', display_name: '激活' },
|
||||
{ key: '0', display_name: '锁定' }
|
||||
{ key: true, display_name: '激活' },
|
||||
{ key: false, display_name: '锁定' }
|
||||
],
|
||||
rules: {
|
||||
username: [
|
||||
{ required: true, message: '请输入用户名', trigger: 'blur' },
|
||||
{ min: 2, max: 20, message: '长度在 2 到 20 个字符', trigger: 'blur' }
|
||||
],
|
||||
person_name: [
|
||||
personName: [
|
||||
{ required: true, message: '请输入用户姓名', trigger: 'blur' },
|
||||
{ min: 2, max: 20, message: '长度在 2 到 20 个字符', trigger: 'blur' }
|
||||
]
|
||||
@@ -573,7 +573,7 @@ export default {
|
||||
},
|
||||
normalizer(node) {
|
||||
return {
|
||||
id: node.dept_id,
|
||||
id: node.deptId,
|
||||
label: node.name,
|
||||
children: node.children
|
||||
}
|
||||
@@ -672,10 +672,10 @@ export default {
|
||||
// // permissions
|
||||
// crudDataPermission.getDataPermissionOption().then(res => {
|
||||
// this.permissions = res
|
||||
// this.dataDialog.person_name = row.person_name
|
||||
// this.dataDialog.personName = row.personName
|
||||
// this.dataDialog.username = row.username
|
||||
// this.dataDialog.user_id = row.user_id
|
||||
// this.dataPermissionTitle = '[' + row.person_name + '] 数据权限'
|
||||
// this.dataPermissionTitle = '[' + row.personName + '] 数据权限'
|
||||
// this.dataPerm = true
|
||||
// // 回显数据
|
||||
// crudDataPermission.getDataShow(row.user_id).then(res => {
|
||||
|
||||
Reference in New Issue
Block a user