Merge remote-tracking branch 'origin/master'
This commit is contained in:
+10
-8
@@ -33,8 +33,8 @@ class MinglujiData {
|
|||||||
def prov = "浙江省"
|
def prov = "浙江省"
|
||||||
def city = "嘉兴"
|
def city = "嘉兴"
|
||||||
// exportDatas(city)
|
// exportDatas(city)
|
||||||
// matchDev(prov, city)
|
matchDev(prov, city)
|
||||||
// matchCommunity(city)
|
matchCommunity(city)
|
||||||
|
|
||||||
// tempMatchDev(prov)
|
// tempMatchDev(prov)
|
||||||
// saveMljData()
|
// saveMljData()
|
||||||
@@ -204,20 +204,22 @@ class MinglujiData {
|
|||||||
|
|
||||||
|
|
||||||
def fiveLevelSplit(city){
|
def fiveLevelSplit(city){
|
||||||
def i = 2;
|
def i = 1;
|
||||||
while(i<20) {
|
while(i<20) {
|
||||||
def fileName = "/home/goojia/gj/mlj_${i}.xlsx"
|
def fileName = "/home/goojia/gj/mlj_${i}.xlsx"
|
||||||
if (CommonDatautils.isWindow()) {
|
if (CommonDatautils.isWindow()) {
|
||||||
fileName = "D:\\数据\\数据建设\\名录集\\${city}_${i}.xlsx"
|
fileName = "D:\\数据\\数据建设\\名录集\\mlj_${i}.xlsx"
|
||||||
}
|
}
|
||||||
|
|
||||||
File file = new File(fileName);
|
File file = new File(fileName);
|
||||||
if (file.exists()) {
|
if (file.exists()) {
|
||||||
ExcelUtils.multiThreadingModify(fileName, { d ->
|
ExcelUtils.multiThreadingModify(fileName, { d ->
|
||||||
def jsonObject = com.fangjia.script.gj.district.FangjiaClientUtils.formatFivelevel(d['B'], d['J'])
|
if(d['J'] && !d['X']){
|
||||||
if(jsonObject) {
|
def jsonObject = com.fangjia.script.gj.district.FangjiaClientUtils.formatFivelevel(d['B'], d['J'])
|
||||||
if (jsonObject.get("address") && jsonObject.get("address") != "null") {
|
if(jsonObject) {
|
||||||
d['X'] = jsonObject.get("address")
|
if (jsonObject.get("address") && jsonObject.get("address") != "null") {
|
||||||
|
d['X'] = jsonObject.get("address")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
+3
-2
@@ -335,7 +335,7 @@ class FangjiaClientUtils {
|
|||||||
try {
|
try {
|
||||||
address = address.replace("{","")
|
address = address.replace("{","")
|
||||||
// def url = "http://192.168.0.19:31080/FangJiaNlpService/formatFivelevel?address="+URLEncoder.encode(address,"UTF-8")
|
// def url = "http://192.168.0.19:31080/FangJiaNlpService/formatFivelevel?address="+URLEncoder.encode(address,"UTF-8")
|
||||||
def url = "http://192.168.0.100:32080/FangJiaNlpService/formatFivelevel?address="+URLEncoder.encode(address,"UTF-8")
|
def url = "http://192.168.0.93:8080/FangJiaNlpService/formatFivelevel?address="+URLEncoder.encode(address,"UTF-8")
|
||||||
if(city){
|
if(city){
|
||||||
url = url +"&city="+URLEncoder.encode(city,"UTF-8")
|
url = url +"&city="+URLEncoder.encode(city,"UTF-8")
|
||||||
}
|
}
|
||||||
@@ -352,9 +352,10 @@ class FangjiaClientUtils {
|
|||||||
public static def formatNinelevel(city, address){
|
public static def formatNinelevel(city, address){
|
||||||
def jsonObj = null
|
def jsonObj = null
|
||||||
def content = null
|
def content = null
|
||||||
|
def url = null
|
||||||
try {
|
try {
|
||||||
address = address.replace("{","")
|
address = address.replace("{","")
|
||||||
def url = "http://192.168.0.93:8080/FangJiaNlpService/formatNinelevel?address="+URLEncoder.encode(address,"UTF-8")+"&complete=false&useMap=false&addressAssessment=true&fields=dev_confi"
|
url = "http://192.168.0.93:8080/FangJiaNlpService/formatNinelevel?address="+URLEncoder.encode(address,"UTF-8")+"&complete=false&useMap=false&addressAssessment=true&fields=dev_confi"
|
||||||
if(city){
|
if(city){
|
||||||
url = url +"&city="+URLEncoder.encode(city,"UTF-8")
|
url = url +"&city="+URLEncoder.encode(city,"UTF-8")
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user