瀏覽代碼

版本更新

liuguofeng 6 月之前
父節點
當前提交
fc7ce822ca

+ 2 - 1
jiaoyu_mp/pages.json

@@ -104,7 +104,8 @@
 			"path" : "pages/score/index",
 			"style" : 
 			{
-				"navigationBarTitleText" : "积分产品"
+				"navigationBarTitleText" : "积分产品",
+				"enablePullDownRefresh": true
 			}
 		},
 		{

+ 1 - 1
jiaoyu_mp/pages/course/index.vue

@@ -95,7 +95,7 @@
 				if( re.code == 'success' ){
 					if(re.data.last_page <= this.requestParam.page ) this.isLast = true;
 					this.productList = re.data.data;
-					console.log(this.productList);
+					// console.log(this.productList);
 				}
 			});
 		},

+ 16 - 2
jiaoyu_mp/pages/score/index.vue

@@ -44,10 +44,10 @@
 				</view>
 				<view class="title">
 					<view class="">
-						王先生
+						{{username}}
 					</view>
 					<view class="">
-						5000积分
+						{{scoreInfo.score}}积分
 					</view>
 				</view>
 			</view>
@@ -91,10 +91,17 @@
 					name:"",
 					page:1,
 				},
+				scoreInfo:{
+					score:0,
+					use_score:0,
+					wait_score:0,
+				},
 				// 是否最后一页
 				isLast:false,
 				// 是否请求中
 				isReqing:false,
+				//用户名称
+				username:''
 			}
 		},
 		onLoad() {
@@ -121,6 +128,13 @@
 					this.productList = re.data.data;
 				}
 			});
+			this.$http.request('/api/custom_score/get_info').then((res)=>{
+				if(res.code == "success"){
+					this.scoreInfo = res.data;
+					let	{username} = uni.getStorageSync("userInfo");
+					this.username = username;
+				}
+			})
 		},
 		onPullDownRefresh() {
 			// 如果请求中,不允许请求,

+ 2 - 5
jiaoyu_mp/pagesA/course/reservation.vue

@@ -224,7 +224,6 @@
 		onLoad(e) {
 			//接受url参数
 			let {orders_product_id,course_id} = e
-			console.log(e);
 			this.orders_product_id = orders_product_id
 			this.course_id = course_id
 		},
@@ -272,7 +271,6 @@
 					this.course_name = this.shcedule_list[0].course_name
 					this.teacher_desc = this.shcedule_list[0].teacher_desc
 					this.course_image = this.shcedule_list[0].course_image
-					console.log(this.shcedule_list);
 
 				}	
 			},
@@ -396,7 +394,7 @@
 			
 			handleSubmit() {
 				 this.appointTime.push(this.orderDateTime.begin)
-				console.log(this.appointTime);
+				 // console.log(this.appointTime);
 			},
 			
 			
@@ -469,7 +467,6 @@
 					let	starTimeStamp = cruTiem.start_time * 1000
 					let	endTimeStamp = cruTiem.end_time * 1000
 					let timeStr  = 60 * 1000 * cruTiem.duration
-					console.log(starTimeStamp,endTimeStamp);
 					// timeStr = 60 * 1000 * i.duration
 					if (isQuantum) {
 						time.push({
@@ -551,7 +548,7 @@
 		}
 		.days{
 			display: flex;
-			 background-color: #ffffff;
+			background-color: #ffffff;
 			.day{
 				display: inline-flex;
 				flex-direction: column;

+ 0 - 1
jiaoyu_mp/unpackage/dist/dev/mp-weixin/pages/course/index.js

@@ -29,7 +29,6 @@ const _sfc_main = {
         if (re.data.last_page <= this.requestParam.page)
           this.isLast = true;
         this.productList = re.data.data;
-        console.log(this.productList);
       }
     });
   },

+ 18 - 2
jiaoyu_mp/unpackage/dist/dev/mp-weixin/pages/score/index.js

@@ -11,10 +11,17 @@ const _sfc_main = {
         name: "",
         page: 1
       },
+      scoreInfo: {
+        score: 0,
+        use_score: 0,
+        wait_score: 0
+      },
       // 是否最后一页
       isLast: false,
       // 是否请求中
-      isReqing: false
+      isReqing: false,
+      //用户名称
+      username: ""
     };
   },
   onLoad() {
@@ -34,6 +41,13 @@ const _sfc_main = {
         this.productList = re.data.data;
       }
     });
