|
@@ -269,12 +269,8 @@ func GetIndexCreate() (items []index.BaseFromMysteelChemicalIndex, err error) {
|
|
|
return
|
|
|
}
|
|
|
|
|
|
-type IndexRefreshReq struct {
|
|
|
- Frequency string
|
|
|
-}
|
|
|
-
|
|
|
// GetIndexRefreshAllByMergeFile 获取全部刷新所需文件
|
|
|
-func GetIndexRefreshAllByMergeFile(frequency string) (items []index.BaseFromMysteelChemicalIndex, err error) {
|
|
|
+func GetIndexRefreshAllByMergeFile() (items []index.BaseFromMysteelChemicalIndex, err error) {
|
|
|
if global.CONFIG.Serve.EdbLibUrl == `` {
|
|
|
err = errors.New("刷新未配置")
|
|
|
return
|
|
@@ -283,15 +279,7 @@ func GetIndexRefreshAllByMergeFile(frequency string) (items []index.BaseFromMyst
|
|
|
baseUrl := "/mysteel_chemical/query/refresh"
|
|
|
url := fmt.Sprint(global.CONFIG.Serve.EdbLibUrl, baseUrl)
|
|
|
|
|
|
- req := new(IndexRefreshReq)
|
|
|
- req.Frequency = frequency
|
|
|
-
|
|
|
- postData, err := json.Marshal(req)
|
|
|
- if err != nil {
|
|
|
- return
|
|
|
- }
|
|
|
-
|
|
|
- result, err := HttpPost(url, string(postData), "application/json")
|
|
|
+ result, err := HttpPost(url, "", "application/json")
|
|
|
if err != nil {
|
|
|
return
|
|
|
}
|