commit
This commit is contained in:
@@ -93,6 +93,25 @@ layout("/layouts/platform_1.html"){
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
onTableRowDelete(id) {
|
||||
if (!id) {
|
||||
return
|
||||
}
|
||||
this.$confirm('确定删除该数据吗?', '提示', {
|
||||
type: 'warning',
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消'
|
||||
}).then(() => {
|
||||
$.post(this.tableDeleteUrl, {id}).then((res) => {
|
||||
if (res.code === 0) {
|
||||
this.$message.success("删除成功")
|
||||
this.pageData()
|
||||
} else {
|
||||
this.$message.error(res.msg)
|
||||
}
|
||||
})
|
||||
}).catch(() => {})
|
||||
},
|
||||
publishedChange(val, row) {
|
||||
const params = JSON.parse(JSON.stringify(row))
|
||||
this.$set(params, 'published', val)
|
||||
|
||||
Reference in New Issue
Block a user