版本管理同步点击打开模型

This commit is contained in:
zhal 2023-09-26 17:07:19 +08:00
parent 98170379e4
commit 2d23da7acc

View File

@ -29,32 +29,32 @@
<el-dropdown-item v-if="mainRepository.folder && (isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm) " class="el-dropdown-row" @click.native="openUpdateFolder(mainRepository.id,mainRepository.name,mainRepository.desc,mainRepository.methodId,mainRepository.methodName)"> <el-dropdown-item v-if="mainRepository.folder && (isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm) " class="el-dropdown-row" @click.native="openUpdateFolder(mainRepository.id,mainRepository.name,mainRepository.desc,mainRepository.methodId,mainRepository.methodName)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">修改{{mainRepository.methodName}}</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">修改{{mainRepository.methodName}}</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item v-if="!mainRepository.folder" class="el-dropdown-row" @click.native="openDesigner(mainRepository.id)"> <el-dropdown-item v-if="!mainRepository.folder" class="el-dropdown-row" @click.native="openDesigner(item.id)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">打开模型</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">打开模型</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item v-if="(mainRepository.methodId =='default' && (isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)) || mainRepository.methodId !='default'" divided/> <el-dropdown-item v-if="(mainRepository.methodId =='default' && (isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)) || mainRepository.methodId !='default'" divided/>
<el-dropdown-item v-if="mainRepository.isFavorite" class="el-dropdown-row" @click.native="setFavorite('0', mainRepository.versionId, mainRepository.id)"> <el-dropdown-item v-if="mainRepository.isFavorite" class="el-dropdown-row" @click.native="setFavorite('0', mainRepository.versionId, item.id)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"><i class="iconfont" style="font-size: 12px;color: #FFB800;">&#xe618;</i></span><span style="font-size: 12px;">取消收藏</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"><i class="iconfont" style="font-size: 12px;color: #FFB800;">&#xe618;</i></span><span style="font-size: 12px;">取消收藏</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item v-else class="el-dropdown-row" @click.native="setFavorite('1', mainRepository.versionId, mainRepository.id)"> <el-dropdown-item v-else class="el-dropdown-row" @click.native="setFavorite('1', mainRepository.versionId, item.id)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"><i class="iconfont" style="font-size: 12px;">&#xe630;</i></span><span style="font-size: 12px;">收藏</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"><i class="iconfont" style="font-size: 12px;">&#xe630;</i></span><span style="font-size: 12px;">收藏</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item v-if="(isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)" class="el-dropdown-row" @click.native="moveFile(mainRepository.id)"> <el-dropdown-item v-if="(isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)" class="el-dropdown-row" @click.native="moveFile(item.id)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">移动至</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">移动至</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item v-if="(isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)" class="el-dropdown-row" @click.native="copyFiles(mainRepository.id)"> <el-dropdown-item v-if="(isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)" class="el-dropdown-row" @click.native="copyFiles(item.id)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">创建副本</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">创建副本</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item class="el-dropdown-row" @click.native="exportFiles(mainRepository.id)"> <el-dropdown-item class="el-dropdown-row" @click.native="exportFiles(item.id)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">导出</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">导出</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item class="el-dropdown-row" @click.native="openRepositoryInfoById('version',mainRepository)"> <el-dropdown-item class="el-dropdown-row" @click.native="openRepositoryInfoById('version',mainRepository)">
<div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">版本管理</span></div> <div style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"></span><span style="font-size: 12px;">版本管理</span></div>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item v-if="(isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)" divided style="height: 30px;line-height: 30px;" @click.native="removeFiles(mainRepository.id)"> <el-dropdown-item v-if="(isOlderVersion ? havingWritePerm : mainRepository.havingWritePerm)" divided style="height: 30px;line-height: 30px;" @click.native="removeFiles(item.id)">
<div class="text-important-color" style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"><i class="iconfont icon-lajitong1" style="font-size: 12px;"></i></span><span style="font-size: 12px;">删除模型</span></div> <div class="text-important-color" style="height: 100%;width: 100%;font-size: 14px;"><span style="display: inline-block;width: 20px;"><i class="iconfont icon-lajitong1" style="font-size: 12px;"></i></span><span style="font-size: 12px;">删除模型</span></div>
</el-dropdown-item> </el-dropdown-item>
@ -810,6 +810,7 @@
}; };
// //
awsuiAxios.post(data).then(function (ro) { awsuiAxios.post(data).then(function (ro) {
debugger;
if(ro.result == 'ok') { if(ro.result == 'ok') {
//isClickTreeRoot //isClickTreeRoot
// if(ro.data.mainRepository=="undefined"){ // if(ro.data.mainRepository=="undefined"){
@ -967,6 +968,7 @@
}) })
}, },
openDesigner(id) { openDesigner(id) {
debugger;
let that = this; let that = this;
if(that.isHighSecurity && that.isFileSecurity){ if(that.isHighSecurity && that.isFileSecurity){
const data = { const data = {
@ -1805,6 +1807,7 @@
} }
}, },
openRepositoryInfo(type) {// ' openRepositoryInfo(type) {// '
debugger;
let that = this; let that = this;
// //
if(that.isHighSecurity && that.isFileSecurity){ if(that.isHighSecurity && that.isFileSecurity){
@ -1835,6 +1838,7 @@
* @param currRepositoryDetailId * @param currRepositoryDetailId
*/ */
openRepositoryInfoById(type,mainRepository) {// openRepositoryInfoById(type,mainRepository) {//
debugger;
let that = this; let that = this;
// //
if(that.isHighSecurity && that.isFileSecurity){ if(that.isHighSecurity && that.isFileSecurity){
@ -1846,7 +1850,6 @@
} }
}; };
awsuiAxios.post(data).then(function (ro) { awsuiAxios.post(data).then(function (ro) {
debugger;
if(ro.result == 'ok') { if(ro.result == 'ok') {
that.$refs.repositoryInfo.openRepositoryInfoDlg(that, mainRepository.id, mainRepository.version, type, mainRepository.isUse, mainRepository.isPublish, mainRepository.isStop, mainRepository.isApproval, mainRepository.methodId); that.$refs.repositoryInfo.openRepositoryInfoDlg(that, mainRepository.id, mainRepository.version, type, mainRepository.isUse, mainRepository.isPublish, mainRepository.isStop, mainRepository.isApproval, mainRepository.methodId);
}else{ }else{