|
@@ -8,9 +8,10 @@ |
|
@@ -8,9 +8,10 @@ |
|
8
|
<result column="yard_id" jdbcType="VARCHAR" property="yardId"/>
|
8
|
<result column="yard_id" jdbcType="VARCHAR" property="yardId"/>
|
|
9
|
<result column="cop_code" jdbcType="VARCHAR" property="copCode"/>
|
9
|
<result column="cop_code" jdbcType="VARCHAR" property="copCode"/>
|
|
10
|
<result column="name" jdbcType="VARCHAR" property="name"/>
|
10
|
<result column="name" jdbcType="VARCHAR" property="name"/>
|
|
11
|
- <result column="length" jdbcType="DECIMAL" property="length"/>
|
|
|
|
12
|
- <result column="width" jdbcType="DECIMAL" property="width"/>
|
|
|
|
13
|
- <result column="area" jdbcType="DECIMAL" property="area"/>
|
11
|
+ <result column="warehouse_type" jdbcType="VARCHAR" property="warehouseType"/>
|
|
|
|
12
|
+ <result column="warehouse_length" jdbcType="DECIMAL" property="warehouseLength"/>
|
|
|
|
13
|
+ <result column="warehouse_width" jdbcType="DECIMAL" property="warehouseWidth"/>
|
|
|
|
14
|
+ <result column="warehouse_area" jdbcType="DECIMAL" property="warehouseArea"/>
|
|
14
|
<result column="create_by" jdbcType="VARCHAR" property="createBy"/>
|
15
|
<result column="create_by" jdbcType="VARCHAR" property="createBy"/>
|
|
15
|
<result column="create_date" jdbcType="TIMESTAMP" property="createDate"/>
|
16
|
<result column="create_date" jdbcType="TIMESTAMP" property="createDate"/>
|
|
16
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy"/>
|
17
|
<result column="update_by" jdbcType="VARCHAR" property="updateBy"/>
|
|
@@ -18,19 +19,10 @@ |
|
@@ -18,19 +19,10 @@ |
|
18
|
<result column="remarks" jdbcType="VARCHAR" property="remarks"/>
|
19
|
<result column="remarks" jdbcType="VARCHAR" property="remarks"/>
|
|
19
|
<result column="del_flag" jdbcType="CHAR" property="delFlag"/>
|
20
|
<result column="del_flag" jdbcType="CHAR" property="delFlag"/>
|
|
20
|
</resultMap>
|
21
|
</resultMap>
|
|
21
|
-
|
|
|
|
22
|
- <!-- 该Mapper映射关系的作用,是仓库与场站的1:1的关系映射 -->
|
|
|
|
23
|
- <resultMap id="WarehouseAndYardMap" extends="BaseResultMap"
|
|
|
|
24
|
- type="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
|
|
|
25
|
- <association property="yard" javaType="com.sunyo.wlpt.station.manage.domain.Yard">
|
|
|
|
26
|
- <id column="id" property="id"/>
|
|
|
|
27
|
- <result column="yard_name" property="name"/>
|
|
|
|
28
|
- </association>
|
|
|
|
29
|
- </resultMap>
|
|
|
|
30
|
<sql id="Base_Column_List">
|
22
|
<sql id="Base_Column_List">
|
|
31
|
<!--@mbg.generated-->
|
23
|
<!--@mbg.generated-->
|
|
32
|
- id, yard_id, cop_code, `name`, `length`, width, area, create_by, create_date, update_by,
|
|
|
|
33
|
- update_date, remarks, del_flag
|
24
|
+ id, yard_id, cop_code, `name`, warehouse_type, warehouse_length, warehouse_width, warehouse_area,
|
|
|
|
25
|
+ create_by, create_date, update_by, update_date, remarks, del_flag
|
|
34
|
</sql>
|
26
|
</sql>
|
|
35
|
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
27
|
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
|
36
|
<!--@mbg.generated-->
|
28
|
<!--@mbg.generated-->
|
|
@@ -39,38 +31,6 @@ |
|
@@ -39,38 +31,6 @@ |
|
39
|
from warehouse
|
31
|
from warehouse
|
|
40
|
where id = #{id,jdbcType=VARCHAR}
|
32
|
where id = #{id,jdbcType=VARCHAR}
|
|
41
|
</select>
|
33
|
</select>
|
|
42
|
-
|
|
|
|
43
|
- <!-- 分页查询 -->
|
|
|
|
44
|
- <select id="selectListByPage" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse" resultMap="WarehouseAndYardMap">
|
|
|
|
45
|
- select w.id,
|
|
|
|
46
|
- w.yard_id,
|
|
|
|
47
|
- w.cop_code,
|
|
|
|
48
|
- w.name,
|
|
|
|
49
|
- w.length,
|
|
|
|
50
|
- w.width,
|
|
|
|
51
|
- w.area,
|
|
|
|
52
|
- w.create_by,
|
|
|
|
53
|
- w.create_date,
|
|
|
|
54
|
- w.update_by,
|
|
|
|
55
|
- w.update_date,
|
|
|
|
56
|
- w.remarks,
|
|
|
|
57
|
- w.del_flag,
|
|
|
|
58
|
- y.name as yard_name
|
|
|
|
59
|
- from warehouse w,
|
|
|
|
60
|
- yard y
|
|
|
|
61
|
- <where>
|
|
|
|
62
|
- <!-- name,仓库名称 -->
|
|
|
|
63
|
- <if test="name != null and name != ''">
|
|
|
|
64
|
- and w.name = #{name,jdbcType=VARCHAR}
|
|
|
|
65
|
- </if>
|
|
|
|
66
|
- <!-- stationName,货站名称 -->
|
|
|
|
67
|
- <if test="stationName != null and stationName != ''">
|
|
|
|
68
|
- and y.name = #{stationName,jdbcType=VARCHAR}
|
|
|
|
69
|
- </if>
|
|
|
|
70
|
- and w.yard_id = y.id
|
|
|
|
71
|
- </where>
|
|
|
|
72
|
- </select>
|
|
|
|
73
|
-
|
|
|
|
74
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
|
34
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
|
|
75
|
<!--@mbg.generated-->
|
35
|
<!--@mbg.generated-->
|
|
76
|
delete
|
36
|
delete
|
|
@@ -80,15 +40,15 @@ |
|
@@ -80,15 +40,15 @@ |
|
80
|
<insert id="insert" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
40
|
<insert id="insert" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
|
81
|
<!--@mbg.generated-->
|
41
|
<!--@mbg.generated-->
|
|
82
|
insert into warehouse (id, yard_id, cop_code,
|
42
|
insert into warehouse (id, yard_id, cop_code,
|
|
83
|
- `name`, `length`, width,
|
|
|
|
84
|
- area, create_by, create_date,
|
|
|
|
85
|
- update_by, update_date, remarks,
|
|
|
|
86
|
- del_flag)
|
43
|
+ `name`, warehouse_type, warehouse_length,
|
|
|
|
44
|
+ warehouse_width, warehouse_area, create_by,
|
|
|
|
45
|
+ create_date, update_by, update_date,
|
|
|
|
46
|
+ remarks, del_flag)
|
|
87
|
values (#{id,jdbcType=VARCHAR}, #{yardId,jdbcType=VARCHAR}, #{copCode,jdbcType=VARCHAR},
|
47
|
values (#{id,jdbcType=VARCHAR}, #{yardId,jdbcType=VARCHAR}, #{copCode,jdbcType=VARCHAR},
|
|
88
|
- #{name,jdbcType=VARCHAR}, #{length,jdbcType=DECIMAL}, #{width,jdbcType=DECIMAL},
|
|
|
|
89
|
- #{area,jdbcType=DECIMAL}, #{createBy,jdbcType=VARCHAR}, #{createDate,jdbcType=TIMESTAMP},
|
|
|
|
90
|
- #{updateBy,jdbcType=VARCHAR}, #{updateDate,jdbcType=TIMESTAMP}, #{remarks,jdbcType=VARCHAR},
|
|
|
|
91
|
- #{delFlag,jdbcType=CHAR})
|
48
|
+ #{name,jdbcType=VARCHAR}, #{warehouseType,jdbcType=VARCHAR}, #{warehouseLength,jdbcType=DECIMAL},
|
|
|
|
49
|
+ #{warehouseWidth,jdbcType=DECIMAL}, #{warehouseArea,jdbcType=DECIMAL}, #{createBy,jdbcType=VARCHAR},
|
|
|
|
50
|
+ #{createDate,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateDate,jdbcType=TIMESTAMP},
|
|
|
|
51
|
+ #{remarks,jdbcType=VARCHAR}, #{delFlag,jdbcType=CHAR})
|
|
92
|
</insert>
|
52
|
</insert>
|
|
93
|
<insert id="insertSelective" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
53
|
<insert id="insertSelective" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
|
94
|
<!--@mbg.generated-->
|
54
|
<!--@mbg.generated-->
|
|
@@ -106,14 +66,17 @@ |
|
@@ -106,14 +66,17 @@ |
|
106
|
<if test="name != null">
|
66
|
<if test="name != null">
|
|
107
|
`name`,
|
67
|
`name`,
|
|
108
|
</if>
|
68
|
</if>
|
|
109
|
- <if test="length != null">
|
|
|
|
110
|
- `length`,
|
69
|
+ <if test="warehouseType != null">
|
|
|
|
70
|
+ warehouse_type,
|
|
111
|
</if>
|
71
|
</if>
|
|
112
|
- <if test="width != null">
|
|
|
|
113
|
- width,
|
72
|
+ <if test="warehouseLength != null">
|
|
|
|
73
|
+ warehouse_length,
|
|
114
|
</if>
|
74
|
</if>
|
|
115
|
- <if test="area != null">
|
|
|
|
116
|
- area,
|
75
|
+ <if test="warehouseWidth != null">
|
|
|
|
76
|
+ warehouse_width,
|
|
|
|
77
|
+ </if>
|
|
|
|
78
|
+ <if test="warehouseArea != null">
|
|
|
|
79
|
+ warehouse_area,
|
|
117
|
</if>
|
80
|
</if>
|
|
118
|
<if test="createBy != null">
|
81
|
<if test="createBy != null">
|
|
119
|
create_by,
|
82
|
create_by,
|
|
@@ -147,14 +110,17 @@ |
|
@@ -147,14 +110,17 @@ |
|
147
|
<if test="name != null">
|
110
|
<if test="name != null">
|
|
148
|
#{name,jdbcType=VARCHAR},
|
111
|
#{name,jdbcType=VARCHAR},
|
|
149
|
</if>
|
112
|
</if>
|
|
150
|
- <if test="length != null">
|
|
|
|
151
|
- #{length,jdbcType=DECIMAL},
|
113
|
+ <if test="warehouseType != null">
|
|
|
|
114
|
+ #{warehouseType,jdbcType=VARCHAR},
|
|
|
|
115
|
+ </if>
|
|
|
|
116
|
+ <if test="warehouseLength != null">
|
|
|
|
117
|
+ #{warehouseLength,jdbcType=DECIMAL},
|
|
152
|
</if>
|
118
|
</if>
|
|
153
|
- <if test="width != null">
|
|
|
|
154
|
- #{width,jdbcType=DECIMAL},
|
119
|
+ <if test="warehouseWidth != null">
|
|
|
|
120
|
+ #{warehouseWidth,jdbcType=DECIMAL},
|
|
155
|
</if>
|
121
|
</if>
|
|
156
|
- <if test="area != null">
|
|
|
|
157
|
- #{area,jdbcType=DECIMAL},
|
122
|
+ <if test="warehouseArea != null">
|
|
|
|
123
|
+ #{warehouseArea,jdbcType=DECIMAL},
|
|
158
|
</if>
|
124
|
</if>
|
|
159
|
<if test="createBy != null">
|
125
|
<if test="createBy != null">
|
|
160
|
#{createBy,jdbcType=VARCHAR},
|
126
|
#{createBy,jdbcType=VARCHAR},
|
|
@@ -189,14 +155,17 @@ |
|
@@ -189,14 +155,17 @@ |
|
189
|
<if test="name != null">
|
155
|
<if test="name != null">
|
|
190
|
`name` = #{name,jdbcType=VARCHAR},
|
156
|
`name` = #{name,jdbcType=VARCHAR},
|
|
191
|
</if>
|
157
|
</if>
|
|
192
|
- <if test="length != null">
|
|
|
|
193
|
- `length` = #{length,jdbcType=DECIMAL},
|
158
|
+ <if test="warehouseType != null">
|
|
|
|
159
|
+ warehouse_type = #{warehouseType,jdbcType=VARCHAR},
|
|
194
|
</if>
|
160
|
</if>
|
|
195
|
- <if test="width != null">
|
|
|
|
196
|
- width = #{width,jdbcType=DECIMAL},
|
161
|
+ <if test="warehouseLength != null">
|
|
|
|
162
|
+ warehouse_length = #{warehouseLength,jdbcType=DECIMAL},
|
|
197
|
</if>
|
163
|
</if>
|
|
198
|
- <if test="area != null">
|
|
|
|
199
|
- area = #{area,jdbcType=DECIMAL},
|
164
|
+ <if test="warehouseWidth != null">
|
|
|
|
165
|
+ warehouse_width = #{warehouseWidth,jdbcType=DECIMAL},
|
|
|
|
166
|
+ </if>
|
|
|
|
167
|
+ <if test="warehouseArea != null">
|
|
|
|
168
|
+ warehouse_area = #{warehouseArea,jdbcType=DECIMAL},
|
|
200
|
</if>
|
169
|
</if>
|
|
201
|
<if test="createBy != null">
|
170
|
<if test="createBy != null">
|
|
202
|
create_by = #{createBy,jdbcType=VARCHAR},
|
171
|
create_by = #{createBy,jdbcType=VARCHAR},
|
|
@@ -222,18 +191,59 @@ |
|
@@ -222,18 +191,59 @@ |
|
222
|
<update id="updateByPrimaryKey" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
191
|
<update id="updateByPrimaryKey" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
|
223
|
<!--@mbg.generated-->
|
192
|
<!--@mbg.generated-->
|
|
224
|
update warehouse
|
193
|
update warehouse
|
|
225
|
- set yard_id = #{yardId,jdbcType=VARCHAR},
|
|
|
|
226
|
- cop_code = #{copCode,jdbcType=VARCHAR},
|
|
|
|
227
|
- `name` = #{name,jdbcType=VARCHAR},
|
|
|
|
228
|
- `length` = #{length,jdbcType=DECIMAL},
|
|
|
|
229
|
- width = #{width,jdbcType=DECIMAL},
|
|
|
|
230
|
- area = #{area,jdbcType=DECIMAL},
|
|
|
|
231
|
- create_by = #{createBy,jdbcType=VARCHAR},
|
|
|
|
232
|
- create_date = #{createDate,jdbcType=TIMESTAMP},
|
|
|
|
233
|
- update_by = #{updateBy,jdbcType=VARCHAR},
|
|
|
|
234
|
- update_date = #{updateDate,jdbcType=TIMESTAMP},
|
|
|
|
235
|
- remarks = #{remarks,jdbcType=VARCHAR},
|
|
|
|
236
|
- del_flag = #{delFlag,jdbcType=CHAR}
|
194
|
+ set yard_id = #{yardId,jdbcType=VARCHAR},
|
|
|
|
195
|
+ cop_code = #{copCode,jdbcType=VARCHAR},
|
|
|
|
196
|
+ `name` = #{name,jdbcType=VARCHAR},
|
|
|
|
197
|
+ warehouse_type = #{warehouseType,jdbcType=VARCHAR},
|
|
|
|
198
|
+ warehouse_length = #{warehouseLength,jdbcType=DECIMAL},
|
|
|
|
199
|
+ warehouse_width = #{warehouseWidth,jdbcType=DECIMAL},
|
|
|
|
200
|
+ warehouse_area = #{warehouseArea,jdbcType=DECIMAL},
|
|
|
|
201
|
+ create_by = #{createBy,jdbcType=VARCHAR},
|
|
|
|
202
|
+ create_date = #{createDate,jdbcType=TIMESTAMP},
|
|
|
|
203
|
+ update_by = #{updateBy,jdbcType=VARCHAR},
|
|
|
|
204
|
+ update_date = #{updateDate,jdbcType=TIMESTAMP},
|
|
|
|
205
|
+ remarks = #{remarks,jdbcType=VARCHAR},
|
|
|
|
206
|
+ del_flag = #{delFlag,jdbcType=CHAR}
|
|
237
|
where id = #{id,jdbcType=VARCHAR}
|
207
|
where id = #{id,jdbcType=VARCHAR}
|
|
238
|
</update>
|
208
|
</update>
|
|
|
|
209
|
+
|
|
|
|
210
|
+ <!-- 该Mapper映射关系的作用,是仓库与场站的1:1的关系映射 -->
|
|
|
|
211
|
+ <resultMap extends="BaseResultMap" id="WarehouseAndYardMap" type="com.sunyo.wlpt.station.manage.domain.Warehouse">
|
|
|
|
212
|
+ <association javaType="com.sunyo.wlpt.station.manage.domain.Yard" property="yard">
|
|
|
|
213
|
+ <id column="id" property="id"/>
|
|
|
|
214
|
+ <result column="yard_name" property="name"/>
|
|
|
|
215
|
+ </association>
|
|
|
|
216
|
+ </resultMap>
|
|
|
|
217
|
+
|
|
|
|
218
|
+ <!-- 分页查询 -->
|
|
|
|
219
|
+ <select id="selectListByPage" parameterType="com.sunyo.wlpt.station.manage.domain.Warehouse" resultMap="WarehouseAndYardMap">
|
|
|
|
220
|
+ select w.id,
|
|
|
|
221
|
+ w.yard_id,
|
|
|
|
222
|
+ w.cop_code,
|
|
|
|
223
|
+ w.name,
|
|
|
|
224
|
+ w.warehouse_type,
|
|
|
|
225
|
+ w.warehouse_length,
|
|
|
|
226
|
+ w.warehouse_width,
|
|
|
|
227
|
+ w.warehouse_area,
|
|
|
|
228
|
+ w.create_by,
|
|
|
|
229
|
+ w.create_date,
|
|
|
|
230
|
+ w.update_by,
|
|
|
|
231
|
+ w.update_date,
|
|
|
|
232
|
+ w.remarks,
|
|
|
|
233
|
+ w.del_flag,
|
|
|
|
234
|
+ y.name as yard_name
|
|
|
|
235
|
+ from warehouse w,
|
|
|
|
236
|
+ yard y
|
|
|
|
237
|
+ <where>
|
|
|
|
238
|
+ <!-- name,仓库名称 -->
|
|
|
|
239
|
+ <if test="name != null and name != ''">
|
|
|
|
240
|
+ and w.name = #{name,jdbcType=VARCHAR}
|
|
|
|
241
|
+ </if>
|
|
|
|
242
|
+ <!-- stationName,货站名称 -->
|
|
|
|
243
|
+ <if test="stationName != null and stationName != ''">
|
|
|
|
244
|
+ and y.name = #{stationName,jdbcType=VARCHAR}
|
|
|
|
245
|
+ </if>
|
|
|
|
246
|
+ and w.yard_id = y.id
|
|
|
|
247
|
+ </where>
|
|
|
|
248
|
+ </select>
|
|
239
|
</mapper> |
249
|
</mapper> |