diff --git a/src/register.js b/src/register.js index 31804b8f7bcce449004d9b5a53c7794d2f3e19a4..04f595398184c7f191172f9c3eaffc4b754a6fa6 100644 --- a/src/register.js +++ b/src/register.js @@ -1,5 +1,6 @@ import 'vant/es/toast/style/index' +import 'vant/es/notify/style/index' // 自定义svg 图标组件 import DocIcon from '@/components/docIcon/index' diff --git a/src/tumour/screening/simple/form/Index.vue b/src/tumour/screening/simple/form/Index.vue index 43e1541e2dc9baac4e1b58c48dc28095d214f57d..30d9a4ce48c97f5ac813bee8bd20f9743138790e 100644 --- a/src/tumour/screening/simple/form/Index.vue +++ b/src/tumour/screening/simple/form/Index.vue @@ -24,6 +24,7 @@ <script> import BaseForm from './base.vue' import QuestionForm from './Question.vue' +import { showNotify } from 'vant' export default { components: { @@ -41,9 +42,18 @@ export default { }, computed: { routeQuery() { - + return this.$route.query + }, + doctorId() { + return this.routeQuery.doctorId } }, + created() { + if (!this.doctorId) { + showNotify({ type: 'warning', message: '未获取到医生信息', duration: 0 }) + } + + }, methods: { init() { @@ -52,6 +62,7 @@ export default { this.setp = 1 }, onNext() { + if (!this.doctorId) return this.$refs.base.submit().then(res => { console.log(res) this.baseInfo = res @@ -63,12 +74,12 @@ export default { this.$refs.question.submit().then(res => { const result = { ...this.baseInfo, - details: res + details: res, + createdUserId: this.doctorId } console.log(result) }) } - } } </script>