feat(后台): bug修复

master
wayn 4 years ago
parent 0e4616054f
commit ffa2990489

@ -14,7 +14,6 @@ public class RoleMenu {
/**
* ID
*/
@TableId(type = IdType.AUTO)
private Long roleId;
/**

@ -1,7 +1,5 @@
package com.wayn.common.core.domain.system;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@ -14,7 +12,6 @@ public class UserRole {
/**
* ID
*/
@TableId(type = IdType.AUTO)
private Long userId;
/**

@ -16,6 +16,7 @@ import com.wayn.common.exception.BusinessException;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.Arrays;
import java.util.List;
@ -83,6 +84,7 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements IU
}
@Override
@Transactional(rollbackFor = Exception.class)
public boolean updateUserAndRole(User user) {
updateById(user);
iUserRoleService.remove(new QueryWrapper<UserRole>().eq("user_id", user.getUserId()));

Loading…
Cancel
Save