Browse Source

fix:[试验管理][填报,预填,申请,计划]编辑优化

master
15881625488@163.com 5 days ago
parent
commit
371868cda2
14 changed files with 57 additions and 29 deletions
  1. +1
    -0
      src/lang/en/business/study/studyFormApply.js
  2. +1
    -0
      src/lang/en/business/study/studyFormFill.js
  3. +1
    -0
      src/lang/en/business/study/studyFormPlan.js
  4. +1
    -0
      src/lang/en/business/study/studyFormPre.js
  5. +1
    -0
      src/lang/zh/business/study/studyFormApply.js
  6. +1
    -0
      src/lang/zh/business/study/studyFormFill.js
  7. +1
    -0
      src/lang/zh/business/study/studyFormPlan.js
  8. +1
    -0
      src/lang/zh/business/study/studyFormPre.js
  9. +4
    -3
      src/views/business/comps/select/SelectTemplate.vue
  10. +9
    -4
      src/views/business/study/comp/jhbd/Bj.vue
  11. +13
    -8
      src/views/business/study/comp/sqbd/Bj.vue
  12. +10
    -6
      src/views/business/study/comp/tbbd/Bj.vue
  13. +11
    -6
      src/views/business/study/comp/ytbd/Bj.vue
  14. +2
    -2
      vue.config.js

+ 1
- 0
src/lang/en/business/study/studyFormApply.js View File

