银豹cookie增加

This commit is contained in:
苏尹岚
2020-03-26 09:18:21 +08:00
parent e52b87312c
commit 615e6abbae

View File

@@ -123,6 +123,7 @@ var (
mtpsStoreToken string
jd2StorePageCookie string
JdStorePageCookie string
yinbaoCookie string
)
func GetImportantTaskID(taskName string) string {
@@ -247,6 +248,9 @@ func Init() {
if configs, err := dao.QueryConfigs(dao.GetDB(), "jd2StorePageCookie", model.ConfigTypeCookie, ""); err == nil {
jd2StorePageCookie = configs[0].Value
}
if configs, err := dao.QueryConfigs(dao.GetDB(), "yinbaoCookie", model.ConfigTypeCookie, ""); err == nil {
yinbaoCookie = configs[0].Value
}
if globals.Jd2OrgCode != "" {
api.Jd2API.SetJdCookie(jd2StorePageCookie)
}
@@ -261,6 +265,7 @@ func Init() {
api.JdAPI.SetJdCookie(JdStorePageCookie)
api.JdPageAPI.SetCookie(jdapi.AccessStorePageCookieName, JdStorePageCookie)
api.JdPageAPI.SetCookie(jdapi.AccessStorePageCookieName2, JdStorePageCookie)
api.YinBaoAPI.SetCookie(".POSPALAUTH30220", yinbaoCookie)
}
func syncStoreSku() {