|
|
|
@ -210,7 +210,7 @@ func ExportStudentInfoExcel(targetPath string, bureauId string, ExportExcelStatu
|
|
|
|
|
}
|
|
|
|
|
if ExportExcelStatus > 0 {
|
|
|
|
|
//将现有数据填充到下载的模板中
|
|
|
|
|
var myBuilder = builder.Dialect(builder.MYSQL).Select(`t2.stage_id,t2.rxnf,t2.bh,t1.xm,t1.xbm,t1.csrq,
|
|
|
|
|
var myBuilder = builder.Dialect(builder.MYSQL).Select(`t1.person_id,t2.stage_id,t2.rxnf,t2.bh,t1.xm,t1.xbm,t1.csrq,
|
|
|
|
|
(case t1.sfzjh when '-1' then '' else t1.sfzjh end ) as sfzjh,
|
|
|
|
|
t1.mzm,t1.zzmmm,t1.sfzjlxm,t1.dszybz,t1.sqznbz,t1.jcwgrysqznbz,
|
|
|
|
|
t1.gebz,t1.lsetbz,t1.cjbz`).
|
|
|
|
@ -265,6 +265,10 @@ func ExportStudentInfoExcel(targetPath string, bureauId string, ExportExcelStatu
|
|
|
|
|
cName = cName + strconv.Itoa(i+2+ExcelUtil.HiddenRows)
|
|
|
|
|
_ = f.SetCellValue(SheetName, cName, list[i][colNames[j]])
|
|
|
|
|
}
|
|
|
|
|
//单独填充上person_id,为了能在没有身份号的唯一标识的情况下,确定是新增还是修改
|
|
|
|
|
cName := "Q"
|
|
|
|
|
cName = cName + strconv.Itoa(i+2+ExcelUtil.HiddenRows)
|
|
|
|
|
f.SetCellValue(SheetName, cName, list[i]["person_id"])
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
// 6、根据指定路径保存文件
|
|
|
|
@ -625,6 +629,8 @@ func readToTable(excelPath string, s1 ExcelUtil.TemplateStruct, MapClass map[str
|
|
|
|
|
m.Cjbz = int32(CommonUtil.ConvertStringToInt(SysDictKit.MapTrueOrFalseNameToValue[row[15]]))
|
|
|
|
|
//批次号
|
|
|
|
|
m.BatchId = batchId
|
|
|
|
|
//人员ID
|
|
|
|
|
m.PersonId = row[16]
|
|
|
|
|
//第几行的数据
|
|
|
|
|
m.RowNumber = int32(i + 1)
|
|
|
|
|
//添加到数组中
|
|
|
|
|