diff --git a/pages/oldmanindex/account.vue b/pages/oldmanindex/account.vue index 0a95211..4168ae6 100644 --- a/pages/oldmanindex/account.vue +++ b/pages/oldmanindex/account.vue @@ -164,16 +164,19 @@ console.log("data", data) - if (data.nuFailType == "ORG_PAYMENT_DISABLED") { + if (data.nuFailType ) { uni.showToast({ - title: '机构已经关闭微信支付功能', - icon: 'none' + title: data.msg, + icon: 'none', + duration:4000 }); setTimeout(() => { - uni.reLaunch({ - url: '/pages/oldmanindex/index' - }) - }, 1000) + // uni.reLaunch({ + // url: '/pages/oldmanindex/index' + // }) + uni.navigateBack({delta:2}) + }, 4000) + return } else if (data.nuFailType == "NU_HAS_BEEN_BOUND") { uni.showToast({ title: '护理单元已被其他用户绑定', @@ -200,6 +203,7 @@ if (data.appId || data.timeStamp || data.package || data.paySign) { await callWeixinPay(data); } else { + console.log(data) // 如果后端使用另一种返回结构,请按实际字段判断 uni.showToast({ title: '支付信息获取失败', @@ -208,6 +212,16 @@ console.error('支付返回:', data); } } catch (err) { + uni.request({ + url: payurl.value+'/api/nuInfo/cancelBind', + method: 'POST', + header: { + 'Content-Type': 'application/json' + }, + data: { + nuId:item.value.nuId + } + }); uni.hideLoading(); console.error('请求失败:', err); uni.showToast({ @@ -313,6 +327,16 @@ }); } catch (e) { console.error('uni.requestPayment 调用异常', e); + uni.request({ + url: payurl.value+'/api/nuInfo/cancelBind', + method: 'POST', + header: { + 'Content-Type': 'application/json' + }, + data: { + nuId:item.value.nuId + } + }); uni.showToast({ title: '支付调用失败', icon: 'none' diff --git a/pages/oldmanindex/input.vue b/pages/oldmanindex/input.vue index 1974642..fdd1a3c 100644 --- a/pages/oldmanindex/input.vue +++ b/pages/oldmanindex/input.vue @@ -67,7 +67,10 @@ import { getOrgNuId } from './api.js' - + onShow(()=>{ + uuid.value = ''; + item.value = {}; + }) const uuid = ref(""); const goBack = () => { diff --git a/pages/supplierindex/index.vue b/pages/supplierindex/index.vue index a75e7b4..510ad6a 100644 --- a/pages/supplierindex/index.vue +++ b/pages/supplierindex/index.vue @@ -9,13 +9,15 @@ + - - + --> - 敬请期待 + 供应商信息 - 敬请期待 + 信息变更 @@ -167,7 +169,7 @@ + v-if="item.suppliersStatus==`-1`"> @@ -190,11 +192,11 @@ --> - + - @@ -208,7 +210,7 @@ {{menuArray[which]?.departName}} - + --> @@ -268,7 +270,7 @@ }) } - const buttonArray = ref(["供应商", "敬请期待", "敬请期待"]) + const buttonArray = ref(["供应商", "物料信息", "敬请期待"]) const statusarray = ["loading", "success", "fail"] const which = ref(0); @@ -428,15 +430,17 @@ onUnmounted(() => {}) const menuArray = ref([]) + const item = ref([]) const loadingData = () => { getSuppliersOrgInfo().then(res => { - menuArray.value = [] - res.result.records.forEach((element) => { - menuArray.value.push(element) - }) - menuArray.value.push({ - applyStatus: `-1` - }) + item.value = res.result.records[0] + // menuArray.value = [] + // res.result.records.forEach((element) => { + // menuArray.value.push(element) + // }) + // menuArray.value.push({ + // applyStatus: `-1` + // }) }) // getMessageList().then(res => { // console.log("special", res) diff --git a/pages/supplierindex/index1.vue b/pages/supplierindex/index1.vue new file mode 100644 index 0000000..a75e7b4 --- /dev/null +++ b/pages/supplierindex/index1.vue @@ -0,0 +1,1086 @@ + + + + + \ No newline at end of file