This commit is contained in:
2023-11-15 10:31:52 +08:00
parent 1c8404ffd8
commit 54af0a0bd0
4 changed files with 143 additions and 157 deletions

View File

@ -77,6 +77,9 @@
detail,
checkSignApply
} from '@/api/pages/homepage/homepage.js'
import {
mapActions
} from "vuex";
export default {
data() {
return {
@ -104,6 +107,7 @@
} else {}
},
methods: {
...mapActions(["openPopup"]),
//
city() {
uni.navigateTo({
@ -134,34 +138,37 @@
},
//
goonline() {
if (!this.userinfo) {
this.gologin();
} else if (this.userinfo) {
if (this.region == 3) {
this.family()
} else {
if (this.region == 1 || this.region == 2) {
if (this.checkSign == "0") {
this.$refs.uToast.show({
title: '未签约,请先签约',
type: 'error',
url: "/pagesC/Onlinesigning/Onlinesigning"
})
} else if (this.checkSign == "01") {
this.$refs.uToast.show({
title: this.infotitle,
type: 'error',
})
} else {
uni.navigateTo({
url: "/pagesB/mysigning/mysigning"
})
}
} else {
this.openPopup();
setTimeout(e => {
if (!this.userinfo) {
this.gologin();
} else if (this.userinfo) {
if (this.region == 3) {
this.family()
} else {
if (this.region == 1 || this.region == 2) {
if (this.checkSign == "0") {
this.$refs.uToast.show({
title: '未签约,请先签约',
type: 'error',
url: "/pagesC/Onlinesigning/Onlinesigning"
})
} else if (this.checkSign == "01") {
this.$refs.uToast.show({
title: this.infotitle,
type: 'error',
})
} else {
uni.navigateTo({
url: "/pagesB/mysigning/mysigning"
})
}
} else {
this.family()
}
}
}
}
}, 50)
},
//
count() {
@ -242,34 +249,37 @@
},
//
goappoint() {
if (!this.userinfo) {
this.gologin();
} else {
if (this.region == 3) {
this.family()
this.openPopup();
setTimeout(e => {
if (!this.userinfo) {
this.gologin();
} else {
if (this.region == 1 || this.region == 2) {
if (this.checkSign == "0") {
this.$refs.uToast.show({
title: '未签约,请先签约',
type: 'error',
url: "/pagesC/Onlinesigning/Onlinesigning"
})
} else if (this.checkSign == "01") {
this.$refs.uToast.show({
title: this.infotitle,
type: 'error',
})
} else {
uni.navigateTo({
url: "/pagesC/ServiceAppointment/ServiceAppointment"
})
}
} else {
if (this.region == 3) {
this.family()
} else {
if (this.region == 1 || this.region == 2) {
if (this.checkSign == "0") {
this.$refs.uToast.show({
title: '未签约,请先签约',
type: 'error',
url: "/pagesC/Onlinesigning/Onlinesigning"
})
} else if (this.checkSign == "01") {
this.$refs.uToast.show({
title: this.infotitle,
type: 'error',
})
} else {
uni.navigateTo({
url: "/pagesC/ServiceAppointment/ServiceAppointment"
})
}
} else {
this.family()
}
}
}
}
}, 50)
},
//
servicerecord() {

View File

@ -43,7 +43,6 @@
<script>
import {
mapState,
mapActions
} from "vuex";
import {
@ -73,48 +72,45 @@
this.getHeathHousing();
},
methods: {
//
...mapActions(["openPopup"]),
goAppointmentscreening() {
//
if (!this.userInfo) {
uni.showModal({
title: "提示",
content: "您还未注册,是否去注册?",
confirmText: '是',
cancelText: '否',
success(res) {
if (res.confirm) {
uni.redirectTo({
url: "/pages/register/register"
})
} else {
wx.exitMiniProgram()
this.openPopup();
setTimeout(e => {
//
if (!this.userInfo) {
uni.showModal({
title: "提示",
content: "您还未注册,是否去注册?",
confirmText: '是',
cancelText: '否',
success(res) {
if (res.confirm) {
uni.redirectTo({
url: "/pages/register/register"
})
} else {
wx.exitMiniProgram()
}
},
})
} else {
getScreening(this.patientId).then(res => {
if (res.code == 200) {
let userinfo = JSON.stringify(this.userInfo)
if (!res.data || res.data == null) {
uni.navigateTo({
url: `/pagesB/screenorder/screenorder?userinfo=${userinfo}`
})
} else {
uni.navigateTo({
url: `/pagesB/orderlist/orderlist?userinfo=${userinfo}`
})
}
}
},
})
}
else {
getScreening(this.patientId).then(res => {
if (res.code == 200) {
let userinfo = JSON.stringify(this.userInfo)
if (!res.data || res.data == null) {
uni.navigateTo({
url: `/pagesB/screenorder/screenorder?userinfo=${userinfo}`
})
} else {
uni.navigateTo({
url: `/pagesB/orderlist/orderlist?userinfo=${userinfo}`
})
}
}
})
}
// uni.navigateTo({
// url: '/pagesB/screenorder/screenorder'
// })
// uni.navigateTo({
// url: '/pagesB/orderlist/orderlist'
// })
})
}
}, 0)
},
//item
gohealthitem(item) {
@ -132,7 +128,6 @@
url: '/pages/login/login'
})
}
},
//
getHeathHousing() {
@ -146,8 +141,6 @@
})
},
//
//
...mapActions(["openPopup"]),
gomaterialbenefits() {
//
// this.$store.dispatch("openPopup");
@ -188,7 +181,6 @@
url: '/pages/login/login'
})
}
}, 0)
},
//
@ -207,31 +199,29 @@
url: '/pages/login/login'
})
}
},
//
result() {
const value = uni.getStorageSync('openid');
const value2 = uni.getStorageSync('patientId');
if (value && value2) {
uni.navigateTo({
url: '/pagesB/SelectItem/SelectItem'
})
} else {
this.$refs.uToast.show({
title: '您未登录,请先登录',
type: 'error',
duration: '1000',
url: '/pages/login/login'
})
}
this.openPopup();
setTimeout(e => {
const value = uni.getStorageSync('openid');
const value2 = uni.getStorageSync('patientId');
if (value && value2) {
uni.navigateTo({
url: '/pagesB/SelectItem/SelectItem'
})
} else {
this.$refs.uToast.show({
title: '您未登录,请先登录',
type: 'error',
duration: '1000',
url: '/pages/login/login'
})
}
}, 50)
},
//
goshopping() {
// this.openPopup();
setTimeout(e => {
const value = uni.getStorageSync('openid');
const value2 = uni.getStorageSync('patientId');
@ -247,34 +237,27 @@
url: '/pages/login/login'
})
}
}, 0)
},
//
goconsultationplatform() {
const value = uni.getStorageSync('openid');
const value2 = uni.getStorageSync('patientId');
const value3 = uni.getStorageSync('region');
if (value && value2 &&value3!=3) {
uni.navigateTo({
url: '/pagesB/consultationplatform/consultationplatform',
})
} else if(!value && !value2) {
this.$refs.uToast.show({
title: '您未登录,请先登录',
type: 'error',
duration: '1000',
url: '/pages/login/login'
})
}else if(value3==3){
this.$refs.uToast.show({
title: '请重新选择区域',
type: 'error',
duration: '1000',
})
}
this.openPopup();
setTimeout(e => {
const value = uni.getStorageSync('openid');
const value2 = uni.getStorageSync('patientId');
if (value && value2) {
uni.navigateTo({
url: '/pagesB/consultationplatform/consultationplatform',
})
} else {
this.$refs.uToast.show({
title: '您未登录,请先登录',
type: 'error',
duration: '1000',
url: '/pages/login/login'
})
}
}, 0)
},
},
//1.
@ -300,4 +283,4 @@
<style lang="scss">
@import "./medicalservice.scss";
</style>
</style>

