提交 | 用户 | 时间
|
1ac2bc
|
1 |
<?xml version="1.0" encoding="UTF-8"?> |
懒 |
2 |
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
|
3 |
<mapper namespace="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.mapper.ProductBomChildInfoMapper"> |
|
4 |
|
|
5 |
<!-- 通用查询映射结果 --> |
|
6 |
<resultMap id="BaseResultMap" type="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.entity.ProductBomChildInfo"> |
|
7 |
<id column="id" property="id" /> |
|
8 |
<result column="op_code" property="opCode" /> |
|
9 |
<result column="op_name" property="opName" /> |
|
10 |
<result column="material_code" property="materialCode" /> |
|
11 |
<result column="material_name" property="materialName" /> |
|
12 |
<result column="cost_qty" property="costQty" /> |
|
13 |
<result column="unit" property="unit" /> |
|
14 |
<result column="spare_field_1" property="spareField1" /> |
|
15 |
<result column="spare_field_2" property="spareField2" /> |
|
16 |
<result column="spare_field_3" property="spareField3" /> |
|
17 |
<result column="remark" property="remark" /> |
|
18 |
<result column="bom_code" property="bomCode" /> |
|
19 |
</resultMap> |
|
20 |
|
|
21 |
<!-- 通用查询结果列 --> |
|
22 |
<sql id="Base_Column_List"> |
|
23 |
id AS "id", op_code AS "opCode", op_name AS "opName", material_code AS "materialCode", material_name AS "materialName", cost_qty AS "costQty", unit AS "unit", spare_field_1 AS "spareField1", spare_field_2 AS "spareField2", spare_field_3 AS "spareField3", remark AS "remark", bom_code AS "bomCode" |
|
24 |
</sql> |
|
25 |
|
|
26 |
|
|
27 |
<select id="customList" resultType="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.model.result.ProductBomChildInfoResult" parameterType="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.model.params.ProductBomChildInfoParam"> |
|
28 |
select |
|
29 |
<include refid="Base_Column_List"/> |
|
30 |
from bs_product_bom_child_info where 1 = 1 |
|
31 |
<if test="paramCondition.opCode != null and paramCondition.opCode != ''"> |
|
32 |
and op_code like CONCAT('%',#{paramCondition.opCode},'%') |
|
33 |
</if> |
|
34 |
<if test="paramCondition.opName != null and paramCondition.opName != ''"> |
|
35 |
and op_name like CONCAT('%',#{paramCondition.opName},'%') |
|
36 |
</if> |
|
37 |
<if test="paramCondition.materialCode != null and paramCondition.materialCode != ''"> |
|
38 |
and material_code like CONCAT('%',#{paramCondition.materialCode},'%') |
|
39 |
</if> |
|
40 |
<if test="paramCondition.materialName != null and paramCondition.materialName != ''"> |
|
41 |
and material_name like CONCAT('%',#{paramCondition.materialName},'%') |
|
42 |
</if> |
|
43 |
<if test="paramCondition.bomCode != null and paramCondition.bomCode != ''"> |
|
44 |
and bom_code like CONCAT('%',#{paramCondition.bomCode},'%') |
|
45 |
</if> |
|
46 |
</select> |
|
47 |
|
|
48 |
<select id="customMapList" resultType="map" parameterType="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.model.params.ProductBomChildInfoParam"> |
|
49 |
select |
|
50 |
<include refid="Base_Column_List"/> |
|
51 |
from bs_product_bom_child_info where 1 = 1 |
|
52 |
<if test="paramCondition.opCode != null and paramCondition.opCode != ''"> |
|
53 |
and op_code like CONCAT('%',#{paramCondition.opCode},'%') |
|
54 |
</if> |
|
55 |
<if test="paramCondition.opName != null and paramCondition.opName != ''"> |
|
56 |
and op_name like CONCAT('%',#{paramCondition.opName},'%') |
|
57 |
</if> |
|
58 |
<if test="paramCondition.materialCode != null and paramCondition.materialCode != ''"> |
|
59 |
and material_code like CONCAT('%',#{paramCondition.materialCode},'%') |
|
60 |
</if> |
|
61 |
<if test="paramCondition.materialName != null and paramCondition.materialName != ''"> |
|
62 |
and material_name like CONCAT('%',#{paramCondition.materialName},'%') |
|
63 |
</if> |
|
64 |
<if test="paramCondition.bomCode != null and paramCondition.bomCode != ''"> |
|
65 |
and bom_code like CONCAT('%',#{paramCondition.bomCode},'%') |
|
66 |
</if> |
|
67 |
</select> |
|
68 |
|
|
69 |
<select id="customPageList" resultType="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.model.result.ProductBomChildInfoResult" parameterType="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.model.params.ProductBomChildInfoParam"> |
|
70 |
select |
|
71 |
<include refid="Base_Column_List"/> |
|
72 |
from bs_product_bom_child_info where 1 = 1 |
|
73 |
<if test="paramCondition.opCode != null and paramCondition.opCode != ''"> |
|
74 |
and op_code like CONCAT('%',#{paramCondition.opCode},'%') |
|
75 |
</if> |
|
76 |
<if test="paramCondition.opName != null and paramCondition.opName != ''"> |
|
77 |
and op_name like CONCAT('%',#{paramCondition.opName},'%') |
|
78 |
</if> |
|
79 |
<if test="paramCondition.materialCode != null and paramCondition.materialCode != ''"> |
|
80 |
and material_code like CONCAT('%',#{paramCondition.materialCode},'%') |
|
81 |
</if> |
|
82 |
<if test="paramCondition.materialName != null and paramCondition.materialName != ''"> |
|
83 |
and material_name like CONCAT('%',#{paramCondition.materialName},'%') |
|
84 |
</if> |
|
85 |
<if test="paramCondition.bomCode != null and paramCondition.bomCode != ''"> |
|
86 |
and bom_code like CONCAT('%',#{paramCondition.bomCode},'%') |
|
87 |
</if> |
|
88 |
</select> |
|
89 |
|
|
90 |
<select id="customPageMapList" resultType="map" parameterType="cn.stylefeng.guns.modular.zsx.bs.productBomChildInfo.model.params.ProductBomChildInfoParam"> |
|
91 |
select |
|
92 |
<include refid="Base_Column_List"/> |
|
93 |
from bs_product_bom_child_info where 1 = 1 |
|
94 |
<if test="paramCondition.opCode != null and paramCondition.opCode != ''"> |
|
95 |
and op_code like CONCAT('%',#{paramCondition.opCode},'%') |
|
96 |
</if> |
|
97 |
<if test="paramCondition.opName != null and paramCondition.opName != ''"> |
|
98 |
and op_name like CONCAT('%',#{paramCondition.opName},'%') |
|
99 |
</if> |
|
100 |
<if test="paramCondition.materialCode != null and paramCondition.materialCode != ''"> |
|
101 |
and material_code like CONCAT('%',#{paramCondition.materialCode},'%') |
|
102 |
</if> |
|
103 |
<if test="paramCondition.materialName != null and paramCondition.materialName != ''"> |
|
104 |
and material_name like CONCAT('%',#{paramCondition.materialName},'%') |
|
105 |
</if> |
|
106 |
<if test="paramCondition.bomCode != null and paramCondition.bomCode != ''"> |
|
107 |
and bom_code like CONCAT('%',#{paramCondition.bomCode},'%') |
|
108 |
</if> |
|
109 |
</select> |
|
110 |
|
|
111 |
</mapper> |