Merge remote-tracking branch 'origin/master'
This commit is contained in:
+7
-2
@@ -202,13 +202,18 @@ class DistrictSellStatBatch extends BaseBatch {
|
|||||||
if(curPrice!=curPriceObj.avg_price){
|
if(curPrice!=curPriceObj.avg_price){
|
||||||
def data = new BasicDBObject()
|
def data = new BasicDBObject()
|
||||||
data.put("m_date", new Date())
|
data.put("m_date", new Date())
|
||||||
data.put("commid", dist._id.toString())
|
// data.put("commid", dist._id.toString())
|
||||||
data.put("mom", mom)
|
data.put("mom", mom)
|
||||||
data.put("yoy", yoy)
|
data.put("yoy", yoy)
|
||||||
data.put("avg_price",curPrice)
|
data.put("avg_price",curPrice)
|
||||||
data.put("value_type", weekendPriceObj.value_type)
|
data.put("value_type", weekendPriceObj.value_type)
|
||||||
data.put("credit", weekendPriceObj.credit)
|
data.put("credit", weekendPriceObj.credit)
|
||||||
DISTRICT_SELL_STAT.update(new BasicDBObject("_id", curPriceObj._id) , new BasicDBObject('$set', data),true,false)
|
|
||||||
|
def q = new BasicDBObject()
|
||||||
|
q.put("date", curMonth)
|
||||||
|
q.put("commid", dist._id.toString())
|
||||||
|
DISTRICT_SELL_STAT.update(q , new BasicDBObject('$set', data),true,false)
|
||||||
|
// DISTRICT_SELL_STAT.update(new BasicDBObject("_id", curPriceObj._id) , new BasicDBObject('$set', data),true,false)
|
||||||
println "[update]"+totalCount.get()+" "+ dist.city+" "+dist.name
|
println "[update]"+totalCount.get()+" "+ dist.city+" "+dist.name
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
|
|||||||
+8
-6
@@ -36,7 +36,7 @@ class RelatedTaiWanBatch extends BaseBatch{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void process(Object args) {
|
public void process(Object args) {
|
||||||
createDatas() //企业库获取涉台园区企业
|
// createDatas() //企业库获取涉台园区企业
|
||||||
updateRangeByPoint() //更改企业所在自贸区
|
updateRangeByPoint() //更改企业所在自贸区
|
||||||
export() //导出数据
|
export() //导出数据
|
||||||
}
|
}
|
||||||
@@ -57,12 +57,14 @@ class RelatedTaiWanBatch extends BaseBatch{
|
|||||||
println dbcursor.count()
|
println dbcursor.count()
|
||||||
for(def r : dbcursor){
|
for(def r : dbcursor){
|
||||||
def resKey = null
|
def resKey = null
|
||||||
for(def m : zimaoqu_range_datas){
|
if(r.lon && r.lat){
|
||||||
|
for(def m : zimaoqu_range_datas){
|
||||||
// def flag = InsidePolygon.isInArea(r.lon, r.lat, InsidePolygon.createPoint5(m.shape))
|
// def flag = InsidePolygon.isInArea(r.lon, r.lat, InsidePolygon.createPoint5(m.shape))
|
||||||
def flag = InsidePolygon.isPtInPoly(r.lon, r.lat, InsidePolygon.createPoint5(m.shape))
|
def flag = InsidePolygon.isPtInPoly(r.lon, r.lat, InsidePolygon.createPoint5(m.shape))
|
||||||
if(flag){
|
if(flag){
|
||||||
resKey = m.name
|
resKey = m.name
|
||||||
break
|
break
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(resKey){
|
if(resKey){
|
||||||
|
|||||||
Reference in New Issue
Block a user