Browse Source

fix:钢联可以不用单位和频度

Roc 7 months ago
parent
commit
3fad711482
2 changed files with 2 additions and 4 deletions
  1. 2 2
      services/init_base_index.go
  2. 0 2
      services/init_mysteel_index.go

+ 2 - 2
services/init_base_index.go

@@ -1111,10 +1111,10 @@ func InitDataToEdbInfo(filePath string) {
 				if indexName == "" {
 					tmpErrMsgList = append(tmpErrMsgList, `指标名称不允许为空`)
 				}
-				if frequency == "" {
+				if frequency == "" && source != `钢联` {
 					tmpErrMsgList = append(tmpErrMsgList, `频度不允许为空`)
 				}
-				if unit == "" {
+				if unit == "" && source != `钢联` {
 					tmpErrMsgList = append(tmpErrMsgList, `单位不允许为空`)
 				}
 				if source == "" {

+ 0 - 2
services/init_mysteel_index.go

@@ -81,8 +81,6 @@ func InitMysteelChemicalIndex(filePath string) {
 				classifyThree != "" &&
 				indexCode != "" &&
 				indexName != "" &&
-				unit != "" &&
-				frequency != "" &&
 				terminalCode != `` {
 
 				//classifyFirstMap := make(map[string]interface{})