|
@@ -22,10 +22,13 @@
|
|
|
<result column="DEL_USERNAME" jdbcType="VARCHAR" property="delUsername" />
|
|
|
<result column="IS_DEL" jdbcType="VARCHAR" property="isDel" />
|
|
|
<result column="SEQN" jdbcType="INTEGER" property="seqn" />
|
|
|
+ <result column="PAR_CLASSIFY" jdbcType="VARCHAR" property="parClassify" />
|
|
|
+ <result column="PAR_NUMBER" jdbcType="VARCHAR" property="parNumber" />
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="Base_Column_List">
|
|
|
- PAR_ID,APP_ID,INS_CODE,DEPT_ID,PAR_CODE,PAR_NAME,PAR_VALUES,PAR_DES,CREATE_DATE,CREATE_USER,CREATE_USERNAME,UPDATE_DATE,UPDATE_USER,UPDATE_USERNAME,DEL_DATE,DEL_USER,DEL_USERNAME,IS_DEL,SEQN
|
|
|
+ PAR_ID,APP_ID,INS_CODE,DEPT_ID,PAR_CODE,PAR_NAME,PAR_VALUES,PAR_DES,CREATE_DATE,CREATE_USER,CREATE_USERNAME,UPDATE_DATE,UPDATE_USER,UPDATE_USERNAME,
|
|
|
+DEL_DATE,DEL_USER,DEL_USERNAME,IS_DEL,SEQN,PAR_CLASSIFY,PAR_NUMBER
|
|
|
</sql>
|
|
|
|
|
|
<delete id="deleteByCondition" parameterType="TSysParam">
|
|
@@ -34,15 +37,19 @@
|
|
|
|
|
|
<!--单个插入-->
|
|
|
<insert id="insert" parameterType="TSysParam">
|
|
|
- insert into t_sys_param (PAR_ID,APP_ID,INS_CODE,DEPT_ID,PAR_CODE,PAR_NAME,PAR_VALUES,PAR_DES,CREATE_DATE,CREATE_USER,CREATE_USERNAME,SEQN) values
|
|
|
- (#{parId},#{appId},#{insCode},#{deptId},#{parCode},#{parName},#{parValues},#{parDes},#{createDate},#{createUser},#{createUsername},#{seqn})
|
|
|
+ insert into t_sys_param (PAR_ID,APP_ID,INS_CODE,DEPT_ID,PAR_CODE,PAR_NAME,
|
|
|
+ PAR_VALUES,PAR_DES,CREATE_DATE,CREATE_USER,CREATE_USERNAME,SEQN,PAR_CLASSIFY,PAR_NUMBER) values
|
|
|
+ (#{parId},#{appId},#{insCode},#{deptId},#{parCode},#{parName},
|
|
|
+ #{parValues},#{parDes},#{createDate},#{createUser},#{createUsername},#{seqn},#{parClassify},#{parNumber})
|
|
|
</insert>
|
|
|
|
|
|
<!--批量插入-->
|
|
|
<insert id="insertList" parameterType="List">
|
|
|
- insert into t_sys_param (PAR_ID,APP_ID,INS_CODE,DEPT_ID,PAR_CODE,PAR_NAME,PAR_VALUES,PAR_DES,CREATE_DATE,CREATE_USER,CREATE_USERNAME,SEQN) values
|
|
|
+ insert into t_sys_param (PAR_ID,APP_ID,INS_CODE,DEPT_ID,PAR_CODE,PAR_NAME,PAR_VALUES,PAR_DES,
|
|
|
+ CREATE_DATE,CREATE_USER,CREATE_USERNAME,SEQN,PAR_CLASSIFY,PAR_NUMBER) values
|
|
|
<foreach collection="list" item="item" index="index" separator="," >
|
|
|
- (#{ item.parId },#{item.appId},#{item.insCode},#{item.deptId},#{item.parCode},#{item.parName},#{item.parValues},#{item.parDes},#{item.createDate},#{item.createUser},#{item.createUsername},#{item.seqn})
|
|
|
+ (#{ item.parId },#{item.appId},#{item.insCode},#{item.deptId},#{item.parCode},#{item.parName},#{item.parValues},#{item.parDes},
|
|
|
+ #{item.createDate},#{item.createUser},#{item.createUsername},#{item.seqn},#{item.parClassify},#{item.parNumber})
|
|
|
</foreach>
|
|
|
</insert>
|
|
|
|
|
@@ -100,6 +107,12 @@
|
|
|
<if test="isDel != null">
|
|
|
IS_DEL = #{ isDel },
|
|
|
</if>
|
|
|
+ <if test="parClassify != null">
|
|
|
+ PAR_CLASSIFY = #{parClassify},
|
|
|
+ </if>
|
|
|
+ <if test="parNumber != null">
|
|
|
+ PAR_NUMBER = #{parNumber},
|
|
|
+ </if>
|
|
|
</set>
|
|
|
where PAR_ID = #{ parId }
|
|
|
</update>
|
|
@@ -123,7 +136,7 @@
|
|
|
<!--分页查询基础语句返回对象-->
|
|
|
<select id="getPageListByObj" parameterType="TSysParam" resultMap="BaseResultMap">
|
|
|
SELECT p.PAR_ID,p.APP_ID,p.INS_CODE,p.DEPT_ID,p.PAR_CODE,p.PAR_NAME,p.PAR_VALUES,p.PAR_DES,p.CREATE_DATE,p.CREATE_USER,p.CREATE_USERNAME,
|
|
|
- DATE_FORMAT(p.UPDATE_DATE,'%Y-%m-%d %H:%i:%s') UPDATE_DATE,p.UPDATE_USER,p.UPDATE_USERNAME,p.SEQN,
|
|
|
+ DATE_FORMAT(p.UPDATE_DATE,'%Y-%m-%d %H:%i:%s') UPDATE_DATE,p.UPDATE_USER,p.UPDATE_USERNAME,p.SEQN,p.PAR_CLASSIFY,p.PAR_NUMBER,
|
|
|
i.INS_NAME as insName,
|
|
|
a.app_name as appName
|
|
|
from t_sys_param p
|
|
@@ -145,14 +158,20 @@
|
|
|
<if test="parCode != null and parCode!='' ">
|
|
|
and p.PAR_CODE = #{parCode}
|
|
|
</if>
|
|
|
+ <if test="parClassify != null and parClassify!='' ">
|
|
|
+ and p.PAR_CLASSIFY = #{parClassify}
|
|
|
+ </if>
|
|
|
+ <if test="parNumber != null and parNumber!='' ">
|
|
|
+ and p.PAR_NUMBER = #{parNumber}
|
|
|
+ </if>
|
|
|
GROUP BY p.PAR_CODE
|
|
|
- ORDER BY p.PAR_CODE, p.SEQN
|
|
|
+ ORDER BY p.PAR_NUMBER,p.PAR_CODE, p.SEQN
|
|
|
</select>
|
|
|
|
|
|
|
|
|
<!--分页查询基础语句返回对象-->
|
|
|
<select id="getListByCode" parameterType="TSysParam" resultMap="BaseResultMap">
|
|
|
- SELECT p.PAR_ID,p.APP_ID,p.INS_CODE,p.DEPT_ID,p.PAR_CODE,p.PAR_NAME,p.PAR_VALUES,p.PAR_DES,p.SEQN,
|
|
|
+ SELECT p.PAR_ID,p.APP_ID,p.INS_CODE,p.DEPT_ID,p.PAR_CODE,p.PAR_NAME,p.PAR_VALUES,p.PAR_DES,p.SEQN,p.PAR_CLASSIFY,p.PAR_NUMBER,
|
|
|
i.INS_NAME as insName, a.app_name as appName
|
|
|
from t_sys_param p
|
|
|
left join sys_institution i on i.INS_CODE = p.INS_CODE and p.APP_ID = i.APP_ID
|
|
@@ -170,7 +189,7 @@
|
|
|
<if test="parCode != null and parCode!='' ">
|
|
|
and p.PAR_CODE = #{parCode}
|
|
|
</if>
|
|
|
- order by p.PAR_CODE, p.SEQN
|
|
|
+ order by p.PAR_NUMBER,p.PAR_CODE, p.SEQN
|
|
|
</select>
|
|
|
|
|
|
<select id="getObjectByAppIdInsCodeAndCode" resultMap="BaseResultMap" parameterType="TSysParam">
|
|
@@ -196,4 +215,10 @@
|
|
|
from t_sys_param where IS_DEL='0'
|
|
|
group by PAR_CODE
|
|
|
</select>
|
|
|
+ <select id="getAllParamClassifyList" resultType="java.util.Map">
|
|
|
+ select
|
|
|
+ PAR_NUMBER as parNumber
|
|
|
+ from t_sys_param where IS_DEL = '0'
|
|
|
+ GROUP BY PAR_NUMBER
|
|
|
+ </select>
|
|
|
</mapper>
|