|
@@ -238,12 +238,18 @@ func GetMerchantCanvasCard(c *gin.Context) {
|
|
|
outData.Static.Background = "/images/背景.jpg"
|
|
|
var swiperList []models.SwiperList
|
|
|
var rightButton models.RightButton
|
|
|
- err = json.Unmarshal([]byte(merchantCard.Picture), &swiperList)
|
|
|
- if err != nil {
|
|
|
- fmt.Println("picture")
|
|
|
- app.Error(c, 500, err, err.Error())
|
|
|
- return
|
|
|
- }
|
|
|
+ var swiper models.SwiperList
|
|
|
+
|
|
|
+ swiper.ID = 0
|
|
|
+ swiper.URL = merchantCard.Picture
|
|
|
+ swiperList = append(swiperList, swiper)
|
|
|
+ //err = json.Unmarshal([]byte(merchantCard.Picture), &swiperList)
|
|
|
+ //if err != nil {
|
|
|
+ // fmt.Println("picture")
|
|
|
+ // app.Error(c, 500, err, err.Error())
|
|
|
+ // return
|
|
|
+ //}
|
|
|
+
|
|
|
outData.SwiperList = swiperList
|
|
|
|
|
|
rightButton.ImageURL = "/images/资源 24.png"
|