Pārlūkot izejas kodu

续期与购买

shish 8 mēneši atpakaļ
vecāks
revīzija
0f6fd7ad6c

+ 9 - 4
ghsApp/src/admin/shop/renew.vue

@@ -94,7 +94,6 @@ export default {
                 that.hasRenew = res.data.hasRenew ? res.data.hasRenew : 0
                 that.hasRenew = res.data.hasRenew ? res.data.hasRenew : 0
                 that.currentDeadline = res.data.currentDeadline
                 that.currentDeadline = res.data.currentDeadline
                 that.newDeadline = res.data.newDeadline
                 that.newDeadline = res.data.newDeadline
-                that.renewType = res.data.renewType?res.data.renewType:0
             }
             }
         })
         })
     },
     },
@@ -106,13 +105,20 @@ export default {
 
 
         },
         },
 		startRenew(type,price){
 		startRenew(type,price){
-            // #ifdef APP-PLUS
             let that = this
             let that = this
+            // #ifdef APP-PLUS
             let type = uni.getSystemInfoSync().platform
             let type = uni.getSystemInfoSync().platform
             that.$msg("APP不能操作,请打开微信小程序操作")
             that.$msg("APP不能操作,请打开微信小程序操作")
             // #endif
             // #endif
             // #ifdef MP-WEIXIN
             // #ifdef MP-WEIXIN
             uni.showLoading({mask:true})
             uni.showLoading({mask:true})
+            if(type == 1){
+                if(Number(price) <= 0){
+                    that.$msg("请输入金额")
+                    return false
+                }
+            }
+            this.renewType = type
             renewShop({price:price,type:type}).then(res=>{
             renewShop({price:price,type:type}).then(res=>{
                 uni.hideLoading()
                 uni.hideLoading()
                 if(res.code == 1){
                 if(res.code == 1){
@@ -122,10 +128,9 @@ export default {
             // #endif
             // #endif
         },
         },
 		getSuccess(){
 		getSuccess(){
-			this.$util.pageTo({url:"/admin/shop/renewSuccess",type:2})
+			this.$util.pageTo({url:"/admin/shop/renewSuccess?type="+this.renewType,type:2})
 		},
 		},
 		getError(){
 		getError(){
-
         },
         },
         closeRenew(){
         closeRenew(){
             uni.navigateBack()
             uni.navigateBack()

+ 5 - 3
ghsApp/src/admin/shop/renewSuccess.vue

@@ -4,8 +4,8 @@
         <view class="top-view"> </view>
         <view class="top-view"> </view>
         <view class="result-view">
         <view class="result-view">
           <view :class="['iconfont', 'iconchenggong']"></view>
           <view :class="['iconfont', 'iconchenggong']"></view>
-          <view class="result-title">续期成功</view>
-          <view class="result-title">已延长到:{{ deadline?deadline.substr(0,10):'' }}</view>
+          <view class="result-title">支付成功</view>
+          <view class="result-title" v-if="type == 0">已延长到:{{ deadline?deadline.substr(0,10):'' }}</view>
           <button class="admin-button-com big" style="width:45vw;margin-top:20upx;" @click="goBack">返回</button>
           <button class="admin-button-com big" style="width:45vw;margin-top:20upx;" @click="goBack">返回</button>
         </view>
         </view>
       </view>
       </view>
@@ -18,10 +18,12 @@
     name: "renewSuccess",
     name: "renewSuccess",
     data() {
     data() {
       return {
       return {
-        deadline:''
+        deadline:'',
+        type:0
       }
       }
     },
     },
     onLoad () {
     onLoad () {
+      this.type = this.option.type?this.option.type:0
     },
     },
     methods: {
     methods: {
       goBack(){
       goBack(){

+ 1 - 1
ghsApp/src/pages.json

@@ -222,7 +222,7 @@
 				{"path": "selectShop","style": {"navigationBarTitleText": "选择门店"}},
 				{"path": "selectShop","style": {"navigationBarTitleText": "选择门店"}},
 				{"path": "wl","style": {"navigationBarTitleText": "物流列表"}},
 				{"path": "wl","style": {"navigationBarTitleText": "物流列表"}},
 				{"path": "myShop","style": {"navigationBarTitleText": "我的门店"}},
 				{"path": "myShop","style": {"navigationBarTitleText": "我的门店"}},
-				{"path": "renew","style": {"navigationBarTitleText": "续期"}},
+				{"path": "renew","style": {"navigationBarTitleText": "续期与购买"}},
 				{"path": "expressSet","style": {"navigationBarTitleText": "跑腿设置"}}
 				{"path": "expressSet","style": {"navigationBarTitleText": "跑腿设置"}}
 			]
 			]
 		},
 		},

+ 1 - 1
ghsApp/src/pagesPurchase/components/pageSuccess.vue

@@ -14,7 +14,7 @@
 						<view class="flex title" v-if="info.status == 3"> 入库前请确认售价: </view>
 						<view class="flex title" v-if="info.status == 3"> 入库前请确认售价: </view>
 						<view class="flex title" v-else> 确认售价: </view>
 						<view class="flex title" v-else> 确认售价: </view>
 						<view class="flex title">
 						<view class="flex title">
-							<text style="font-size:22upx;font-weight:normal;color:#CCCCCC;">
+							<text style="font-size:24upx;font-weight:normal;color:#CCCCCC;">
 								<text style="color:black;font-weight:bold;margin:0 3upx 0 0;">花材名称</text>/
 								<text style="color:black;font-weight:bold;margin:0 3upx 0 0;">花材名称</text>/
 								<text style="color:red;font-weight:normal;margin:0 3upx 0 3upx;">进价</text>/
 								<text style="color:red;font-weight:normal;margin:0 3upx 0 3upx;">进价</text>/
 								<text style="color:black;font-weight:normal;margin:0 3upx 0 3upx;">本次成本</text>/
 								<text style="color:black;font-weight:normal;margin:0 3upx 0 3upx;">本次成本</text>/