Pārlūkot izejas kodu

拼多多

master
huangjiajun pirms 5 mēnešiem
vecāks
revīzija
feb1b21b94
1 mainītis faili ar 24 papildinājumiem un 0 dzēšanām
  1. +24
    -0
      pdd_union/extend_url.go

+ 24
- 0
pdd_union/extend_url.go Parādīt failu

@@ -17,6 +17,12 @@ func ExtendUrl(keyArr map[string]string, param map[string]interface{}) map[strin
"page_path": "",
"schema_url": "",
}
if param["open_app"] == "<nil>" || param["open_app"] == nil {
param["open_app"] = ""
}
if param["link_type"] == "<nil>" || param["link_type"] == nil {
param["link_type"] = ""
}
for _, v := range res.GoodsPromotionUrlGenerateResponse.GoodsPromotionUrlList {
tmp["url"] = v.ShortUrl
tmp["open_app_url"] = v.MobileUrl
@@ -54,6 +60,12 @@ func MainThemeUrl(keyArr map[string]string, param map[string]interface{}) map[st
tmp["no_open_app_url"] = res.ResourceUrlResponse.SingleUrlList.ShortUrl
tmp["page_path"] = res.ResourceUrlResponse.WeAppInfo.PagePath
tmp["schema_url"] = res.ResourceUrlResponse.SingleUrlList.SchemaUrl
if param["open_app"] == "<nil>" || param["open_app"] == nil {
param["open_app"] = ""
}
if param["link_type"] == "<nil>" || param["link_type"] == nil {
param["link_type"] = ""
}
if param["open_app"] == "" && param["link_type"] != "" {
tmp["url"] = res.ResourceUrlResponse.SingleUrlList.Url
}
@@ -87,6 +99,12 @@ func WnMainThemeUrl(keyArr map[string]string, param map[string]interface{}) map[
tmp["no_open_app_url"] = res.GoodsZsUnitGenerateResponse.ShortUrl
tmp["page_path"] = res.GoodsZsUnitGenerateResponse.WeAppInfo.PagePath
tmp["schema_url"] = res.GoodsZsUnitGenerateResponse.SchemaUrl
if param["open_app"] == "<nil>" || param["open_app"] == nil {
param["open_app"] = ""
}
if param["link_type"] == "<nil>" || param["link_type"] == nil {
param["link_type"] = ""
}
if param["open_app"] == "" && param["link_type"] != "" {
tmp["url"] = res.GoodsZsUnitGenerateResponse.Url
}
@@ -116,6 +134,12 @@ func RpUrl(keyArr map[string]string, param map[string]interface{}) map[string]st
"user_name": "",
"app_id": "",
}
if param["open_app"] == "<nil>" || param["open_app"] == nil {
param["open_app"] = ""
}
if param["link_type"] == "<nil>" || param["link_type"] == nil {
param["link_type"] = ""
}
for _, v := range res.RpPromotionUrlGenerateResponse.UrlList {
tmp["url"] = v.ShortUrl
tmp["open_app_url"] = v.MobileUrl


Notiek ielāde…
Atcelt
Saglabāt