master
huanghai 5 years ago
parent 05e5094c68
commit 9480ac97b9

@ -552,8 +552,12 @@ func checkTempTable(excelPath string, s1 ExcelUtil.TemplateStruct, batchId strin
var success = true
/****************************************************************************/
//是否存在本次导入的身份证号与其它单位的已有身份证号相同,这样的不让导入,用蓝色标识出来
sql := `select t1.sfzjh,t2.row_number from t_base_teacher as t1 inner join t_base_teacher_import_excel as t2
on t1.sfzjh=t2.sfzjh where t2.batch_id=? and t1.bureau_id<>?`
sql := `select t1.sfzjh,t2.row_number from t_base_teacher as t1
inner join t_base_teacher_import_excel as t2
on t1.sfzjh=t2.sfzjh
inner join t_base_teacher_org as t3
on t1.person_id=t3.person_id and t3.b_use=1 and t3.is_main=1
where t2.batch_id=? and t3.bureau_id<>?`
listIdCardTeacher, err := db.SQL(sql, batchId, bureauId).Query().List()
if err != nil {
LogUtil.Error(Const.DataBaseActionError, "在查询教师的身份证号重复时发生严重错误!")

Loading…
Cancel
Save