智能算法添加置顶按钮
This commit is contained in:
parent
c4597f6cbd
commit
91d3622d77
|
@ -129,13 +129,13 @@
|
|||
width="150"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<!-- <el-button
|
||||
v-if="$hasPermission('ability:bsabilityai:update')"
|
||||
<el-button
|
||||
v-if="scope.row.infoList.filter(val=>val.attrType=='组件类型')[0].attrValue == '智能算法'"
|
||||
type="text"
|
||||
size="small"
|
||||
@click="UpdateHandle(scope.row)"
|
||||
>{{ $t("update") }}</el-button
|
||||
> -->
|
||||
@click="toppingCapacity(scope.row)"
|
||||
>置顶</el-button
|
||||
>
|
||||
<el-button
|
||||
v-if="$hasPermission('ability:bsabilityai:update')"
|
||||
type="text"
|
||||
|
@ -314,6 +314,23 @@ export default {
|
|||
// this.fullScreen()
|
||||
},
|
||||
methods: {
|
||||
// 置顶
|
||||
toppingCapacity (item) {
|
||||
this.$http.put('/resource/pin_top/' + item.id).then(res => {
|
||||
console.log('置顶', res.data.code)
|
||||
if (res.data.code == 0) {
|
||||
this.$message({
|
||||
message: '置顶成功',
|
||||
type: 'success'
|
||||
})
|
||||
} else {
|
||||
this.$message({
|
||||
message: '置顶失败',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
reset () {
|
||||
this.$http
|
||||
.get(
|
||||
|
|
Loading…
Reference in New Issue