Procházet zdrojové kódy

座位预定-创建订单

panyong před 3 roky
rodič
revize
66960bcddb

+ 1 - 0
htmldev/dashboard/src/api/request.js

@@ -33,6 +33,7 @@ request.interceptors.request.use(request => {
   request.url = requestUrl + (requestUrl.indexOf('?') > -1 ? '&' : '?') + 'nextUrl=' + encodeURIComponent(location.href)
   // 因为微信开发者工具重复授权,本地开发时写死
   if (/^(0|192|10|localhost)|(test$)/.test(domain)) {
+    // request.url += '&owner_open_id=0c540a8d284b38f84d2f8ad262ab5d2c'
     request.headers.wechatToken = '0c540a8d284b38f84d2f8ad262ab5d2c'
   }
   return request

+ 2 - 2
htmldev/dashboard/src/login/index.vue

@@ -149,7 +149,7 @@ export default {
       return this.arrErrorList.length <= 0
     },
     async funSubmit () {
-      const { phone, code, msg } = this.postData
+      const { phone, code } = this.postData
       if (!this.verifyData()) {
         Toast({
           message: this.arrErrorList[0],
@@ -163,7 +163,7 @@ export default {
         forbidClick: true
       })
       try {
-        const { status, data } = await login(phone, code)
+        const { status, data, msg } = await login(phone, code)
         myToast.clear()
         if (status) {
           const { token } = data

+ 6 - 2
htmldev/dashboard/src/views/place/check/index.vue

@@ -45,6 +45,10 @@ export default {
   methods: {
     createQRCode () {
       const orderNumber = this.objPlaceCheck.order_number
+      const codeText = JSON.stringify({
+        type: 1,
+        place_number: orderNumber
+      })
       if (!orderNumber) {
         Dialog.alert({
           title: '提示',
@@ -59,13 +63,13 @@ export default {
         this.qrcode = new QRCode('af-qrcode', {
           width: 140,
           height: 140,
-          text: orderNumber,
+          text: codeText,
           colorDark: '#000',
           colorLight: '#fff'
         })
       } else {
         this.qrcode.clear()
-        this.qrcode.makeCode(orderNumber)
+        this.qrcode.makeCode(codeText)
       }
       this.codeUrl = ''
       setTimeout(() => {

+ 8 - 2
htmldev/dashboard/src/views/place/list/index.vue

@@ -43,7 +43,10 @@
           <div class="right"
                v-if="place.place_num - place.place_pre_num > 0">
             <!--place_pre_type:座位预定类型(0整桌预定1座位预定) 整桌预定价格不变,座位预定价格由人数*价格-->
-            <p class="price">¥ {{ place.place_price | fen2Yuan }}{{ place.place_pre_type === 1 ? '起' : ''}}</p>
+            <p class="price">
+              <span>¥ {{ place.place_price | fen2Yuan }}</span>
+              <span>{{ place.place_pre_type === 1 ? '起' : ''}}</span>
+            </p>
             <p class="btn-wrap">
               <span class="btn">立即预订</span>
               <van-icon name="arrow" size="12px"/>
@@ -53,7 +56,10 @@
           <div class="sell-out" v-else>
             <img src="./image/sell_out@2x.png" alt="">
             <div>
-              <p class="price disabled">¥ {{ place.place_price }}{{ place.place_pre_type === 1 ? '起' : ''}}</p>
+              <p class="price disabled">
+                <span>¥ {{ place.place_price }}</span>
+                <span>{{ place.place_pre_type === 1 ? '起' : ''}}</span>
+              </p>
               <p class="sell-des">已订满</p>
             </div>
           </div>

+ 18 - 26
htmldev/dashboard/src/views/place/list/style/index.scss

@@ -55,7 +55,6 @@
       font-weight: 600;
       color: #1F1E1E;
       line-height: 25px;
-      letter-spacing: 1px;
     }
   }
 
@@ -80,7 +79,6 @@
       font-weight: 400;
       color: #FFFFFF;
       line-height: 20px;
-      letter-spacing: 1px;
     }
   }
 }
@@ -99,7 +97,6 @@
     font-weight: 600;
     color: #FFFFFF;
     line-height: 25px;
-    letter-spacing: 1px;
   }
 
   .date {
@@ -109,7 +106,6 @@
     font-weight: 600;
     color: #FFFFFF;
     line-height: 17px;
-    letter-spacing: 1px;
   }
 
   ::v-deep .van-tabs__wrap {
@@ -162,10 +158,9 @@
   .name {
     font-size: 18px;
     font-family: PingFangSC-Semibold, PingFang SC;
-    font-weight: 600;
+    font-weight: 700;
     color: #1F1E1E;
     line-height: 25px;
-    letter-spacing: 1px;
   }
 
   .des {
@@ -174,16 +169,28 @@
     font-size: 12px;
     color: #736F6F;
     line-height: 17px;
-    letter-spacing: 1px;
     word-break: break-all;
   }
 
   .price {
-    font-size: 24px;
-    font-weight: bold;
+    display: flex;
+    justify-content: flex-end;
+    align-items: flex-end;
     color: #D32323;
-    line-height: 28px;
-    letter-spacing: 1px;
+
+    span {
+      &:nth-of-type(1) {
+        font-size: 24px;
+        font-weight: bold;
+        line-height: 28px;
+      }
+
+      &:nth-of-type(2) {
+        font-size: 16px;
+        font-weight: bold;
+        line-height: 26px;
+      }
+    }
 
     &.disabled {
       color: #CCC6C6;
@@ -201,7 +208,6 @@
     font-size: 12px;
     color: #1F1E1E;
     line-height: 17px;
-    letter-spacing: 1px;
     margin-right: 4px;
   }
 
@@ -232,7 +238,6 @@
       font-size: 12px;
       color: #D32323;
       line-height: 17px;
-      letter-spacing: 1px;
       text-align: right;
     }
   }
@@ -274,7 +279,6 @@
     font-weight: 600;
     color: #1F1E1E;
     line-height: 20px;
-    letter-spacing: 1px;
     background: url("./image/icon_juxing@2x.png") center center/100% 100% no-repeat;
   }
 
@@ -292,7 +296,6 @@
     font-weight: 600;
     color: #FFFFFF;
     line-height: 33px;
-    letter-spacing: 1px;
   }
 
   .place-name {
@@ -302,7 +305,6 @@
     font-size: 14px;
     color: #FFFFFF;
     line-height: 20px;
-    letter-spacing: 1px;
     background: url("./image/logo_0@2x.png") left top/100% 100% no-repeat;
   }
 }
@@ -324,14 +326,12 @@
         font-size: 14px;
         color: #736F6F;
         line-height: 20px;
-        letter-spacing: 1px;
       }
 
       &:nth-of-type(2) {
         font-size: 14px;
         color: #CCC6C6;
         line-height: 20px;
-        letter-spacing: 1px;
       }
     }
   }
@@ -343,7 +343,6 @@
     font-weight: 600;
     color: #1F1E1E;
     line-height: 33px;
-    letter-spacing: 1px;
   }
 }
 
@@ -357,7 +356,6 @@
   font-size: 14px;
   color: #736F6F;
   line-height: 20px;
-  letter-spacing: 1px;
 }
 
 .people-options {
@@ -379,7 +377,6 @@
     font-size: 16px;
     color: #736F6F;
     line-height: 22px;
-    letter-spacing: 1px;
 
     &:nth-of-type(4n+1) {
       margin-left: 0;
@@ -401,7 +398,6 @@
       font-size: 16px;
       color: #736F6F;
       line-height: 22px;
-      letter-spacing: 1px;
     }
   }
 