View File

@ -204,9 +204,6 @@
</template>
<script>
import {
mapActions
} from "vuex";
import {
appPersonal,
getFamilyList,
@ -233,7 +230,7 @@
list: {},
showhome: false, //
familyList: null, //
region:'',//
region: '', //
infotitle: null,
};
},
@ -417,7 +414,7 @@
duration: '3000',
})
},
//
Signing() {
if (!this.appPersonallist) {
@ -562,17 +559,13 @@
// }
},
//
...mapActions(["integralopenPopup"]),
gointegral() {
const value = uni.getStorageSync('userinfo');
const value2 = uni.getStorageSync('patientId');
if (value && value2) {
this.integralopenPopup();
setTimeout(e => {
uni.navigateTo({
url: `/pagesB/healthybeans/healthybeans?integral=${this.appPersonallist.integral}`
})
}, 0)
uni.navigateTo({
url: `/pagesB/healthybeans/healthybeans?integral=${this.appPersonallist.integral}`
})
} else {
this.gologin();
}

View File

@ -8,22 +8,22 @@ const store = new Vuex.Store({
mutations: {
//相当于同步的操作
//点击确认
subscribesuccess(state) {
integralsubscribesuccess(state) {
wx.requestSubscribeMessage({
tmplIds: [
'-IxZeEkkXFhoSwGtBHbipKQ6kjEmkdTkswKeOypSsNQ',
'e1JRZaw1OfTz2b6X9DTqqaJtV4rXEt7uhwXoZLDb_eA',
'nUB9HRbqQXOVuTpkKBIHMgzWlNq6touzxf5QYBiMkbU',
// 'S_c9bR4znSWpXg-6ACIMn7AkaR11dzo113XM8w4CKz0'
],
success(res) {},
fail(err) {},
complete(scc) {}
})
},
integralsubscribesuccess(state) {
subscribesuccess(state) {
wx.requestSubscribeMessage({
tmplIds: [
'S_c9bR4znSWpXg-6ACIMn7AkaR11dzo113XM8w4CKz0'
'8InV9jXDT5sMj9OWfXEvlLQGlw2UaWfZ9OBMFxufmfk',
'2wn1BssReKjZasxKKZRWxBN0VqSmGmkuhc3AhTr18I0',
'MSSKCxOdtMUkY1ACu-u3itz8Vh_w5xDkO2llAOGwElU',
],
success(res) {},
fail(err) {},
@ -60,4 +60,4 @@ const store = new Vuex.Store({
},
}
})
export default store
export default store