1234567891011121314151617181920212223242526272829 |
- package services
- import (
- "eta/mysteel_watch/global"
- "fmt"
- "github.com/rdlucklib/rdluck_tools/http"
- "net/url"
- )
- const (
- RefreshUrl = "http://127.0.0.1:7007/mysteel_chemical/refresh"
- )
- // MysteelChemicalRefresh
- // @Description: 调用python服务去刷新excel文件
- // @author: Roc
- // @datetime 2023-11-27 09:39:05
- // @param filePath string
- func MysteelChemicalRefresh(filePath string) {
- //filePathStr:=url.PathEscape(filePath)
- refreshUrl := RefreshUrl + "?FilePath=" + url.QueryEscape(filePath)
- fmt.Println("MysteelChemicalRefresh URL:" + refreshUrl)
- body, err := http.Get(refreshUrl)
- if err != nil {
- global.LOG.Error("MysteelChemicalRefresh Err:" + err.Error())
- return
- }
- global.LOG.Debug("MysteelChemicalRefresh Result:" + string(body))
- }
|