|
|
@ -38,14 +38,15 @@ |
|
|
|
</el-card> |
|
|
|
|
|
|
|
<el-card> |
|
|
|
<!-- :span-method="mergeCells"--> |
|
|
|
<!-- default-expand-all--> |
|
|
|
<el-table |
|
|
|
:span-method="mergeCells" |
|
|
|
:data="formItemList" |
|
|
|
style="width: 100%;margin-bottom: 20px;" |
|
|
|
:span-method="mergeCells" |
|
|
|
style="width: 100%" |
|
|
|
row-key="id" |
|
|
|
border |
|
|
|
default-expand-all |
|
|
|
:tree-props="{children: 'children', hasChildren: 'hasChildren'}"> |
|
|
|
:tree-props="{children: 'children'}"> |
|
|
|
<el-table-column |
|
|
|
prop="formCode" |
|
|
|
label="表单编码" |
|
|
@ -61,6 +62,11 @@ |
|
|
|
label="表单项名称" |
|
|
|
width="180"> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="parentItemLabel" |
|
|
|
label="上级表单项" |
|
|
|
width="180"> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="optionSourceType" |
|
|
|
label="选项来源类型"> |
|
|
@ -213,10 +219,12 @@ export default { |
|
|
|
this.setMergeRowQty(httpData.data[i], httpData.data[i + 1], i === 0); |
|
|
|
|
|
|
|
// 设置hasChildren属性 |
|
|
|
item.hasChildren = (item.children.length > 0); |
|
|
|
// item.hasChildren = (item.children.length > 0); |
|
|
|
} |
|
|
|
|
|
|
|
debugger |
|
|
|
this.formItemList = httpData.data; |
|
|
|
console.log(this.formItemList) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
@ -349,9 +357,11 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
onClose() { |
|
|
|
onClose({ type: type }) { |
|
|
|
this.createDlgVisible = false; |
|
|
|
|
|
|
|
if (type === 'submit') { |
|
|
|
this.loadItemList() // 如果是提交,就重新加载表单 |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|