bayi 2 years ago
parent
commit
cb2d3d6816
3 changed files with 12 additions and 5 deletions
  1. 8 2
      components/vipModal/index.js
  2. 3 2
      pages/my/index.js
  3. 1 1
      pages/my/index.wxml

+ 8 - 2
components/vipModal/index.js

@@ -67,7 +67,7 @@ Component({
                     canvas.width = res[0].width * dpr;
                     canvas.width = res[0].width * dpr;
                     canvas.height = res[0].height * dpr;
                     canvas.height = res[0].height * dpr;
                     ctx.scale(dpr, dpr);
                     ctx.scale(dpr, dpr);
-                    ctx.font = '16px PingFang';
+                    ctx.font = '18px PingFang';
                     let pic = canvas.createImage();
                     let pic = canvas.createImage();
                     pic.src = type == 'svip' ? 'http://reader-wx.ai160.com/images/reader/v3/learn/vip1.png' : 'http://reader-wx.ai160.com/images/reader/v3/learn/vip2.png'
                     pic.src = type == 'svip' ? 'http://reader-wx.ai160.com/images/reader/v3/learn/vip1.png' : 'http://reader-wx.ai160.com/images/reader/v3/learn/vip2.png'
                     pic.onload = () => {
                     pic.onload = () => {
@@ -85,7 +85,13 @@ Component({
                                 success(res) {
                                 success(res) {
                                     wx.saveImageToPhotosAlbum({
                                     wx.saveImageToPhotosAlbum({
                                         filePath: res.tempFilePath,
                                         filePath: res.tempFilePath,
-                                        success(res) {}
+                                        success(res) {
+                                            wx.showToast({
+                                                title: '保存成功!',
+                                                icon: "none",
+                                                duration: 3000
+                                            })
+                                        }
                                     })
                                     })
                                 },
                                 },
                                 fail(res) {
                                 fail(res) {

+ 3 - 2
pages/my/index.js

@@ -62,8 +62,9 @@ Page({
         })
         })
     },
     },
     async getProducts() {
     async getProducts() {
-        let products = await getProducts()
+        let {
-        console.log(products);
+            productList: products,
+        } = await getProducts()
         this.setData({
         this.setData({
             products,
             products,
         })
         })

+ 1 - 1
pages/my/index.wxml

@@ -78,7 +78,7 @@
     <view class="renewBox" wx:if="{{vipTime&&vipTime!='1'}}">
     <view class="renewBox" wx:if="{{vipTime&&vipTime!='1'}}">
         <view class="title">续费</view>
         <view class="title">续费</view>
         <view class="renew">
         <view class="renew">
-            <view class="left">升级成svlp会员终身的 <view class="money">+200元</view>
+            <view class="left">{{products[0].title}} <view class="money">+{{products[0].price/100}}元</view>
             </view>
             </view>
         </view>
         </view>
         <view class="renew">
         <view class="renew">