Roc 1 year ago
parent
commit
f540c16d49
2 changed files with 3 additions and 2 deletions
  1. 2 2
      models/data_manage/excel/excel_edb_mapping.go
  2. 1 0
      services/data/excel/excel_op.go

+ 2 - 2
models/data_manage/excel/excel_edb_mapping.go

@@ -88,10 +88,10 @@ func GetNoCustomAnalysisExcelEdbMappingCount(edbInfoId int) (count int, err erro
 	return
 }
 
-// GetAllExcelEdbMappingByExcelInfoId 根据品种id获取所有的指标
+// GetAllExcelEdbMappingByExcelInfoId 根据excel的id获取所有的指标
 func GetAllExcelEdbMappingByExcelInfoId(excelInfoId int) (items []*ExcelEdbMapping, err error) {
 	o := orm.NewOrmUsingDB("data")
-	sql := `SELECT b.* FROM  excel_edb_mapping a
+	sql := `SELECT a.* FROM  excel_edb_mapping a
          WHERE a.excel_info_id = ? ORDER BY a.excel_edb_mapping_id ASC `
 	_, err = o.Raw(sql, excelInfoId).QueryRows(&items)
 	return

+ 1 - 0
services/data/excel/excel_op.go

@@ -231,6 +231,7 @@ func UpdateExcelInfoFileUrl(excelInfo *excelModel.ExcelInfo) {
 	defer func() {
 		if err != nil {
 			go alarm_msg.SendAlarmMsg(fmt.Sprintf("更新excel表格的下载地址失败,表格id:%d;表格名称:%s; ERR:%s", excelInfo.ExcelInfoId, excelInfo.ExcelName, err), 3)
+			utils.FileLog.Info(fmt.Sprintf("更新excel表格的下载地址失败,表格id:%d;表格名称:%s; ERR:%s", excelInfo.ExcelInfoId, excelInfo.ExcelName, err), 3)
 		}
 	}()
 	fileName := excelInfo.ExcelName + "_" + excelInfo.UniqueCode + ".xlsx"