forked from github/dataease
fix: 用户管理删除组织会闪现0(null)
This commit is contained in:
parent
99bd4727ed
commit
256c0efe6b
@ -30,6 +30,7 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Service
|
||||
@ -117,6 +118,7 @@ public class SysUserService {
|
||||
user.setUpdateTime(now);
|
||||
deleteUserRoles(user.getUserId());//先删除用户角色关联
|
||||
saveUserRoles(user.getUserId(), request.getRoleIds());//再插入角色关联
|
||||
if (ObjectUtils.isEmpty(user.getDeptId())) user.setDeptId(0L);
|
||||
return sysUserMapper.updateByPrimaryKeySelective(user);
|
||||
}
|
||||
|
||||
|
@ -106,7 +106,7 @@ export default {
|
||||
const { meta, path } = route
|
||||
// if set path, the sidebar will highlight the path you set
|
||||
if (meta.activeMenu) {
|
||||
return meta.activeMenu
|
||||
// return meta.activeMenu
|
||||
}
|
||||
// 如果是首页,首页高亮
|
||||
if (path === '/panel') {
|
||||
|
@ -5,7 +5,8 @@
|
||||
|
||||
<div class="span-header">
|
||||
<div class="bi-text">
|
||||
{{ $t('pblink.key_pwd') }}
|
||||
<span style="text-align: center;">{{ $t('pblink.key_pwd') }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@ -288,7 +288,7 @@ export default {
|
||||
save() {
|
||||
this.$refs.createUserForm.validate(valid => {
|
||||
if (valid) {
|
||||
!this.form.deptId && (this.form.deptId = 0)
|
||||
// !this.form.deptId && (this.form.deptId = 0)
|
||||
const method = this.formType === 'add' ? addUser : editUser
|
||||
method(this.form).then(res => {
|
||||
this.$success(this.$t('commons.save_success'))
|
||||
|
Loading…
Reference in New Issue
Block a user