地址估值加入别墅判断
修改地址校准化链接
This commit is contained in:
+13
-3
@@ -1568,6 +1568,9 @@ public class PropertyController {
|
||||
model.setDistrict(fangjiaOfficialAreaMap.getFangjiaDistrict());
|
||||
}
|
||||
}
|
||||
|
||||
boolean villaFlag = DataUtil.isVilla(model.getSize(), model.getName(), model.getHeight(), model.getRoom());
|
||||
|
||||
District district = null;
|
||||
Map<String, Object> params = new HashMap<String, Object>();
|
||||
params.put("city", model.getCity());
|
||||
@@ -1585,7 +1588,14 @@ public class PropertyController {
|
||||
if(json.getInt("code")==200){
|
||||
Map<String, Object> map = (Map<String, Object>) json.get("result");
|
||||
if((Integer)map.get("precise")>=0){
|
||||
district = districtService.findByNameAndAlias((String) map.get("city"), (String) map.get("district"), (String) map.get("name"), "district");
|
||||
String propertyType = (String) map.get("propertyType");
|
||||
if(villaFlag && StringUtils.isNotBlank(propertyType) && !propertyType.equals("别墅")){
|
||||
district = districtService.findByNameAndAlias((String) map.get("city"), (String) map.get("district"), (String) map.get("name")+"别墅", "district");
|
||||
}
|
||||
if(null == district){
|
||||
district = districtService.findByNameAndAlias((String) map.get("city"), (String) map.get("district"), (String) map.get("name"), "district");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2792,7 +2802,7 @@ public class PropertyController {
|
||||
evaluation.setOtherFactor(model.getOtherFactor());
|
||||
}
|
||||
evaluation.setRegion(model.getDistrict());
|
||||
if (0 != model.getRoom()) {
|
||||
if (null != model.getRoom()) {
|
||||
evaluation.setRoom(model.getRoom());
|
||||
}
|
||||
if (StringUtils.isNotBlank(model.getRoomNumber())) {
|
||||
@@ -5549,7 +5559,7 @@ public class PropertyController {
|
||||
|
||||
//周边相似小区租金
|
||||
Integer room = null;
|
||||
if(model.getRoom()!=0){
|
||||
if(model.getRoom()!=null && model.getRoom()>0){
|
||||
room = model.getRoom();
|
||||
}else{
|
||||
room = houseService.getDistrictRoomType((float)model.getSize());
|
||||
|
||||
+6
-6
@@ -70,12 +70,12 @@ public class PropertyEvaluationModel extends FangjiaApiModel {
|
||||
/**
|
||||
* 总楼层
|
||||
*/
|
||||
private int height;
|
||||
private Integer height;
|
||||
|
||||
/**
|
||||
* 室数
|
||||
*/
|
||||
private int room;
|
||||
private Integer room;
|
||||
|
||||
/**
|
||||
* 厅数
|
||||
@@ -345,19 +345,19 @@ public class PropertyEvaluationModel extends FangjiaApiModel {
|
||||
this.floor = floor;
|
||||
}
|
||||
|
||||
public int getHeight() {
|
||||
public Integer getHeight() {
|
||||
return height;
|
||||
}
|
||||
|
||||
public void setHeight(int height) {
|
||||
public void setHeight(Integer height) {
|
||||
this.height = height;
|
||||
}
|
||||
|
||||
public int getRoom() {
|
||||
public Integer getRoom() {
|
||||
return room;
|
||||
}
|
||||
|
||||
public void setRoom(int room) {
|
||||
public void setRoom(Integer room) {
|
||||
this.room = room;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user