|
@@ -26,11 +26,12 @@
|
|
|
<result column="reviewer" jdbcType="VARCHAR" property="reviewer" />
|
|
<result column="reviewer" jdbcType="VARCHAR" property="reviewer" />
|
|
|
<result column="amb_id" jdbcType="VARCHAR" property="ambId" />
|
|
<result column="amb_id" jdbcType="VARCHAR" property="ambId" />
|
|
|
<result column="amb_role" jdbcType="VARCHAR" property="ambRole" />
|
|
<result column="amb_role" jdbcType="VARCHAR" property="ambRole" />
|
|
|
|
|
+ <result column="amb_manage" jdbcType="INTEGER" property="ambManage" />
|
|
|
</resultMap>
|
|
</resultMap>
|
|
|
<sql id="Base_Column_List">
|
|
<sql id="Base_Column_List">
|
|
|
id, mobile, `name`, `password`, email, create_time, `number`, province, `position`,
|
|
id, mobile, `name`, `password`, email, create_time, `number`, province, `position`,
|
|
|
superior_id, city, department_id, `status`, user_no, duty, district, head_portrait_url,
|
|
superior_id, city, department_id, `status`, user_no, duty, district, head_portrait_url,
|
|
|
- contact_mobile, last_login_time, open_id, `type`, reviewer, amb_id, amb_role
|
|
|
|
|
|
|
+ contact_mobile, last_login_time, open_id, `type`, reviewer, amb_id, amb_role, amb_manage
|
|
|
</sql>
|
|
</sql>
|
|
|
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
|
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
|
|
select
|
|
select
|
|
@@ -50,7 +51,8 @@
|
|
|
user_no, duty, district,
|
|
user_no, duty, district,
|
|
|
head_portrait_url, contact_mobile, last_login_time,
|
|
head_portrait_url, contact_mobile, last_login_time,
|
|
|
open_id, `type`, reviewer,
|
|
open_id, `type`, reviewer,
|
|
|
- amb_id, amb_role)
|
|
|
|
|
|
|
+ amb_id, amb_role, amb_manage
|
|
|
|
|
+ )
|
|
|
values (#{mobile,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR},
|
|
values (#{mobile,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR},
|
|
|
#{email,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{number,jdbcType=INTEGER},
|
|
#{email,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{number,jdbcType=INTEGER},
|
|
|
#{province,jdbcType=VARCHAR}, #{position,jdbcType=VARCHAR}, #{superiorId,jdbcType=VARCHAR},
|
|
#{province,jdbcType=VARCHAR}, #{position,jdbcType=VARCHAR}, #{superiorId,jdbcType=VARCHAR},
|
|
@@ -58,7 +60,8 @@
|
|
|
#{userNo,jdbcType=VARCHAR}, #{duty,jdbcType=VARCHAR}, #{district,jdbcType=VARCHAR},
|
|
#{userNo,jdbcType=VARCHAR}, #{duty,jdbcType=VARCHAR}, #{district,jdbcType=VARCHAR},
|
|
|
#{headPortraitUrl,jdbcType=VARCHAR}, #{contactMobile,jdbcType=VARCHAR}, #{lastLoginTime,jdbcType=TIMESTAMP},
|
|
#{headPortraitUrl,jdbcType=VARCHAR}, #{contactMobile,jdbcType=VARCHAR}, #{lastLoginTime,jdbcType=TIMESTAMP},
|
|
|
#{openId,jdbcType=VARCHAR}, #{type,jdbcType=INTEGER}, #{reviewer,jdbcType=VARCHAR},
|
|
#{openId,jdbcType=VARCHAR}, #{type,jdbcType=INTEGER}, #{reviewer,jdbcType=VARCHAR},
|
|
|
- #{ambId,jdbcType=VARCHAR}, #{ambRole,jdbcType=VARCHAR})
|
|
|
|
|
|
|
+ #{ambId,jdbcType=VARCHAR}, #{ambRole,jdbcType=VARCHAR}, #{ambManage,jdbcType=INTEGER}
|
|
|
|
|
+ )
|
|
|
</insert>
|
|
</insert>
|
|
|
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.Admin" useGeneratedKeys="true">
|
|
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.Admin" useGeneratedKeys="true">
|
|
|
insert into admin
|
|
insert into admin
|
|
@@ -132,6 +135,9 @@
|
|
|
<if test="ambRole != null">
|
|
<if test="ambRole != null">
|
|
|
amb_role,
|
|
amb_role,
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="ambManage != null">
|
|
|
|
|
+ amb_manage,
|
|
|
|
|
+ </if>
|
|
|
</trim>
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="mobile != null">
|
|
<if test="mobile != null">
|
|
@@ -203,6 +209,9 @@
|
|
|
<if test="ambRole != null">
|
|
<if test="ambRole != null">
|
|
|
#{ambRole,jdbcType=VARCHAR},
|
|
#{ambRole,jdbcType=VARCHAR},
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="ambManage != null">
|
|
|
|
|
+ #{ambManage,jdbcType=INTEGER},
|
|
|
|
|
+ </if>
|
|
|
</trim>
|
|
</trim>
|
|
|
</insert>
|
|
</insert>
|
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.Admin">
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.Admin">
|
|
@@ -277,6 +286,9 @@
|
|
|
<if test="ambRole != null">
|
|
<if test="ambRole != null">
|
|
|
amb_role = #{ambRole,jdbcType=VARCHAR},
|
|
amb_role = #{ambRole,jdbcType=VARCHAR},
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ <if test="ambManage != null">
|
|
|
|
|
+ amb_manage = #{ambManage,jdbcType=INTEGER},
|
|
|
|
|
+ </if>
|
|
|
</set>
|
|
</set>
|
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
|
</update>
|
|
</update>
|
|
@@ -304,11 +316,15 @@
|
|
|
`type` = #{type,jdbcType=INTEGER},
|
|
`type` = #{type,jdbcType=INTEGER},
|
|
|
reviewer = #{reviewer,jdbcType=VARCHAR},
|
|
reviewer = #{reviewer,jdbcType=VARCHAR},
|
|
|
amb_id = #{ambId,jdbcType=VARCHAR},
|
|
amb_id = #{ambId,jdbcType=VARCHAR},
|
|
|
- amb_role = #{ambRole,jdbcType=VARCHAR}
|
|
|
|
|
|
|
+ amb_role = #{ambRole,jdbcType=VARCHAR},
|
|
|
|
|
+ amb_manage = #{ambManage,jdbcType=INTEGER}
|
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
|
</update>
|
|
</update>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
<select id="selectAllAdmin" resultMap="BaseResultMap">
|
|
<select id="selectAllAdmin" resultMap="BaseResultMap">
|
|
|
select
|
|
select
|
|
|
<include refid="Base_Column_List" />
|
|
<include refid="Base_Column_List" />
|
|
@@ -579,7 +595,7 @@
|
|
|
and (ambs.id=#{ancestors} or find_in_set( #{ancestors} ,ambs.ancestors))
|
|
and (ambs.id=#{ancestors} or find_in_set( #{ancestors} ,ambs.ancestors))
|
|
|
</if>
|
|
</if>
|
|
|
<if test="ambManage !=null">
|
|
<if test="ambManage !=null">
|
|
|
- and a.ts= #{ambManage}
|
|
|
|
|
|
|
+ and a.amb_manage= #{ambManage}
|
|
|
</if>
|
|
</if>
|
|
|
order by a.last_login_time desc
|
|
order by a.last_login_time desc
|
|
|
<if test="page_sql!=null">
|
|
<if test="page_sql!=null">
|
|
@@ -629,7 +645,7 @@
|
|
|
and (ambs.id=#{ancestors} or find_in_set( #{ancestors} ,ambs.ancestors))
|
|
and (ambs.id=#{ancestors} or find_in_set( #{ancestors} ,ambs.ancestors))
|
|
|
</if>
|
|
</if>
|
|
|
<if test="ambManage !=null">
|
|
<if test="ambManage !=null">
|
|
|
- and a.ts= #{ambManage}
|
|
|
|
|
|
|
+ and a.amb_manage= #{ambManage}
|
|
|
</if>
|
|
</if>
|
|
|
</select>
|
|
</select>
|
|
|
<insert id="insertn" parameterType="com.goafanti.common.model.Admin">
|
|
<insert id="insertn" parameterType="com.goafanti.common.model.Admin">
|