修改模型管理 默认版本提示

This commit is contained in:
limengnan 2026-05-22 11:06:36 +08:00
parent 75bf0af5cd
commit 95dcc8aaa2
2 changed files with 6 additions and 6 deletions

View File

@ -252,7 +252,7 @@ onMounted(() => {
gettableData(); gettableData();
}); });
function changeStatus(row: any) { function changeStatus(row: any) {
ElMessageBox.confirm("确定是否激活此算法版本吗?", "激活提示", { ElMessageBox.confirm("确认将此版本设为默认版本吗?", "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
type: "warning", type: "warning",
@ -291,7 +291,7 @@ function changeShowResult(isShow:boolean){ // 切换显示结果模型
<el-select v-model="queryParams.deviceType" placeholder="请选择设备"style="width: 200px;margin-left: 10px" clearable @change="gettableData"> <el-select v-model="queryParams.deviceType" placeholder="请选择设备"style="width: 200px;margin-left: 10px" clearable @change="gettableData">
<el-option v-for="item in menuData" :key="item.itemCode" :label="item.dictName + '(' + item.itemCode + ')'" :value="item.itemCode" /> <el-option v-for="item in menuData" :key="item.itemCode" :label="item.dictName + '(' + item.itemCode + ')'" :value="item.itemCode" />
</el-select> </el-select>
<el-select v-model="queryParams.isCurrent" placeholder="请选择是否激活" <el-select v-model="queryParams.isCurrent" placeholder="请选择是否默认版本"
style="width: 200px;margin-left: 10px" clearable @change="gettableData"> style="width: 200px;margin-left: 10px" clearable @change="gettableData">
<el-option key="1" label="是" value="1" /> <el-option key="1" label="是" value="1" />
<el-option key="0" label="否" value="0" /> <el-option key="0" label="否" value="0" />
@ -316,7 +316,7 @@ function changeShowResult(isShow:boolean){ // 切换显示结果模型
<el-table-column prop="trainedAt" label="训练完成时间" width="170"></el-table-column> <el-table-column prop="trainedAt" label="训练完成时间" width="170"></el-table-column>
<el-table-column prop="modelPath" label="模型文件路径 " min-width="140"></el-table-column> <el-table-column prop="modelPath" label="模型文件路径 " min-width="140"></el-table-column>
<el-table-column prop="metrics" label="训练评估指标 " min-width="100"></el-table-column> <el-table-column prop="metrics" label="训练评估指标 " min-width="100"></el-table-column>
<el-table-column prop="updatedAt" label="是否激活" width="90" align="center"> <el-table-column prop="updatedAt" label="是否默认版本" width="120" align="center">
<template #default="scope"> <template #default="scope">
<!-- <el-switch <!-- <el-switch
v-model="scope.row.isCurrent" v-model="scope.row.isCurrent"
@ -336,7 +336,7 @@ function changeShowResult(isShow:boolean){ // 切换显示结果模型
style="display: flex;display: -webkit-flex; justify-content: space-around;-webkit-justify-content: space-around; "> style="display: flex;display: -webkit-flex; justify-content: space-around;-webkit-justify-content: space-around; ">
<img src="@/assets/table/view.png" alt="" title="查看详情" <img src="@/assets/table/view.png" alt="" title="查看详情"
@click="editClick(scope.row)" style="cursor: pointer; "> @click="editClick(scope.row)" style="cursor: pointer; ">
<img src="@/assets/table/activate.png" alt="" title="是否激活" <img src="@/assets/table/activate.png" alt="" title="默认版本设置"
@click="changeStatus(scope.row)" style="cursor: pointer; " v-hasPerm="['algorithmModel:activate']"> @click="changeStatus(scope.row)" style="cursor: pointer; " v-hasPerm="['algorithmModel:activate']">
<img v-if="scope.row.isCurrent == 0" src="@/assets/table/del.png" alt="" title="删除" <img v-if="scope.row.isCurrent == 0" src="@/assets/table/del.png" alt="" title="删除"
@click="delAloneClick(scope.row)" style="cursor: pointer; " v-hasPerm="['algorithmModel:delete']"> @click="delAloneClick(scope.row)" style="cursor: pointer; " v-hasPerm="['algorithmModel:delete']">