黎海 vor 2 Jahren
Ursprung
Commit
fc537ba559

Datei-Diff unterdrückt, da er zu groß ist
+ 80 - 21165
package-lock.json


+ 1 - 0
package.json

@@ -16,6 +16,7 @@
16 16
     "element-ui": "^2.8.2",
17 17
     "js-cookie": "^3.0.1",
18 18
     "qrcodejs2": "0.0.2",
19
+    "vant": "^2.12.47",
19 20
     "vue": "^2.6.6",
20 21
     "vue-infinite-scroll": "^2.0.2",
21 22
     "vue-router": "^3.0.1",

+ 1 - 0
public/index.html

@@ -16,5 +16,6 @@
16 16
   <script src="https://ydcommon.51yund.com/vue/axios.min.js"></script>
17 17
   <!-- built files will be auto injected -->
18 18
 </body>
19
+<!-- <script type="text/javascript" src="https://ydcommon.51yund.com/test_web_hd/vendor/vconsole.min.js"></script> -->
19 20
 
20 21
 </html>

+ 0 - 4
src/common/http.js

@@ -23,7 +23,6 @@ axios.defaults.timeout = 10000;
23 23
 
24 24
 // post请求头
25 25
 axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded;charset=UTF-8';
26
-console.log(store.state.comVal.token, 'this.$store.state.comVal.token111', localStorage.getItem('token'));
27 26
 axios.defaults.headers.post['token'] = localStorage.getItem('token') || store.state.comVal.token;
28 27
 axios.defaults.headers.get['token'] = localStorage.getItem('token') || store.state.comVal.token;
29 28
 
@@ -120,7 +119,6 @@ function get (url, params) {
120 119
             type: 'error'
121 120
           });
122 121
         }
123
-        console.log(res.data);
124 122
         resolve(res.data);
125 123
       })
