|
|
|
@@ -149,8 +149,12 @@ |
|
|
|
:class="{ disabled: !scope.row.isCanOper }" |
|
|
|
>{{ i18n.modify }}</a> |
|
|
|
<a class="op-btn" v-show="scope.row.modelType != 1" style="color:transparent;cursor:default;" >{{ i18n.modify }}</a> |
|
|
|
<a class="op-btn" v-show="repoIsPrivate == false && scope.row.isPrivate==true && scope.row.isCanOper">{{ i18n.modelaccess_setpublic }}</a> |
|
|
|
<a class="op-btn" v-show="repoIsPrivate == false && scope.row.isPrivate==false && scope.row.isCanOper">{{ i18n.modelaccess_setprivate }}</a> |
|
|
|
<a class="op-btn" v-show="repoIsPrivate == false && scope.row.isPrivate==true && scope.row.isCanOper" @click=" |
|
|
|
modifyModelStatus(scope.row.id, scope.row.cName, scope.row.rowKey,false) |
|
|
|
">{{ i18n.modelaccess_setpublic }}</a> |
|
|
|
<a class="op-btn" v-show="repoIsPrivate == false && scope.row.isPrivate==false && scope.row.isCanOper" @click=" |
|
|
|
modifyModelStatus(scope.row.id, scope.row.cName, scope.row.rowKey,true) |
|
|
|
">{{ i18n.modelaccess_setprivate }}</a> |
|
|
|
|
|
|
|
<a class="op-btn" |
|
|
|
:href="loadhref + scope.row.id" |
|
|
|
@@ -399,6 +403,20 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
modifyModelStatus(id, name, rowKey,isPrivate) { |
|
|
|
let row = { cName: name, id: id, rowKey: rowKey }; |
|
|
|
let _this = this; |
|
|
|
_this.$axios |
|
|
|
.put(_this.url + "modify_model_status", { |
|
|
|
params: { |
|
|
|
id: id, |
|
|
|
isPrivate:isPrivate, |
|
|
|
}, |
|
|
|
}) |
|
|
|
.then((res) => { |
|
|
|
_this.loadrefresh(row); |
|
|
|
}); |
|
|
|
}, |
|
|
|
deleteModel(id, name, rowKey) { |
|
|
|
let row = { cName: name, id: id, rowKey: rowKey }; |
|
|
|
let _this = this; |
|
|
|
|