From cf90b32f42454aa153e6bc63b31cfe54b0d7fff9 Mon Sep 17 00:00:00 2001 From: huanghai <10402852@qq.com> Date: Wed, 30 Sep 2020 15:58:25 +0800 Subject: [PATCH] 'commit' --- .../BaseStudent/BaseStudentDao/BaseStudentDao.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/dsBaseRpc/RpcService/BaseStudent/BaseStudentDao/BaseStudentDao.go b/dsBaseRpc/RpcService/BaseStudent/BaseStudentDao/BaseStudentDao.go index 00bd4b18..5ee2824a 100644 --- a/dsBaseRpc/RpcService/BaseStudent/BaseStudentDao/BaseStudentDao.go +++ b/dsBaseRpc/RpcService/BaseStudent/BaseStudentDao/BaseStudentDao.go @@ -26,6 +26,7 @@ import ( "github.com/xormplus/builder" "regexp" "strconv" + "strings" "time" ) @@ -193,7 +194,7 @@ func ExportStudentInfoExcel(targetPath string, bureauId string, ExportExcelStatu for k := 2 + ExcelUtil.HiddenRows; k <= 5000+ExcelUtil.HiddenRows; k++ { //设置单元格格式 - cName:="B"+CommonUtil.ConvertIntToString(k) + cName := "B" + CommonUtil.ConvertIntToString(k) f.SetCellStyle(SheetName, cName, cName, tableStyleIntStyle) //入学年份 @@ -204,7 +205,7 @@ func ExportStudentInfoExcel(targetPath string, bureauId string, ExportExcelStatu _ = f.AddDataValidation(SheetName, dvRange) //设置单元格格式 - cName="C"+CommonUtil.ConvertIntToString(k) + cName = "C" + CommonUtil.ConvertIntToString(k) f.SetCellStyle(SheetName, cName, cName, tableStyleIntStyle) //班号 @@ -525,36 +526,42 @@ func checkExcel(excelPath string, s1 ExcelUtil.TemplateStruct, MapClass map[stri } //(10)独生子女 if j == 10 { + row[j] = strings.Replace(row[j], " ", "", -1) if _, ok := SysDictKit.MapTrueOrFalseNameToValue[row[j]]; !ok { pass = false } } //(11)随迁子女 if j == 11 { + row[j] = strings.Replace(row[j], " ", "", -1) if _, ok := SysDictKit.MapTrueOrFalseNameToValue[row[j]]; !ok { pass = false } } //(12)务工子女 if j == 12 { + row[j] = strings.Replace(row[j], " ", "", -1) if _, ok := SysDictKit.MapTrueOrFalseNameToValue[row[j]]; !ok { pass = false } } //(13)孤儿 if j == 13 { + row[j] = strings.Replace(row[j], " ", "", -1) if _, ok := SysDictKit.MapTrueOrFalseNameToValue[row[j]]; !ok { pass = false } } //(14)留守儿童 if j == 14 { + row[j] = strings.Replace(row[j], " ", "", -1) if _, ok := SysDictKit.MapTrueOrFalseNameToValue[row[j]]; !ok { pass = false } } //(15)残疾儿童 if j == 15 { + row[j] = strings.Replace(row[j], " ", "", -1) if _, ok := SysDictKit.MapTrueOrFalseNameToValue[row[j]]; !ok { pass = false }