设置指导价修改时间
This commit is contained in:
+3
-8
@@ -69,7 +69,7 @@ class DistrictHouseBatch extends BaseBatch {
|
||||
for(DBObject district : districts) {
|
||||
def names = []
|
||||
names << district.name
|
||||
if(district.alias && districts.size()>0){
|
||||
if(district.alias && district.alias.size()>0){
|
||||
for(def name : district.alias){
|
||||
if(!names.contains(name)){
|
||||
names << name
|
||||
@@ -81,14 +81,9 @@ class DistrictHouseBatch extends BaseBatch {
|
||||
long rentCount = 0
|
||||
for(def name : names){
|
||||
String key = name.toString().trim() + "_" + district.get("region") + "_" + district.get("city")
|
||||
if(!sellCount){
|
||||
sellCount = sellCountMap.get(key) ? sellCountMap.get(key) : 0
|
||||
}
|
||||
if(!rentCount){
|
||||
rentCount = rentCountMap.get(key) ? rentCountMap.get(key) : 0
|
||||
}
|
||||
sellCount = sellCount + (sellCountMap.get(key) ? sellCountMap.get(key) : 0)
|
||||
rentCount = rentCount + (rentCountMap.get(key) ? rentCountMap.get(key) : 0)
|
||||
}
|
||||
|
||||
saveToDistrictHouse(district.get('city'), district.get("region"), district.get("name"), sellCount, rentCount, sn)
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,11 @@ import com.fangjia.datastore.driver.DataStore
|
||||
import com.fangjia.script.util.DbUtils
|
||||
import com.mongodb.BasicDBObject
|
||||
|
||||
DSCollection seabird = new DataStore("192.168.0.38", 27007).getCollection("fangjia.seaweed")
|
||||
seabird.find(DbUtils.buildSeaweedQuery("³£ÖÝ", "äàÑô", "ÎáÔù㳡").append("if_sell", 1)).each {
|
||||
println(it)
|
||||
//、DSCollection seabird = new DataStore("192.168.0.38", 27007).getCollection("fangjia.seaweed")
|
||||
//seabird.find(DbUtils.buildSeaweedQuery("常州", "溧阳", "吾悦广场").append("if_sell", 1)).each {
|
||||
// println(it)
|
||||
//}
|
||||
long l = 0
|
||||
if(!l){
|
||||
println(l)
|
||||
}
|
||||
Reference in New Issue
Block a user