|
@@ -45,7 +45,7 @@ func DeWater(in models.DyJieXiInput) (error, models.DyJieXiOutput) {
|
|
|
var out models.DyJieXiOutput
|
|
|
var dysy mysql.DysyUrlInfo
|
|
|
var p []byte
|
|
|
-
|
|
|
+
|
|
|
str := ""
|
|
|
baseHost := in.Url
|
|
|
client := &http.Client{
|
|
@@ -53,7 +53,6 @@ func DeWater(in models.DyJieXiInput) (error, models.DyJieXiOutput) {
|
|
|
return http.ErrUseLastResponse
|
|
|
},
|
|
|
}
|
|
|
-
|
|
|
|
|
|
res, err := client.Get(baseHost)
|
|
|
if err != nil {
|
|
@@ -83,32 +82,17 @@ func DeWater(in models.DyJieXiInput) (error, models.DyJieXiOutput) {
|
|
|
return errors.New(apis.JsonUnmarshalFail), out
|
|
|
|
|
|
}
|
|
|
-
|
|
|
|
|
|
-
|
|
|
-
|
|
|
|
|
|
var videoUrl = inData.ItemList[0].Video.PlayAddr.URLList[0]
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
out.Data.VideoUrl = strings.Replace(videoUrl, "playwm", "play", 1)
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
out.Data.AudioUrl = inData.ItemList[0].Music.PlayURL.URI
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
out.Data.VideoPic = inData.ItemList[0].Video.DynamicCover.URLList[0]
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
out.Data.Desc = inData.ItemList[0].Desc
|
|
|
|
|
|
|
|
@@ -138,51 +122,14 @@ func DeWater(in models.DyJieXiInput) (error, models.DyJieXiOutput) {
|
|
|
}
|
|
|
ss, err := ioutil.ReadAll(res1.Body)
|
|
|
fmt.Println(string(ss))
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+ videoStr := string(ss)
|
|
|
+
|
|
|
+
|
|
|
+ comma = strings.Index(videoStr, "\"")
|
|
|
+ pos = strings.Index(videoStr[comma+1:], "\"")
|
|
|
+ fmt.Println(videoStr[comma+1 : pos])
|
|
|
+
|
|
|
+
|
|
|
|
|
|
return nil, out
|
|
|
|