浏览代码

Merge branch 'ETA_1.4.4' into debug

zwxi 1 年之前
父节点
当前提交
4eb19cd06f
共有 1 个文件被更改,包括 13 次插入2 次删除
  1. 13 2
      controllers/data_manage/edb_info.go

+ 13 - 2
controllers/data_manage/edb_info.go

@@ -5605,7 +5605,17 @@ func (this *EdbInfoController) EdbInfoSmmSearch() {
 			}
 		} else {
 			// 有勾选,不查询
-			edbCodeArr = strings.Split(selectCode, ",")
+			codeArr = strings.Split(selectCode, ",")
+
+			noUseCodeArr := strings.Split(edbCode, ",")
+
+			for _, code := range codeArr {
+				// 检查code是否在noUseCodeArr数组中
+				if !utils.ArrContainsStr(noUseCodeArr, code) {
+					// 如果不在,将其添加到结果数组中
+					edbCodeArr = append(edbCodeArr, code)
+				}
+			}
 		}
 	} else {
 		//未勾选全选EdbCode就是需要的code
@@ -5646,8 +5656,9 @@ func (this *EdbInfoController) EdbInfoSmmSearch() {
 
 	edbCodeStr := ""
 	for i, _ := range edbCodeArr {
-		edbCodeStr += "'"+edbCodeArr[i]+"'"
+		edbCodeStr += "'"+edbCodeArr[i]+"'" + ","
 	}
+	edbCodeStr = strings.Trim(edbCodeStr, ",")
 	smmInfoList, err := data_manage.GetBaseFromSmmIndexByIndexCodes(edbCodeStr)
 	if err != nil && err.Error() != utils.ErrNoRow() {
 		br.Msg = "获取失败"