126 124
       .catch(err => {
@@ -141,7 +139,6 @@ function post (url, params) {
141 139
   return new Promise((resolve, reject) => {
142 140
     axios.post(reqUrl, QS.stringify(params))
143 141
       .then(res => {
144
-        console.log(res, 'resres');
145 142
         if (res.data.code != 200 && localStorage.getItem('token')) {
146 143
           Message({
147 144
             message: res.data.msg,
@@ -151,7 +148,6 @@ function post (url, params) {
151 148
         resolve(res.data);
152 149
       })
153 150
       .catch(err => {
154
-        console.log(err, 'errerrerr');
155 151
         reject(err.data)
156 152
       })
157 153
   });

+ 1 - 2
src/common/utils.js

@@ -5,6 +5,7 @@ const utils = {
5 5
   },
6 6
   test: function () { },
7 7
   isBack: false,
8
+  //标准时间格式化
8 9
   formatTime: function (date, fmt) {
9 10
     var date = new Date(date);
10 11
     if (/(y+)/.test(fmt)) {
@@ -25,8 +26,6 @@ const utils = {
25 26
     }
26 27
     return fmt;
27 28
   },
28
-
29
-
30 29
 }
31 30
 
32 31
 export default () => {

+ 10 - 7
src/components/common/layout/layout.vue

@@ -6,14 +6,17 @@
6 6
                  @changeIsBack="changeIsBack"></left-menu>
7 7
     </div>
8 8
     <div class="content">
9
-      <header :style="menuIndex==0?'justify-content: space-between;':''">
9
+      <header>
10
+
10 11
         <div class="back-icon"
11 12
              v-if="isback"
12 13
              @click="goBack"><img src="https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/back.png"
13 14
                alt=""></div>
14
-        <div class="left"
15
-             v-if="menuIndex==0">
16
-          <div class="address">{{userInfo.store_name}}</div>
15
+        <div>
16
+          <div class="left"
17
+               v-if="menuIndex==0">
18
+            <div class="address">{{userInfo.store_name}}</div>
19
+          </div>
17 20
         </div>
18 21
         <div class="right">
19 22
           <div class="news"><img src="https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/home/news.png"></div>
@@ -73,7 +76,7 @@ export default {
73 76
     },
74 77
     loginOut () {
75 78
       localStorage.removeItem('token');
76
-      location.reload();
79
+      this.$router.replace('/login')
77 80
     },
78 81
     changeMenu (index) {
79 82
       this.menuIndex = index
@@ -138,6 +141,7 @@ export default {
138 141
   overflow: hidden;
139 142
 
140 143
   header {
144
+    width: 100%;
141 145
     line-height: 50px;
142 146
     font-size: 16px;
143 147
     color: #409eff;
@@ -146,8 +150,7 @@ export default {
146 150
     height: 60px;
147 151
     display: flex;
148 152
     align-items: center;
149
-    justify-content: right;
150
-
153
+    justify-content: space-between;
151 154
     position: relative;
152 155
     .back-icon {
153 156
       position: absolute;

+ 14 - 12
src/components/common/layout/leftMenu.vue

@@ -49,12 +49,14 @@ export default {
49 49
           unicon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/unhome.png',
50 50
           icon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/home.png'
51 51
 
52
-        }, {
53
-          name: "测肤记录",
54
-          path: "/testSkin",
55
-          unicon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/unskin.png',
56
-          icon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/Skin.png',
57
-        }, {
52
+        },
53
+        // {
54
+        //   name: "测肤记录",
55
+        //   path: "/testSkin",
56
+        //   unicon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/unskin.png',
57
+        //   icon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/Skin.png',
58
+        // },
59
+        {
58 60
           name: "发券中心",
59 61
           path: "/coupon",
60 62
           unicon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/uncoupon.png',
@@ -75,7 +77,7 @@ export default {
75 77
         //   path: "/storeDetection",
76 78
         //   icon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/testing.png',
77 79
         //   unicon: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/untesting.png'
78
-        // }, 
80
+        // },   
79 81
         {
80 82
           name: "客户管理",
81 83
           path: "/customerMan",
@@ -88,8 +90,9 @@ export default {
88 90
   },
89 91
   watch: {
90 92
     $route (to, from) {
91
-      let patname = `/${window.location.hash.split('/')[1]}`
92
-      console.log(patname, 'patname', to);
93
+      let patname = `/${to.path.split('/')[1]}`
94
+      console.log(window.location, 'window.location.pathname', to);
95
+
93 96
       this.$emit('changeIsBack', to.meta.isback)
94 97
       this.menu.forEach((item, index) => {
95 98
         if (patname == item.path) {
@@ -100,8 +103,8 @@ export default {
100 103
     }
101 104
   },
102 105
   mounted () {
103
-    let patname = `/${window.location.pathname.split('/')[1]}`
104
-    console.log(patname, 'patname');
106
+    let patname = `/${window.location.hash.substr(1).split('/')[1]}`
107
+    console.log(window.location, 'window.location.pathname', patname);
105 108
     this.menu.forEach((item, index) => {
106 109
       if (patname == item.path) {
107 110
         this.nowIndex = index
@@ -143,7 +146,6 @@ export default {
143 146
 
144 147
 .el-menu-item {
145 148
   margin-left: 8px;
146
-  padding: 0;
147 149
   padding-left: 9px !important;
148 150
   height: auto;
149 151
   line-height: initial;

+ 29 - 29
src/components/modules/helloWorld.vue

@@ -1,40 +1,40 @@
1 1
 <template>
2
-    <div class="hello">
3
-        <h1>{{ msg }},样式由less书写</h1>
4
-        <input type="text" class="common">
5
-        <button @click="test()">点击</button>
6
-    </div>
2
+  <div class="hello">
3
+    <h1>{{ msg }},样式由less书写</h1>
4
+    <input type="text"
5
+           class="common">
6
+    <button @click="test()">点击</button>
7
+  </div>
7 8
 </template>
8 9
 
9 10
 <script>
10 11
 export default {
11
-    name: 'HelloWorld',
12
-    props: {
13
-        msg: String
14
-    },
15
-    data() {
16
-        return {
17
-            
18
-        }
19
-    },
20
-    mounted: function () {
21
-    },
22
-    created: function () {
23
-    },
24
-    methods: {
25
-        test(){
26
-            console.log("点击了")
27
-        }
12
+  name: 'HelloWorld',
13
+  props: {
14
+    msg: String
15
+  },
16
+  data () {
17
+    return {
18
+
19
+    }
20
+  },
21
+  mounted: function () {
22
+  },
23
+  created: function () {
24
+  },
25
+  methods: {
26
+    test () {
28 27
     }
28
+  }
29 29
 }
30 30
 </script>
31 31
 
32 32
 <style lang='less' scoped>
33
-    @import url(../../style/root.less);
34
-    h1 {
35
-        .hei(60px);
36
-        &:hover {
37
-            color: #696;
38
-        }
39
-    }
33
+@import url(../../style/root.less);
34
+h1 {
35
+  .hei(60px);
36
+  &:hover {
37
+    color: #696;
38
+  }
39
+}
40 40
 </style>

+ 436 - 202
src/pages/confirmOrder/details/index.vue

@@ -84,7 +84,8 @@
84 84
       <div class="project">
85 85
         <div class="project-title">
86 86
           <div>共<span>{{order_data.project_list?order_data.project_list.length:0}}个</span>项目</div>
87
-          <div class="add-project"
87
+          <div v-if="order_data.type!='one'"
88
+               class="add-project"
88 89
                @click="addProject">添加</div>
89 90
         </div>
90 91
         <div class="project-list">
@@ -95,12 +96,12 @@
95 96
             <div class="project-content">
96 97
               <div class="title-price">
97 98
                 <div class="project-tit">{{item.name | ellipsis(14)}}</div>
98
-                <div class="project-price"><span class="min-size">¥</span>{{item.price}}</div>
99
+                <div class="project-price"><span class="min-size">¥</span>{{Number(item.price).toFixed(2)}}</div>
99 100
               </div>
100 101
               <div class="project-tips">{{item.product_names}}</div>
101 102
               <div class="project-zoom">
102 103
                 <div> <span v-if="item.device_name">{{item.device_name}}({{item.room}}){{item.use_time}}分钟</span></div>
103
-                <div><img @click="eidt(item)"
104
+                <div v-if="order_data.type!='one'"><img @click="eidt(item)"
104 105
                        src="https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/coupon/eidt.png">
105 106
                   <img v-if="order_data.project_list.length>1"
106 107
                        @click="deleteProject(item)"
@@ -132,7 +133,6 @@
132 133
             <div class="on-icon">></div>
133 134
           </div>
134 135
 
135
-
136 136
           <!-- <div v-if="order_data.coupon_list&&order_data.coupon_list.length>0">
137 137
             <div class="coupon-ps"
138 138
                  v-for="item,index in order_data.coupon_list"
@@ -147,18 +147,18 @@
147 147
                  v-for="item,index in isSelectCoup"
148 148
                  :key="index">
149 149
               <div>{{item.coupon_name}}</div>
150
-      <div class="cou-price" v-if="item.type==4?true:false">抵扣{{item.projectName}}</div>
151
-      <div class="cou-price" v-if="item.type==3?true:false">抵扣全部项目(除升级包)</div>
152
-      <div class="cou-price" v-if="item.type==2?true:false">¥{{item.price}}</div>
153
-      <div class="cou-price" v-if="item.type==1?true:false">¥{{item.price}}</div>
154
-                    <!-- <div class="cou-price">-¥{{price}}</div> -->
150
+              <div class="cou-price"
151
+                   v-if="item.type==4?true:false">抵扣{{item.projectName}}</div>
152
+              <div class="cou-price"
153
+                   v-if="item.type==3?true:false">抵扣全部项目(除升级包)</div>
154
+              <div class="cou-price"
155
+                   v-if="item.type==2?true:false">¥{{item.price}}</div>
156
+              <div class="cou-price"
157
+                   v-if="item.type==1?true:false">¥{{item.price}}</div>
158
+              <!-- <div class="cou-price">-¥{{price}}</div> -->
155 159
             </div>
156 160
           </div>
157 161
 
158
-
159
-
160
-
161
-
162 162
         </div>
163 163
         <div class="over-price">
164 164
           合计: <span class="price-num"><span class="min-size">¥</span>{{showMoney}}<span class="min-size"></span></span>
@@ -178,7 +178,7 @@
178 178
           <li class="coupon-info"
179 179
               v-for="item,index in couponList"
180 180
               :key="index">
181
-  <!-- 1: '抵扣券',
181
+            <!-- 1: '抵扣券',
182 182
       2: '满减券',
183 183
       3: '全额减免券',
184 184
       4: '项目卡券' -->
@@ -332,11 +332,65 @@
332 332
         </div>
333 333
       </div>
334 334
     </mine-pupop>
335
+    <!-- 支付 -->
336
+    <mine-pupop :show="choicePayType">
337
+      <div class="pay-block">
338
+        <div class="delete-pupop"
339
+             @click="choicePayType=false"><img src="https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/delete.png"
340
+               alt=""></div>
341
+        <div class="pay-title">选择支付方式</div>
342
+        <div class="pay-price">¥<span>{{showMoney}}</span></div>
343
+        <div class="pay-list">
344
+          <div class="pay-info"
345
+               v-for="item,index in payList"
346
+               @click="changeType(index)"
347
+               :style="item.isSelect?'border: 1px solid #FA7D22;':'border: 1px solid #D0D0D0;'"
348
+               :key="index">
349
+            <div class="pay-left">
350
+              <img :src="item.payImg"
351
+                   alt="">
352
+              <span>{{item.title}}</span>
353
+            </div>
354
+            <div class="pay-right">
355
+              <img :src="item.isSelect?select:unSelect"
356
+                   alt="">
357
+            </div>
358
+          </div>
359
+        </div>
360
+        <div class="pay-button"
361
+             @click="pay">确认</div>
362
+      </div>
363
+    </mine-pupop>
364
+    <!-- 支付状态 -->
365
+    <mine-pupop :show="PayStatus">
366
+      <div class="pay-block">
367
+        <div class="delete-pupop"
368
+             @click="PayStatus=false"><img src="https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/slices/delete.png"
369
+               alt=""></div>
370
+        <div v-if="isPayCode">
371
+          <div class="pay-title">请扫码支付</div>
372
+          <div class="pay-price">¥<span>{{showMoney}}</span></div>
373
+          <div class="banner">
374
+            <div id="qrCode"
375
+                 class="qrCode"
376
+                 ref="qrCodeDiv"></div>
377
+          </div>
378
+        </div>
379
+        <div v-else>
380
+          <div class="pay-title">支付成功</div>
381
+          <div class="pay-suc"><img src="https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/coupon/paySuc.png"
382
+                 alt=""></div>
383
+          <div class="pay-button"
384
+               @click="toHome">返回首页</div>
385
+        </div>
386
+      </div>
387
+    </mine-pupop>
335 388
   </div>
336 389
 </template>
337 390
 
338 391
 <script>
339 392
 import minePupop from '../../../components/minePupop/index.vue'
393
+import QRCode from 'qrcodejs2'
340 394
 import api from '../../../server/home'
341 395
 
342 396
 export default {
@@ -367,21 +421,6 @@ export default {
367 421
       },
368 422
       //皮肤状态列表
369 423
       poreList: [
370
-        {
371
-          medium: 133,
372
-          small: 344,
373
-          mini: 242
374
-        },
375
-        {
376
-          medium: 133,
377
-          small: 344,
378
-          mini: 242
379
-        },
380
-        {
381
-          medium: 133,
382
-          small: 344,
383
-          mini: 242
384
-        }
385 424
       ],
386 425
       //优惠券列表
387 426
       couponList: [],
@@ -389,6 +428,27 @@ export default {
389 428
       selectCouponList: [],
390 429
       //已选择优惠券的id(同一个id只能选择一张优惠券)
391 430
       selectCouponListId: [],
431
+      //支付方式
432
+      payList: [
433
+        {
434
+          title: '储值支付',
435
+          pay_way: 'amount',
436
+          payImg: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/coupon/savingsPay.png',
437
+          isSelect: true
438
+        },
439
+        {
440
+          pay_way: 'weixin',
441
+          title: '微信支付',
442
+          payImg: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/coupon/weiXinPay.png',
443
+          isSelect: false
444
+        },
445
+        {
446
+          pay_way: 'alipay',
447
+          title: '支付宝支付',
448
+          payImg: 'https://we-spa.oss-cn-shenzhen.aliyuncs.com/pad_clerk/icon/coupon/zhifubaoPay.png',
449
+          isSelect: false
450
+        },
451
+      ],
392 452
       timesInfo: '',
393 453
       reservationPrice: 0,//预约费用
394 454
       projectInfo: '',
@@ -402,22 +462,23 @@ export default {
402 462
       isProject: false,//是否展示选择项目弹窗
403 463
       isTs: false,//是否展示选择时间弹窗
404 464
       isPore: false,//皮肤状态弹窗
465
+      choicePayType: false,//支付弹窗
466
+      PayStatus: false,//支付状态弹窗
467
+      isPayCode: true,//是否展示支付二维码
405 468
       id: 0,//订单id
469
+      lastProjectPrice: '',//项目已选择的升级包
406 470
       isChange: false,//项目是否有改变
407 471
       isEditProject: false,//是否编辑项目
472
+      payStatusInterval: null,//轮循拉支付状态
408 473
       page: 1,
409 474
       limit: 200,
410
-
411
-
412
-
413
-
414
-    needSelect: false,
415
-    coupSelectType: '',
416
-    productDiscount: '',
417
-    isSelectCoup: [], // 选择的优惠券
418
-    // 下面是支付的数据
419
-    showMoney: 0, // 价值总额
420
-    // showRuleText: 10086,
475
+      needSelect: false,
476
+      coupSelectType: '',
477
+      productDiscount: '',
478
+      isSelectCoup: [], // 选择的优惠券
479
+      // 下面是支付的数据
480
+      showMoney: 0, // 价值总额
481
+      // showRuleText: 10086,
421 482
 
422 483
     };
423 484
   },
@@ -427,6 +488,9 @@ export default {
427 488
   watch: {},
428 489
 
429 490
   methods: {
491
+    toHome () {
492
+      this.$router.replace('/home')
493
+    },
430 494
     getOrderInfo () {
431 495
       api.getOrderInfo({ id: this.id }).then(res => {
432 496
         this.userInfo = res.data.user
@@ -434,7 +498,7 @@ export default {
434 498
         this.remarks = res.data.remark
435 499
         this.programmeList = res.data.scheme_list
436 500
         this.order_data = res.data.order_data
437
-        this.showMoney=res.data.order_data.price
501
+        this.showMoney = res.data.order_data.price
438 502
         this.poreList = res.data.detail_list
439 503
         this.calculationPrice()
440 504
       })
@@ -445,13 +509,19 @@ export default {
445 509
       })
446 510
     },
447 511
     getProducts (e) {
448
-      this.productsInfo = ''
512
+      // this.productsInfo = ''
449 513
       api.getProducts({ id: e }).then(res => {
450 514
         this.productsList = res.data.list
515
+        this.productsList.forEach(item => {
516
+          if (this.productsInfo == item.id) {
517
+            this.lastProjectPrice = Number(item.price)
518
+          }
519
+        })
451 520
       })
452 521
     },
453 522
     eidt (item) {
454 523
       this.projectInfo = item.id
524
+      this.productsInfo = item.product_ids == '' ? '' : Number(item.product_ids)
455 525
       this.getProducts(item.id)
456 526
       this.isEditProject = true
457 527
       this.isProject = true
@@ -469,6 +539,7 @@ export default {
469 539
     },
470 540
     addProject () {
471 541
       this.projectInfo = ''
542
+      this.productsInfo = ''
472 543
       this.isEditProject = false
473 544
       this.isProject = true
474 545
     },
@@ -477,16 +548,18 @@ export default {
477 548
       // 编辑
478 549
       if (this.isEditProject) {
479 550
         if (this.productsInfo != '') {
551
+
480 552
           this.order_data.project_list.forEach(e => {
481 553
             if (this.projectInfo == e.id) {
482 554
               this.productsList.forEach(item => {
483
-                if (e.product_ids != '') {
484
-                  e.price = Number(e.price) - Number(item.price)
485
-                }
486 555
                 e.product_ids = this.productsInfo
487 556
                 if (item.id == e.product_ids) {
557
+                  if (e.product_ids != '') {
558
+                    e.price = Number(e.price) - Number(this.lastProjectPrice)
559
+                  }
488 560
                   this.isChange = true
489 561
                   e.product_names = item.name
562
+                  console.log(Number(e.price), Number(item.price), 'Number(e.price) + Number(item.price)');
490 563
                   e.price = Number(e.price) + Number(item.price)
491 564
                   this.isProject = false
492 565
                   this.isEditProject = false
@@ -524,7 +597,6 @@ export default {
524 597
             }
525 598
           })
526 599
         }
527
-        console.log(nowProjectInfo, 'nowProjectInfo', productsInfo);
528 600
         projectInfo['name'] = nowProjectInfo.name
529 601
         projectInfo['id'] = nowProjectInfo.id
530 602
         projectInfo['cover_url'] = nowProjectInfo.cover_url
@@ -560,14 +632,12 @@ export default {
560 632
         let year = myDate.getFullYear();
561 633
         let month = myDate.getMonth() + 1;
562 634
         let date = myDate.getDate();
563
-        console.log(year + "-" + month + "-" + date)
564 635
         let str = "周" + "日一二三四五六".charAt(myDate.getDay());
565 636
         let tsTableInfo = {}
566 637
         tsTableInfo['text'] = i == 0 ? '今天' : i == 1 ? '明天' : str
567 638
         tsTableInfo['ts'] = month + "-" + date
568 639
         tsTableInfo['order_day'] = year + "-" + month + "-" + date
569 640
         tsTableList.push(tsTableInfo)
570
-        console.log(str)
571 641
       }
572 642
       this.tsTableList = tsTableList
573 643
     },
@@ -580,7 +650,7 @@ export default {
580 650
         this.tsTableIndex = 0
581 651
         this.isTs = true
582 652
       } else {
583
-        debugger
653
+        this.choicePayType = true
584 654
       }
585 655
     },
586 656
     //确定时间选择
@@ -593,10 +663,8 @@ export default {
593 663
         if (item.product_ids != "") {
594 664
           order_data_info['product_id'] = item.product_ids
595 665
         }
596
-        console.log(order_data_info, 'order_data_info');
597 666
         order_data.push(order_data_info)
598 667
       })
599
-      console.log(order_data, 'order_data');
600 668
       let params = {
601 669
         id: this.id,
602 670
         order_data: JSON.stringify(order_data),
@@ -620,9 +688,9 @@ export default {
620 688
     //获取订单优惠券
621 689
     onCoupon () {
622 690
 
623
-      if(this.couponList.length>0){
624
-         this.isCoupun = true
625
-         return
691
+      if (this.couponList.length > 0) {
692
+        this.isCoupun = true
693
+        return
626 694
       }
627 695
 
628 696
       let params = {
@@ -640,10 +708,76 @@ export default {
640 708
           this.onCoupon()
641 709
         }
642 710
       })
643
-      console.log(this.couponList)
644 711
       this.isCoupun = true
645 712
     },
713
+    //选择支付方式
714
+    changeType (i) {
715
+      this.payList.forEach((res, index) => {
716
+        if (index == i) {
717
+          res.isSelect = true
718
+        } else {
719
+          res.isSelect = false
720
+        }
721
+      })
722
+    },
723
+    pay () {
724
+      let that = this
725
+      let payWayList = this.payList.filter(res => {
726
+        return res.isSelect == true
727
+      })
728
+      // 卡券,项目券数据包, id:订单项目ID, coupon_id:优惠券ID, 如:[{ "id": 1220, coupon_id: 199 }]isSelectCoup
729
+      let params = {
730
+        id: this.id,
731
+        pay_way: payWayList[0].pay_way
732
+      }
733
+
734
+      let coupon_data = []
735
+      if (this.isSelectCoup.length > 0) {
736
+        this.isSelectCoup.forEach(item => {
737
+          if (item.type != 4) {
738
+            params['coupon_id'] = item.id
739
+          } else {
740
+            let couponInfo = {}
741
+            couponInfo['id'] = item.projectids
742
+            couponInfo['coupon_id'] = item.id
743
+          }
744
+        })
745
+      }
746
+      params['coupon_data'] = coupon_data.length > 0 ? JSON.stringify(coupon_data) : null
747
+      api.orderPay(params).then(res => {
748
+        if (res.code == 200) {
749
+          this.choicePayType = false
750
+          this.PayStatus = true
751
+          if (res.data.pay_status == 1) {
752
+            this.isPayCode = false
753
+          } else {
754
+            this.$nextTick(() => {
755
+              new QRCode(that.$refs.qrCodeDiv, {
756
+                text: res.data.qr_code_string,
757
+                width: 140,
758
+                height: 140,
759
+                colorDark: "#333333", //二维码颜色
760
+                colorLight: "#ffffff", //二维码背景色
761
+                correctLevel: QRCode.CorrectLevel.L//容错率,L/M/H
762
+              })
763
+            })
764
+            this.payStatusInterval = setInterval(e => {
765
+              this.payStatus()
766
+            }, 1000)
767
+          }
768
+        }
769
+
770
+      })
771
+    },
772
+    payStatus () {
773
+      api.payStatus({ id: this.id, }).then(res => {
646 774
 
775
+        if (res.data.pay_status == 1) {
776
+          clearInterval(this.payStatusInterval)
777
+          this.isPayCode = false
778
+        }
779
+      })
780
+    },
647 781
 
648 782
     //数组包含关系
649 783
     includes (arr1, arr2) {
@@ -661,191 +795,179 @@ export default {
661 795
     // },
662 796
 
663 797
 
664
-// 不可以用的不显示,如果同时有项目劵、抵扣劵、满减劵,只能用一种类型,其他劵不显示
665
-// 1、针对单个项目,项目劵可以多选
666
-// 2、抵扣劵、满减劵针对的是整个订单,当用户已使用了单个项目劵时,抵扣劵、满减劵就不能使用
667
-// 3、优惠劵可以给多个项目抵扣,
668
-// 4、默认抵扣金额最高的
669
-// 5、优惠劵排序,到期时间倒叙
798
+    // 不可以用的不显示,如果同时有项目劵、抵扣劵、满减劵,只能用一种类型,其他劵不显示
799
+    // 1、针对单个项目,项目劵可以多选
800
+    // 2、抵扣劵、满减劵针对的是整个订单,当用户已使用了单个项目劵时,抵扣劵、满减劵就不能使用
801
+    // 3、优惠劵可以给多个项目抵扣,
802
+    // 4、默认抵扣金额最高的
803
+    // 5、优惠劵排序,到期时间倒叙
670 804
 
671 805
 
672
-/**
673
-   * 点击使用按钮、勾选按钮
674
-   */
675
-  selectPupop: function (item, index) {
806
+    /**
807
+       * 点击使用按钮、勾选按钮
808
+       */
809
+    selectPupop: function (item, index) {
676 810
 
677 811
 
678
-    let CouPonIndex = this.couponList
812
+      let CouPonIndex = this.couponList
679 813
 
680
-    let selectIndex = index
681
-    let curreValue = !CouPonIndex[selectIndex].isSelect
682
-    let project_list = this.order_data.project_list //这里是项目列表
814
+      let selectIndex = index
815
+      let curreValue = !CouPonIndex[selectIndex].isSelect
816
+      let project_list = this.order_data.project_list //这里是项目列表
683 817
 
684
-    // 判断是否是不相同的项目券
685
-    if (this.couponList[selectIndex].type != 4) {
686
-      for (let i = 0; i < CouPonIndex.length; i++) {
687
-        CouPonIndex[i].isSelect = false
688
-      }
689
-      for (let i = 0; i < project_list.length; i++) {
690
-        project_list[i].cardId = ''
691
-      }
818
+      // 判断是否是不相同的项目券
819
+      if (this.couponList[selectIndex].type != 4) {
820
+        for (let i = 0; i < CouPonIndex.length; i++) {
821
+          CouPonIndex[i].isSelect = false
822
+        }
823
+        for (let i = 0; i < project_list.length; i++) {
824
+          project_list[i].cardId = ''
825
+        }
692 826
 
693
-    } else if (this.coupSelectType != 4) {
694
-      for (let i = 0; i < CouPonIndex.length; i++) {
695
-        CouPonIndex[i].isSelect = false
696
-      }
697
-      for (let i = 0; i < project_list.length; i++) {
698
-        project_list[i].cardId = ''
699
-      }
700
-    } else {
701
-      let numberSelect = 0
702
-      for (let i = 0; i < CouPonIndex.length; i++) {
703
-        if (CouPonIndex[i].isSelect) {
704
-          numberSelect = numberSelect + 1
827
+      } else if (this.coupSelectType != 4) {
828
+        for (let i = 0; i < CouPonIndex.length; i++) {
829
+          CouPonIndex[i].isSelect = false
830
+        }
831
+        for (let i = 0; i < project_list.length; i++) {
832
+          project_list[i].cardId = ''
833
+        }
834
+      } else {
835
+        let numberSelect = 0
836
+        for (let i = 0; i < CouPonIndex.length; i++) {
837
+          if (CouPonIndex[i].isSelect) {
838
+            numberSelect = numberSelect + 1
839
+          }
840
+        }
841
+        if (numberSelect == this.order_data.project_list.length && curreValue) {
842
+          this.$message.error('最多选择' + this.order_data.project_list.length + '项目券!');
843
+          return
705 844
         }
706 845
       }
707
-      console.log('numberSelect')
708
-      console.log(numberSelect)
709
-      if (numberSelect == this.order_data.project_list.length && curreValue) {
710
-            this.$message.error('最多选择' + this.order_data.project_list.length + '项目券!');
711
-        return
712
-      }
713
-    }
714
-    // 判断是否是取消选择项目券
715
-    CouPonIndex[selectIndex].isSelect = curreValue
716
-    if (!curreValue) {
717
-      for (let j = 0; j < project_list.length; j++) {
718
-        if (project_list[j].cardId && project_list[j].cardId == this.couponList[selectIndex].id) { // 如果是取消选择,那么也要取消绑定项目的id
719
-          project_list[j].cardId = ''
846
+      // 判断是否是取消选择项目券
847
+      CouPonIndex[selectIndex].isSelect = curreValue
848
+      if (!curreValue) {
849
+        for (let j = 0; j < project_list.length; j++) {
850
+          if (project_list[j].cardId && project_list[j].cardId == this.couponList[selectIndex].id) { // 如果是取消选择,那么也要取消绑定项目的id
851
+            project_list[j].cardId = ''
852
+          }
720 853
         }
854
+        CouPonIndex[selectIndex].projectids = ''
721 855
       }
722
-      CouPonIndex[selectIndex].projectids = ''
723
-    }
724
-    let orderDetails1 = this.order_data
725
-    orderDetails1.project_list = project_list
856
+      let orderDetails1 = this.order_data
857
+      orderDetails1.project_list = project_list
726 858
 
727 859
 
728
-      this.order_data=orderDetails1
729
-      this.couponList=CouPonIndex
730
-      this.coupSelectType=this.couponList[selectIndex].type
860
+      this.order_data = orderDetails1
861
+      this.couponList = CouPonIndex
862
+      this.coupSelectType = this.couponList[selectIndex].type
731 863
 
732
-    console.log(this.order_data)
733
-    console.log(this.couponList)
734 864
 
735
-    this.selectCoup()
865
+      this.selectCoup()
736 866
 
737
-  },
867
+    },
738 868
 
739
-// 选择项目进行绑定
740
-  selectCoup() {
741
-    let that = this
742
-    let isSelectCoups = []
743
-    for (let i = 0; i < this.couponList.length; i++) {
744
-      if (this.couponList[i].isSelect) {
745
-        let selectCoup = that.couponList[i]
746
-        isSelectCoups.push(selectCoup)
869
+    // 选择项目进行绑定
870
+    selectCoup () {
871
+      let that = this
872
+      let isSelectCoups = []
873
+      for (let i = 0; i < this.couponList.length; i++) {
874
+        if (this.couponList[i].isSelect) {
875
+          let selectCoup = that.couponList[i]
876
+          isSelectCoups.push(selectCoup)
877
+        }
747 878
       }
748
-    }
749
-      this.isSelectCoup=isSelectCoups
750
-    console.log(this.isSelectCoup)
879
+      this.isSelectCoup = isSelectCoups
751 880
 
752
-    // 抵扣顺序按照项目金额计算
753
-    that.theMoneyBest()
754
-  },
881
+      // 抵扣顺序按照项目金额计算
882
+      that.theMoneyBest()
883
+    },
755 884
 
756
-  // 抵扣顺序按照项目金额计算
757
-  // 卡券,项目券数据包,id:订单项目ID,coupon_id:优惠券ID,如:[{"id":1220,coupon_id:199}]  
758
-  theMoneyBest() {
759
-    let that = this
760
-    let project_list = this.order_data.project_list //这里是项目列表
761
-    let isSelectCoup = this.isSelectCoup //这里选择了的卡券列表
762
-    let selectProjectList = [] // 适合的卡券列表
763
-    // let CouPonIndex = this.CouPonIndex // 卡券选择的Id
764
-    let productDiscount = this.couponList // 卡券列表
765
-    console.log(productDiscount)
766
-    // debugger
767
-    if (isSelectCoup[0].type == 4) {
768
-      for (let i = 0; i < isSelectCoup.length; i++) { // 首先遍历卡券
769
-        if (!isSelectCoup[i].projectids) { // 如果卡券没绑定项目
770
-          console.log('没绑定过!')
885
+    // 抵扣顺序按照项目金额计算
886
+    // 卡券,项目券数据包,id:订单项目ID,coupon_id:优惠券ID,如:[{"id":1220,coupon_id:199}]  
887
+    theMoneyBest () {
888
+      let that = this
889
+      let project_list = this.order_data.project_list //这里是项目列表
890
+      let isSelectCoup = this.isSelectCoup //这里选择了的卡券列表
891
+      let selectProjectList = [] // 适合的卡券列表
892
+      // let CouPonIndex = this.CouPonIndex // 卡券选择的Id
893
+      let productDiscount = this.couponList // 卡券列表
894
+        (productDiscount)
895
+      // debugger
896
+      if (isSelectCoup[0].type == 4) {
897
+        for (let i = 0; i < isSelectCoup.length; i++) { // 首先遍历卡券
898
+          if (!isSelectCoup[i].projectids) { // 如果卡券没绑定项目
771 899
 
772
-          let selectIndexMoney = 0 // 初始值
773
-          let selectIndex = 111 // 初始金额
774
-          for (let j = 0; j < project_list.length; j++) { // 遍历项目
775
-            if (isSelectCoup[i].project_ids.indexOf(project_list[j].id) != -1 && !project_list[j].cardId) { // 如果卡券能够使用这个项目并且这个项目没有被绑定过
776
-              console.log('project_list[j].price')
777
-              console.log(project_list[j].price)
778
-              console.log(selectIndexMoney)
779
-              console.log(project_list[j].price > selectIndexMoney)
780
-              if (project_list[j].price * 1 > selectIndexMoney * 1) {
781
-                selectIndex = j
782
-                selectIndexMoney = project_list[j].price
783
-                console.log('--' + selectIndexMoney)
900
+            let selectIndexMoney = 0 // 初始值
901
+            let selectIndex = 111 // 初始金额
902
+            for (let j = 0; j < project_list.length; j++) { // 遍历项目
903
+              if (isSelectCoup[i].project_ids.indexOf(project_list[j].id) != -1 && !project_list[j].cardId) { // 如果卡券能够使用这个项目并且这个项目没有被绑定过
904
+                if (project_list[j].price * 1 > selectIndexMoney * 1) {
905
+                  selectIndex = j
906
+                  selectIndexMoney = project_list[j].price
907
+                }
908
+                // selectProjectList.push(project_list[i])
784 909
               }
785
-              // selectProjectList.push(project_list[i])
786 910
             }
787
-          }
788
-          if (selectIndex != 111) {
789
-            console.log('走了这里走了这里')
790
-            isSelectCoup[i].projectids = project_list[selectIndex].id
791
-            isSelectCoup[i].projectName = project_list[selectIndex].name
792
-            project_list[selectIndex].cardId = isSelectCoup[i].id
793
-          } else {
794
-            for (let k = 0; k < productDiscount.length; k++) {
795
-              if (productDiscount[k].id == isSelectCoup[i].id) {
796
-                // isSelectCoup.
797
-                productDiscount[k].isSelect = false
798
-                // isSelectCoup.splice(isSelectCoup.length-1,1);
799
-                this.$message.error('没有适合的项目!');
911
+            if (selectIndex != 111) {
912
+              isSelectCoup[i].projectids = project_list[selectIndex].id
913
+              isSelectCoup[i].projectName = project_list[selectIndex].name
914
+              project_list[selectIndex].cardId = isSelectCoup[i].id
915
+            } else {
916
+              for (let k = 0; k < productDiscount.length; k++) {
917
+                if (productDiscount[k].id == isSelectCoup[i].id) {
918
+                  // isSelectCoup.
919
+                  productDiscount[k].isSelect = false
920
+                  // isSelectCoup.splice(isSelectCoup.length-1,1);
921
+                  this.$message.error('没有适合的项目!');
922
+                }
800 923
               }
801 924
             }
802
-          }
803 925
 
926
+          }
804 927
         }
928
+        let orderDetails1 = this.order_data
929
+        orderDetails1.project_list = project_list
930
+        this.couponList = productDiscount
931
+        this.isSelectCoup = isSelectCoup
932
+        this.order_data = orderDetails1
805 933
       }
806
-      let orderDetails1 = this.order_data
807
-      orderDetails1.project_list = project_list
808
-        this.couponList= productDiscount
809
-        this.isSelectCoup= isSelectCoup
810
-        this.order_data= orderDetails1
811
-    }
812 934
 
813
-    this.calculateMoney() //计算总额
814
-  },
935
+      this.calculateMoney() //计算总额
936
+    },
815 937
 
816
-  // 计算总额
817
-  calculateMoney() {
818
-    let that = this
819
-    let money = this.order_data.price
820
-    let isSelectCoup = this.isSelectCoup
821
-    let project_list = this.order_data.project_list //这里是项目列表
938
+    // 计算总额
939
+    calculateMoney () {
940
+      let that = this
941
+      let money = this.order_data.price
942
+      let isSelectCoup = this.isSelectCoup
943
+      let project_list = this.order_data.project_list //这里是项目列表
822 944
 
823
-    if (isSelectCoup.length == 0) {
824
-        this.showMoney=money.toFixed(2)
825
-      return
826
-    }
945
+      if (isSelectCoup.length == 0) {
946
+        this.showMoney = money.toFixed(2)
947
+        return
948
+      }
827 949
 
828
-    // 如果是项目
829
-    if (isSelectCoup[0].type == 4) {
830
-      for (let i = 0; i < project_list.length; i++) {
831
-        if (project_list[i].cardId) {
950
+      // 如果是项目
951
+      if (isSelectCoup[0].type == 4) {
952
+        for (let i = 0; i < project_list.length; i++) {
953
+          if (project_list[i].cardId) {
954
+            money = money - project_list[i].price
955
+          }
956
+        }
957
+        this.showMoney = money.toFixed(2)
958
+      } else if (isSelectCoup[0].type == 3) {
959
+        for (let i = 0; i < project_list.length; i++) {
832 960
           money = money - project_list[i].price
833 961
         }
834
-      }
835
-        this.showMoney=money.toFixed(2)
836
-    } else if (isSelectCoup[0].type == 3) {
837
-      for (let i = 0; i < project_list.length; i++) {
838
-        money = money - project_list[i].price
839
-      }
840 962
 
841
-    } else {
842
-      money = money - isSelectCoup[0].price
843
-    }
963
+      } else {
964
+        money = money - isSelectCoup[0].price
965
+      }
844 966
 
845
-        this.showMoney=money.toFixed(2)
967
+      this.showMoney = money.toFixed(2)
846 968
 
847 969
 
848
-  },
970
+    },
849 971
 
850 972
 
851 973
     changeActive (e) {
@@ -899,6 +1021,11 @@ export default {
899 1021
   mounted () {
900 1022
 
901 1023
   },
1024
+  destroyed () {
1025
+    if (this.payStatusInterval) { //如果定时器在运行则关闭
1026
+      clearInterval(this.payStatusInterval)
1027
+    }
1028
+  }
902 1029
 }
903 1030
 
904 1031
 </script>
@@ -1666,5 +1793,112 @@ export default {
1666 1793
       }
1667 1794
     }
1668 1795
   }
1796
+  .pay-block {
1797
+    width: 540px;
1798
+    height: 400px;
1799
+    background: #ffffff;
1800
+    border-radius: 8px;
1801
+    position: relative;
1802
+    padding: 42px;
1803
+    .delete-pupop {
1804
+      width: 32px;
1805
+      position: absolute;
1806
+      right: 5px;
1807
+      top: 5px;
1808
+      img {
1809
+        width: 100%;
1810
+      }
1811
+    }
1812
+    .pay-title {
1813
+      font-size: 14px;
1814
+      font-family: PingFangSC-Medium, PingFang SC;
1815
+      font-weight: 500;
1816
+      color: #333333;
1817
+      line-height: 20px;
1818
+      text-align: center;
1819
+    }
1820
+    .pay-suc {
1821
+      margin-top: 40px;
1822
+      margin-bottom: 80px;
1823
+      text-align: center;
1824
+      img {
1825
+        width: 140px;
1826
+      }
1827
+    }
1828
+    .pay-price {
1829
+      margin-top: 10px;
1830
+      font-size: 14px;
1831
+      font-family: OPPOSans-B, OPPOSans;
1832
+      font-weight: normal;
1833
+      color: #fa4622;
1834
+      text-align: center;
1835
+      line-height: 31px;
1836
+      span {
1837
+        font-size: 20px;
1838
+      }
1839
+    }
1840
+    .banner {
1841
+      margin-top: 24px;
1842
+      .qrCode {
1843
+        text-align: center;
1844
+      }
1845
+    }
1846
+    .pay-list {
1847
+      width: 338px;
1848
+      margin-top: 8px;
1849
+      position: relative;
1850
+      left: 50%;
1851
+      transform: translateX(-50%);
1852
+      .pay-info {
1853
+        margin-top: 16px;
1854
+        display: flex;
1855
+        justify-content: space-between;
1856
+        align-items: center;
1857
+
1858
+        height: 44px;
1859
+        border-radius: 35px;
1860
+        border: 1px solid #d0d0d0;
1861
+
1862
+        padding: 0 20px;
1863
+        .pay-left {
1864
+          margin-left: 8px;
1865
+          font-size: 16px;
1866
+          font-family: PingFangSC-Regular, PingFang SC;
1867
+          font-weight: 400;
1868
+          color: #333333;
1869
+          line-height: 22px;
1870
+          display: flex;
1871
+          align-items: center;
1872
+          img {
1873
+            width: 24px;
1874
+          }
1875
+          span {
1876
+            margin-left: 20px;
1877
+          }
1878
+        }
1879
+        .pay-right {
1880
+          img {
1881
+            width: 24px;
1882
+          }
1883
+        }
1884
+      }
1885
+    }
1886
+    .pay-button {
1887
+      margin-top: 28px;
1888
+      width: 176px;
1889
+      height: 28px;
1890
+      background: #fa7d22;
1891
+      border-radius: 14px;
1892
+      font-size: 14px;
1893
+      font-family: PingFangSC-Medium, PingFang SC;
1894
+      font-weight: 500;
1895
+      color: #ffffff;
1896
+      line-height: 28px;
1897
+      text-align: center;
1898
+      position: relative;
1899
+      left: 50%;
1900
+      transform: translateX(-50%);
1901
+    }
1902
+  }
1669 1903
 }
1670 1904
 </style>

+ 0 - 6
src/pages/coupon/index.vue

@@ -98,11 +98,9 @@ export default {
98 98
     },
99 99
     handleSelectionChange (val) {
100 100
       this.multipleSelection = val;
101
-      console.log(this.multipleSelection);
102 101
     },
103 102
     // 发送优惠券
104 103
     sendCoupon () {
105
-      console.log(this.coupon);
106 104
       let selectIds = "";
107 105
       for (let i = 0; i < this.multipleSelection.length; i++) {
108 106
         selectIds = selectIds + "," + this.multipleSelection[i].id;
@@ -117,7 +115,6 @@ export default {
117 115
 
118 116
     // 获取订单列表
119 117
     getUserList () {
120
-      console.log("xxxxxxx");
121 118
       let params = {
122 119
         page: this.currentPage1,
123 120
         limit: this.limit,
@@ -133,7 +130,6 @@ export default {
133 130
 
134 131
     // 获取优惠券列表
135 132
     getCouponInfo () {
136
-      console.log("xxxxxxx");
137 133
       let params = {
138 134
         page: this.currentPage1,
139 135
         limit: 100
@@ -148,11 +144,9 @@ export default {
148 144
     handleCurrentChange (e) {
149 145
       this.currentPage1 = e;
150 146
       this.getUserList();
151
-      console.log(e, "eeeeee");
152 147
     },
153 148
 
154 149
     handleSizeChange (val) {
155
-      console.log(`每页 ${val} 条`);
156 150
     }
157 151
   },
158 152
 

+ 0 - 3
src/pages/customerMan/index.vue

@@ -85,7 +85,6 @@ export default {
85 85
 
86 86
     // 获取订单列表
87 87
     getUserList () {
88
-      console.log("xxxxxxx");
89 88
       let params = {
90 89
         page: this.currentPage1,
91 90
         limit: this.limit,
@@ -102,11 +101,9 @@ export default {
102 101
     handleCurrentChange (e) {
103 102
       this.currentPage1 = e;
104 103
       this.getUserList();
105
-      console.log(e, "eeeeee");
106 104
     },
107 105
 
108 106
     handleSizeChange (val) {
109
-      console.log(`每页 ${val} 条`);
110 107
     },
111 108
     handleSelectionChange (row, column, event) {
112 109
       this.$router.push({

+ 108 - 82
src/pages/customerMan/myOrder/index.vue

@@ -4,30 +4,42 @@
4 4
       <el-tabs type="border-card">
5 5
         <el-tab-pane label="项目订单">
6 6
           <div class="user-list">
7
-            <el-table
8
-              ref="multipleTable"
9
-              :data="projectData"
10
-              tooltip-effect="dark"
11
-              height="354"
12
-              style="width: 100%;border-radius: 8px;"
13
-              @row-click="handleSelectionChange"
14
-            >
15
-              <el-table-column prop="goods" label="项目名称" width="200">
7
+            <el-table ref="multipleTable"
8
+                      :data="projectData"
9
+                      tooltip-effect="dark"
10
+                      height="354"
11
+                      style="width: 100%;border-radius: 8px;"
12
+                      @row-click="handleSelectionChange">
13
+              <el-table-column prop="goods"
14
+                               label="项目名称"
15
+                               width="200">
16 16
                 <template slot-scope="scope">
17
-                  <div v-for="(val,index) in scope.row.goods" :key="index">
17
+                  <div v-for="(val,index) in scope.row.goods"
18
+                       :key="index">
18 19
                     <div>{{val.name}}</div>
19 20
                   </div>
20 21
                 </template>
21 22
               </el-table-column>
22
-              <el-table-column prop="goods" label="数量" show-overflow-tooltip>
23
+              <el-table-column prop="goods"
24
+                               label="数量"
25
+                               show-overflow-tooltip>
23 26
                 <template slot-scope="scope">
24 27
                   <div>{{scope.row.goods.length}}</div>
25 28
                 </template>
26 29
               </el-table-column>
27
-              <el-table-column prop="price" label="总价格" show-overflow-tooltip></el-table-column>
28
-              <el-table-column prop="order_time" label="预约时间" width="180" show-overflow-tooltip></el-table-column>
29
-              <el-table-column prop="store_name" label="预约店铺" show-overflow-tooltip></el-table-column>
30
-              <el-table-column prop="status" label="状态" show-overflow-tooltip>
30
+              <el-table-column prop="price"
31
+                               label="总价格"
32
+                               show-overflow-tooltip></el-table-column>
33
+              <el-table-column prop="order_time"
34
+                               label="预约时间"
35
+                               width="180"
36
+                               show-overflow-tooltip></el-table-column>
37
+              <el-table-column prop="store_name"
38
+                               label="预约店铺"
39
+                               show-overflow-tooltip></el-table-column>
40
+              <el-table-column prop="status"
41
+                               label="状态"
42
+                               show-overflow-tooltip>
31 43
                 <template slot-scope="scope">
32 44
                   <div :class="'color'+scope.row.status">{{statusStr[scope.row.status]}}</div>
33 45
                 </template>
@@ -35,41 +47,51 @@
35 47
             </el-table>
36 48
 
37 49
             <div class="pagin">
38
-              <el-pagination
39
-                background
40
-                layout="prev, pager, next"
41
-                @size-change="handleSizeChange"
42
-                @current-change="handleCurrentChange"
43
-                :current-page.sync="currentPage1"
44
-                :total="1000"
45
-              ></el-pagination>
50
+              <el-pagination background
51
+                             layout="prev, pager, next"
52
+                             @size-change="handleSizeChange"
53
+                             @current-change="handleCurrentChange"
54
+                             :current-page.sync="currentPage1"
55
+                             :total="1000"></el-pagination>
46 56
             </div>
47 57
           </div>
48 58
         </el-tab-pane>
49 59
         <el-tab-pane label="卡卷订单">
50 60
           <div class="user-list">
51
-            <el-table
52
-              ref="multipleTable"
53
-              :data="couponData"
54
-              tooltip-effect="dark"
55
-              height="354"
56
-              style="width: 100%;border-radius: 8px;"
57
-              @row-click="handleSelectionChange"
58
-            >
61
+            <el-table ref="multipleTable"
62
+                      :data="couponData"
63
+                      tooltip-effect="dark"
64
+                      height="354"
65
+                      style="width: 100%;border-radius: 8px;"
66
+                      @row-click="handleSelectionChange">
59 67
 
60
-<!-- create_time: "2022-03-10 10:39:19"
68
+              <!-- create_time: "2022-03-10 10:39:19"
61 69
 ex_time: "2022.03.17 23:59"
62 70
 id: 2517
63 71
 name: "新人体验券"
64 72
 status: 2
65 73
 type: "全额券" -->
66 74
 
67
-              <el-table-column prop="name" label="卡卷名称" width="200"></el-table-column>
68
-              <el-table-column prop="type" label="卡卷类型" show-overflow-tooltip></el-table-column>
69
-              <el-table-column prop="price" label="总价格" show-overflow-tooltip></el-table-column>
70
-              <el-table-column prop="create_time" label="到期时间" width="180" show-overflow-tooltip></el-table-column>
71
-              <el-table-column prop="create_time" label="创建时间" width="180" show-overflow-tooltip></el-table-column>
72
-              <el-table-column prop="status" label="状态" show-overflow-tooltip>
75
+              <el-table-column prop="name"
76
+                               label="卡卷名称"
77
+                               width="200"></el-table-column>
78
+              <el-table-column prop="type"
79
+                               label="卡卷类型"
80
+                               show-overflow-tooltip></el-table-column>
81
+              <el-table-column prop="price"
82
+                               label="总价格"
83
+                               show-overflow-tooltip></el-table-column>
84
+              <el-table-column prop="create_time"
85
+                               label="到期时间"
86
+                               width="180"
87
+                               show-overflow-tooltip></el-table-column>
88
+              <el-table-column prop="create_time"
89
+                               label="创建时间"
90
+                               width="180"
91
+                               show-overflow-tooltip></el-table-column>
92
+              <el-table-column prop="status"
93
+                               label="状态"
94
+                               show-overflow-tooltip>
73 95
                 <template slot-scope="scope">
74 96
                   <div :class="'color'+scope.row.status">{{statusStr[scope.row.status]}}</div>
75 97
                 </template>
@@ -77,50 +99,58 @@ type: "全额券" -->
77 99
             </el-table>
78 100
 
79 101
             <div class="pagin">
80
-              <el-pagination
81
-                background
82
-                layout="prev, pager, next"
83
-                @size-change="handleSizeChange"
84
-                @current-change="handleCurrentChange"
85
-                :current-page.sync="currentPage1"
86
-                :total="1000"
87
-              ></el-pagination>
102
+              <el-pagination background
103
+                             layout="prev, pager, next"
104
+                             @size-change="handleSizeChange"
105
+                             @current-change="handleCurrentChange"
106
+                             :current-page.sync="currentPage1"
107
+                             :total="1000"></el-pagination>
88 108
             </div>
89 109
           </div>
90 110
         </el-tab-pane>
91 111
 
92 112
         <el-tab-pane label="商品订单">
93 113
           <div class="user-list">
94
-            <el-table
95
-              ref="multipleTable"
96
-              :data="goodData"
97
-              tooltip-effect="dark"
98
-              height="354"
99
-              style="width: 100%;border-radius: 8px;"
100
-              @row-click="handleSelectionChange"
101
-            >
114
+            <el-table ref="multipleTable"
115
+                      :data="goodData"
116
+                      tooltip-effect="dark"
117
+                      height="354"
118
+                      style="width: 100%;border-radius: 8px;"
119
+                      @row-click="handleSelectionChange">
102 120
 
103
-<!-- create_time: "2022-03-19 22:53:40"
121
+              <!-- create_time: "2022-03-19 22:53:40"
104 122
 goods: [{order_id: 47, name: "润百颜玻尿酸屏障调理面膜", num: 1}]
105 123
 id: 47
106 124
 price: "0.01"
107 125
 status: 5 -->
108 126
 
109
-              <el-table-column prop="goods" label="商品名称" width="200">
127
+              <el-table-column prop="goods"
128
+                               label="商品名称"
129
+                               width="200">
110 130
                 <template slot-scope="scope">
111
-                  <div v-for="(val,index) in scope.row.goods" :key="index">
131
+                  <div v-for="(val,index) in scope.row.goods"
132
+                       :key="index">
112 133
                     <div>{{val.name}}</div>
113 134
                   </div>
114 135
                 </template>
115 136
               </el-table-column>
116
-              <el-table-column prop="goods" label="数量" show-overflow-tooltip>
137
+              <el-table-column prop="goods"
138
+                               label="数量"
139
+                               show-overflow-tooltip>
117 140
                 <template slot-scope="scope">
118 141
                   <div>{{scope.row.goods.length}}</div>
119 142
                 </template>
120 143
               </el-table-column>
121
-              <el-table-column prop="price" label="实付款" show-overflow-tooltip></el-table-column>
122
-              <el-table-column prop="create_time" label="下单时间" width="180" show-overflow-tooltip></el-table-column>
123
-              <el-table-column prop="status" label="状态" show-overflow-tooltip>
144
+              <el-table-column prop="price"
145
+                               label="实付款"
146
+                               show-overflow-tooltip></el-table-column>
147
+              <el-table-column prop="create_time"
148
+                               label="下单时间"
149
+                               width="180"
150
+                               show-overflow-tooltip></el-table-column>
151
+              <el-table-column prop="status"
152
+                               label="状态"
153
+                               show-overflow-tooltip>
124 154
                 <template slot-scope="scope">
125 155
                   <div :class="'classShow'+scope.$index">{{statusStr[scope.row.status]}}</div>
126 156
                 </template>
@@ -128,14 +158,12 @@ status: 5 -->
128 158
             </el-table>
129 159
 
130 160
             <div class="pagin">
131
-              <el-pagination
132
-                background
133
-                layout="prev, pager, next"
134
-                @size-change="handleSizeChange"
135
-                @current-change="handleCurrentChange"
136
-                :current-page.sync="currentPage1"
137
-                :total="1000"
138
-              ></el-pagination>
161
+              <el-pagination background
162
+                             layout="prev, pager, next"
163
+                             @size-change="handleSizeChange"
164
+                             @current-change="handleCurrentChange"
165
+                             :current-page.sync="currentPage1"
166
+                             :total="1000"></el-pagination>
139 167
             </div>
140 168
           </div>
141 169
         </el-tab-pane>
@@ -148,7 +176,7 @@ status: 5 -->
148 176
 import api from "../../../server/home";
149 177
 
150 178
 export default {
151
-  data() {
179
+  data () {
152 180
     return {
153 181
       couponList: [
154 182
         {
@@ -205,7 +233,7 @@ export default {
205 233
 
206 234
   methods: {
207 235
     // 获取优惠券订单
208
-    getUserCoupon() {
236
+    getUserCoupon () {
209 237
       let params = {
210 238
         page: this.currentPage1,
211 239
         limit: this.limit,
@@ -218,7 +246,7 @@ export default {
218 246
     },
219 247
 
220 248
     // 获取商品订单
221
-    getUserGoods() {
249
+    getUserGoods () {
222 250
       let params = {
223 251
         page: this.currentPage1,
224 252
         limit: this.limit,
@@ -231,7 +259,7 @@ export default {
231 259
     },
232 260
 
233 261
     // 获取获取项目订单
234
-    getUserProject() {
262
+    getUserProject () {
235 263
       let params = {
236 264
         page: this.currentPage1,
237 265
         limit: this.limit,
@@ -243,18 +271,16 @@ export default {
243 271
       });
244 272
     },
245 273
 
246
-    handleSizeChange(val) {
247
-      console.log(`每页 ${val} 条`);
274
+    handleSizeChange (val) {
248 275
     },
249
-    handleCurrentChange(val) {
250
-      console.log(`当前页: ${val}`);
276
+    handleCurrentChange (val) {
251 277
     },
252
-    handleSelectionChange(row, column, event) {},
253
-    onSubmit() {},
254
-    submitFrequency() {}
278
+    handleSelectionChange (row, column, event) { },
279
+    onSubmit () { },
280
+    submitFrequency () { }
255 281
   },
256 282
 
257
-  created() {
283
+  created () {
258 284
     let id = this.$route.query.id;
259 285
     this.id = id;
260 286
     this.getUserCoupon();
@@ -262,7 +288,7 @@ export default {
262 288
     this.getUserProject();
263 289
   },
264 290
 
265
-  mounted() {}
291
+  mounted () { }
266 292
 };
267 293
 </script>
268 294
 

+ 65 - 54
src/pages/historicalOrder/index.vue

@@ -1,48 +1,65 @@
1 1
 <template>
2 2
   <div class="mine">
3 3
     <div class="condition">
4
-      <el-date-picker
5
-        v-model="dates"
6
-        type="daterange"
7
-        range-separator="->"
8
-        start-placeholder="开始日期"
9
-        end-placeholder="结束日期"
10
-      ></el-date-picker>
4
+      <el-date-picker v-model="dates"
5
+                      type="daterange"
6
+                      range-separator="->"
7
+                      start-placeholder="开始日期"
8
+                      end-placeholder="结束日期"></el-date-picker>
11 9
 
12
-      <el-input placeholder="请输入项目" class="search" v-model="product">
13
-        <i slot="prefix" class="el-input__icon el-icon-search"></i>
10
+      <el-input placeholder="请输入项目"
11
+                class="search"
12
+                v-model="product">
13
+        <i slot="prefix"
14
+           class="el-input__icon el-icon-search"></i>
14 15
       </el-input>
15 16
 
16
-      <el-input placeholder="请输入优惠券" class="search" v-model="coupon">
17
-        <i slot="prefix" class="el-input__icon el-icon-search"></i>
17
+      <el-input placeholder="请输入优惠券"
18
+                class="search"
19
+                v-model="coupon">
20
+        <i slot="prefix"
21
+           class="el-input__icon el-icon-search"></i>
18 22
       </el-input>
19 23
 
20
-      <el-input placeholder="请输入内容" class="search" v-model="searchText">
21
-        <i slot="prefix" class="el-input__icon el-icon-search"></i>
24
+      <el-input placeholder="请输入内容"
25
+                class="search"
26
+                v-model="searchText">
27
+        <i slot="prefix"
28
+           class="el-input__icon el-icon-search"></i>
22 29
       </el-input>
23
-      <el-button type="primary" class="searchButton" @click="getOrderList()">搜索</el-button>
30
+      <el-button type="primary"
31
+                 class="searchButton"
32
+                 @click="getOrderList()">搜索</el-button>
24 33
     </div>
25 34
 
26 35
     <div class="user-list">
27
-      <el-table
28
-        ref="multipleTable"
29
-        :data="tableData"
30
-        tooltip-effect="dark"
31
-        height="354"
32
-        style="width: 100%;border-radius: 8px;"
33
-        @row-click="handleSelectionChange"
34
-      >
35
-        <el-table-column label="头像" width="120">
36
+      <el-table ref="multipleTable"
37
+                :data="tableData"
38
+                tooltip-effect="dark"
39
+                height="354"
40
+                style="width: 100%;border-radius: 8px;"
41
+                @row-click="handleSelectionChange">
42
+        <el-table-column label="头像"
43
+                         width="120">
36 44
           <template slot-scope="scope">
37 45
             <div class="head-img">
38
-              <img :src="scope.row.avatar_url" alt />
46
+              <img :src="scope.row.avatar_url"
47
+                   alt />
39 48
             </div>
40 49
           </template>
41 50
         </el-table-column>
42
-        <el-table-column prop="nickname" label="昵称" width="120"></el-table-column>
43
-        <el-table-column prop="mobile" label="联系电话" show-overflow-tooltip></el-table-column>
44
-        <el-table-column prop="order_time" label="预约时间" show-overflow-tooltip></el-table-column>
45
-        <el-table-column prop="date" label="状态" show-overflow-tooltip>
51
+        <el-table-column prop="nickname"
52
+                         label="昵称"
53
+                         width="120"></el-table-column>
54
+        <el-table-column prop="mobile"
55
+                         label="联系电话"
56
+                         show-overflow-tooltip></el-table-column>
57
+        <el-table-column prop="order_time"
58
+                         label="预约时间"
59
+                         show-overflow-tooltip></el-table-column>
60
+        <el-table-column prop="date"
61
+                         label="状态"
62
+                         show-overflow-tooltip>
46 63
           <template slot-scope="scope">
47 64
             <div :class="'color'+scope.row.status">{{statusStr[scope.row.status]}}</div>
48 65
           </template>
@@ -50,14 +67,12 @@
50 67
       </el-table>
51 68
 
52 69
       <div class="pagin">
53
-        <el-pagination
54
-          background
55
-          layout="prev, pager, next"
56
-          @size-change="handleSizeChange"
57
-          @current-change="handleCurrentChange"
58
-          :current-page.sync="currentPage1"
59
-          :total="total"
60
-        ></el-pagination>
70
+        <el-pagination background
71
+                       layout="prev, pager, next"
72
+                       @size-change="handleSizeChange"
73
+                       @current-change="handleCurrentChange"
74
+                       :current-page.sync="currentPage1"
75
+                       :total="total"></el-pagination>
61 76
       </div>
62 77
     </div>
63 78
   </div>
@@ -68,15 +83,15 @@ import api from "../../server/home";
68 83
 
69 84
 export default {
70 85
   components: {},
71
-  data() {
86
+  data () {
72 87
     return {
73 88
       searchText: "",
74 89
       dates: "",
75 90
       coupon: "",
76 91
       limit: 10,
77 92
       total: 0,
78
-      product:"",
79
-      coupon:"",
93
+      product: "",
94
+      coupon: "",
80 95
       statusStr: [
81 96
         "已预约",
82 97
         "未支付",
@@ -123,21 +138,19 @@ export default {
123 138
 
124 139
   methods: {
125 140
     // 获取订单列表
126
-    getOrderList() {
127
-      console.log("xxxxxxx");
141
+    getOrderList () {
128 142
       let start_date = "",
129 143
         end_date = "";
130 144
       if (this.dates && this.dates.length > 0) {
131 145
         start_date = utils.formatTime(this.dates[0], "yyyy-MM-dd");
132 146
         end_date = utils.formatTime(this.dates[1], "yyyy-MM-dd");
133 147
       }
134
-      console.log(start_date, end_date, "end_date");
135 148
       let params = {
136 149
         page: this.currentPage1,
137 150
         limit: this.limit,
138 151
         keywords: this.searchText,
139
-        project_name:this.product,
140
-        coupon_name:this.coupon,
152
+        project_name: this.product,
153
+        coupon_name: this.coupon,
141 154
         start_date: start_date,
142 155
         end_date: end_date
143 156
       };
@@ -148,17 +161,15 @@ export default {
148 161
         }
149 162
       });
150 163
     },
151
-    
152
-    handleCurrentChange(e) {
164
+
165
+    handleCurrentChange (e) {
153 166
       this.currentPage1 = e;
154 167
       this.getOrderList();
155
-      console.log(e, "eeeeee");
156 168
     },
157 169
 
158
-    handleSizeChange(val) {
159
-      console.log(`每页 ${val} 条`);
170
+    handleSizeChange (val) {
160 171
     },
161
-    handleSelectionChange(row, column, event) {
172
+    handleSelectionChange (row, column, event) {
162 173
       this.$router.push({
163 174
         path: "/historicalOrder/details",
164 175
         query: {
@@ -168,11 +179,11 @@ export default {
168 179
     }
169 180
   },
170 181
 
171
-  created() {
182
+  created () {
172 183
     this.getOrderList();
173 184
   },
174 185
 
175
-  mounted() {}
186
+  mounted () { }
176 187
 };
177 188
 </script>
178 189
 
@@ -242,7 +253,7 @@ export default {
242 253
     color: #00eeee;
243 254
   }
244 255
   .color3 {
245
-    color: #61D09D;
256
+    color: #61d09d;
246 257
   }
247 258
   .color4 {
248 259
     color: #3115cc;
@@ -251,7 +262,7 @@ export default {
251 262
     color: #fc3019;
252 263
   }
253 264
   .color6 {
254
-    color: #A999EA;
265
+    color: #a999ea;
255 266
   }
256 267
 }
257 268
 </style>

+ 54 - 39
src/pages/home/index.vue

@@ -15,44 +15,51 @@
15 15
     </div>
16 16
     <div class="order-list">
17 17
       <div class="title">预约订单列表</div>
18
-      <div v-if="orderList.length>0"
19
-           class="list-info">
20
-        <div class="user-info"
21
-             v-for="(item,index) in orderList"
22
-             :key="index"
23
-             @click="toOrderDetails(item)"
24
-             :style="index==orderList.length-1?'border-bottom:0px':''">
25
-          <div class="head-img">
26
-            <div class="new">新</div><img :src="item.avatar_url"
27
-                 alt="">
28
-          </div>
29
-          <div class="user-information">
30
-            <div class="name">客户昵称:<span>{{ item.nickname }}</span></div>
31
-            <div class="name">预约项目时间:<span>{{ item.order_time }}</span></div>
32
-            <div class="name">预约项目数量:<span>{{ item.project_num }}</span></div>
33
-          </div>
34
-          <ul class="product-list">
35
-            <li class="product-image"
36
-                v-for="value,i in item.project_list"
37
-                :key="i"><img :src="value.cover_url"
38
-                   alt=""></li>
39
-          </ul>
40
-          <div class="status"
41
-               :style="item.status==0?'color: #FC3019':item.status==5?'color: #A999EA':'color: #61D09D;'">
42
-            {{ item.status==0?'未支付':item.status==5?'已取消':'待使用' }}
18
+      <div class="list-info">
19
+        <van-list v-model="loading"
20
+                  :finished="finished"
21
+                  finished-text="没有更多了"
22
+                  @load=" getToday ">
23
+
24
+          <div class="user-info"
25
+               v-for="(item,index) in orderList"
26
+               :key="index"
27
+               @click="toOrderDetails(item)"
28
+               :style="index==orderList.length-1?'border-bottom:0px':''">
29
+            <div class="head-img">
30
+              <div class="new">新</div><img :src="item.avatar_url"
31
+                   alt="">
32
+            </div>
33
+            <div class="user-information">
34
+              <div class="name">客户昵称:<span>{{ item.nickname }}</span></div>
35
+              <div class="name">预约项目时间:<span>{{ item.order_time }}</span></div>
36
+              <div class="name">预约项目数量:<span>{{ item.project_num }}</span></div>
37
+            </div>
38
+            <ul class="product-list">
39
+              <li class="product-image"
40
+                  v-for="value,i in item.project_list"
41
+                  :key="i"><img :src="value.cover_url"
42
+                     alt=""></li>
43
+            </ul>
44
+            <div class="status"
45
+                 :style="item.status==0?'color: #FC3019':item.status==5?'color: #A999EA':'color: #61D09D;'">
46
+              {{ item.status==0?'未支付':item.status==5?'已取消':'待使用' }}
47
+            </div>
43 48
           </div>
44
-        </div>
49
+        </van-list>
45 50
       </div>
46
-      <div v-else
51
+      <!-- <div v-else
47 52
            class="empty">
48 53
         暂无数据
49
-      </div>
54
+      </div> -->
50 55
     </div>
51 56
   </div>
52 57
 </template>
53 58
 
54 59
 <script>
55 60
 import api from '@/server/home'
61
+import vanList from 'vant/lib/list';
62
+import 'vant/lib/list/style';
56 63
 
57 64
 export default {
58 65
   name: 'home',
@@ -77,16 +84,20 @@ export default {
77 84
       ],
78 85
       orderList: [
79 86
       ],
87
+      loading: false,
88
+      finished: false,
89
+      page: 1,
90
+      limit: 10
80 91
 
81 92
     }
82 93
   },
94
+  components: { vanList },
83 95
   mounted: function () {
84 96
 
85 97
   },
86 98
   created: function () {
87 99
     this.getTotal()
88
-    this.getToday()
89
-    console.log(this.$store.state.comVal.token, 'this.$store.state.comVal.token');
100
+    // this.getToday()
90 101
   },
91 102
   methods: {
92 103
     getTotal () {
@@ -96,19 +107,24 @@ export default {
96 107
           this.tabList[1].num = res.data.wait_pay_num
97 108
           this.tabList[2].num = res.data.cancel_num
98 109
         }
99
-        console.log(res, 'res====');
100 110
       })
101 111
     },
102 112
     getToday () {
103
-      api.getToday().then(res => {
104
-        if (res.code = 200) {
105
-          this.orderList = res.data.list
106
-        }
107
-        console.log(res, 'res');
108
-      })
113
+      setTimeout(() => {
114
+        api.getToday({ page: this.page, limit: this.limit }).then(res => {
115
+          if (res.code = 200) {
116
+            this.orderList = [...this.orderList, ...res.data.list]
117
+            this.page++
118
+            this.loading = false;
119
+            if (this.orderList.length >= res.data.total) {
120
+              this.finished = true;
121
+            }
122
+          }
123
+        })
124
+      }, 1000);
125
+
109 126
     },
110 127
     toOrderDetails (e) {
111
-      console.log(e);
112 128
       if (e.status != 0) return
113 129
       this.$router.push({
114 130
         path: '/confirmOrder/details',
@@ -231,7 +247,6 @@ export default {
231 247
         .user-information {
232 248
           margin-left: 16px;
233 249
           text-align: left;
234
-          min-width: 260px;
235 250
           font-size: 14px;
236 251
           font-family: SourceHanSansCN-Regular, SourceHanSansCN;
237 252
           font-weight: 400;

+ 0 - 1
src/pages/login/login.vue

@@ -53,7 +53,6 @@ export default {
53 53
       api.getToken(params).then(res => {
54 54
         if (res.code == 200) {
55 55
           this.$store.state.comVal.token = res.data.token
56
-          console.log(this.$store.state.comVal.token, 'this.$store.');
57 56
           localStorage.setItem("token", res.data.token)
58 57
           this.$router.push({
59 58
             path: '/home'

+ 0 - 2
src/pages/testSkin/index.vue

@@ -76,7 +76,6 @@ export default {
76 76
         start_date = utils.formatTime(this.dates[0], 'yyyy-MM-dd')
77 77
         end_date = utils.formatTime(this.dates[1], 'yyyy-MM-dd')
78 78
       }
79
-      console.log(start_date, end_date, 'end_date');
80 79
       let params = {
81 80
         page: this.currentPage1,
82 81
         limit: this.limit,
@@ -102,7 +101,6 @@ export default {
102 101
     handleCurrentChange (e) {
103 102
       this.currentPage1 = e
104 103
       this.getSkinList
105
-      console.log(e, 'eeeeee');
106 104
     }
107 105
   },
108 106
 

+ 7 - 1
src/server/home.js

@@ -60,6 +60,12 @@ export default class Home {
60 60
   static getOrderByCode (parms) {
61 61
     return $http.get(url.getOrderByCode, parms);
62 62
   }
63
+  static orderPay (parms) {
64
+    return $http.post(url.orderPay, parms);
65
+  }
66
+  static payStatus (parms) {
67
+    return $http.get(url.payStatus, parms);
68
+  }
63 69
 
64 70
   // 获取历史订单
65 71
   static getOrderList (parms) {
@@ -95,7 +101,7 @@ export default class Home {
95 101
   static getPadUserInfo (parms) {
96 102
     return $http.get(url.getPadUserInfo, parms);
97 103
   }
98
-  
104
+
99 105
   // 获取优惠券订单
100 106
   static getUserCoupon (parms) {
101 107
     return $http.get(url.getUserCoupon, parms);

+ 4 - 0
src/server/urls.js

@@ -33,6 +33,10 @@ export default {
33 33
   checkCode: '/v2/pad/order/check_code',
34 34
   //通过授权码获取未支付订单
35 35
   getOrderByCode: '/v2/pad/order/get_order_by_code',
36
+  //支付
37
+  orderPay: '/v2/pad/order/pay',
38
+  //支付状态
39
+  payStatus: '/v2/pad/order/pay_status',
36 40
 
37 41
   /**
38 42
    *  by ListKer