|
|
@ -11,31 +11,32 @@ G |
|
|
<div :class="showIndex == 1 ? 'el-step__icon is-text is-finish' : 'el-step__icon is-text is-info'"> |
|
|
<div :class="showIndex == 1 ? 'el-step__icon is-text is-finish' : 'el-step__icon is-text is-info'"> |
|
|
<div class="el-step__icon-inner">1</div> |
|
|
<div class="el-step__icon-inner">1</div> |
|
|
</div> |
|
|
</div> |
|
|
基础设置 |
|
|
|
|
|
|
|
|
{{ $t('page.business.study.studyFormPre.jcsz') }} |
|
|
</div> |
|
|
</div> |
|
|
<div class="line"></div> |
|
|
<div class="line"></div> |
|
|
<div> |
|
|
<div> |
|
|
<div :class="showIndex == 2 ? 'el-step__icon is-text is-finish' : 'el-step__icon is-text is-info'"> |
|
|
<div :class="showIndex == 2 ? 'el-step__icon is-text is-finish' : 'el-step__icon is-text is-info'"> |
|
|
<div class="el-step__icon-inner">2</div> |
|
|
<div class="el-step__icon-inner">2</div> |
|
|
</div> |
|
|
</div> |
|
|
表单设计 |
|
|
|
|
|
|
|
|
{{ $t('page.business.study.studyFormPre.bdsj') }} |
|
|
</div> |
|
|
</div> |
|
|
</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> |
|
|
<template v-if="showIndex == 1"> |
|
|
<template v-if="showIndex == 1"> |
|
|
<el-button @click="save">暂存</el-button> |
|
|
|
|
|
<el-button type="primary" @click="next">下一步</el-button> |
|
|
|
|
|
|
|
|
<el-button @click="save">{{ $t('page.business.study.studyFormPre.zc') }}</el-button> |
|
|
|
|
|
<el-button type="primary" @click="next">{{ $t('page.business.study.studyFormPre.next') }}</el-button> |
|
|
</template> |
|
|
</template> |
|
|
<template v-else> |
|
|
<template v-else> |
|
|
<el-button @click="saveNext">保存</el-button> |
|
|
|
|
|
<el-button type="primary" @click="openSubmit = true">提交</el-button> |
|
|
|
|
|
|
|
|
<el-button @click="saveNext">{{ $t('page.business.study.studyFormPre.save') }}</el-button> |
|
|
|
|
|
<el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormPre.submit') |
|
|
|
|
|
}}</el-button> |
|
|
</template> |
|
|
</template> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div class="edit-content"> |
|
|
<div class="edit-content"> |
|
|
<div class="content" style="width:60%"> |
|
|
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="120px" v-if="showIndex == 1"> |
|
|
|
|
|
|
|
|
<div class="content" style="width:60%" v-show="showIndex == 1"> |
|
|
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="120px"> |
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :span="24"> |
|
|
<el-col :span="24"> |
|
|
<el-form-item :label="$t('page.business.form.xtmbmc')" prop="templateId"> |
|
|
<el-form-item :label="$t('page.business.form.xtmbmc')" prop="templateId"> |
|
|
@ -52,7 +53,7 @@ G |
|
|
</el-row> |
|
|
</el-row> |
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :span="24"> |
|
|
<el-col :span="24"> |
|
|
<el-form-item label="表单说明" prop="bdsm"> |
|
|
|
|
|
|
|
|
<el-form-item :label="$t('page.business.study.studyFormPre.bdsm')" prop="bdsm"> |
|
|
<el-input type="textarea" v-model="form.bdsm" :rows="5" maxlength="500" |
|
|
<el-input type="textarea" v-model="form.bdsm" :rows="5" maxlength="500" |
|
|
:placeholder="$t('form.placeholderInput')"> |
|
|
:placeholder="$t('form.placeholderInput')"> |
|
|
</el-input> |
|
|
</el-input> |
|
|
@ -60,25 +61,26 @@ G |
|
|
</el-col> |
|
|
</el-col> |
|
|
</el-row> |
|
|
</el-row> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<div v-else> |
|
|
|
|
|
表单详情todo |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="content" v-show="showIndex == 2"> |
|
|
|
|
|
<TemplateTable ref="templateTable" sn="SP001" fillType="preFill" /> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
<el-dialog title="提交预设表" :visible.sync="openSubmit" width="500px" append-to-body :close-on-click-modal="false"> |
|
|
|
|
|
|
|
|
<el-dialog :title="$t('page.business.study.studyFormPre.tjysb')" :visible.sync="openSubmit" width="500px" |
|
|
|
|
|
append-to-body :close-on-click-modal="false"> |
|
|
<el-form ref="formSubmit" :model="form" :rules="rulesApprove" label-width="120px"> |
|
|
<el-form ref="formSubmit" :model="form" :rules="rulesApprove" label-width="120px"> |
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :span="24"> |
|
|
<el-col :span="24"> |
|
|
<el-form-item label="审核人员" prop="shryId"> |
|
|
|
|
|
|
|
|
<el-form-item :label="$t('page.business.study.studyFormPre.shryId')" prop="shryId"> |
|
|
<SelectDeptUser v-model="form.shryId" :name="form.shryMc" key="shryId" @change="selectDeptUserChange" /> |
|
|
<SelectDeptUser v-model="form.shryId" :name="form.shryMc" key="shryId" @change="selectDeptUserChange" /> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
</el-row> |
|
|
</el-row> |
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :span="24"> |
|
|
<el-col :span="24"> |
|
|
<el-form-item label="是否需要试验负责人审核" prop="fzrsh"> |
|
|
|
|
|
|
|
|
<el-form-item :label="$t('page.business.study.studyFormPre.shryId')" prop="fzrsh"> |
|
|
<el-radio-group v-model="form.fzrsh"> |
|
|
<el-radio-group v-model="form.fzrsh"> |
|
|
<el-radio :label="10">是</el-radio> |
|
|
<el-radio :label="10">是</el-radio> |
|
|
<el-radio :label="1">否</el-radio> |
|
|
<el-radio :label="1">否</el-radio> |
|
|
@ -133,10 +135,11 @@ import { studyFormPre_bc, studyFormPre_tj, studyFormPre_info } from "@/api/busin |
|
|
import { mapGetters } from 'vuex' |
|
|
import { mapGetters } from 'vuex' |
|
|
import SelectTemplate from "@/views/business/comps/select/SelectTemplate"; |
|
|
import SelectTemplate from "@/views/business/comps/select/SelectTemplate"; |
|
|
import SelectDeptUser from '@/views/business/comps/select/SelectDeptUser'; |
|
|
import SelectDeptUser from '@/views/business/comps/select/SelectDeptUser'; |
|
|
|
|
|
import TemplateTable from '@/views/business/comps/template/TemplateTable'; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: "Bj", |
|
|
name: "Bj", |
|
|
components: { SelectTemplate, SelectDeptUser }, |
|
|
|
|
|
|
|
|
components: { SelectTemplate, SelectDeptUser, TemplateTable }, |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
open: false, |
|
|
open: false, |
|
|
@ -243,7 +246,9 @@ export default { |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
saveNext() { |
|
|
|
|
|
|
|
|
async saveNext() { |
|
|
|
|
|
let content = await this.$refs.templateTable.getFormData() |
|
|
|
|
|
this.form.bdnr=JSON.stringify(content) |
|
|
this.$modal.loading() |
|
|
this.$modal.loading() |
|
|
studyFormPre_bc(this.form).then(response => { |
|
|
studyFormPre_bc(this.form).then(response => { |
|
|
this.$emit('close') |
|
|
this.$emit('close') |
|
|
@ -253,14 +258,19 @@ export default { |
|
|
tj() { |
|
|
tj() { |
|
|
this.$refs["formSubmit"].validate(valid => { |
|
|
this.$refs["formSubmit"].validate(valid => { |
|
|
if (valid) { |
|
|
if (valid) { |
|
|
this.$modal.loading() |
|
|
|
|
|
studyFormPre_tj(this.form).then(response => { |
|
|
|
|
|
this.$emit('close') |
|
|
|
|
|
this.openSubmit = false |
|
|
|
|
|
this.$modal.closeLoading() |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
this.dotj() |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
async dotj() { |
|
|
|
|
|
let content = await this.$refs.templateTable.getFormData() |
|
|
|
|
|
this.form.bdnr=JSON.stringify(content) |
|
|
|
|
|
this.$modal.loading() |
|
|
|
|
|
studyFormPre_tj(this.form).then(response => { |
|
|
|
|
|
this.$emit('close') |
|
|
|
|
|
this.openSubmit = false |
|
|
|
|
|
this.$modal.closeLoading() |
|
|
|
|
|
}) |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|