+    this.$http.request("/api/custom_score/get_info").then((res) => {
+      if (res.code == "success") {
+        this.scoreInfo = res.data;
+        let { username } = common_vendor.index.getStorageSync("userInfo");
+        this.username = username;
+      }
+    });
   },
   onPullDownRefresh() {
     if (this.isReqing)
@@ -117,7 +131,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
       };
     }),
     b: common_assets._imports_0$2,
-    c: common_vendor.p({
+    c: common_vendor.t($data.username),
+    d: common_vendor.t($data.scoreInfo.score),
+    e: common_vendor.p({
       type: "search",
       size: "20"
     })

+ 1 - 0
jiaoyu_mp/unpackage/dist/dev/mp-weixin/pages/score/index.json

@@ -1,5 +1,6 @@
 {
   "navigationBarTitleText": "积分产品",
+  "enablePullDownRefresh": true,
   "usingComponents": {
     "uni-icons": "../../uni_modules/uni-icons/components/uni-icons/uni-icons"
   }

+ 1 - 1
jiaoyu_mp/unpackage/dist/dev/mp-weixin/pages/score/index.wxml

@@ -1 +1 @@
-<view><view class="product_box"><view class="product_list"><view wx:for="{{a}}" wx:for-item="item" wx:key="e" bindtap="{{item.d}}" data-eventsync="true" class="product_item"><image class="product_image" src="{{item.a}}" mode=""></image><view class="product_name"><text>{{item.b}}</text></view><view class="stock_price"><view class="product_price"><text>{{item.c}} 积分</text></view></view></view></view></view><view class="header_fixed"><view class="user_title"><view class="user_prc"><image src="{{b}}"></image></view><view class="title"><view class=""> 王先生 </view><view class=""> 5000积分 </view></view></view><view class="search"><view class="search_box"><view class="search_input"><input type="text" placeholder="一年级系统班"/></view><view class="search_icon"><uni-icons wx:if="{{c}}" u-i="b5b70676-0" bind:__l="__l" u-p="{{c}}"></uni-icons></view></view></view><view class="course_option"><view class="option_name"> 综合 </view><view class="option_name"> 我可兑换 </view><view class="option_name"> 销量 </view><view class="option_name"> 积分 </view></view></view><view class="to_bottom"> -----到底了-----</view></view>
+<view><view class="product_box"><view class="product_list"><view wx:for="{{a}}" wx:for-item="item" wx:key="e" bindtap="{{item.d}}" data-eventsync="true" class="product_item"><image class="product_image" src="{{item.a}}" mode=""></image><view class="product_name"><text>{{item.b}}</text></view><view class="stock_price"><view class="product_price"><text>{{item.c}} 积分</text></view></view></view></view></view><view class="header_fixed"><view class="user_title"><view class="user_prc"><image src="{{b}}"></image></view><view class="title"><view class="">{{c}}</view><view class="">{{d}}积分 </view></view></view><view class="search"><view class="search_box"><view class="search_input"><input type="text" placeholder="一年级系统班"/></view><view class="search_icon"><uni-icons wx:if="{{e}}" u-i="b5b70676-0" bind:__l="__l" u-p="{{e}}"></uni-icons></view></view></view><view class="course_option"><view class="option_name"> 综合 </view><view class="option_name"> 我可兑换 </view><view class="option_name"> 销量 </view><view class="option_name"> 积分 </view></view></view><view class="to_bottom"> -----到底了-----</view></view>

+ 0 - 4
jiaoyu_mp/unpackage/dist/dev/mp-weixin/pagesA/course/reservation.js

@@ -185,7 +185,6 @@ const _sfc_main = {
   },
   onLoad(e) {
     let { orders_product_id, course_id } = e;
-    console.log(e);
     this.orders_product_id = orders_product_id;
     this.course_id = course_id;
   },
@@ -226,7 +225,6 @@ const _sfc_main = {
         this.course_name = this.shcedule_list[0].course_name;
         this.teacher_desc = this.shcedule_list[0].teacher_desc;
         this.course_image = this.shcedule_list[0].course_image;
-        console.log(this.shcedule_list);
       }
     },
     //预约课程事件
@@ -320,7 +318,6 @@ const _sfc_main = {
     },
     handleSubmit() {
       this.appointTime.push(this.orderDateTime.begin);
-      console.log(this.appointTime);
     },
     //字符串拼接
     strFormat(str) {
@@ -391,7 +388,6 @@ const _sfc_main = {
         let starTimeStamp = cruTiem.start_time * 1e3;
         let endTimeStamp = cruTiem.end_time * 1e3;
         60 * 1e3 * cruTiem.duration;
-        console.log(starTimeStamp, endTimeStamp);
         if (isQuantum) {
           time.push({
             begin: this.timeStamp(starTimeStamp, isQuantum).hour,