瀏覽代碼

Merge branch 'ETA_2.0.5'

zwxi 7 月之前
父節點
當前提交
1a73a61104
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      controllers/hisugar_data.go

+ 6 - 0
controllers/hisugar_data.go

@@ -899,6 +899,7 @@ func (this *TradeCommonController) HisugarIndexData() {
 		return
 	}
 	frequency := this.GetString("Frequency")
+	indexCode := this.GetString("IndexCode")
 
 	// 获取指标
 	var condition string
@@ -920,6 +921,11 @@ func (this *TradeCommonController) HisugarIndexData() {
 		pars = append(pars, frequency)
 	}
 
+	if indexCode != "" {
+		condition += ` AND index_code=? `
+		pars = append(pars, indexCode)
+	}
+
 	indexes, err := data_manage.GetHisugarIndex(condition, pars)
 	if err != nil {
 		br.Msg = "获取数据失败"