Browse Source

删除冗余弹窗

master
kola-web 2 weeks ago
parent
commit
6fafba87bb
  1. 53
      src/patient/pages/index/index.ts

53
src/patient/pages/index/index.ts

@ -34,11 +34,7 @@ Page({ @@ -34,11 +34,7 @@ Page({
liveDownList: [],
// toastShow: true,
// toastType: "doubleStandards",
// toastType: "healthCare",
// toastType: "aldAlert",
// toastType:"dedicatedDoctor",
// toastType: 'public-toast',
// toastType: "dedicatedDoctor",
// toastType: 'medical-guide',
// toastType: 'question-toast',
// toastType: 'guideEnterInfo',
@ -115,8 +111,8 @@ Page({ @@ -115,8 +111,8 @@ Page({
})
},
async getPopup() {
if (this.data.toastShow)
return
// https://fa0ci3qr2z.feishu.cn/wiki/EBX6woN7xiaartkYkBpcfbYQnfn
if (this.data.toastShow) return
const noteGuideShown = wx.getStorageSync('noteGuideShown')
if (!noteGuideShown) {
@ -231,13 +227,11 @@ Page({ @@ -231,13 +227,11 @@ Page({
// 设置显示状态
if (code === 'medicalInsurance' && showStatus == 1) {
statusMap.medicalInsuranceShow = true
if (openStatus == 1)
statusMap.medicalInsuranceJump = true
if (openStatus == 1) statusMap.medicalInsuranceJump = true
}
if (code === 'hospitalMap' && showStatus == 1) {
statusMap.hospitalMapShow = true
if (openStatus == 1)
statusMap.hospitalMapJump = true
if (openStatus == 1) statusMap.hospitalMapJump = true
}
if (code === 'adl' && showStatus == 1) {
statusMap.qolShow = true
@ -357,8 +351,7 @@ Page({ @@ -357,8 +351,7 @@ Page({
})
return
}
if (!url)
return
if (!url) return
if (code === 'doctor') {
app.mpBehavior({ PageName: 'BTN_PatientHomeDoctorCard' })
}
@ -392,8 +385,8 @@ Page({ @@ -392,8 +385,8 @@ Page({
},
handleAddQol() {
const { qolDetail } = this.data
const url
= qolDetail.Id && qolDetail.isTodayRecord
const url =
qolDetail.Id && qolDetail.isTodayRecord
? `/patient/pages/qolAdd/index?id=${qolDetail.Id}&edit=1`
: `/patient/pages/qol/index`
wx.navigateTo({
@ -414,8 +407,7 @@ Page({ @@ -414,8 +407,7 @@ Page({
wx.navigateTo({
url: `/patient/pages/hormones/index?id=${hormoneDetail.recordId}`,
})
}
else {
} else {
wx.navigateTo({
url: '/patient/pages/hormonesStart/index',
})
@ -431,14 +423,12 @@ Page({ @@ -431,14 +423,12 @@ Page({
url: '/patient/pages/adl/index?nrdl=1',
})
this.handleToastCancel()
}
else if (toastType === 'doubleStandards') {
} else if (toastType === 'doubleStandards') {
wx.navigateTo({
url: '/patient/pages/adl/index',
})
this.handleToastCancel()
}
else if (toastType === 'dedicatedDoctor') {
} else if (toastType === 'dedicatedDoctor') {
wx.ajax({
method: 'POST',
url: '?r=zd/popup/close-popup',
@ -451,8 +441,7 @@ Page({ @@ -451,8 +441,7 @@ Page({
})
})
this.handleToastCancel(null, false)
}
else if (toastType === 'medical-guide') {
} else if (toastType === 'medical-guide') {
wx.ajax({
method: 'POST',
url: '?r=zd/popup/add-record',
@ -463,8 +452,7 @@ Page({ @@ -463,8 +452,7 @@ Page({
})
})
this.handleToastCancel(null, false)
}
else if (toastType === 'guideEnterInfo') {
} else if (toastType === 'guideEnterInfo') {
wx.ajax({
method: 'POST',
url: '?r=zd/popup/close-need-popup',
@ -475,8 +463,7 @@ Page({ @@ -475,8 +463,7 @@ Page({
})
this.handleToastCancel(null, false)
})
}
else if (toastType === 'guideEnterInfoJump') {
} else if (toastType === 'guideEnterInfoJump') {
wx.navigateTo({
url: '/patient/pages/personalInformation/index',
})
@ -493,8 +480,7 @@ Page({ @@ -493,8 +480,7 @@ Page({
Type: 5,
},
})
}
else if (toastType === 'dedicatedDoctor' && sure) {
} else if (toastType === 'dedicatedDoctor' && sure) {
wx.ajax({
method: 'POST',
url: '?r=zd/popup/close-popup',
@ -502,15 +488,13 @@ Page({ @@ -502,15 +488,13 @@ Page({
Type: 6,
},
})
}
else if (toastType === 'medical-guide' && sure) {
} else if (toastType === 'medical-guide' && sure) {
wx.ajax({
method: 'POST',
url: '?r=zd/popup/add-record',
data: { type: 3 },
})
}
else if (toastType === 'guideEnterInfo' && sure) {
} else if (toastType === 'guideEnterInfo' && sure) {
wx.ajax({
method: 'POST',
url: '?r=zd/popup/close-need-popup',
@ -553,8 +537,7 @@ Page({ @@ -553,8 +537,7 @@ Page({
infoList: list,
})
})
}
else {
} else {
wx.ajax({
method: 'POST',
url: '?r=zd/pic-text/collection',

Loading…
Cancel
Save