no message
Former-commit-id: 1b2f1baeae33e808752807c3a81a1c223f1d6977 Former-commit-id: ad497bd41f2cc3e768dfe3ac26f93d6f14f966db Former-commit-id: b02a77a0a87900942921eab8f587c9b6409ab1b7
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
"github-markdown-css": "^2.10.0",
|
||||
"highlight.js": "^9.12.0",
|
||||
"js-cookie": "^2.2.0",
|
||||
"lodash.clonedeep": "^4.5.0",
|
||||
"lodash.get": "^4.4.2",
|
||||
"marked": "^0.3.9",
|
||||
"mockjs": "^1.0.1-beta3",
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="100" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="small">编辑</el-button>
|
||||
<el-button v-bind="editButtonSettingMaker(scope)">编辑</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -66,7 +66,7 @@ export default {
|
||||
name,
|
||||
address1,
|
||||
address2,
|
||||
__edit: true // 在这里可以添加额外的判断逻辑
|
||||
__edit: false // 在这里可以添加额外的判断逻辑
|
||||
})
|
||||
return val.map(e => rowFilter(e))
|
||||
},
|
||||
@@ -95,6 +95,13 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
// 返回编辑按钮需要的参数
|
||||
editButtonSettingMaker (scope) {
|
||||
const isEdit = scope.row.__edit
|
||||
return {
|
||||
size: 'small'
|
||||
}
|
||||
},
|
||||
// 测试
|
||||
log (scope) {
|
||||
console.log(scope)
|
||||
|
||||
Reference in New Issue
Block a user