@@ -418,7 +414,6 @@
       opacity: 1;
       background: transparent;
       box-shadow: inset 0 0 0 1000px #F7F7F7 !important;
-      letter-spacing: 1px;
 
       &::-webkit-input-placeholder {
         -webkit-text-fill-color: #ccc;
@@ -473,7 +468,6 @@
   font-size: 12px;
   color: #736F6F;
   line-height: 18px;
-  letter-spacing: 1px;
 }
 
 .payment-type {
@@ -558,7 +552,6 @@
     span {
       font-family: PingFangSC-Semibold, PingFang SC;
       font-weight: 600;
-      letter-spacing: 1px;
 
       &:nth-of-type(1) {
         font-size: 16px;
@@ -585,7 +578,6 @@
     font-weight: 600;
     color: #FFFFFF;
     line-height: 50px;
-    letter-spacing: 1px;
     text-align: center;
   }
 }

+ 8 - 0
htmldev/dashboard/src/views/place/reserve/index.vue

@@ -31,6 +31,7 @@
                 <img src="./image/ic_WeChat_nor@2x.png" alt="" v-show="item.order_pay_type === 1">
               </p>
             </div>
+            <p class="create-at">订单创建时间:{{ item.created_at }}</p>
             <div class="btn-wrap">
               <van-button
                 class="pay"
@@ -260,6 +261,13 @@ ul {
   }
 }
 
+.create-at {
+  margin-top: 12px;
+  font-size: 14px;
+  color: #736F6F;
+  line-height: 20px;
+}
+
 .btn-wrap {
   text-align: right;