|
|
@ -6,7 +6,7 @@ |
|
|
|
:column-name="defaultCategotyKey" |
|
|
|
@search="handleSearch" /> |
|
|
|
<el-card class="resi-card-table"> |
|
|
|
<div class="resi-row-btn"> |
|
|
|
<!-- <div class="resi-row-btn"> |
|
|
|
<el-button size="small" |
|
|
|
class="diy-button--add" |
|
|
|
@click="handleAdd">新增</el-button> |
|
|
@ -38,9 +38,8 @@ |
|
|
|
class="diy-button--add" |
|
|
|
size="small" |
|
|
|
@click="deleteBatch">批量删除</el-button> |
|
|
|
<!-- <el-button type="primary" size="small">下载人口模板</el-button> --> |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> --> |
|
|
|
<el-table ref="ref_table" |
|
|
|
:data="tableData" |
|
|
|
v-loading="tableLoading" |
|
|
@ -68,8 +67,8 @@ |
|
|
|
align="center" |
|
|
|
:fixed="item.columnName == 'NAME' ? 'left' : false" |
|
|
|
:show-overflow-tooltip="true" |
|
|
|
:width="item.width || computedWidth(item.label, item.itemType)" |
|
|
|
> |
|
|
|
<!-- :width="item.width || computedWidth(item.label, item.itemType)" --> |
|
|
|
<!-- :width="item.itemType === 'radio' ? computedWidth(item.label) : 180" --> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<a v-if="item.columnName == 'NAME'" |
|
|
@ -80,16 +79,19 @@ |
|
|
|
<span v-else>{{ handleFilterSpan(scope.row, item) }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column fixed="right" |
|
|
|
label="操作" |
|
|
|
<el-table-column label="操作" |
|
|
|
align="center" |
|
|
|
width="150"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button @click="joinBlacklist(scope.row)" |
|
|
|
type="text" |
|
|
|
size="small" |
|
|
|
class="div-table-button--detail">加入黑名单</el-button> |
|
|
|
<!-- <el-button @click="handleLook(scope.row)" |
|
|
|
type="text" |
|
|
|
size="small" |
|
|
|
class="btn-color-look">查看</el-button> --> |
|
|
|
<el-button @click="handleTransfer(scope.row)" |
|
|
|
<!-- <el-button @click="handleTransfer(scope.row)" |
|
|
|
type="text" |
|
|
|
size="small" |
|
|
|
class="div-table-button--detail">变动</el-button> |
|
|
@ -104,12 +106,8 @@ |
|
|
|
class="div-table-button--edit">修改</el-button> |
|
|
|
<el-popconfirm title="删除之后无法回复,确认删除?" |
|
|
|
@onConfirm="handleDel(scope.row)"> |
|
|
|
<!-- <el-button slot="reference" |
|
|
|
type="text" |
|
|
|
size="small" |
|
|
|
class="btn-color-del">删除</el-button> --> |
|
|
|
</el-popconfirm> |
|
|
|
</template> |
|
|
|
</template> --> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
@ -389,6 +387,21 @@ export default { |
|
|
|
console.log('document.documentElement.clientWidth', document.documentElement.clientHeight) |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
searchFilter (columnName) { |
|
|
|
const filterName = [ 'NAME', 'MOBILE', 'ID_CARD' ] |
|
|
|
return filterName.some(item => { |
|
|
|
return item == columnName |
|
|
|
}) |
|
|
|
}, |
|
|
|
tableHeaderFilter (columnName) { |
|
|
|
const filterName = [ 'NAME', 'GRID_ID', 'HOME_ID', 'MOBILE', 'ID_CARD', 'GENDER' ] |
|
|
|
return filterName.some(item => { |
|
|
|
return item == columnName |
|
|
|
}) |
|
|
|
}, |
|
|
|
joinBlacklist (row) { |
|
|
|
console.log(row) |
|
|
|
}, |
|
|
|
checkSelect (row, index) { |
|
|
|
|
|
|
|
return row.isChecked |
|
|
@ -921,7 +934,13 @@ export default { |
|
|
|
if (res.code !== 0) { |
|
|
|
return this.$message.error(res.msg) |
|
|
|
} else { |
|
|
|
this.tableHeader = res.data |
|
|
|
this.tableHeader = [] |
|
|
|
res.data.forEach(item => { |
|
|
|
if (this.tableHeaderFilter(item.columnName)) { |
|
|
|
this.tableHeader.push(item) |
|
|
|
} |
|
|
|
}) |
|
|
|
console.log('xxxxxxxxxxxxxxx', this.tableHeader) |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch(() => { |
|
|
@ -1065,7 +1084,12 @@ export default { |
|
|
|
return this.$message.error(res.msg) |
|
|
|
} else { |
|
|
|
console.log('获取查询详情成功--sss', res) |
|
|
|
this.searchList = res.data |
|
|
|
this.searchList = [] |
|
|
|
res.data.forEach(item => { |
|
|
|
if (this.searchFilter(item.columnName)) { |
|
|
|
this.searchList.push(item) |
|
|
|
} |
|
|
|
}) |
|
|
|
res.data.forEach((item) => { |
|
|
|
if (item.optionSourceType === 'remote') { |
|
|
|
this.getOptionsList(item.optionSourceValue).then((res) => { |
|
|
|