style(代码优化): userId由Long类型改为String类型
This commit is contained in:
parent
c31053087a
commit
6bc4b2dd94
@ -16,6 +16,6 @@ public class UserRole {
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long userRoleId;
|
||||
private Long userId;
|
||||
private String userId;
|
||||
private Long roleId;
|
||||
}
|
||||
|
@ -10,7 +10,7 @@ import java.util.List;
|
||||
public interface UserMapper extends BaseMapper<UserBean> {
|
||||
int insertUser(UserBean userBean);
|
||||
|
||||
int insertUserRole(String userId, long roleId);
|
||||
int insertUserRole(@Param("userId") String userId, @Param("roleId") long roleId);
|
||||
|
||||
List<Role> selectRoleListByUserId(@Param("userId") String userId);
|
||||
|
||||
|
@ -11,9 +11,9 @@
|
||||
VALUES (#{userId}, #{username},#{salt}, #{password}, #{telephone}, #{sex}, #{imageUrl}, #{registerTime}, 1);
|
||||
</insert>
|
||||
|
||||
<insert id="insertUserRole" parameterType="Long">
|
||||
<insert id="insertUserRole">
|
||||
INSERT INTO user_role (userId, roleId)
|
||||
VALUES (#{param1}, #{param2});
|
||||
VALUES (#{userId}, #{roleId});
|
||||
</insert>
|
||||
|
||||
<select id="selectRoleListByUserId" resultType="com.qiwenshare.file.domain.user.Role">
|
||||
|
Loading…
Reference in New Issue
Block a user