|
|
|
@ -1,21 +1,37 @@ |
|
|
|
<template> |
|
|
|
<div style="display: flex;width:100%;"> |
|
|
|
<div style="width:180;"> |
|
|
|
<!-- :row-class-name="tableRowClassName" --> |
|
|
|
<el-table :data="RegisterCheckList" width="180" |
|
|
|
:height="window.pageHeight < 600 ? 330:window.pageHeight-270" |
|
|
|
border highlight-current-row |
|
|
|
:row-style="{ height: '40px' }" :row-class-name="tableRowClassName" @row-click="rowClick"> |
|
|
|
<el-table-column prop="asbitemName" label="组合项目" width="180" /> |
|
|
|
@row-click="rowClick"> |
|
|
|
<el-table-column prop="asbitemName" label="组合项目" width="180"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<div> |
|
|
|
<el-tooltip class="item" effect="dark" content="未检" placement="top"> |
|
|
|
<i v-show="scope.row.completeFlag == '0'" class="el-icon-circle-plus" style="font-size: 18px;color: red;"></i> |
|
|
|
</el-tooltip> |
|
|
|
<el-tooltip class="item" effect="dark" content="已检" placement="top"> |
|
|
|
<i v-show="scope.row.completeFlag == '1'" class="el-icon-success" style="font-size: 18px;color: green;"></i> |
|
|
|
</el-tooltip> |
|
|
|
<el-tooltip class="item" effect="dark" content="弃检" placement="top"> |
|
|
|
<i v-show="scope.row.completeFlag == '2'" class="el-icon-remove" style="font-size: 18px;"></i> |
|
|
|
</el-tooltip> |
|
|
|
{{scope.row.asbitemName}} |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</div> |
|
|
|
<div :style="'width:' + (window.pageWidth - 180 - 110 - 45) + 'px;'"> |
|
|
|
<el-table :data="tableData" :width="(window.pageWidth - 330 - 80)" |
|
|
|
:height="window.pageHeight < 600 ? 330:window.pageHeight-270" |
|
|
|
border :row-style="{ height: '40px' }"> |
|
|
|
border highlight-current-row> |
|
|
|
<el-table-column prop="itemName" label="项目" width="150" /> |
|
|
|
<el-table-column prop="unitName" label="单位" width="90" /> |
|
|
|
<el-table-column prop="referenceRangeValue" label="参考范围" width="120" /> |
|
|
|
<el-table-column v-for="(item, index) of tableCols" :label="item" :prop="item" :key="index" width="150"> |
|
|
|
<el-table-column prop="unitName" label="单位" width="80" align="center"/> |
|
|
|
<el-table-column prop="referenceRangeValue" label="参考范围" width="80" align="center"/> |
|
|
|
<el-table-column v-for="(item, index) of tableCols" :label="item" :prop="item" :key="index" min-width="150" align="center"> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</div> |
|
|
|
@ -116,7 +132,7 @@ export default { |
|
|
|
this.tableRows = [] //动态行 |
|
|
|
this.tableCols = [] //动态列 |
|
|
|
|
|
|
|
console.log('tableData', tableData) |
|
|
|
// console.log('tableData', tableData) |
|
|
|
tableData.forEach(e => { |
|
|
|
if (this.tableRows.indexOf(e.itemName) == - 1) this.tableRows.push(e.itemName) |
|
|
|
if (this.tableCols.indexOf(e.checkDate) == - 1) this.tableCols.push(e.checkDate) |
|
|
|
@ -142,9 +158,9 @@ export default { |
|
|
|
}); |
|
|
|
this.tableData.push(item) |
|
|
|
}); |
|
|
|
console.log('this.tableRows', this.tableRows) |
|
|
|
console.log('this.tableCols', this.tableCols) |
|
|
|
console.log('this.tableData', this.tableData) |
|
|
|
// console.log('this.tableRows', this.tableRows) |
|
|
|
// console.log('this.tableCols', this.tableCols) |
|
|
|
// console.log('this.tableData', this.tableData) |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
@ -165,9 +181,7 @@ export default { |
|
|
|
}; |
|
|
|
</script> |
|
|
|
<style scoped> |
|
|
|
::v-deep .el-table td.el-table__cell, |
|
|
|
.el-table th.el-table__cell.is-leaf { |
|
|
|
padding: 0; |
|
|
|
} |
|
|
|
@import '../../assets/css/global_table.css'; |
|
|
|
|
|
|
|
</style> |
|
|
|
|