|
@@ -17,6 +17,7 @@
|
17
|
17
|
t.room_name,
|
18
|
18
|
t.price,
|
19
|
19
|
t.heat,
|
|
20
|
+ t.real_heat,
|
20
|
21
|
t.apartment_id,
|
21
|
22
|
t.`status`,
|
22
|
23
|
t.org_id,
|
|
@@ -56,48 +57,49 @@
|
56
|
57
|
|
57
|
58
|
<update id="updateForAddHeat" parameterType="java.lang.String">
|
58
|
59
|
UPDATE ta_housing_resources t
|
59
|
|
- SET t.heat = t.heat + 1
|
|
60
|
+ SET t.real_heat = t.real_heat + 1
|
60
|
61
|
WHERE
|
61
|
62
|
t.house_id = #{houseId}
|
62
|
|
- AND t.heat >= 0
|
|
63
|
+ AND t.real_heat >= 0
|
63
|
64
|
</update>
|
64
|
65
|
|
65
|
66
|
<update id="updateForSubtractHeat" parameterType="java.lang.String">
|
66
|
67
|
UPDATE ta_housing_resources t
|
67
|
|
- SET t.heat = t.heat - 1
|
|
68
|
+ SET t.real_heat = t.real_heat - 1
|
68
|
69
|
WHERE
|
69
|
70
|
t.house_id = #{houseId}
|
70
|
|
- AND t.heat > 0
|
|
71
|
+ AND t.real_heat > 0
|
71
|
72
|
</update>
|
72
|
73
|
|
73
|
74
|
<select id="getHousingDetailById" resultType="com.huiju.estateagents.po.TaHousingResourcesPO">
|
74
|
75
|
SELECT
|
75
|
|
- t.house_id,
|
76
|
|
- t.building_id,
|
77
|
|
- t.block_id,
|
78
|
|
- t.block_name,
|
79
|
|
- t.sales_batch_id,
|
80
|
|
- t.unit_id,
|
81
|
|
- t.unit_name,
|
82
|
|
- t.floor_id,
|
83
|
|
- t.floor_name,
|
84
|
|
- t.room_id,
|
85
|
|
- t.room_name,
|
86
|
|
- t.price,
|
87
|
|
- t.heat,
|
88
|
|
- t.apartment_id,
|
89
|
|
- t.`status`,
|
90
|
|
- t.org_id,
|
91
|
|
- t2.apartment_name,
|
92
|
|
- t2.inside_area,
|
93
|
|
- t2.building_area,
|
94
|
|
- t3.preselection_start_time,
|
95
|
|
- t3.preselection_end_time,
|
96
|
|
- t3.`status` saleBatchStatus
|
|
76
|
+ t.house_id,
|
|
77
|
+ t.building_id,
|
|
78
|
+ t.block_id,
|
|
79
|
+ t.block_name,
|
|
80
|
+ t.sales_batch_id,
|
|
81
|
+ t.unit_id,
|
|
82
|
+ t.unit_name,
|
|
83
|
+ t.floor_id,
|
|
84
|
+ t.floor_name,
|
|
85
|
+ t.room_id,
|
|
86
|
+ t.room_name,
|
|
87
|
+ t.price,
|
|
88
|
+ t.heat,
|
|
89
|
+ t.real_heat,
|
|
90
|
+ t.apartment_id,
|
|
91
|
+ t.`status`,
|
|
92
|
+ t.org_id,
|
|
93
|
+ t2.apartment_name,
|
|
94
|
+ t2.inside_area,
|
|
95
|
+ t2.building_area,
|
|
96
|
+ t3.preselection_start_time,
|
|
97
|
+ t3.preselection_end_time,
|
|
98
|
+ t3.`status` saleBatchStatus
|
97
|
99
|
FROM
|
98
|
|
- ta_housing_resources t,
|
99
|
|
- ta_building_apartment t2,
|
100
|
|
- ta_sales_batch t3
|
|
100
|
+ ta_housing_resources t,
|
|
101
|
+ ta_building_apartment t2,
|
|
102
|
+ ta_sales_batch t3
|
101
|
103
|
WHERE
|
102
|
104
|
t.house_id = #{houseId}
|
103
|
105
|
AND t.apartment_id = t2.apartment_id
|