Merge branch 'script_gj' into 'master'
Script gj See merge request !1220
This commit is contained in:
@@ -17,10 +17,8 @@
|
|||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
<version>2.3.2</version>
|
<version>2.3.2</version>
|
||||||
<configuration>
|
<configuration>
|
||||||
<source>1.6</source>
|
<source>1.8</source>
|
||||||
<target>1.6</target>
|
<target>1.8</target>
|
||||||
<!-- <source>1.8</source>-->
|
|
||||||
<!-- <target>1.8</target>-->
|
|
||||||
<encoding>GBK</encoding>
|
<encoding>GBK</encoding>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
|||||||
+27
-27
@@ -24,33 +24,33 @@ class XiaMenVillageBatch extends BaseBatch{
|
|||||||
def outFileName = "xmbank_"+monthStr+"_result.xlsx"
|
def outFileName = "xmbank_"+monthStr+"_result.xlsx"
|
||||||
def inFileName = "xmbank_"+monthStr+".xlsx"
|
def inFileName = "xmbank_"+monthStr+".xlsx"
|
||||||
println "输入文件:"+inFileName+" 输出文件:"+outFileName
|
println "输入文件:"+inFileName+" 输出文件:"+outFileName
|
||||||
def exists = checkFileExists(outFileName)
|
// def exists = checkFileExists(outFileName)
|
||||||
if(!exists){
|
// if(!exists){
|
||||||
def rows = []
|
// def rows = []
|
||||||
rows << ["序号","地址","判定后涉农组织类型(城市企业[不含县城企业]、农村企业、县城企业)","所属工业园区或经济开发区"]
|
// rows << ["序号","地址","判定后涉农组织类型(城市企业[不含县城企业]、农村企业、县城企业)","所属工业园区或经济开发区"]
|
||||||
def rets = XmBankVillageFtpUtils.readExcelFile(inFileName)
|
// def rets = XmBankVillageFtpUtils.readExcelFile(inFileName)
|
||||||
if(rets){
|
// if(rets){
|
||||||
for(def row : rets){
|
// for(def row : rets){
|
||||||
if(row[1]){
|
// if(row[1]){
|
||||||
def dto = OpenApiUtils.addrVerifyXiameng(null, row[1], 2)
|
// def dto = OpenApiUtils.addrVerifyXiameng(null, row[1], 2)
|
||||||
if(dto){
|
// if(dto){
|
||||||
row[2] = dto.addrArea //所属区域 农村区域 城市区域 县城城区(对公)
|
// row[2] = dto.addrArea //所属区域 农村区域 城市区域 县城城区(对公)
|
||||||
if(dto.devDistrictName){
|
// if(dto.devDistrictName){
|
||||||
row[3] = dto.devDistrictName//开发区
|
// row[3] = dto.devDistrictName//开发区
|
||||||
}else{
|
// }else{
|
||||||
row[3] = ""
|
// row[3] = ""
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
rows << row
|
// rows << row
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
uploadExcel(rows, outFileName)
|
// uploadExcel(rows, outFileName)
|
||||||
println "新增文件,上传已完成"
|
// println "新增文件,上传已完成"
|
||||||
}else{
|
// }else{
|
||||||
println "已存在 "+ DateUtil.formatByPattern(new Date(), "yyyy-MM-dd HH:mm:ss")
|
// println "已存在 "+ DateUtil.formatByPattern(new Date(), "yyyy-MM-dd HH:mm:ss")
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user