ソースを参照

Signed-off-by: yukangzhe <382985154@qq.com>

yukangzhe 3 年 前
コミット
b7fc6d3841

+ 1 - 1
pages/makePiano/makePiano.wxml

@@ -71,7 +71,7 @@
                 <view class="class-stu-num">
                   {{ item.hasVisitNum}}/{{ item.maxNum}}
                 </view>
-                <view class="class-get-btn" bindtap="doAppointment" data-id="{{item.id}}">
+                <view class="class-get-btn" bindtap="doAppointment" data-index="{{index}}" data-id="{{item.id}}">
                  {{ item.hasVisitNum < item.maxNum ?  '预约' : '已约满'}}
                 </view>
               </view>

+ 2 - 2
pages/myself/myself.wxml

@@ -22,13 +22,13 @@
 				</view>
 				<image lazy-load mode="aspectFill" class="li-arrow" src="{{imageUrl? imageUrl+'arrow0603.png' : ''}}"></image>
 			</view>
-			<view class="list-item" catchtap="goNavigateTo" data-url="/pages/cardList/cardList" wx:if="{{!isShow}}">
+			<!-- <view class="list-item" catchtap="goNavigateTo" data-url="/pages/cardList/cardList" wx:if="{{!isShow}}">
 				<view class="li-left">
 					<image lazy-load mode="aspectFill" class="li-icon" src="/images/kab.png" style="width:40rpx;height:40rpx;margin-left:4rpx;"></image>
 					<text>我的卡包</text>
 				</view>
 				<image lazy-load mode="aspectFill" class="li-arrow" src="{{imageUrl? imageUrl+'arrow0603.png' : ''}}"></image>
-			</view>
+			</view> -->
 			<view class="list-item" catchtap="goNavigateTo" data-url="/pages/classOrder/classOrder">
 				<view class="li-left">
 					<image lazy-load mode="aspectFill" class="li-icon" src="/images/my-classOrder.png"></image>

+ 1 - 1
pages/payDone/payDone.js

@@ -31,7 +31,7 @@ Page({
 
   toOrder:function(){
     wx.redirectTo({
-      url:'/pages/cardList/cardList',
+      url:'/pages/classOrder/classOrder',
     })
   },
 

+ 46 - 10
pages/playShow/playShow.js

@@ -10,15 +10,41 @@ Page({
   data: {
     id: null,
     item: null,
-    creator: null
+    creator: null,
+    cHeight: 0,
   },
 
   /**
    * 生命周期函数--监听页面加载
    */
   onLoad: function (options) {
-    this.setData({ id: options.vid })
+    this.setData({
+      id: options.vid
+    })
     this.loadInfo()
+
+    let wHeight = wx.getSystemInfoSync().windowHeight
+    let psHeight = 0
+    wx.createSelectorQuery().select('#playShow').boundingClientRect(rect => {
+      psHeight = rect.height;
+      console.log(psHeight)
+    }).exec();
+    let tHeight = 0
+    wx.createSelectorQuery().select('.title').boundingClientRect(rect => {
+      tHeight = rect.height;
+      console.log(tHeight)
+    }).exec();
+    let evHeight = 0
+    wx.createSelectorQuery().select('.edit-view').boundingClientRect(rect => {
+      evHeight = rect.height;
+      console.log(evHeight)
+      console.log(wHeight)
+      const cHeight = wHeight - psHeight - evHeight - tHeight - 40
+      this.setData({
+        cHeight
+      })
+    }).exec();
+    
   },
 
   /**
@@ -76,24 +102,32 @@ Page({
   loadInfo: function () {
     const urls = urlDef.urls;
     let stu = wx.getStorageSync('student');
-    this.setData({ curStu: stu })
+    this.setData({
+      curStu: stu
+    })
 
     util.apiPost(urls.person_video_list + '&q.videoId=' + this.data.id).then((rs) => {
       if (rs && rs.length > 0) {
         let o = rs[0]
         o.viewsCount = this.formatCount(o.viewsCount)
-        this.setData({ item: o })
+        this.setData({
+          item: o
+        })
         util.apiPost(urls.video_loadInfo + this.data.id).then((rs) => {
           o.imgUrl = rs.img
           o.playUrl = rs.url
-          this.setData({ item: o })
+          this.setData({
+            item: o
+          })
         })
 
 
-        let goodEntity = { videoId: this.data.id, personId: stu.studentId, personType: 1 };
-        util.apiPost(urls.person_video_view_save, goodEntity, 'application/json').then(rs => {
-        }).catch(e => {
-        });
+        let goodEntity = {
+          videoId: this.data.id,
+          personId: stu.studentId,
+          personType: 1
+        };
+        util.apiPost(urls.person_video_view_save, goodEntity, 'application/json').then(rs => {}).catch(e => {});
       }
     })
 
@@ -105,7 +139,9 @@ Page({
         u = {}
         u.imageUrl = urls.oss_file + 'image/' + u.imageUrl
       }
-      this.setData({ creator: u })
+      this.setData({
+        creator: u
+      })
     })
 
 

+ 6 - 3
pages/playShow/playShow.wxml

@@ -3,11 +3,14 @@
     <video id="playShow" poster="{{item.imgUrl}}" src="{{item.playUrl}}" controls="true"></video>
   </view>
 
-  <view class="title">{{item.title}}</view>
-  <view class="desc">
-    {{item.content}}
+  <view class="title">{{item.title}}
     <view class="desc2">浏览次数: {{item.viewsCount}}</view>
   </view>
+  <view class="desc" style="height:{{cHeight}}px">
+    {{item.content}}
+    {{item.content}}
+    {{item.content}}
+  </view>
   
 
   <view class="edit-view">

+ 11 - 6
pages/playShow/playShow.wxss

@@ -14,8 +14,9 @@
   font-size: 32rpx;
 }
 .desc{
-  color: #999; 
-  min-height: 300px;
+  color: #999;
+    height: 610rpx;
+    overflow-y: auto;
 }
 .desc2{
   color: #999;
@@ -24,13 +25,16 @@
 }
 
 .zan-view image,.share-view image{
-  width: 100rpx ;
-  height: 100rpx;
+  width: 70rpx ;
+  height: 70rpx;
 }
 .edit-view{
-  width: 600rpx;
+  width: 759rpx;
   display: flex;
-  margin: 20px auto 0;
+  position: fixed;
+  background: #FFF;
+  bottom: 0;
+  font-size: 24rpx;
 }
 .edit-view>view{
   margin: 0 auto;
@@ -48,4 +52,5 @@
 }
 .share-view view{
   font-weight: 400 !important;
+  font-size: 24rpx;
 }