shish 3 سال پیش
والد
کامیت
607719ea4c
3فایلهای تغییر یافته به همراه21 افزوده شده و 7 حذف شده
  1. 12 2
      ghsApp/src/pagesOrder/refundDetail.vue
  2. 2 2
      hdApp/src/pagesPurchase/purDetails.vue
  3. 7 3
      hdApp/src/pagesPurchase/refund.vue

+ 12 - 2
ghsApp/src/pagesOrder/refundDetail.vue

@@ -120,12 +120,22 @@ export default {
 				passRefund({id: this.option.id}).then(res=>{
 					uni.hideLoading()
 					if(res.code == 1){
-						that.$msg('操作成功')
-						that.init()
+						if(res.data.error && res.data.error == 'hasUnClearOrder'){
+							that.needCancelRemind(res.data.clearId)
+						}else{
+							that.$msg('操作成功')
+							that.init()
+						}
 					}
 				})
 			})
 		},
+		needCancelRemind(id){
+			let that = this
+			that.$util.confirmModal({content:'有结账单取消了才能审核?',okText:'去取消',cancelText:'不操作'},() => {
+				that.$util.pageTo({url: '/admin/clear/customInfo?id='+id})
+			})
+		},
 		showBig(index){
 			if(this.info.bigImgList && !this.$util.isEmpty(this.info.bigImgList)){
 				if(this.info.bigImgList[index]){

+ 2 - 2
hdApp/src/pagesPurchase/purDetails.vue

@@ -132,11 +132,11 @@
           <view>本单赊账:</view>
           <view v-if="detailInfo.clearId > 0" style="font-weight:bold;color:#3385FF;font-size:29upx;">已结清</view>
           <view class="price" v-if="detailInfo.clearId > 0">
-            <button style="padding:20upx 15upx;" @click="pageTo({url: '/admin/clear/info',query: {id: detailInfo.clearId}})" class="admin-button-com">查看账单</button>
+            <button style="padding:20upx 15upx;" @click="pageTo({url: '/admin/clear/info',query: {id: detailInfo.clearId}})" class="admin-button-com">查看账单</button>
           </view>
         </view>
         <view class="order-info_box" style="margin-top:35upx;" v-if="Number(detailInfo.debtAmount)>0">
-          <view>累计赊账:</view>
+          <view>总共赊账:</view>
           <view style="font-weight:bold;color:red;font-size:29upx;">¥{{detailInfo.debtAmount?parseFloat(detailInfo.debtAmount):0}}</view>
           <view class="price" v-if="loginStyle != 0">
             <button @click="goToSettle(detailInfo)" class="admin-button-com" style="padding:20upx 15upx;">

+ 7 - 3
hdApp/src/pagesPurchase/refund.vue

@@ -73,7 +73,8 @@
 			<view class="flex refund-item">
 				<view class="refund-label">审核结果:</view>
 				<view class="list">
-					<button class="admin-button-com big default" @click="noticeMe()">点我开启通知</button>
+					<button class="admin-button-com big default" @click="noticeMe()" v-if="needNotice == 0">点我开启通知</button>
+					<button class="admin-button-com big blue" v-else>已经开启通知</button>
 				</view>
 			</view>
 			<!-- #endif -->
@@ -109,7 +110,8 @@ export default {
 			unClear:[],
 			refundImgData:[],
 			uploadRefundImg:[],
-			headers:{token:''}
+			headers:{token:''},
+			needNotice:0
 		};
 	},
 	onLoad() {
@@ -145,7 +147,9 @@ export default {
 				uni.requestSubscribeMessage({
 					tmplIds: [this.getDictionariesInfo.hdMiniMessage.afterSale.msgId],
 					success(res) {
-						console.log(res)
+						if(res[that.getDictionariesInfo.hdMiniMessage.afterSale.msgId] && res[that.getDictionariesInfo.hdMiniMessage.afterSale.msgId] == 'accept'){
+							that.needNotice = 1
+						}
 					},
 					fail(err) {
 						console.log(err)