yuantianjiao 6 年前
父节点
当前提交
a75e31d687

二进制
src/common/icon/Group 3@3x.png 查看文件


二进制
src/common/icon/bottomMsg.png 查看文件


+ 8
- 4
src/components/myCard/myCard.vue 查看文件

@@ -63,7 +63,11 @@ export default {
63 63
   methods: {
64 64
     share () {
65 65
       if (!this.data.invalid) {
66
-        this.$emit('share', this.data)
66
+        if (this.isgrey) {
67
+          this.$toast('您的卡券分享功能已被关闭,请联系主管')
68
+        } else {
69
+          this.$emit('share', this.data)
70
+        }
67 71
       }
68 72
     }
69 73
   }
@@ -90,8 +94,8 @@ export default {
90 94
       display: -webkit-box;
91 95
       -webkit-line-clamp: 2;
92 96
       -webkit-box-orient: vertical;
93
-      height: .32rem;
94
-      line-height: .16rem;
97
+      height: 0.32rem;
98
+      line-height: 0.16rem;
95 99
     }
96 100
     div:nth-of-type(1) {
97 101
       width: 1.15rem;
@@ -128,7 +132,7 @@ export default {
128 132
       }
129 133
       span {
130 134
         color: #323645;
131
-        font-size: 12px;      
135
+        font-size: 12px;
132 136
         padding-top: 0.05rem;
133 137
       }
134 138
     }

+ 6
- 5
src/components/noMore/noMore.vue 查看文件

@@ -16,12 +16,13 @@ export default {
16 16
 </script>
17 17
 
18 18
 <style lang="scss" scoped>
19
-.nomore{
20
-  img{
21
-    width: 100%;
19
+.nomore {
20
+  img {
21
+    width: 40%;
22 22
     position: absolute;
23
-    top: 40%;
24
-    transform: translateX(-50%);
23
+    top: 50%;
24
+    left: 50%;
25
+    transform: translate(-50%, -50%);
25 26
   }
26 27
 }
27 28
 </style>

+ 1
- 1
src/components/orderItem/index.vue 查看文件

@@ -18,7 +18,7 @@
18 18
           </div>
19 19
         </div>
20 20
         <i class="iconfont icon-jian" :class="{'active': defaultNum > 0}" @click="subtract" v-if="!data.spec.length && data.status === 1"></i>
21
-        <input v-if="!data.spec.length && data.status === 1" type="tel" @input="input" v-model="defaultNum">
21
+        <input v-if="!data.spec.length && data.status === 1" type="tel" @input="input" v-model="defaultNum" readonly style="color:#000;">
22 22
         <i class="iconfont icon-jia" :class="{'active': defaultNum > 0}" @click="add" v-if="!data.spec.length && data.status === 1"></i>
23 23
         <a v-if="data.spec.length && data.status === 1" @click="selectSpec">选规格</a>
24 24
         <span v-if="data.status !== 1">已售罄</span>

+ 1
- 1
src/components/orderPopup/index.vue 查看文件

@@ -22,7 +22,7 @@
22 22
           </div>
23 23
         </div>
24 24
         <i class="iconfont icon-jian" @click="subtract"></i>
25
-        <input type="tel" v-model="num">
25
+        <input type="tel" v-model="num" readonly style="color:#000;">
26 26
         <i class="iconfont icon-jia" @click="add"></i>
27 27
         <a @click="sure">确定</a>
28 28
       </div>

+ 3
- 2
src/pages/sales/customerSearch/page.scss 查看文件

@@ -89,13 +89,14 @@
89 89
         height: .3rem;
90 90
         background: #eee;
91 91
         border-radius: .08rem;
92
-        padding-left: .2rem;
92
+        padding-left: .3rem;
93 93
         line-height: .3rem;
94
+        padding-top: .03rem;
94 95
       }
95 96
       i{
96 97
         font-size: .16rem;
97 98
         position: absolute;
98
-        top: .16rem;
99
+        top: .18rem;
99 100
         left: .23rem;
100 101
         color: #aaa;
101 102
       }

+ 7
- 1
src/pages/user/bindMobile/bindMobile.vue 查看文件

@@ -110,6 +110,13 @@ export default {
110 110
           }
111 111
         }
112 112
       }
113
+      if (this.caseInfo.manager) {
114
+        for (let i = 0; i < this.caseInfo.manager.length; i++) {
115
+          if (this.caseInfo.manager[i].CaseId === this.postData.case) {
116
+            this.columnsS.push(this.caseInfo.manager[i])
117
+          }
118
+        }
119
+      }
113 120
       this.showCase = false
114 121
     },
