文档工具-虚拟认证清单维护-编辑
This commit is contained in:
@@ -20,7 +20,7 @@
|
|||||||
<a-form-model-item class="itemModel" prop="serialNumber">
|
<a-form-model-item class="itemModel" prop="serialNumber">
|
||||||
<j-dict-select-tag class="box-input"
|
<j-dict-select-tag class="box-input"
|
||||||
v-model="formInline.serialNumber"
|
v-model="formInline.serialNumber"
|
||||||
:disabled="disabled"
|
:disabled="true"
|
||||||
:placeholder="$t('PleaseSelect')+$t('regulationNo')"
|
:placeholder="$t('PleaseSelect')+$t('regulationNo')"
|
||||||
:type="'select'"
|
:type="'select'"
|
||||||
:triggerChange="false"/>
|
:triggerChange="false"/>
|
||||||
@@ -39,7 +39,7 @@
|
|||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
||||||
:type="'select'"
|
:type="'select'"
|
||||||
:triggerChange="false"/>
|
:triggerChange="false" :dictCode="'duty_territory'"/>
|
||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</a-col>
|
||||||
@@ -68,12 +68,10 @@
|
|||||||
<span class="title-text-text" :title="$t('category')">{{$t('category')}}</span>
|
<span class="title-text-text" :title="$t('category')">{{$t('category')}}</span>
|
||||||
</div>
|
</div>
|
||||||
<a-form-model-item class="itemModel" prop="category">
|
<a-form-model-item class="itemModel" prop="category">
|
||||||
<j-dict-select-tag class="box-input"
|
<a-input class="box-input"
|
||||||
v-model="formInline.category"
|
v-model="formInline.category"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:placeholder="$t('PleaseSelect')+$t('category')"
|
:placeholder="$t('PleaseEnter')+$t('category')" />
|
||||||
:type="'select'"
|
|
||||||
:triggerChange="false"/>
|
|
||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</a-col>
|
||||||
@@ -84,12 +82,10 @@
|
|||||||
<span class="title-text-text" :title="$t('inspectionItems')">{{$t('inspectionItems')}}</span>
|
<span class="title-text-text" :title="$t('inspectionItems')">{{$t('inspectionItems')}}</span>
|
||||||
</div>
|
</div>
|
||||||
<a-form-model-item class="itemModel" prop="inspectionItem">
|
<a-form-model-item class="itemModel" prop="inspectionItem">
|
||||||
<j-dict-select-tag class="box-input"
|
<a-input class="box-input"
|
||||||
v-model="formInline.inspectionItem"
|
v-model="formInline.inspectionItem"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:placeholder="$t('PleaseSelect')+$t('inspectionItems')"
|
:placeholder="$t('PleaseEnter')+$t('inspectionItems')"/>
|
||||||
:type="'select'"
|
|
||||||
:triggerChange="false"/>
|
|
||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</a-col>
|
||||||
@@ -99,15 +95,36 @@
|
|||||||
<div class="box-title-text">
|
<div class="box-title-text">
|
||||||
<div class="title-text">
|
<div class="title-text">
|
||||||
<span class="Required">*</span>
|
<span class="Required">*</span>
|
||||||
<span class="title-text-text" :title="$t('Deliverables')">{{$t('Deliverables')}}</span>
|
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
|
||||||
</div>
|
</div>
|
||||||
<a-form-model-item class="itemModel" prop="deliverable">
|
<a-form-model-item class="itemModel" prop="configItem">
|
||||||
<j-dict-select-tag class="box-input"
|
<a-input class="box-input"
|
||||||
v-model="formInline.deliverable"
|
v-model="formInline.configItem"
|
||||||
:disabled="disabled"
|
:placeholder="$t('PleaseEnter')+$t('configurationItem')"/>
|
||||||
:placeholder="$t('PleaseSelect')+$t('Deliverables')"
|
</a-form-model-item>
|
||||||
:type="'select'"
|
</div>
|
||||||
:triggerChange="false"/>
|
</a-col>
|
||||||
|
<a-col :span="12">
|
||||||
|
<div class="box-title-text">
|
||||||
|
<div class="title-text">
|
||||||
|
<span class="Required">*</span>
|
||||||
|
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
|
||||||
|
</div>
|
||||||
|
<a-form-model-item class="itemModel"
|
||||||
|
prop="deliverableType"
|
||||||
|
:rules="[{ required: true, message: $t('typeOfDeliverables') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||||
|
>
|
||||||
|
<a-tree-select
|
||||||
|
tree-node-filter-prop="title"
|
||||||
|
v-model="formInline.deliverableType"
|
||||||
|
:maxTagCount="1"
|
||||||
|
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||||
|
class="box-input"
|
||||||
|
style="width: 100%"
|
||||||
|
:tree-data="DeliverableTreeList"
|
||||||
|
tree-checkable
|
||||||
|
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
|
||||||
|
/>
|
||||||
</a-form-model-item>
|
</a-form-model-item>
|
||||||
</div>
|
</div>
|
||||||
</a-col>
|
</a-col>
|
||||||
@@ -133,6 +150,7 @@ export default {
|
|||||||
confirmLoading: false,
|
confirmLoading: false,
|
||||||
formInline: {},
|
formInline: {},
|
||||||
disabled: false,
|
disabled: false,
|
||||||
|
DeliverableTreeList: [],
|
||||||
rules: {
|
rules: {
|
||||||
serialNumber: [
|
serialNumber: [
|
||||||
{
|
{
|
||||||
@@ -179,6 +197,9 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
this.getDeliverableTree()
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
handleCancel() {
|
handleCancel() {
|
||||||
this.visible = false
|
this.visible = false
|
||||||
@@ -187,6 +208,9 @@ export default {
|
|||||||
this.visible = true
|
this.visible = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.formInline = item || {}
|
this.formInline = item || {}
|
||||||
|
if (this.formInline.deliverableType) {
|
||||||
|
this.formInline.deliverableType = this.formInline.deliverableType.split(',')
|
||||||
|
}
|
||||||
this.$refs.ruleForm.clearValidate()
|
this.$refs.ruleForm.clearValidate()
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@@ -194,6 +218,11 @@ export default {
|
|||||||
this.$refs.ruleForm.validate(valid => {
|
this.$refs.ruleForm.validate(valid => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
let formInline = JSON.parse(JSON.stringify(this.formInline))
|
let formInline = JSON.parse(JSON.stringify(this.formInline))
|
||||||
|
Object.keys(formInline).forEach(res => {
|
||||||
|
if (formInline[res] && formInline[res] instanceof Array) {
|
||||||
|
formInline[res] = formInline[res].join(',')
|
||||||
|
}
|
||||||
|
})
|
||||||
this.confirmLoading = true
|
this.confirmLoading = true
|
||||||
postAction(this.url.editModel, formInline).then((res) => {
|
postAction(this.url.editModel, formInline).then((res) => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
@@ -212,6 +241,15 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
getDeliverableTree() {
|
||||||
|
getAction('/sys/category/getDeliverableTree', {}).then((res) => {
|
||||||
|
if (res.success) {
|
||||||
|
this.DeliverableTreeList = res.result
|
||||||
|
} else {
|
||||||
|
this.DeliverableTreeList = []
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
+10
-3
@@ -286,6 +286,13 @@ export default {
|
|||||||
ellipsis: true,
|
ellipsis: true,
|
||||||
scopedSlots: { customRender: 'inspectionItems' }
|
scopedSlots: { customRender: 'inspectionItems' }
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
title: this.$t('configurationItem'),
|
||||||
|
align: 'left',
|
||||||
|
dataIndex: 'configItem',
|
||||||
|
width: 150,
|
||||||
|
ellipsis: true,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
title: 'WVTA ID',
|
title: 'WVTA ID',
|
||||||
align: 'left',
|
align: 'left',
|
||||||
@@ -303,14 +310,14 @@ export default {
|
|||||||
{
|
{
|
||||||
title: this.$t('areaOfResponsibility'),
|
title: this.$t('areaOfResponsibility'),
|
||||||
align: 'left',
|
align: 'left',
|
||||||
dataIndex: 'dutyTerritory',
|
dataIndex: 'dutyTerritoryName',
|
||||||
width: 200,
|
width: 200,
|
||||||
ellipsis: true,
|
ellipsis: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: this.$t('Deliverables'),
|
title: this.$t('typeOfDeliverables'),
|
||||||
align: 'left',
|
align: 'left',
|
||||||
dataIndex: 'deliverable',
|
dataIndex: 'deliverableTypeName',
|
||||||
width: 200,
|
width: 200,
|
||||||
ellipsis: true,
|
ellipsis: true,
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user