修改类型管理bug
This commit is contained in:
parent
21fd1572e7
commit
666248b402
@ -104,20 +104,40 @@ function confirmClick(formEl: any) {
|
||||
defaultHyperParams: info.value.defaultHyperParams,
|
||||
status: info.value.status,
|
||||
}
|
||||
addAlgorithms(params).then((res) => {
|
||||
addAlgorithms(params).then((res:any) => {
|
||||
if(res == true){
|
||||
ElMessage({
|
||||
type: "success",
|
||||
message: "新增成功",
|
||||
});
|
||||
gettableData();
|
||||
}
|
||||
dialogVisible.value = false;
|
||||
});
|
||||
} else if (info.value.algorithmId) {
|
||||
const params = {
|
||||
algorithmId: info.value.algorithmId,
|
||||
algorithmType: info.value.algorithmType,
|
||||
name: info.value.name,
|
||||
description: info.value.description,
|
||||
version: info.value.version,
|
||||
principle: info.value.principle,
|
||||
inputParams: info.value.inputParams,
|
||||
outputParams: info.value.outputParams,
|
||||
inferBaseUrl: info.value.inferBaseUrl,
|
||||
trainBaseUrl: info.value.trainBaseUrl,
|
||||
supportedDeviceTypes: info.value.supportedDeviceTypes,
|
||||
defaultHyperParams: info.value.defaultHyperParams,
|
||||
}
|
||||
updateAlgorithms(params).then((res) => {
|
||||
updateAlgorithms(params).then((res:any) => {
|
||||
if(res == true){
|
||||
ElMessage({
|
||||
type: "success",
|
||||
message: "修改成功",
|
||||
});
|
||||
gettableData();
|
||||
}
|
||||
|
||||
dialogVisible.value = false;
|
||||
});
|
||||
} else {
|
||||
@ -286,7 +306,7 @@ function changeStatus(row: any) {
|
||||
:modal="false" draggable :before-close="handleClose" :title="title"
|
||||
append-to-body width="1145px" height="600px">
|
||||
<el-form ref="infoForm" :model="info" :rules="rules" label-width="100px"
|
||||
style="margin-top: 20px;">
|
||||
style="margin-top: 20px;max-height: calc(100vh - 150px);overflow: auto;">
|
||||
<el-form-item label="算法名称" prop="name" style="width: 100%;" >
|
||||
<el-input v-model="info.name" style="width: 100%" placeholder="输入算法名称"></el-input>
|
||||
</el-form-item>
|
||||
@ -311,7 +331,7 @@ function changeStatus(row: any) {
|
||||
<el-input v-model="info.supportedDeviceTypes" style="width: 100%" placeholder="输入设备类型"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="默认超参" style="width: 100%;" >
|
||||
<el-input v-model="info.defaultHyperParams" style="width: 100%" placeholder="输入默认超参"></el-input>
|
||||
<el-input type="textarea" v-model="info.defaultHyperParams" :autosize="true" style="width: 100%" placeholder="输入默认超参"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="版本" style="width: 100%;" >
|
||||
<el-input v-model="info.version" style="width: 100%" placeholder="输入版本"></el-input>
|
||||
|
||||
@ -219,7 +219,7 @@ function submitClick(){
|
||||
|
||||
let data:any = {
|
||||
scenarioId: info.value.scenarioId,
|
||||
algorithm_type: info.value.algorithmType,
|
||||
algorithmType: info.value.algorithmType,
|
||||
name: info.value.name,
|
||||
description: info.value.description,
|
||||
keffThreshold: info.value.keffThreshold,
|
||||
@ -468,7 +468,7 @@ function initDeviceData(){
|
||||
</el-form-item>
|
||||
<el-form-item label="算法类型:" :disabled="title == '查看事故情景'">
|
||||
<el-select v-model="info.algorithmType" placeholder="请选择" style="width:100%;" clearable :disabled="title == '查看事故情景'">
|
||||
<el-option v-for="item in algorithmTypeData" :key="item.algorithmType" :label="item.name" :value="item.algorithmType" />
|
||||
<el-option v-for="item in algorithmTypeData" :key="item.algorithmType" :label="item.name + '(' + item.algorithmType + ')' " :value="item.algorithmType" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="设备算法配置映射:">
|
||||
|
||||
Loading…
Reference in New Issue
Block a user