用户增加是否认证

This commit is contained in:
19173159168
2025-08-16 22:03:48 +08:00
parent 60c05768b4
commit 9565f5f2cd
3 changed files with 42 additions and 12 deletions

View File

@ -34,23 +34,27 @@ public class ZcBaseUser extends BaseEntity
@Excel(name = "手机号")
private String phoneNumber;
/** 角色id */
@Excel(name = "租车用户",dictType = "sys_yes_no")
private Long roleId;
@Excel(name = "门店用户",dictType = "sys_yes_no")
private Long isStore;
/** 昵称 */
@Excel(name = "昵称")
private String nickName;
/** 微信小程序 openid */
@Excel(name = "微信小程序 openid")
@Excel(name = "微信小程序")
private String wechatOpenid;
/** 支付宝小程序 userid */
@Excel(name = "支付宝小程序 userid")
@Excel(name = "支付宝小程序")
private String alipayUserid;
/** 角色id */
@Excel(name = "租车用户",dictType = "key_yes_no")
private Long roleId;
@Excel(name = "门店用户",dictType = "key_yes_no")
private Long isStore;
@Excel(name = "是否认证",dictType = "key_base_user_authed")
private Long authed;
/** 删除标志0代表存在 2代表删除 */
private String delFlag;
@ -162,6 +166,14 @@ public class ZcBaseUser extends BaseEntity
return delFlag;
}
public Long getAuthed() {
return authed;
}
public void setAuthed(Long authed) {
this.authed = authed;
}
public List<ZcBaseUserStore> getZcBaseUserStoreList()
{
return zcBaseUserStoreList;

View File

@ -15,6 +15,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="nickName" column="nick_name" />
<result property="wechatOpenid" column="wechat_openid" />
<result property="alipayUserid" column="alipay_userid" />
<result property="authed" column="authed" />
<result property="delFlag" column="del_flag" />
<result property="createTime" column="create_time" />
<result property="updateTime" column="update_time" />
@ -39,12 +40,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql id="selectZcBaseUserVo">
select id, user_name, avatar_url, password, phone_number, role_id, is_store, nick_name, wechat_openid, alipay_userid, del_flag, create_time, update_time from zc_base_user
select id, user_name, avatar_url, password, phone_number, role_id, is_store, nick_name, wechat_openid, alipay_userid, authed, del_flag, create_time, update_time from zc_base_user
</sql>
<select id="selectZcBaseUserList" parameterType="ZcBaseUser" resultMap="ZcBaseUserZcBaseUserStoreResult">
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.del_flag, a.create_time, a.update_time,
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.authed, a.del_flag, a.create_time, a.update_time,
b.id as sub_id, b.user_id as sub_user_id, b.operator_id as sub_operator_id, b.store_id as sub_store_id, b.create_time as sub_create_time
from zc_base_user a
left join zc_base_user_store b on b.user_id = a.id
@ -56,6 +57,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="phoneNumber != null and phoneNumber != ''"> and a.phone_number = #{phoneNumber}</if>
<if test="roleId != null "> and a.role_id = #{roleId}</if>
<if test="isStore != null "> and a.is_store = #{isStore}</if>
<if test="authed != null "> and a.authed = #{authed}</if>
<if test="nickName != null and nickName != ''"> and a.nick_name like concat('%', #{nickName}, '%')</if>
<if test="wechatOpenid != null and wechatOpenid != ''"> and a.wechat_openid = #{wechatOpenid}</if>
<if test="alipayUserid != null and alipayUserid != ''"> and a.alipay_userid = #{alipayUserid}</if>
@ -65,7 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select>
<select id="selectZcBaseUserByStoreId" parameterType="Long" resultMap="ZcBaseUserZcBaseUserStoreResult">
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.del_flag, a.create_time, a.update_time,
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.authed, a.del_flag, a.create_time, a.update_time,
b.id as sub_id, b.user_id as sub_user_id, b.operator_id as sub_operator_id, b.store_id as sub_store_id, b.create_time as sub_create_time
from zc_base_user a
left join zc_base_user_store b on b.user_id = a.id
@ -75,7 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select>
<select id="selectZcBaseUserById" parameterType="Long" resultMap="ZcBaseUserZcBaseUserStoreResult">
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.del_flag, a.create_time, a.update_time,
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.authed, a.del_flag, a.create_time, a.update_time,
b.id as sub_id, b.user_id as sub_user_id, b.operator_id as sub_operator_id, b.store_id as sub_store_id, b.create_time as sub_create_time,
c.name as sub_store_name, d.company_name as sub_operator_name
from zc_base_user a
@ -85,7 +87,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where a.del_flag = '0' and a.id = #{id}
</select>
<select id="selectZcBaseUserByPhone" resultMap="ZcBaseUserResult">
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.del_flag, a.create_time, a.update_time
select a.id, a.user_name, a.avatar_url, a.password, a.phone_number, a.role_id, a.is_store, a.nick_name, a.wechat_openid, a.alipay_userid, a.authed, a.del_flag, a.create_time, a.update_time
from zc_base_user a
where a.del_flag = '0' and a.phone_number = #{phoneNumber}
</select>
@ -134,6 +136,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="nickName != null">nick_name = #{nickName},</if>
<if test="wechatOpenid != null">wechat_openid = #{wechatOpenid},</if>
<if test="alipayUserid != null">alipay_userid = #{alipayUserid},</if>
<if test="authed != null">authed = #{authed},</if>
<if test="delFlag != null">del_flag = #{delFlag},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>

View File

@ -34,6 +34,13 @@
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<label>是否认证:</label>
<select name="authed" th:with="type=${@dict.getType('key_base_user_authed')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
@ -67,6 +74,7 @@
var editFlag = [[${@permission.hasPermi('baseUser:user:edit')}]];
var removeFlag = [[${@permission.hasPermi('baseUser:user:remove')}]];
var yesNoDatas = [[${@dict.getType('key_yes_no')}]];
var authedDatas = [[${@dict.getType('key_base_user_authed')}]];
var prefix = ctx + "baseUser/user";
$(function() {
@ -119,6 +127,13 @@
return $.table.selectDictLabel(yesNoDatas, value);
}
},
{
field: 'authed',
title: '是否认证',
formatter: function(value, row, index) {
return $.table.selectDictLabel(authedDatas, value);
}
},
{
title: '操作',
align: 'center',