ProcurementWeighingTicketApplyLineMapper.xml
2.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.lframework.xingyun.sc.procurement.mappers.weighing.ProcurementWeighingTicketApplyLineMapper">
<resultMap id="ProcurementWeighingTicketApplyLineResult" type="com.lframework.xingyun.sc.procurement.entity.weighing.ProcurementWeighingTicketApplyLine">
<id column="id" property="id"/>
<result column="weighing_ticket_id" property="weighingTicketId"/>
<result column="category" property="category"/>
<result column="breed_relationship_id" property="breedRelationshipId"/>
<result column="quantity" property="quantity"/>
<result column="order_no" property="orderNo"/>
<result column="item_id" property="itemId"/>
<result column="create_by_id" property="createById"/>
<result column="create_by" property="createBy"/>
<result column="update_by_id" property="updateById"/>
<result column="update_by" property="updateBy"/>
<result column="create_time" property="createTime"/>
<result column="update_time" property="updateTime"/>
</resultMap>
<sql id="PWTA_sql">
SELECT
pwta.id,
pwta.weighing_ticket_id,
pwta.category,
pwta.breed_relationship_id,
pwta.quantity,
pwta.order_no,
pwta.item_id,
pwta.create_by_id,
pwta.create_by,
pwta.update_by_id,
pwta.update_by,
pwta.create_time,
pwta.update_time
FROM procurement_weighing_ticket_apply_line AS pwta
</sql>
<select id="getByWeighingTicketId" resultMap="ProcurementWeighingTicketApplyLineResult">
<include refid="PWTA_sql"/>
WHERE pwta.weighing_ticket_id = #{weighingTicketId}
ORDER BY pwta.order_no ASC
</select>
<delete id="deleteByWeighingTicketId">
DELETE FROM procurement_weighing_ticket_apply_line WHERE weighing_ticket_id = #{weighingTicketId}
</delete>
</mapper>