|
@@ -18,6 +18,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
18
|
18
|
<result property="amount" column="amount" />
|
19
|
19
|
<result property="content" column="content" />
|
20
|
20
|
<result property="remark" column="remark" />
|
|
21
|
+ <result property="projectRegistrant" column="project_registrant" />
|
|
22
|
+ <result property="registerTime" column="register_time" />
|
21
|
23
|
<association property="partner" javaType="CmcPartner" resultMap="CmcPartnerResult" />
|
22
|
24
|
<association property="partyA" javaType="CmcPartyA" resultMap="CmcPartyAResult" />
|
23
|
25
|
</resultMap>
|
|
@@ -33,7 +35,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
33
|
35
|
</resultMap>
|
34
|
36
|
|
35
|
37
|
<sql id="selectCmcBrandProjectVo">
|
36
|
|
- select bp.project_id, bp.project_number, bp.project_name, bp.party_a_id, pa.party_a_name, bp.a_person, bp.a_phone, bp.partner_id, p.partner_name, bp.contact_person, bp.telephone, bp.duration, bp.amount, bp.content, bp.remark from cmc_brand_project as bp
|
|
38
|
+ select bp.project_id, bp.project_number, bp.project_name, bp.party_a_id, pa.party_a_name, bp.a_person, bp.a_phone, bp.partner_id, p.partner_name, bp.contact_person, bp.telephone,
|
|
39
|
+ bp.duration, bp.amount, bp.content, bp.remark, bp.register_time, bp.project_registrant from cmc_brand_project as bp
|
37
|
40
|
left join cmc_partner as p on p.partner_id = bp.partner_id
|
38
|
41
|
left join cmc_party_a as pa on pa.party_a_id = bp.party_a_id
|
39
|
42
|
</sql>
|
|
@@ -52,6 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
52
|
55
|
<if test="duration != null and duration != ''"> and bp.duration = #{duration}</if>
|
53
|
56
|
<if test="amount != null "> and bp.amount = #{amount}</if>
|
54
|
57
|
</where>
|
|
58
|
+ order by project_number desc
|
55
|
59
|
</select>
|
56
|
60
|
|
57
|
61
|
<select id="selectCmcBrandProjectByProjectId" parameterType="String" resultMap="CmcBrandProjectResult">
|
|
@@ -75,6 +79,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
75
|
79
|
<if test="amount != null">amount,</if>
|
76
|
80
|
<if test="content != null">content,</if>
|
77
|
81
|
<if test="remark != null">remark,</if>
|
|
82
|
+ <if test="projectRegistrant != null">project_registrant,</if>
|
|
83
|
+ <if test="registerTime != null">register_time,</if>
|
78
|
84
|
</trim>
|
79
|
85
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
80
|
86
|
<if test="projectId != null">#{projectId},</if>
|
|
@@ -90,6 +96,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
90
|
96
|
<if test="amount != null">#{amount},</if>
|
91
|
97
|
<if test="content != null">#{content},</if>
|
92
|
98
|
<if test="remark != null">#{remark},</if>
|
|
99
|
+ <if test="projectRegistrant != null">#{projectRegistrant},</if>
|
|
100
|
+ <if test="registerTime != null">#{registerTime},</if>
|
93
|
101
|
</trim>
|
94
|
102
|
</insert>
|
95
|
103
|
|
|
@@ -108,6 +116,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
108
|
116
|
<if test="amount != null">amount = #{amount},</if>
|
109
|
117
|
<if test="content != null">content = #{content},</if>
|
110
|
118
|
<if test="remark != null">remark = #{remark},</if>
|
|
119
|
+ <if test="projectRegistrant != null">project_registrant = #{projectRegistrant},</if>
|
|
120
|
+ <if test="registerTime != null">register_time = #{registerTime},</if>
|
111
|
121
|
</trim>
|
112
|
122
|
where project_id = #{projectId}
|
113
|
123
|
</update>
|