|
@@ -175,46 +175,6 @@
|
|
|
where mobile = #{mobile,jdbcType=VARCHAR}
|
|
where mobile = #{mobile,jdbcType=VARCHAR}
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
- <select id= "findAdminListByPage" parameterType="java.lang.String" resultType="com.goafanti.admin.bo.AdminListBo" >
|
|
|
|
|
- select
|
|
|
|
|
- a.number, a.mobile, a.name,
|
|
|
|
|
- a.position, a.email, a.id,
|
|
|
|
|
- a.create_time as createTime, GROUP_CONCAT(DISTINCT(al.province)) AS province,
|
|
|
|
|
- aa.name as superior, a.superior_id as superiorId
|
|
|
|
|
- from admin a
|
|
|
|
|
- left join admin_location al on a.id = al.admin_id
|
|
|
|
|
- left join admin aa on aa.id = a.superior_id
|
|
|
|
|
- where a.id <![CDATA[ <> ]]> '1'
|
|
|
|
|
- <if test = "mobile != null">
|
|
|
|
|
- and a.mobile = #{mobile,jdbcType=VARCHAR}
|
|
|
|
|
- </if>
|
|
|
|
|
- <if test = "name != null">
|
|
|
|
|
- and a.name = #{name,jdbcType=VARCHAR}
|
|
|
|
|
- </if>
|
|
|
|
|
- <if test = "number != null">
|
|
|
|
|
- and a.number = #{number,jdbcType=INTEGER}
|
|
|
|
|
- </if>
|
|
|
|
|
- group by a.id
|
|
|
|
|
- order by a.number
|
|
|
|
|
- <if test="page_sql!=null">
|
|
|
|
|
- ${page_sql}
|
|
|
|
|
- </if>
|
|
|
|
|
- </select>
|
|
|
|
|
-
|
|
|
|
|
- <select id = "findAdminCount" parameterType="java.lang.String" resultType="java.lang.Integer">
|
|
|
|
|
- select count(1) from admin
|
|
|
|
|
- where id <![CDATA[ <> ]]> '1'
|
|
|
|
|
- <if test = "mobile != null">
|
|
|
|
|
- and mobile = #{mobile,jdbcType=VARCHAR}
|
|
|
|
|
- </if>
|
|
|
|
|
- <if test = "name != null">
|
|
|
|
|
- and name = #{name,jdbcType=VARCHAR}
|
|
|
|
|
- </if>
|
|
|
|
|
- <if test = "number != null">
|
|
|
|
|
- and number = #{number,jdbcType=INTEGER}
|
|
|
|
|
- </if>
|
|
|
|
|
- </select>
|
|
|
|
|
-
|
|
|
|
|
<select id="selectRolesByPrimaryKey" parameterType="java.lang.String">
|
|
<select id="selectRolesByPrimaryKey" parameterType="java.lang.String">
|
|
|
select r.name, r.id, r.type
|
|
select r.name, r.id, r.type
|
|
|
from role r
|
|
from role r
|
|
@@ -350,7 +310,33 @@
|
|
|
</if>
|
|
</if>
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
- <select id= "findAreaAdminListByPage" parameterType="java.lang.String" resultType="com.goafanti.admin.bo.AdminListBo" >
|
|
|
|
|
|
|
+ <select id= "findAdminListByPage" parameterType="java.lang.String" resultType="com.goafanti.admin.bo.AdminListBo" >
|
|
|
|
|
+ select
|
|
|
|
|
+ a.number, a.mobile, a.name,
|
|
|
|
|
+ a.position, a.email, a.id,
|
|
|
|
|
+ a.create_time as createTime, GROUP_CONCAT(DISTINCT(al.province)) AS province,
|
|
|
|
|
+ aa.name as superior, a.superior_id as superiorId
|
|
|
|
|
+ from admin a
|
|
|
|
|
+ left join admin_location al on a.id = al.admin_id
|
|
|
|
|
+ left join admin aa on aa.id = a.superior_id
|
|
|
|
|
+ where a.id <![CDATA[ <> ]]> '1'
|
|
|
|
|
+ <if test = "mobile != null">
|
|
|
|
|
+ and a.mobile = #{mobile,jdbcType=VARCHAR}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test = "name != null">
|
|
|
|
|
+ and a.name = #{name,jdbcType=VARCHAR}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test = "number != null">
|
|
|
|
|
+ and a.number = #{number,jdbcType=INTEGER}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ group by a.id
|
|
|
|
|
+ order by a.number
|
|
|
|
|
+ <if test="page_sql!=null">
|
|
|
|
|
+ ${page_sql}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ </select>
|
|
|
|
|
+
|
|
|
|
|
+ <select id= "findAreaAdminListByPage" parameterType="java.lang.String" resultType="com.goafanti.admin.bo.AdminListBo" >
|
|
|
select
|
|
select
|
|
|
a.number, a.mobile, a.name,
|
|
a.number, a.mobile, a.name,
|
|
|
a.position, a.email, a.id,
|
|
a.position, a.email, a.id,
|
|
@@ -376,7 +362,7 @@
|
|
|
#{plist}
|
|
#{plist}
|
|
|
</foreach>
|
|
</foreach>
|
|
|
</if>
|
|
</if>
|
|
|
- <if test = "provinceList != null && cityList != null">
|
|
|
|
|
|
|
+ <if test = "provinceList != null and cityList != null">
|
|
|
or
|
|
or
|
|
|
</if>
|
|
</if>
|
|
|
<if test="cityList != null">
|
|
<if test="cityList != null">
|
|
@@ -395,6 +381,20 @@
|
|
|
</if>
|
|
</if>
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
+ <select id = "findAdminCount" parameterType="java.lang.String" resultType="java.lang.Integer">
|
|
|
|
|
+ select count(1) from admin
|
|
|
|
|
+ where id <![CDATA[ <> ]]> '1'
|
|
|
|
|
+ <if test = "mobile != null">
|
|
|
|
|
+ and mobile = #{mobile,jdbcType=VARCHAR}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test = "name != null">
|
|
|
|
|
+ and name = #{name,jdbcType=VARCHAR}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test = "number != null">
|
|
|
|
|
+ and number = #{number,jdbcType=INTEGER}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ </select>
|
|
|
|
|
+
|
|
|
<select id = "findAreaAdminCount" parameterType="java.lang.String" resultType="java.lang.Integer">
|
|
<select id = "findAreaAdminCount" parameterType="java.lang.String" resultType="java.lang.Integer">
|
|
|
select count(distinct(a.number))
|
|
select count(distinct(a.number))
|
|
|
from admin a
|
|
from admin a
|