+4
@@ -1033,8 +1033,12 @@ class BigdataCitypriceBatch extends BaseBatch{
|
|||||||
if(regionPriceMap){
|
if(regionPriceMap){
|
||||||
for(def m : datas){
|
for(def m : datas){
|
||||||
def regionAvgPrice = regionPriceMap.get(m.region)
|
def regionAvgPrice = regionPriceMap.get(m.region)
|
||||||
|
if(regionAvgPrice){
|
||||||
def val = (m.avg_price-regionAvgPrice)*100/regionAvgPrice
|
def val = (m.avg_price-regionAvgPrice)*100/regionAvgPrice
|
||||||
distRegionRateMap.put(m.comm_id, DataHandleUtils.getDoubleRound(4, val))
|
distRegionRateMap.put(m.comm_id, DataHandleUtils.getDoubleRound(4, val))
|
||||||
|
}else{
|
||||||
|
println m.region+" 无区域均价"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return distRegionRateMap;
|
return distRegionRateMap;
|
||||||
|
|||||||
Reference in New Issue
Block a user