|
@@ -132,6 +132,27 @@ public class TaBuildingServiceImpl extends ServiceImpl<TaBuildingMapper, TaBuild
|
132
|
132
|
|
133
|
133
|
List<TaBuildingImg> buildingListImg = taBuildingImgMapper.selectList(queryListWrapper);
|
134
|
134
|
taBuilding.setBuildingListImg(buildingListImg);
|
|
135
|
+
|
|
136
|
+ //获取项目类型里的价格
|
|
137
|
+ QueryWrapper<TaBuildingProjectType> projectTypeQueryWrapper = new QueryWrapper<>();
|
|
138
|
+ projectTypeQueryWrapper.eq("building_id",taBuilding.getBuildingId());
|
|
139
|
+ projectTypeQueryWrapper.eq("building_type_id",taBuilding.getBuildingTypeId());
|
|
140
|
+ TaBuildingProjectType taBuildingProjectType = taBuildingProjectTypeMapper.selectOne(projectTypeQueryWrapper);
|
|
141
|
+ //价格相同显示一个否则显示区间
|
|
142
|
+ if (null != taBuildingProjectType){
|
|
143
|
+ Integer startPrice = taBuildingProjectType.getStartPrice();
|
|
144
|
+ Integer endPrice = taBuildingProjectType.getEndPrice();
|
|
145
|
+ if (null != startPrice || null != endPrice){
|
|
146
|
+ if (startPrice == endPrice){
|
|
147
|
+ taBuilding.setPrice(String.valueOf(startPrice));
|
|
148
|
+ }else {
|
|
149
|
+ taBuilding.setPrice(startPrice + "--" + endPrice);
|
|
150
|
+ }
|
|
151
|
+ }
|
|
152
|
+ taBuilding.setPriceType(taBuildingProjectType.getPriceType());
|
|
153
|
+ }else {
|
|
154
|
+ taBuilding.setPrice(null);
|
|
155
|
+ }
|
135
|
156
|
}
|
136
|
157
|
}
|
137
|
158
|
|