[add] 项目

This commit is contained in:
zhaomeijing
2022-05-13 18:05:29 +08:00
parent 939b7ec6ee
commit 855206754c
2 changed files with 27 additions and 2 deletions
@@ -230,6 +230,7 @@
<a-col :span="24" > <a-col :span="24" >
<a-tabs> <a-tabs>
<a-tab-pane v-for='(item,index) in contentList' :tab="item.textVal" :key="index + 1"> <a-tab-pane v-for='(item,index) in contentList' :tab="item.textVal" :key="index + 1">
<!-- <a-form-model :model="formInline" class="formAdd" :rules="rulesItem" ref="ruleFormItem" key='ruleFormItem'>-->
<a-row :gutter="24"> <a-row :gutter="24">
<a-col :span="12"> <a-col :span="12">
<div class="box-title-text"> <div class="box-title-text">
@@ -277,6 +278,7 @@
</div> </div>
</a-col> </a-col>
</a-row> </a-row>
<!-- </a-form-model>-->
</a-tab-pane> </a-tab-pane>
</a-tabs> </a-tabs>
</a-col> </a-col>
@@ -302,7 +304,18 @@ export default {
uploadFile, uploadFile,
PersonnelSelection PersonnelSelection
}, },
props: ['url'], props: {
url: {
type: Object,
default: {},
require: true
},
certCategoryParamsInfoEOListItem: {
type: Array,
default: [],
require: false
}
},
data() { data() {
return { return {
controlType: [ // 控件类型 controlType: [ // 控件类型
@@ -457,6 +470,12 @@ export default {
this.title = '编辑' this.title = '编辑'
this.$nextTick(() => { this.$nextTick(() => {
this.formInline = value this.formInline = value
this.contentList = this.certCategoryParamsInfoEOListItem
console.log(this.contentList,'this.contentListthis.contentListthis.contentList')
this.contentList.map((item,index) => {
item.textVal = item.certCategory_dictText
})
console.log(this.contentList,'333333333333')
}) })
}, },
handleCancel() { handleCancel() {
@@ -468,6 +487,8 @@ export default {
if (res) { if (res) {
this.$refs.ruleForm.validate(valid => { this.$refs.ruleForm.validate(valid => {
if (valid) { if (valid) {
// this.$refs.ruleFormItem.validate(valid => {
// if (valid) {
let url = '' let url = ''
let Action let Action
this.formInline.paramsTemplateId = this.$route.query.id this.formInline.paramsTemplateId = this.$route.query.id
@@ -498,6 +519,8 @@ export default {
this.confirmLoading = false this.confirmLoading = false
} }
}) })
// }
// })
} }
}) })
} else { } else {
@@ -97,7 +97,7 @@
@showSizeChange="SizeChange" @showSizeChange="SizeChange"
/> />
</div> </div>
<addModel :url="url" ref="addModelRef" @addModelList="addModelList"/> <addModel :url="url" ref="addModelRef" @addModelList="addModelList" :certCategoryParamsInfoEOListItem='certCategoryParamsInfoEOList'/>
</a-card> </a-card>
</template> </template>
@@ -116,6 +116,7 @@ export default {
}, },
data() { data() {
return { return {
certCategoryParamsInfoEOList: [],
orderBy: '1', orderBy: '1',
selectedRowKeysArray: '', selectedRowKeysArray: '',
token:Vue.ls.get(ACCESS_TOKEN), token:Vue.ls.get(ACCESS_TOKEN),
@@ -296,6 +297,7 @@ export default {
let _this = this let _this = this
getAction(_this.url.queryById, { id: item.id }).then((res) => { getAction(_this.url.queryById, { id: item.id }).then((res) => {
if (res.success) { if (res.success) {
this.certCategoryParamsInfoEOList = res.result.certCategoryParamsInfoEOList
this.$refs.addModelRef.editModel(JSON.parse(JSON.stringify(res.result))) this.$refs.addModelRef.editModel(JSON.parse(JSON.stringify(res.result)))
} }
}) })