Browse Source

fix:[试验管理]表单bug

lkf
15881625488@163.com 2 months ago
parent
commit
89ab6bcf93
2 changed files with 30 additions and 6 deletions
  1. +15
    -3
      src/views/business/study/comp/tbbd/Bj.vue
  2. +15
    -3
      src/views/business/study/comp/ytbd/Xq.vue

+ 15
- 3
src/views/business/study/comp/tbbd/Bj.vue View File

@ -535,6 +535,18 @@ export default {
this.$tab.closeOpenPage('/404') this.$tab.closeOpenPage('/404')
} }
}, },
cancelSave() {
try {
let key = caesarDecipher(this.$route.params.key)
let data = JSON.parse(key)
if (data && data != undefined && data != '') {
const obj = { path: data.urlTj ? data.urlTj : data.url }
this.$tab.closeOpenPage(obj)
}
} catch (e) {
this.$tab.closeOpenPage('/404')
}
},
reset() { reset() {
this.form = { this.form = {
id: null, id: null,
@ -564,7 +576,7 @@ export default {
this.$modal.loading() this.$modal.loading()
studyFormFill_bcOnly(this.form).then(response => { studyFormFill_bcOnly(this.form).then(response => {
this.$modal.closeLoading() this.$modal.closeLoading()
this.cancel()
this.cancelSave()
}).finally(() => { }).finally(() => {
this.$modal.closeLoading() this.$modal.closeLoading()
}) })
@ -585,7 +597,7 @@ export default {
this.$modal.loading() this.$modal.loading()
studyFormFill_bc(this.form).then(response => { studyFormFill_bc(this.form).then(response => {
this.$modal.closeLoading() this.$modal.closeLoading()
this.cancel()
this.cancelSave()
}).finally(() => { }).finally(() => {
this.$modal.closeLoading() this.$modal.closeLoading()
}) })
@ -607,7 +619,7 @@ export default {
studyFormFill_tj(that.formApprove).then(response => { studyFormFill_tj(that.formApprove).then(response => {
that.openApprove = false that.openApprove = false
that.$modal.closeLoading() that.$modal.closeLoading()
that.cancel()
that.cancelSave()
}).finally(() => { }).finally(() => {
that.$modal.closeLoading() that.$modal.closeLoading()
}) })

+ 15
- 3
src/views/business/study/comp/ytbd/Xq.vue View File

@ -10,8 +10,10 @@
</div> </div>
<div class="right-top"> <div class="right-top">
<el-button @click="cancel()">{{ $t('form.cancel') }}</el-button> <el-button @click="cancel()">{{ $t('form.cancel') }}</el-button>
<el-button type="primary" v-hasPermi="['business:studyFormPre:tb','business:nonTrialFormPre:tb','business:drugFormPre:tb']" v-if="form.bdzt === 5 && (fromNon || isMatchSubject)" @click="openApprove = true">{{
$t('page.business.study.studyFormPre.tb') }}</el-button>
<el-button type="primary"
v-hasPermi="['business:studyFormPre:tb', 'business:nonTrialFormPre:tb', 'business:drugFormPre:tb']"
v-if="form.bdzt === 5 && (fromNon || isMatchSubject)" @click="openApprove = true">{{
$t('page.business.study.studyFormPre.tb') }}</el-button>
</div> </div>
</div> </div>
<div class="edit-content "> <div class="edit-content ">
@ -55,7 +57,8 @@
append-to-body :close-on-click-modal="false"> append-to-body :close-on-click-modal="false">
<el-form ref="formApprove" :model="formApprove" :rules="rulesApprove" label-width="120px" v-if="openApprove"> <el-form ref="formApprove" :model="formApprove" :rules="rulesApprove" label-width="120px" v-if="openApprove">
<div class="sbzdtcma"> <input type="text"> <input type="password"> </div> <div class="sbzdtcma"> <input type="text"> <input type="password"> </div>
<el-alert :title="$t('page.business.study.studyFormPre.ts')" :closable="false" style="margin-bottom: 10px;" type="success">
<el-alert :title="$t('page.business.study.studyFormPre.ts')" :closable="false" style="margin-bottom: 10px;"
type="success">
</el-alert> </el-alert>
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
@ -232,8 +235,17 @@ export default {
if (valid) { if (valid) {
this.$modal.loading() this.$modal.loading()
studyFormPre_tb(this.formApprove).then(response => { studyFormPre_tb(this.formApprove).then(response => {
let type = ''
if (this.$route.fullPath.indexOf('/study/') > -1) {
type = '/study'
} else if (this.$route.fullPath.indexOf('/nonTrial/') > -1) {
type = '/nonTrial'
} else {
type = '/drug'
}
let params = caesarCipher(JSON.stringify({ let params = caesarCipher(JSON.stringify({
url: this.$route.fullPath, url: this.$route.fullPath,
urlTj: type+'/enter/' + this.form.studyId + '/tbbd',
studyId: this.form.studyId, studyId: this.form.studyId,
formId: response.data.id, formId: response.data.id,
fromYt: true fromYt: true

Loading…
Cancel
Save