Commit 905f1a49 authored by gengchunlei's avatar gengchunlei

医生端 v1.2 1、撤销(表单在 物理返回按键下 正常返回上一步)

parent 19955157
...@@ -152,17 +152,6 @@ export default { ...@@ -152,17 +152,6 @@ export default {
return this.$route.query return this.$route.query
} }
}, },
watch: {
'routerDetail': {
handler() {
if (this.routerDetail.step) {
this.step = this.routerDetail.step
} else {
this.step = 1
}
}
}
},
methods: { methods: {
async init() { async init() {
this.info = {} this.info = {}
...@@ -202,18 +191,13 @@ export default { ...@@ -202,18 +191,13 @@ export default {
}, },
async toNext(val) { async toNext(val) {
this.$refs.all.scrollTo(0, 0) this.$refs.all.scrollTo(0, 0)
try { if (val == 2) {
if (val == 2) { this.firstForm = await this.$refs.baseInfo.onSubmit()
this.firstForm = await this.$refs.baseInfo.onSubmit() }
} else if (val == 3) { if (val == 3) {
await this.$refs.generalFUForm.onSubmit() await this.$refs.generalFUForm.onSubmit()
} else { //返回上一步 }
this.$router.back() this.step = val
return
}
this.step = val
this.toRouter(this.step)
} catch (e) {}
}, },
//图片上传 //图片上传
async upload(imgList = []) { async upload(imgList = []) {
...@@ -258,27 +242,15 @@ export default { ...@@ -258,27 +242,15 @@ export default {
fun(params, true).then(({ code }) => { fun(params, true).then(({ code }) => {
if (code == 'SUCCESS') { if (code == 'SUCCESS') {
this.store.onRefreshMark() this.store.onRefreshMark()
this.$router.push({ this.$router.back()
path:`/doctor/patient-detail`,
query: {
residentInfoId: this.routerDetail.residentInfoId
}
})
} }
}) })
}, },
toRouter(val) {
this.$router.push({
path: '/doctor/followUp/generalFU/add',
query: { ...this.routerDetail, step: val }
})
},
toBack() { toBack() {
// if (this.step != 1) { if (this.step != 1) {
// this.step-- this.step--
// this.toRouter(this.step) return
// return }
// }
this.$router.back() this.$router.back()
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment