添加查询条件

This commit is contained in:
lvleigang 2024-09-10 17:22:28 +08:00
parent 1e6ca2aab9
commit a242a89fc2
3 changed files with 58 additions and 2 deletions

View File

@ -22,6 +22,10 @@ public class DictCheckTypeEntity extends BaseEntity {
private String branch_code; private String branch_code;
/** 院区名称 */ /** 院区名称 */
private String branch_name; private String branch_name;
/** 会计年度 */
private String kjnd;
/** gsdm */
private String gsdm;
public String getCheck_type_code() { public String getCheck_type_code() {
return check_type_code; return check_type_code;
@ -70,5 +74,22 @@ public class DictCheckTypeEntity extends BaseEntity {
public void setBranch_name(String branch_name) { public void setBranch_name(String branch_name) {
this.branch_name = branch_name; this.branch_name = branch_name;
} }
public String getKjnd() {
return kjnd;
}
public void setKjnd(String kjnd) {
this.kjnd = kjnd;
}
public String getGsdm() {
return gsdm;
}
public void setGsdm(String gsdm) {
this.gsdm = gsdm;
}
} }

View File

@ -3,6 +3,8 @@
<mapper namespace="com.hzya.frame.xsFinance.dictCheckType.dao.impl.DictCheckTypeDaoImpl"> <mapper namespace="com.hzya.frame.xsFinance.dictCheckType.dao.impl.DictCheckTypeDaoImpl">
<resultMap id="get-DictCheckTypeEntity-result" type="com.hzya.frame.xsFinance.dictCheckType.entity.DictCheckTypeEntity" > <resultMap id="get-DictCheckTypeEntity-result" type="com.hzya.frame.xsFinance.dictCheckType.entity.DictCheckTypeEntity" >
<result property="kjnd" column="kjnd" jdbcType="VARCHAR"/>
<result property="gsdm" column="gsdm" jdbcType="VARCHAR"/>
<result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/> <result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/>
<result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/> <result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/> <result property="org_code" column="org_code" jdbcType="VARCHAR"/>
@ -12,7 +14,9 @@
</resultMap> </resultMap>
<!-- 查询的字段--> <!-- 查询的字段-->
<sql id = "DictCheckTypeEntity_Base_Column_List"> <sql id = "DictCheckTypeEntity_Base_Column_List">
check_type_code kjnd
,gsdm
,check_type_code
,check_type_name ,check_type_name
,org_code ,org_code
,org_name ,org_name
@ -25,6 +29,8 @@
<include refid="DictCheckTypeEntity_Base_Column_List" /> <include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type from dict_check_type
<trim prefix="where" prefixOverrides="and"> <trim prefix="where" prefixOverrides="and">
<if test="kjnd != null and kjnd != ''"> and kjnd = #{kjnd} </if>
<if test="gsdm != null and gsdm != ''"> and gsdm = #{gsdm} </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if> <if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if> <if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if> <if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
@ -38,6 +44,8 @@
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.xsFinance.dictCheckType.entity.DictCheckTypeEntity"> <select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.xsFinance.dictCheckType.entity.DictCheckTypeEntity">
select count(1) from dict_check_type select count(1) from dict_check_type
<trim prefix="where" prefixOverrides="and"> <trim prefix="where" prefixOverrides="and">
<if test="kjnd != null and kjnd != ''"> and kjnd = #{kjnd} </if>
<if test="gsdm != null and gsdm != ''"> and gsdm = #{gsdm} </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if> <if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if> <if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if> <if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
@ -53,6 +61,8 @@
<include refid="DictCheckTypeEntity_Base_Column_List" /> <include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type from dict_check_type
<trim prefix="where" prefixOverrides="and"> <trim prefix="where" prefixOverrides="and">
<if test="kjnd != null and kjnd != ''"> and kjnd like concat('%',#{kjnd},'%') </if>
<if test="gsdm != null and gsdm != ''"> and gsdm like concat('%',#{gsdm},'%') </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code like concat('%',#{check_type_code},'%') </if> <if test="check_type_code != null and check_type_code != ''"> and check_type_code like concat('%',#{check_type_code},'%') </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name like concat('%',#{check_type_name},'%') </if> <if test="check_type_name != null and check_type_name != ''"> and check_type_name like concat('%',#{check_type_name},'%') </if>
<if test="org_code != null and org_code != ''"> and org_code like concat('%',#{org_code},'%') </if> <if test="org_code != null and org_code != ''"> and org_code like concat('%',#{org_code},'%') </if>
@ -68,6 +78,8 @@
<include refid="DictCheckTypeEntity_Base_Column_List" /> <include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type from dict_check_type
<trim prefix="where" prefixOverrides="and"> <trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm != ''"> or gsdm = #{gsdm} </if>
<if test="kjnd != null and kjnd != ''"> or kjnd = #{kjnd} </if>
<if test="check_type_code != null and check_type_code != ''"> or check_type_code = #{check_type_code} </if> <if test="check_type_code != null and check_type_code != ''"> or check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> or check_type_name = #{check_type_name} </if> <if test="check_type_name != null and check_type_name != ''"> or check_type_name = #{check_type_name} </if>
<if test="org_code != null and org_code != ''"> or org_code = #{org_code} </if> <if test="org_code != null and org_code != ''"> or org_code = #{org_code} </if>
@ -78,6 +90,8 @@
</select> </select>
<resultMap id="get-DictCheckTypeEntityVo-result" type="com.hzya.frame.xsFinance.dictCheckType.entity.DictCheckTypeEntityVo" > <resultMap id="get-DictCheckTypeEntityVo-result" type="com.hzya.frame.xsFinance.dictCheckType.entity.DictCheckTypeEntityVo" >
<result property="kjnd" column="kjnd" jdbcType="VARCHAR"/>
<result property="gsdm" column="gsdm" jdbcType="VARCHAR"/>
<result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/> <result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/>
<result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/> <result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/> <result property="org_code" column="org_code" jdbcType="VARCHAR"/>
@ -91,6 +105,8 @@
<include refid="DictCheckTypeEntity_Base_Column_List" /> <include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type from dict_check_type
<trim prefix="where" prefixOverrides="and"> <trim prefix="where" prefixOverrides="and">
<if test="kjnd != null and kjnd != ''"> and kjnd = '${kjnd}' </if>
<if test="gsdm != null and gsdm != ''"> and gsdm = '${gsdm}' </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code like '%${check_type_code}%' </if> <if test="check_type_code != null and check_type_code != ''"> and check_type_code like '%${check_type_code}%' </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name like '%${check_type_name}%' </if> <if test="check_type_name != null and check_type_name != ''"> and check_type_name like '%${check_type_name}%' </if>
<if test="org_code != null and org_code != ''"> and org_code like '%${org_code}%' </if> <if test="org_code != null and org_code != ''"> and org_code like '%${org_code}%' </if>

View File

@ -23,6 +23,9 @@ public class DictCheckTypeEntityVo {
/** 院区名称 */ /** 院区名称 */
private String branch_name; private String branch_name;
private String kjnd;
private String gsdm;
public String getCheck_type_code() { public String getCheck_type_code() {
return check_type_code; return check_type_code;
} }
@ -70,5 +73,21 @@ public class DictCheckTypeEntityVo {
public void setBranch_name(String branch_name) { public void setBranch_name(String branch_name) {
this.branch_name = branch_name; this.branch_name = branch_name;
} }
public String getKjnd() {
return kjnd;
}
public void setKjnd(String kjnd) {
this.kjnd = kjnd;
}
public String getGsdm() {
return gsdm;
}
public void setGsdm(String gsdm) {
this.gsdm = gsdm;
}
} }