115 122
     onCancelC () {
@@ -169,7 +176,6 @@ export default {
169 176
       //   return
170 177
       // }
171 178
       this.submitData(this.postData).then((res) => {
172
-        this.$toast(res)
173 179
         if (this.$route.query.isLottery) {
174 180
           setTimeout(() => {
175 181
             const from = this.$route.query.luckshare ? `#/from/${this.$route.query.luckshare}` : ''

+ 25
- 19
src/pages/user/card/index.vue 查看文件

@@ -3,7 +3,8 @@
3 3
     <nav class="flex-h" v-if='false'>
4 4
       <a class="flex-item" v-for="(item,index) in nav" :key="index" :class="{'active':index==active}" @click="change(item,index)">{{item}}</a>
5 5
     </nav>
6
-    <scroll ref='scroll' :isloading='isloading' class='wrapper' :data='data[active].list' :pullUpLoad='pullUpLoadObj' :startY='parseInt(startY)' @pullingUp='getList'>
6
+    <div style="background:#fff;">
7
+    <!-- <scroll ref='scroll' :isloading='isloading' class='wrapper' :data='data[active].list' :pullUpLoad='pullUpLoadObj' :startY='parseInt(startY)' @pullingUp='getList'> -->
7 8
       <div class="box">
8 9
         <div v-if="active == 0">
9 10
           <discounts v-for="(item,index) in data[0].list" :key='index' @toUse='toUse' :data='item' @toDetail="toCardDetail(item)"></discounts>
@@ -29,7 +30,7 @@
29 30
               </div>
30 31
               <div class="card-bottom">
31 32
                 <img :src="line" alt="">
32
-                <div class="time">有效期:{{toolClass.dateFormat(item.EndDate)}}</div>
33
+                <div class="time">有效期:{{toolClass.dateFormat(item.EndDate,'yyyy-MM-dd')}}</div>
33 34
                 <div class="status" :class="{'gray-location' : item.CardStatus == 'used'}">
34 35
                   <span v-if="item.GymType == 'year'">年卡</span>
35 36
                   <span v-if="item.GymType == 'quarter'">季卡</span>
@@ -46,7 +47,8 @@
46 47
           <noMore v-if="data[active].hasPic"></noMore>
47 48
         </div>
48 49
       </div>
49
-    </scroll>
50
+    </div>
51
+    <!-- </scroll> -->
50 52
   </div>
51 53
 </template>
52 54
 
@@ -80,14 +82,14 @@ export default {
80 82
           hasPic: false,
81 83
           hasMore: true,
82 84
           page: 1,
83
-          pageSize: 1,
85
+          pagesize: 1,
84 86
           list: []
85 87
         },
86 88
         {
87 89
           hasPic: false,
88 90
           hasMore: true,
89 91
           page: 0,
90
-          pageSize: 10,
92
+          pagesize: 10000,
91 93
           list: []
92 94
         }
93 95
       ],
@@ -118,15 +120,20 @@ export default {
118 120
   created () {
119 121
     this.change('', 0)
120 122
     this.getCardList().then((res) => {
121
-      for (var n = 0; n < res.length; n++) {
122
-        this.data[0].list.push({
123
-          title: res[n].CardName,
124
-          desc: res[n].Share.CardUseRule,
125
-          time: this.toolClass.dateFormat(res[n].EndDate),
126
-          useType: res[n].Status === 1 ? '未使用' : '已使用',
127
-          tag: '共享',
128
-          cardid: res[n].CardId
129
-        })
123
+      if (res) {
124
+        for (var n = 0; n < res.length; n++) {
125
+          this.data[0].list.push({
126
+            title: res[n].CustomerCardName,
127
+            desc: res[n].Share.CardUseRule,
128
+            time: this.toolClass.dateFormat(res[n].EndDate, 'yyyy-MM-dd'),
129
+            useType: res[n].Status === 1 ? '未使用' : '已使用',
130
+            tag: '共享',
131
+            CustomerCourseId: res[n].CustomerCourseId,
132
+            CustomerCardId: res[n].CustomerCardId
133
+          })
134
+        }
135
+      } else {
136
+        this.data[this.active].hasPic
130 137
       }
131 138
     })
132 139
   },
@@ -141,8 +148,7 @@ export default {
141 148
     },
142 149
     toUse (item) {
143 150
       console.log(item)
144
-      this.$router.push({ name: 'lessonDetail', query: {id: item.CustomerCourseId} })
145
-      // this.$router.push({ name: 'lessonOrder' })
151
+      this.$router.push({ name: 'lessonDetail', query: { id: item.CustomerCourseId } })
146 152
     },
147 153
     getList (param) {
148 154
       if (this.active === 0) {
@@ -152,10 +158,10 @@ export default {
152 158
           this.data[this.active].page = 0
153 159
         }
154 160
         if (this.data[this.active].hasMore) {
155
-          this.getgymCardList({ page: this.data[this.active].page, pageSize: this.data[this.active].pageSize }).then((res) => {
161
+          this.getgymCardList({ page: this.data[this.active].page, pagesize: this.data[this.active].pagesize }).then((res) => {
156 162
             this.data[this.active].list = this.data[this.active].list.concat(this.gymCardList)
157 163
             this.data[this.active].page++
158
-            if (this.gymCardList.length < this.data[this.active].pageSize) {
164
+            if (this.gymCardList.length < this.data[this.active].pagesize) {
159 165
               this.data[this.active].hasMore = false
160 166
             }
161 167
             if (this.data[this.active].list.length <= 0) {
@@ -171,7 +177,7 @@ export default {
171 177
       this.$router.push({ name: 'gymCardDetail', query: { CustomerGymId: item.CustomerGymId } })
172 178
     },
173 179
     toCardDetail (item) {
174
-      this.$router.push({ name: 'cardDetail', query: { id: item.cardid } })
180
+      this.$router.push({ name: 'cardDetail', query: { id: item.CustomerCardId } })
175 181
     }
176 182
   }
177 183
 }

+ 1
- 1
src/pages/user/card/page.scss 查看文件

@@ -28,7 +28,7 @@
28 28
     }
29 29
   }
30 30
   .box{
31
-    padding: .25rem;
31
+    padding: .25rem .25rem 0;
32 32
     box-sizing: border-box;
33 33
     .fitness-card{
34 34
       overflow: hidden;

+ 3
- 3
src/pages/user/cardDetail/index.vue 查看文件

@@ -4,12 +4,12 @@
4 4
     <div class="content" v-if="info !== null">
5 5
       <div class="message">
6 6
         <div>
7
-          <span>{{info.CardName}}</span>
8
-          <span class="sub">(可在银城会所健身房和游泳池使用)</span>
7
+          <span>{{info.CustomerCardName}}</span>
8
+          <!-- <span class="sub">(可在银城会所健身房和游泳池使用)</span> -->
9 9
         </div>
10 10
         <div>
11 11
           <span>有效时间</span>
12
-          <span>{{toolClass.dateFormat(info.EndDate)}}</span>
12
+          <span>{{toolClass.dateFormat(info.StartDate,'yyyy-MM-dd') + '~' + toolClass.dateFormat(info.EndDate,'yyyy-MM-dd')}}</span>
13 13
         </div>
14 14
       </div>
15 15
       <div class="rule">

+ 22
- 12
src/pages/user/coupons/index.vue 查看文件

@@ -46,18 +46,23 @@ export default {
46 46
     this.getCouponList().then((res) => {
47 47
       // console.log(JSON.stringify(res))
48 48
       // console.log(JSON.stringify(this.couponList))
49
-      for (var n = 0; n < res.length; n++) {
50
-        this.list.push({
51
-          title: res[n].Coupon.CouponName,
52
-          desc: res[n].Coupon.Share.UseInstruction,
53
-          time: this.toolClass.dateFormat(res[n].EndDate),
54
-          useType: res[n].Status === 1 ? '未使用' : '已使用',
55
-          tag: res[n].Coupon.CouponType === 'course' ? '课程' : '商品',
56
-          customercouponid: res[n].CustomerCouponId,
57
-          couponid: res[n].Coupon.CouponId,
58
-          Coupon: res[n].Coupon
59
-        })
49
+      if (res) {
50
+        for (var n = 0; n < res.length; n++) {
51
+          this.list.push({
52
+            title: res[n].Coupon.CouponName,
53
+            desc: res[n].Coupon.Share.UseInstruction,
54
+            time: this.toolClass.dateFormat(res[n].EndDate),
55
+            useType: res[n].Status === 1 ? '未使用' : '已使用',
56
+            tag: res[n].Coupon.CouponType === 'course' ? '课程' : '商品',
57
+            customercouponid: res[n].CustomerCouponId,
58
+            couponid: res[n].Coupon.CouponId,
59
+            Coupon: res[n].Coupon
60
+          })
61
+        }
62
+      } else {
63
+        this.hasPic = true
60 64
       }
65
+
61 66
     })
62 67
   },
63 68
   methods: {
@@ -69,13 +74,18 @@ export default {
69 74
     },
70 75
     toUse (item) {
71 76
       console.log(item)
77
+      item.Coupon.Targets = item.Coupon.Targets || []
72 78
       if (item.Coupon.Targets.length > 1) {
73 79
         this.$router.push({ name: 'indexPage' })
74 80
       } else {
75 81
         if (item.tag === '商品') {
76 82
           this.$router.push({ name: 'coffeeIndex' })
77 83
         } else {
78
-          this.$router.push({ name: 'majorProjectsDetail', query: { id: item.Coupon.Targets[0].TargetId } })
84
+          if (item.Coupon.Targets && item.Coupon.Targets.length === 1) {
85
+            this.$router.push({ name: 'majorProjectsDetail', query: { id: item.Coupon.Targets[0].TargetId } })
86
+          } else {
87
+            this.$router.push({ name: 'indexPage' })
88
+          }
79 89
         }
80 90
       }
81 91
     },

+ 1
- 2
src/pages/user/fiveA/index.vue 查看文件

@@ -22,9 +22,8 @@
22 22
                 <courseItem :data="courseInfo(course)"></courseItem>
23 23
               </router-link>
24 24
             </ul>
25
-            <span v-if="fiveANoData" style="width:100%;line-height:.3rem;display:block;text-align:center;color:#ccc;margin-bottom:.1rem;">暂无数据</span>
25
+            <!-- <span v-if="fiveANoData" style="width:100%;line-height:.3rem;display:block;text-align:center;color:#ccc;margin-bottom:.1rem;">暂无数据</span> -->
26 26
           </div>
27
-          <router-link :to="{name:'',query:{}}" class="more">查看更多</router-link>
28 27
           <div style="width:100%;height:.1rem;background:#f8f8f8;margin:0 auto;"></div>
29 28
           <h5>{{item.Consult}}</h5>
30 29
           <div class="newsList flex-h">

+ 7
- 5
src/pages/user/lessonDetail/index.vue 查看文件

@@ -1,5 +1,5 @@
1 1
 <template>
2
-  <div class="mainPage">
2
+  <div class="mainPage" v-if="showPage">
3 3
     <div class="title">课程详情</div>
4 4
     <div class="content" :class="{'opacity' : courseOrderDetail.IsDone === 1, 'gray': courseOrderDetail.IsDone === 1}">
5 5
       <div class="list-item flex-h">
@@ -28,7 +28,7 @@
28 28
       </div>
29 29
       <div class="list-item flex-h">
30 30
         <span>课程时间</span>
31
-        <span class="flex-item">{{toolClass.dateFormat(courseOrderDetail.CreateDate)}}</span>
31
+        <span class="flex-item">{{toolClass.dateFormat(courseOrderDetail.BeginDate) + ' ~ ' + toolClass.dateFormat(courseOrderDetail.EndDate)}}<span class="remark">计划备注({{courseOrderDetail.Remark}})</span> </span>
32 32
       </div>
33 33
       <div class="list-item">
34 34
         <span>地点</span>
@@ -36,8 +36,9 @@
36 36
       </div>
37 37
       <div class="list-item">
38 38
         <span>付款方式</span>
39
-        <span>{{courseOrderDetail.CourseObtaimType === 'cheng-coin' ? '城币支付' : '优惠券抵用'}}</span>
40
-        <!-- <span>优惠券抵用 <div class="coupon-name">小拉伸柔韧度体验券</div></span> -->
39
+        <span v-if="courseOrderDetail.CourseObtaimType === 'cheng-coin'">城币支付</span>
40
+        <span v-if="courseOrderDetail.CourseObtaimType === 'card'">卡券抵用</span>
41
+        <span v-if="courseOrderDetail.CourseObtaimType === 'coupon'">优惠券抵用</span>
41 42
       </div>
42 43
       <div class="half-cic">
43 44
         <span></span>
@@ -45,7 +46,6 @@
45 46
       </div>
46 47
       <div class="qr-code" v-if="courseOrderDetail.IsDone === 0">
47 48
         <qrCode v-if="showQrCode" :msg="courseOrderDetail.QrCodeString"></qrCode>
48
-        <!-- <div class="number">32237489123</div> -->
49 49
       </div>
50 50
     </div>
51 51
     <div class="useType">
@@ -73,6 +73,7 @@ export default {
73 73
       used,
74 74
       failure,
75 75
       showQrCode: false,
76
+      showPage: false
76 77
     }
77 78
   },
78 79
   created () {
@@ -82,6 +83,7 @@ export default {
82 83
           id: this.$route.query.id
83 84
         }).then((res) => {
84 85
           this.showQrCode = true
86
+          this.showPage = true
85 87
           // console.log(JSON.stringify(res))
86 88
         })
87 89
       })

+ 4
- 0
src/pages/user/lessonDetail/page.scss 查看文件

@@ -71,4 +71,8 @@
71 71
     width: .76rem;
72 72
     height: .76rem;
73 73
   }
74
+  .remark{
75
+    font-size: .12rem;
76
+    color: #FC6243 !important;
77
+  }
74 78
 }

+ 2
- 2
src/pages/user/lessonOrder/index.vue 查看文件

@@ -19,8 +19,8 @@
19 19
             <div class="type" :class="{'un-use' : item.IsDone === 0}">{{item.IsDone === 0 ? '未使用' : '已使用'}}</div>
20 20
           </div>
21 21
         </div>
22
-        <span v-if="noData" style="width:100%;display:block;text-align:center;font-size:.11rem;color:#ccc;">暂无数据</span>
23
-        <!-- <noMore v-if="hasPic"></noMore> -->
22
+        <noMore v-if="noData"></noMore>
23
+        <!-- <span v-if="noData" style="width:100%;display:block;text-align:center;font-size:.11rem;color:#ccc;">暂无数据</span> -->
24 24
       </div>
25 25
     </scroll>
26 26
   </div>

+ 63
- 47
src/pages/user/mainPage/coffeeIndex/index.vue 查看文件

@@ -60,6 +60,7 @@
60 60
                   <a @click="toSalesHistory" v-if="userInfo.customer.UserTypeId == 'manager'">销售记录</a>
61 61
                 </div>
62 62
                 <myCard v-for="(item,index) in data[1].list" :isgrey="checkCanDo()" :key="index" :data='item' @share='shareCard'></myCard>
63
+                <noMore v-if="data[1].hasPic"></noMore>
63 64
               </div>
64 65
             </li>
65 66
             <li :hidden="navActive !== 2" class="my-card">
@@ -74,6 +75,7 @@
74 75
                   <a @click="toSalesHistory" v-if="userInfo.customer.UserTypeId == 'manager'">销售记录</a>
75 76
                 </div>
76 77
                 <myCard v-for="(item,index) in data[2].list" :isgrey="checkCanDo()" :key="index" :data='item' @share='shareCoupon'></myCard>
78
+                <noMore v-if="data[2].hasPic"></noMore>
77 79
               </div>
78 80
             </li>
79 81
             <li :hidden="navActive !== 3" class="customer-card">
@@ -92,6 +94,7 @@
92 94
                   <i class="iconfont icon-sousuo search-icon" @click="searchMask"></i>
93 95
                 </div>
94 96
                 <customerCard v-for="(item,index) in postCustomerData.isrecommend ? myRecommendUserList : data[3].list" :key="index" :data='item' @record='record'></customerCard>
97
+                <noMore v-if="data[3].hasPic"></noMore>
95 98
               </div>
96 99
             </li>
97 100
           </ul>
@@ -130,6 +133,7 @@ import active from '../../../../common/icon/check-box-checked.png'
130 133
 import normal from '../../../../common/icon/check-box-empty.png'
131 134
 import logo from '../../../../common/icon/indexlogo.jpg'
132 135
 import wxsdk from '../../../../util/share'
136
+import noMore from '../../../../components/noMore/noMore'
133 137
 import { mapState, createNamespacedHelpers } from 'vuex'
134 138
 const { mapActions: actions } = createNamespacedHelpers('app')
135 139
 const { mapActions: caseTableActions } = createNamespacedHelpers('placeOrderForCoffee')
@@ -252,7 +256,8 @@ export default {
252 256
     topCaseInfo,
253 257
     caseTableItem,
254 258
     myCard,
255
-    customerCard
259
+    customerCard,
260
+    noMore
256 261
   },
257 262
   created () {
258 263
     if (!this.userInfo.customer.MapUser) {
@@ -264,64 +269,75 @@ export default {
264 269
         this.getCustomerList({
265 270
           ...this.postCustomerData
266 271
         }).then((res) => {
267
-          // console.log(JSON.stringify(res))
268
-          for (var n = 0; n < res.length; n++) {
269
-            if (res[n].RecommendId === this.userInfo.customer.MapUser) {
270
-              this.myRecommendUserList.push(res[n])
271
-              res[n].showTag = true
272
-            } else {
273
-              res[n].showTag = false
272
+          if (res) {
273
+            for (var n = 0; n < res.length; n++) {
274
+              if (res[n].RecommendId === this.userInfo.customer.MapUser) {
275
+                this.myRecommendUserList.push(res[n])
276
+                res[n].showTag = true
277
+              } else {
278
+                res[n].showTag = false
279
+              }
280
+              this.data[3].list.push(res[n])
274 281
             }
275
-            this.data[3].list.push(res[n])
282
+          } else {
283
+            this.data[3].hasPic = true
276 284
           }
277 285
         })
278 286
         this.getMyCouponList({
279 287
           ...this.postCouponData
280 288
         }).then((res) => {
281 289
           res.list = res.list || []
282
-          for (var n = 0; n < res.list.length; n++) {
283
-            this.data[2].list.push({
284
-              invalid: this.returnInvalid(res.list[n], 'coupon'),
285
-              price: parseInt(res.list[n].Price),
286
-              title: res.list[n].CouponName,
287
-              desc: res.list[n].Share.UseRule,
288
-              startDate: this.toolClass.dateFormat(res.list[n].StartDate, 'yyyy年MM月dd日'),
289
-              endDate: this.toolClass.dateFormat(res.list[n].EndDate, 'yyyy年MM月dd日'),
290
-              totalCount: res.list[n].TotalCount,
291
-              SentCount: res.list[n].SentCount,
292
-              usedCount: res.list[n].UsedCount,
293
-              CardId: res.list[n].CouponId,
294
-            })
295
-          }
296
-          var count = 0
297
-          for (var n = 0; n < this.data[2].list.length; n++) {
298
-            count += this.data[2].list[n].price * this.data[2].list[n].totalCount - 0
290
+          if (res.list.length > 0) {
291
+            for (var n = 0; n < res.list.length; n++) {
292
+              this.data[2].list.push({
293
+                invalid: this.returnInvalid(res.list[n], 'coupon'),
294
+                price: parseInt(res.list[n].Price),
295
+                title: res.list[n].CouponName,
296
+                desc: res.list[n].Share.UseRule,
297
+                startDate: this.toolClass.dateFormat(res.list[n].StartDate, 'yyyy年MM月dd日'),
298
+                endDate: this.toolClass.dateFormat(res.list[n].EndDate, 'yyyy年MM月dd日'),
299
+                totalCount: res.list[n].TotalCount,
300
+                SentCount: res.list[n].SentCount,
301
+                usedCount: res.list[n].UsedCount,
302
+                CardId: res.list[n].CouponId,
303
+              })
304
+            }
305
+            var count = 0
306
+            for (var n = 0; n < this.data[2].list.length; n++) {
307
+              count += this.data[2].list[n].price * this.data[2].list[n].totalCount - 0
308
+            }
309
+            this.couponTotalCount = count.toFixed(2)
310
+          } else {
311
+            this.data[2].hasPic = true
299 312
           }
300
-          this.couponTotalCount = count.toFixed(2)
301 313
         })
302 314
         this.getMyCardList({
303 315
           ...this.postCardData
304 316
         }).then((res) => {
305 317
           res.list = res.list || []
306
-          for (var n = 0; n < res.list.length; n++) {
307
-            this.data[1].list.push({
308
-              invalid: this.returnInvalid(res.list[n], 'card'),
309
-              price: parseInt(res.list[n].Price),
310
-              title: res.list[n].CardName,
311
-              desc: res.list[n].Share.CardUseRule,
312
-              startDate: this.toolClass.dateFormat(res.list[n].StartDate, 'yyyy年MM月dd日'),
313
-              endDate: this.toolClass.dateFormat(res.list[n].EndDate, 'yyyy年MM月dd日'),
314
-              totalCount: res.list[n].TotalCount,
315
-              SentCount: res.list[n].SentCount,
316
-              usedCount: res.list[n].UsedCount,
317
-              CardId: res.list[n].CardId
318
-            })
319
-          }
320
-          var count = 0
321
-          for (var n = 0; n < this.data[1].list.length; n++) {
322
-            count += this.data[1].list[n].price * this.data[1].list[n].totalCount - 0
318
+          if (res.list.length > 0) {
319
+            for (var n = 0; n < res.list.length; n++) {
320
+              this.data[1].list.push({
321
+                invalid: this.returnInvalid(res.list[n], 'card'),
322
+                price: parseInt(res.list[n].Price),
323
+                title: res.list[n].CardName,
324
+                desc: res.list[n].Share.CardUseRule,
325
+                startDate: this.toolClass.dateFormat(res.list[n].StartDate, 'yyyy年MM月dd日'),
326
+                endDate: this.toolClass.dateFormat(res.list[n].EndDate, 'yyyy年MM月dd日'),
327
+                totalCount: res.list[n].TotalCount,
328
+                SentCount: res.list[n].SentCount,
329
+                usedCount: res.list[n].UsedCount,
330
+                CardId: res.list[n].CardId
331
+              })
332
+            }
333
+            var count = 0
334
+            for (var n = 0; n < this.data[1].list.length; n++) {
335
+              count += this.data[1].list[n].price * this.data[1].list[n].totalCount - 0
336
+            }
337
+            this.cardTotalCount = count.toFixed(2)
338
+          } else {
339
+            this.data[1].hasPic = true
323 340
           }
324
-          this.cardTotalCount = count.toFixed(2)
325 341
         })
326 342
       })
327 343
     } else {
@@ -505,9 +521,9 @@ export default {
505 521
     },
506 522
     toOrders (subItem, item) {
507 523
       const _that = this
508
-      this.getCaseConf({caseid: subItem.CaseId}).then(res => {
524
+      this.getCaseConf({ caseid: subItem.CaseId }).then(res => {
509 525
         if (res.Status === 1) {
510
-          this.$router.push({name: 'placeOrder', query: { tableid: encodeURI(subItem.TableId), tableno: encodeURI(subItem.TableNo), caseid: encodeURI(subItem.CaseId), casename: encodeURI(_that.topCaseInfoData.caseName), areaid: encodeURI(subItem.AreaId), areaname: encodeURI(item.AreaName)}})
526
+          this.$router.push({ name: 'placeOrder', query: { tableid: encodeURI(subItem.TableId), tableno: encodeURI(subItem.TableNo), caseid: encodeURI(subItem.CaseId), casename: encodeURI(_that.topCaseInfoData.caseName), areaid: encodeURI(subItem.AreaId), areaname: encodeURI(item.AreaName) } })
511 527
         } else {
512 528
           _that.$toast('当前案场已歇业!')
513 529
           return

+ 1
- 1
src/pages/user/mainPage/userCenter/index.vue 查看文件

@@ -41,7 +41,7 @@
41 41
 
42 42
       <div class="userCenter-menu">
43 43
         <div class="menu-item flex-h" @click="toLessonOrder">
44
-          <span>课程订单</span>
44
+          <span>我的课程</span>
45 45
           <i class="iconfont icon-jiantou-right"></i>
46 46
         </div>
47 47
         <div class="menu-item flex-h" @click="toGoodsOrder">

+ 7
- 0
src/pages/user/majorProjectsDetail/index.vue 查看文件

@@ -142,6 +142,9 @@ export default {
142 142
       if (nowDate > endData) {
143 143
         this.gray = true
144 144
       }
145
+      if (this.courseDetail.SignupNum >= this.courseDetail.MaxNum) {
146
+        this.gray = true
147
+      }
145 148
       // console.log(JSON.stringify(res))
146 149
       this.showPage = true
147 150
     })
@@ -166,6 +169,10 @@ export default {
166 169
       this.showMoreCourse = !this.showMoreCourse
167 170
     },
168 171
     toBuy () {
172
+      if (this.gray) {
173
+        this.$toast('该课程已过期或参与人数已满')
174
+        return
175
+      }
169 176
       let nowDate = Date.now()
170 177
       let endData = new Date(this.courseDetail.EndDate).getTime()
171 178
       if (nowDate > endData) {

+ 2
- 1
src/pages/user/orderList/index.vue 查看文件

@@ -17,7 +17,8 @@
17 17
                 <orderListItem :data="item"></orderListItem>
18 18
               </li>
19 19
             </ul>
20
-            <span v-if="noData" style="width:100%;display:block;text-align:center;font-size:.11rem;color:#ccc;">暂无数据</span>
20
+            <noMore v-if="noData"></noMore>
21
+            <!-- <span v-if="noData" style="width:100%;display:block;text-align:center;font-size:.11rem;color:#ccc;">暂无数据</span> -->
21 22
           </scroll>
22 23
         </div>
23 24
       </div>

+ 2
- 2
src/pages/user/placeOrder/index.vue 查看文件

@@ -69,7 +69,7 @@
69 69
       <a @click="toPlaceOrder">下单</a>
70 70
     </div>
71 71
     <orderPopup :show="showPopup" :data="currentSpec" @closePopup="closePopup" @returnData="calcMenus"></orderPopup>
72
-    <calcMenu :show="showCalcMenu" :totalNum="sumNum" :data="selGoods" @returnData="calcMenus" @emptyMenus="emptyMenus" @closeCalcMenu="closeCalcMenu" @placeOrder="placeOrder"></calcMenu>
72
+    <calcMenu :show="showCalcMenu" :totalNum="sumNum + caseTotal.total" :data="selGoods" @returnData="calcMenus" @emptyMenus="emptyMenus" @closeCalcMenu="closeCalcMenu" @placeOrder="placeOrder"></calcMenu>
73 73
   </div>
74 74
 </template>
75 75
 
@@ -165,7 +165,7 @@ export default {
165 165
       this.selGoods.map(x => {
166 166
         price += x.price * x.num - 0
167 167
       })
168
-      return price
168
+      return Math.ceil((price) * 100) / 100
169 169
     }
170 170
   },
171 171
   components: {

+ 4
- 1
src/pages/user/placeOrderForCourse/index.vue 查看文件

@@ -63,7 +63,9 @@
63 63
                     <span>优惠券</span>
64 64
                   </div>
65 65
                 </div>
66
-                <span>{{couponList.length ? couponList.length + '张可用优惠券' : '暂无优惠券'}}</span>
66
+                <span v-if='couponList.length <= 0 && !showCoupon'>暂无优惠券</span>
67
+                <span v-if='couponList.length > 0 && !showCoupon' style="color:#fc6243">{{couponList.length + '张可用优惠券'}}</span>
68
+                <span v-if='showCoupon' style="color:#fc6243">{{showCoupon}}</span>
67 69
               </div>
68 70
             </div>
69 71
             <div class="agreement">
@@ -211,6 +213,7 @@ export default {
211 213
         if (this.couponList[n].select) {
212 214
           bool = true
213 215
           this.postData.customercouponid = this.couponList[n].id
216
+          this.showCoupon = this.couponList[n].title
214 217
         }
215 218
       }
216 219
       if (!bool) {

+ 1
- 1
src/pages/user/receive/index.vue 查看文件

@@ -30,7 +30,7 @@
30 30
           <i class="icon-kaquan iconfont"></i>
31 31
           <span>卡券有效期</span>
32 32
         </div>
33
-        <pre>有效期至{{toolClass.dateFormat(data.EndDate)}},请在有效期结束前使用, 过期作废;</pre>
33
+        <pre>有效期至{{toolClass.dateFormat(data.EndDate,'yyyy-MM-dd')}},请在有效期结束前使用, 过期作废;</pre>
34 34
       </div>
35 35
       <div class="text">
36 36
         <div>

+ 1
- 1
src/pages/user/receiveChannel/index.vue 查看文件

@@ -30,7 +30,7 @@
30 30
           <i class="icon-kaquan iconfont"></i>
31 31
           <span>卡券有效期</span>
32 32
         </div>
33
-        <pre>有效期至{{toolClass.dateFormat(data.EndDate)}},请在有效期结束前使用, 过期作废;</pre>
33
+        <pre>有效期至{{toolClass.dateFormat(data.EndDate,'yyyy-MM-dd')}},请在有效期结束前使用, 过期作废;</pre>
34 34
       </div>
35 35
       <div class="text">
36 36
         <div>

+ 5
- 0
src/util/ajax.js 查看文件

@@ -76,6 +76,11 @@ const ajax = (...args) => {
76 76
         if (router.history.current.name !== 'bindMobile') {
77 77
           router.push({ name: 'bindMobile' })
78 78
         }
79
+      } else if (code === 405) {
80
+        // console.log(router.history.current.name)
81
+        // if (router.history.current.name !== 'bindMobile') {
82
+          router.push({ name: 'login' })
83
+        // }
79 84
       } else {
80 85
         if (message.indexOf("log-error") != -1) {
81 86
           console.log(message)