@ -13,6 +13,7 @@ export default {
zc:'暂存', zc:'暂存',
next:'Next', next:'Next',
save:'Save', save:'Save',
pre:'Pre',
submit:'Submit', submit:'Submit',
bdnr:'表单内容', bdnr:'表单内容',
qmxx:'签名信息', qmxx:'签名信息',

+ 1
- 0
src/lang/en/business/study/studyFormFill.js View File

@ -13,6 +13,7 @@ export default {
zc:'暂存', zc:'暂存',
next:'Next', next:'Next',
save:'Save', save:'Save',
pre:'Pre',
submit:'Submit', submit:'Submit',
bdnr:'表单内容', bdnr:'表单内容',
qmxx:'签名信息', qmxx:'签名信息',

+ 1
- 0
src/lang/en/business/study/studyFormPlan.js View File

@ -10,6 +10,7 @@ export default {
zc: '暂存', zc: '暂存',
next:'Next', next:'Next',
save:'Save', save:'Save',
pre:'Pre',
submit:'Submit', submit:'Submit',
bdnr: '表单内容', bdnr: '表单内容',
qmxx: '签名信息', qmxx: '签名信息',

+ 1
- 0
src/lang/en/business/study/studyFormPre.js View File

@ -14,6 +14,7 @@ export default {
reject:'Reject', reject:'Reject',
shtg:'审核通过', shtg:'审核通过',
shjj:'审核拒绝', shjj:'审核拒绝',
pre:'Pre',
tb:'填报', tb:'填报',
bdnr:'表单内容', bdnr:'表单内容',
qmxx:'签名信息', qmxx:'签名信息',

+ 1
- 0
src/lang/zh/business/study/studyFormApply.js View File

@ -12,6 +12,7 @@ export default {
bdsm:'表单说明', bdsm:'表单说明',
zc:'暂存', zc:'暂存',
next:'下一步', next:'下一步',
pre:'上一步',
save:'保存', save:'保存',
submit:'提交', submit:'提交',
bdnr:'表单内容', bdnr:'表单内容',

+ 1
- 0
src/lang/zh/business/study/studyFormFill.js View File

@ -12,6 +12,7 @@ export default {
bdsm:'表单说明', bdsm:'表单说明',
zc:'暂存', zc:'暂存',
next:'下一步', next:'下一步',
pre:'上一步',
save:'保存', save:'保存',
submit:'提交', submit:'提交',
bdnr:'表单内容', bdnr:'表单内容',

+ 1
- 0
src/lang/zh/business/study/studyFormPlan.js View File

@ -9,6 +9,7 @@ export default {
bdsm: '表单说明', bdsm: '表单说明',
zc: '暂存', zc: '暂存',
next: '下一步', next: '下一步',
pre:'上一步',
save: '保存', save: '保存',
submit: '提交', submit: '提交',
bdnr: '表单内容', bdnr: '表单内容',

+ 1
- 0
src/lang/zh/business/study/studyFormPre.js View File

@ -4,6 +4,7 @@ export default {
xzbd:'新增表单', xzbd:'新增表单',
zc:'暂存', zc:'暂存',
next:'下一步', next:'下一步',
pre:'上一步',
save:'保存', save:'保存',
submit:'提交', submit:'提交',
bdsm:'表单说明', bdsm:'表单说明',

+ 4
- 3
src/views/business/comps/select/SelectTemplate.vue View File

@ -2,7 +2,8 @@
<template> <template>
<div> <div>
<el-input v-model="selected.name" :placeholder="$t('form.placeholderSelect')" readonly @click.native="showSelectTemplate" />
{{ readOnly }}
<el-input v-model="selected.name" :placeholder="$t('form.placeholderSelect')" :disabled="disabled" @click.native="showSelectTemplate" />
<SelectTemplateDialog ref="selectTemplateDialog" @callback="handleChange" /> <SelectTemplateDialog ref="selectTemplateDialog" @callback="handleChange" />
</div> </div>
</template> </template>
@ -21,7 +22,7 @@ export default {
type: String, type: String,
default: '' default: ''
}, },
readOnly: {
disabled: {
type: Boolean, type: Boolean,
default: false default: false
}, },
@ -56,7 +57,7 @@ export default {
}, },
methods: { methods: {
showSelectTemplate(){ showSelectTemplate(){
if(!this.readOnly){
if(!this.disabled){
this.$refs.selectTemplateDialog.show({needPre:this.needPre}) this.$refs.selectTemplateDialog.show({needPre:this.needPre})
} }
}, },

+ 9
- 4
src/views/business/study/comp/jhbd/Bj.vue View File

@ -31,6 +31,7 @@
<el-button @click="saveNext">{{ $t('page.business.study.studyFormPlan.save') }}</el-button> <el-button @click="saveNext">{{ $t('page.business.study.studyFormPlan.save') }}</el-button>
<el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormPlan.submit') <el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormPlan.submit')
}}</el-button> }}</el-button>
<el-button type="primary" @click="pre">{{ $t('page.business.study.studyFormPlan.pre') }}</el-button>
</template> </template>
</div> </div>
</div> </div>
@ -40,7 +41,8 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item :label="$t('page.business.form.bdmb')" prop="templateId"> <el-form-item :label="$t('page.business.form.bdmb')" prop="templateId">
<SelectTemplate v-model="form.templateId" :needPre="1" :name="form.templateMc" @change="selectTemplateChange" />
<SelectTemplate v-model="form.templateId" :disabled="form.id && form.id !== ''" :needPre="1"
:name="form.templateMc" @change="selectTemplateChange" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -137,7 +139,9 @@ export default {
created() { created() {
}, },
methods: { methods: {
pre() {
this.showIndex = 1
},
next() { next() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
@ -147,7 +151,7 @@ export default {
}, },
selectTemplateChange(val) { selectTemplateChange(val) {
this.form.bdnr = val.content this.form.bdnr = val.content
this.form.bdmc=val.name
this.form.bdmc = val.name
this.form.templateMc = val.name this.form.templateMc = val.name
this.form.templateSn = val.sn this.form.templateSn = val.sn
}, },
@ -176,8 +180,8 @@ export default {
}, },
edit(row) { edit(row) {
this.reset() this.reset()
this.showIndex = 1
if (row && row.id) { if (row && row.id) {
this.showIndex = 2
this.$modal.loading() this.$modal.loading()
studyFormPlan_info({ id: row.id }).then(response => { studyFormPlan_info({ id: row.id }).then(response => {
this.form = response.data this.form = response.data
@ -186,6 +190,7 @@ export default {
this.$modal.closeLoading() this.$modal.closeLoading()
}) })
} else { } else {
this.showIndex = 1
this.form = _.merge({}, this.form, row) this.form = _.merge({}, this.form, row)
this.open = true this.open = true
} }

+ 13
- 8
src/views/business/study/comp/sqbd/Bj.vue View File

@ -31,6 +31,7 @@
<el-button @click="saveNext">{{ $t('page.business.study.studyFormApply.save') }}</el-button> <el-button @click="saveNext">{{ $t('page.business.study.studyFormApply.save') }}</el-button>
<el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormApply.submit') <el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormApply.submit')
}}</el-button> }}</el-button>
<el-button type="primary" @click="pre">{{ $t('page.business.study.studyFormApply.pre') }}</el-button>
</template> </template>
</div> </div>
</div> </div>
@ -40,7 +41,8 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item :label="$t('page.business.form.bdmb')" prop="templateId"> <el-form-item :label="$t('page.business.form.bdmb')" prop="templateId">
<SelectTemplate v-model="form.templateId" :name="form.templateMc" @change="selectTemplateChange" />
<SelectTemplate v-model="form.templateId" :disabled="form.id && form.id !== ''"
:name="form.templateMc" @change="selectTemplateChange" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -54,10 +56,10 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item :label="$t('page.business.study.studyFormApply.sfbl')" prop="sfbl"> <el-form-item :label="$t('page.business.study.studyFormApply.sfbl')" prop="sfbl">
<el-select v-model="form.sfbl" :placeholder="$t('form.placeholderSelect')" >
<el-option :label="$t('page.business.study.studyFormApply.yes')" :value="10" />
<el-option :label="$t('page.business.study.studyFormApply.no')" :value="1" />
</el-select>
<el-select v-model="form.sfbl" :placeholder="$t('form.placeholderSelect')">
<el-option :label="$t('page.business.study.studyFormApply.yes')" :value="10" />
<el-option :label="$t('page.business.study.studyFormApply.no')" :value="1" />
</el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -152,7 +154,9 @@ export default {
created() { created() {
}, },
methods: { methods: {
pre() {
this.showIndex = 1
},
next() { next() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
@ -161,7 +165,7 @@ export default {
}) })
}, },
selectTemplateChange(val) { selectTemplateChange(val) {
this.form.bdmc=val.name
this.form.bdmc = val.name
this.form.bdnr = val.content this.form.bdnr = val.content
this.form.templateMc = val.name this.form.templateMc = val.name
this.form.templateSn = val.sn this.form.templateSn = val.sn
@ -192,8 +196,8 @@ export default {
}, },
edit(row) { edit(row) {
this.reset() this.reset()
this.showIndex = 1
if (row && row.id) { if (row && row.id) {
this.showIndex = 2
this.$modal.loading() this.$modal.loading()
studyFormApply_info({ id: row.id }).then(response => { studyFormApply_info({ id: row.id }).then(response => {
this.form = response.data this.form = response.data
@ -202,6 +206,7 @@ export default {
this.$modal.closeLoading() this.$modal.closeLoading()
}) })
} else { } else {
this.showIndex = 1
this.form = _.merge({}, this.form, row) this.form = _.merge({}, this.form, row)
this.open = true this.open = true
} }

+ 10
- 6
src/views/business/study/comp/tbbd/Bj.vue View File

@ -31,6 +31,7 @@
<el-button @click="saveNext">{{ $t('page.business.study.studyFormFill.save') }}</el-button> <el-button @click="saveNext">{{ $t('page.business.study.studyFormFill.save') }}</el-button>
<el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormFill.submit') <el-button type="primary" @click="openSubmit = true">{{ $t('page.business.study.studyFormFill.submit')
}}</el-button> }}</el-button>
<el-button type="primary" @click="pre">{{ $t('page.business.study.studyFormFill.pre') }}</el-button>
</template> </template>
</div> </div>
</div> </div>
@ -40,8 +41,8 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item :label="$t('page.business.form.bdmb')" prop="templateId"> <el-form-item :label="$t('page.business.form.bdmb')" prop="templateId">
<SelectTemplate v-model="form.templateId" :name="form.templateMc" @change="selectTemplateChange"
:needPre="1" />
<SelectTemplate v-model="form.templateId" :disabled="form.id && form.id !== ''" :name="form.templateMc"
@change="selectTemplateChange" :needPre="1" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -55,7 +56,7 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item :label="$t('page.business.study.studyFormFill.sfbl')" prop="sfbl"> <el-form-item :label="$t('page.business.study.studyFormFill.sfbl')" prop="sfbl">
<el-select v-model="form.sfbl" :placeholder="$t('form.placeholderSelect')">
<el-select v-model="form.sfbl" :placeholder="$t('form.placeholderSelect')" :disabled="form.id && form.id !== ''">
<el-option :label="$t('page.business.study.studyFormFill.yes')" :value="10" /> <el-option :label="$t('page.business.study.studyFormFill.yes')" :value="10" />
<el-option :label="$t('page.business.study.studyFormFill.no')" :value="1" /> <el-option :label="$t('page.business.study.studyFormFill.no')" :value="1" />
</el-select> </el-select>
@ -153,7 +154,9 @@ export default {
created() { created() {
}, },
methods: { methods: {
pre() {
this.showIndex = 1
},
next() { next() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
@ -164,7 +167,7 @@ export default {
selectTemplateChange(val) { selectTemplateChange(val) {
this.form.bdnr = val.content this.form.bdnr = val.content
this.form.templateMc = val.name this.form.templateMc = val.name
this.form.bdmc=val.name
this.form.bdmc = val.name
this.form.templateSn = val.sn this.form.templateSn = val.sn
}, },
cancel() { cancel() {
@ -193,8 +196,8 @@ export default {
}, },
edit(row) { edit(row) {
this.reset() this.reset()
this.showIndex = 1
if (row && row.id) { if (row && row.id) {
this.showIndex = 2
this.$modal.loading() this.$modal.loading()
studyFormFill_info({ id: row.id }).then(response => { studyFormFill_info({ id: row.id }).then(response => {
this.form = response.data this.form = response.data
@ -203,6 +206,7 @@ export default {
this.$modal.closeLoading() this.$modal.closeLoading()
}) })
} else { } else {
this.showIndex = 1
this.form = _.merge({}, this.form, row) this.form = _.merge({}, this.form, row)
this.open = true this.open = true
} }

+ 11
- 6
src/views/business/study/comp/ytbd/Bj.vue View File

@ -31,6 +31,7 @@
<el-button @click="saveNext">{{ $t('page.business.study.studyFormPre.save') }}</el-button> <el-button @click="saveNext">{{ $t('page.business.study.studyFormPre.save') }}</el-button>
<el-button type="primary" @click="showtj">{{ $t('page.business.study.studyFormPre.submit') <el-button type="primary" @click="showtj">{{ $t('page.business.study.studyFormPre.submit')
}}</el-button> }}</el-button>
<el-button type="primary" @click="pre">{{ $t('page.business.study.studyFormPre.pre') }}</el-button>
</template> </template>
</div> </div>
</div> </div>
@ -40,14 +41,15 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item :label="$t('page.business.form.bdmb')" prop="templateId"> <el-form-item :label="$t('page.business.form.bdmb')" prop="templateId">
<SelectTemplate v-model="form.templateId" :needPre="10" :name="form.templateMc" @change="selectTemplateChange" />
<SelectTemplate v-model="form.templateId" :disabled="form.id&&form.id!==''" :needPre="10" :name="form.templateMc"
@change="selectTemplateChange" />
</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="$t('page.business.form.bdmc')" prop="bdmc"> <el-form-item :label="$t('page.business.form.bdmc')" prop="bdmc">
<el-input type="text" v-model="form.bdmc" maxlength="50" :placeholder="$t('form.placeholderInput')" />
<el-input type="text" v-model="form.bdmc" maxlength="50" :placeholder="$t('form.placeholderInput')" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -63,7 +65,7 @@
</el-form> </el-form>
</div> </div>
<div class="content" v-show="showIndex == 2"> <div class="content" v-show="showIndex == 2">
<TemplateTable ref="templateTable" :sn="form.templateSn" :templateData="form" fillType="preFill" />
<TemplateTable ref="templateTable" :sn="form.templateSn" :templateData="form" fillType="preFill" />
</div> </div>
</div> </div>
</div> </div>
@ -185,7 +187,9 @@ export default {
created() { created() {
}, },
methods: { methods: {
pre(){
this.showIndex = 1
},
next() { next() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
@ -196,7 +200,7 @@ export default {
selectTemplateChange(val) { selectTemplateChange(val) {
this.form.bdnr = val.content this.form.bdnr = val.content
this.form.templateMc = val.name this.form.templateMc = val.name
this.form.bdmc=val.name
this.form.bdmc = val.name
this.form.templateSn = val.sn this.form.templateSn = val.sn
}, },
cancel() { cancel() {
@ -224,8 +228,8 @@ export default {
}, },
edit(row) { edit(row) {
this.reset() this.reset()
this.showIndex = 1
if (row && row.id) { if (row && row.id) {
this.showIndex = 2
this.$modal.loading() this.$modal.loading()
studyFormPre_info({ id: row.id }).then(response => { studyFormPre_info({ id: row.id }).then(response => {
this.form = response.data this.form = response.data
@ -236,6 +240,7 @@ export default {
this.$modal.closeLoading() this.$modal.closeLoading()
}) })
} else { } else {
this.showIndex = 1
this.form = _.merge({}, this.form, row) this.form = _.merge({}, this.form, row)
this.open = true this.open = true
} }

+ 2
- 2
vue.config.js View File

@ -34,8 +34,8 @@ module.exports = {
proxy: { proxy: {
// detail: https://cli.vuejs.org/config/#devserver-proxy // detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
// target: `http://localhost:8080`,
target: `http://39.99.251.173:8080`,
target: `http://localhost:8080`,
// target: `http://39.99.251.173:8080`,
changeOrigin: true, changeOrigin: true,
pathRewrite: { pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: '' ['^' + process.env.VUE_APP_BASE_API]: ''

Loading…
Cancel
Save