Kaynağa Gözat

优化与修复

lighter 1 yıl önce
ebeveyn
işleme
daa42b71d9

+ 1 - 1
src/router/index.js

@@ -124,7 +124,7 @@ export const constantRoutes = [
     meta: { title: '医保结算' },
   },
   {
-    path: '/unPaidDetail/:patientId/:hisOrdNum/:patName/:deptName/:doctorName/:totalAmt/:selfAmt/:fundPay?/:acctPay?',
+    path: '/unPaidDetail/:patientId/:hisOrdNum/:patName/:deptName/:doctorCode/:doctorName/:totalAmt/:selfAmt/:fundPay?/:acctPay?',
     name: 'unPaidDetail',
     component: () => import('../views/hospital-service/pay-mz-fee/UnPaidDetail.vue'),
     meta: { title: '待缴费详情' },

+ 1 - 5
src/utils/wx-pay.js

@@ -20,11 +20,7 @@ export function wxPay(param) {
         },
         function () {
           queryOrderState(res.tradeNo).then((response) => {
-            if (response instanceof Object && response.tradeNo) {
-              resolve(response)
-            } else {
-              reject(response)
-            }
+            resolve(response)
           })
         }
       )

+ 0 - 6
src/views/hospital-service/appointment/PayAppointmentFee.vue

@@ -71,12 +71,6 @@ const pay = () => {
       position: 'top'
     })
     router.push('/hospitalService');
-  }).catch((result) => {
-    showToast({
-      message: result,
-      position: 'top'
-    })
-    router.push('/hospitalService')
   })
 }
 </script>

+ 0 - 6
src/views/hospital-service/appointment/PayClinicAppointmentOrder.vue

@@ -79,12 +79,6 @@ export default {
           position: 'top',
         });
         router.push('/hospitalService')
-      }).catch((result) => {
-        showToast({
-          message: result,
-          position: 'top',
-        });
-        router.push('/hospitalService')
       })
     }
 

+ 6 - 14
src/views/hospital-service/inpatient-service/DisplayPrepaid.vue

@@ -112,21 +112,13 @@ export default {
         inpatientNo: params.inpatientNo,
         admissTimes: params.admissTimes,
       }
-      wxPay(param)
-        .then((result) => {
-          showToast({
-            message: result,
-            position: 'top'
-          })
-          router.push('/hospitalService')
-        })
-        .catch((result) => {
-          showToast({
-            message: result,
-            position: 'top'
-          })
-          router.push('/hospitalService')
+      wxPay(param).then((result) => {
+        showToast({
+          message: result,
+          position: 'top'
         })
+        router.push('/hospitalService')
+      })
     }
     return {
       params,

+ 16 - 32
src/views/hospital-service/pay-mz-fee/UnPaidDetail.vue

@@ -50,23 +50,6 @@
     <div style="height: 10px"></div>
     <van-button block type="primary" @click="wechatPay">微信支付(¥ {{ makePrice(params.selfAmt) }})</van-button>
 
-    <van-dialog
-        v-model:show="showBillInfo"
-        title="缴费成功提醒"
-        show-confirm-button
-        :show-cancel-button="false"
-        @closed="router.push('/hospitalService')"
-    >
-      <div style="height: 12px"></div>
-      <van-cell title="用户姓名" :value="params.patName"/>
-      <van-cell title="订单号" :value="params.hisOrdNum"/>
-      <van-cell title="缴费金额" :value="makePrice(params.selfAmt)"/>
-      <van-cell title="医生" :value="params.doctorName"/>
-      <van-cell title="科室" :value="params.deptName"/>
-      <van-cell title="医院" value="长沙泰和医院"/>
-      <van-cell title="缴费时间" :value="params.paytime"/>
-    </van-dialog>
-
     <van-dialog
         v-model:show="showRate"
         title="您的评价是我们前进的动力"
@@ -113,7 +96,6 @@ import {commitNewComment} from "../../../api/comment";
 const router = useRouter()
 const params = router.currentRoute.value.params
 const fees = ref([])
-const showBillInfo = ref(false)
 const showRate = ref(false)
 const comment = reactive({
   commentLevel: 5,
@@ -164,20 +146,22 @@ const wechatPay = () => {
     hisOrdNum: params.hisOrdNum,
     yjReqNo: store.state.yjReqNo,
   }
-  wxPay(param).then((result) => {
-    params.paytime = result.payDatetime
-    showBillInfo.value = true
-  }).catch((result) => {
-    showToast({
-      message: result,
-      position: 'top',
-    });
-    if (params.doctorCode === '99999') {
-      router.push('/hospitalService')
-    } else {
-      showRate.value = true
-    }
-  })
+  if (params.doctorCode === '99999') {
+    router.push('/hospitalService')
+  } else {
+    showRate.value = true
+  }
+  // wxPay(param).then((result) => {
+  //   showToast({
+  //     message: result,
+  //     position: 'top',
+  //   });
+  //   if (params.doctorCode === '99999') {
+  //     router.push('/hospitalService')
+  //   } else {
+  //     showRate.value = true
+  //   }
+  // })
 }
 onMounted(() => {
   getUnPaidDetail(params.patientId, params.hisOrdNum).then((res) => {