src/views/model/pre/item/MmPredictItemChart.vue | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/views/model/pre/item/MmPredictItemForm.vue | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/views/model/pre/item/index.vue | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
src/views/model/pre/item/MmPredictItemChart.vue
@@ -3,6 +3,7 @@ title="预测数据" :close-on-click-modal="false" width="50%" @close="dialogClose" v-model="visible" > <el-form @@ -12,7 +13,6 @@ > <el-form-item label="开始时间"> <el-date-picker size="mini" v-model="dataForm.startTime" format="YYYY-MM-DD HH:mm:00" value-format="YYYY-MM-DD HH:mm:00" @@ -22,7 +22,6 @@ </el-form-item> <el-form-item label="结束时间"> <el-date-picker size="mini" v-model="dataForm.endTime" format="YYYY-MM-DD HH:mm:00" value-format="YYYY-MM-DD HH:mm:00" @@ -79,9 +78,16 @@ dataForm.value.id = row.id; dataForm.value.itemName = row.itemname; if (row.id) { myChart = echarts.init(chartDomPre.value); myChart.clear() nextTick(() => { myChart = echarts.init(chartDomPre.value); }); getDataList(); } } const dialogClose = () => { if (myChart) { myChart.dispose(); // 组件卸载时销毁实例 } } @@ -96,12 +102,12 @@ chartParams.endTime = dataForm.value.endTime; const data = await McsApi.getPreDataItemChart(chartParams) let legendData = [] if (data.legend && data.legend.length > 0) { data.legend.forEach(item => { legendData.push(item + ":" + '真实值') legendData.push(item + ":" + '预测值') }) } // if (data.legend && data.legend.length > 0) { // data.legend.forEach(item => { // legendData.push(item + ":" + '真实值') // legendData.push(item + ":" + '预测值') // }) // } let seriesData = [] if (data.predictTime) { @@ -134,6 +140,7 @@ Object.keys(data.viewMap).forEach(key => { let viewData = data.viewMap[key] if(viewData.realData) { legendData.push(key + ":" + '真实值') seriesData.push({ name: key + ":" + '真实值', type: "line", @@ -147,6 +154,7 @@ }, }) } legendData.push(key + ":" + '预测值') seriesData.push({ name: key + ":" + '预测值', type: "line", src/views/model/pre/item/MmPredictItemForm.vue
@@ -298,7 +298,7 @@ <el-table-column prop="valuetype" label="类型" align="center" min-width="150"/> <el-table-column prop="" label="值" align="center" min-width="200"> <template #default="scope"> <el-input size="mini" v-model="scope.row.value" maxlength="1000" <el-input v-model="scope.row.value" maxlength="1000" :disabled="scope.row.key === 'pyFile'" style="width:100%;height:100%"/> </template> @@ -372,14 +372,12 @@ <template #default="scope"> <el-button @click="addRow(scope.$index, dataForm.mmModelParamList)" type="text" size="mini"> type="text"> 添加 </el-button> <el-button @click="deleteRow(scope.$index, scope.row, dataForm.mmModelParamList)" type="text" size="mini"> type="text"> 删除 </el-button> </template> src/views/model/pre/item/index.vue
@@ -97,7 +97,7 @@ <el-table-column label="运行时间" min-width="150" align="center" prop="lastTime"/> <el-table-column label="运行状态" align="center" prop="runStatus"> <template #default="scope"> <dict-tag :type="DICT_TYPE.ITEM_RUN_STATUS" :value="scope.row.runStatus" /> <dict-tag :type="DICT_TYPE.ITEM_RUN_STATUS" :value="scope.row.runStatus || 200" /> </template> </el-table-column> <el-table-column label="运行耗时(ms)" align="center" prop="duration"/> @@ -106,17 +106,15 @@ <el-button link type="primary" size="mini" @click="openForm('update', scope.row.id, scope.row.itemtypename)" v-hasPermi="['model:pre-item:update']" > 编辑 </el-button> <el-button link size="mini" type="primary" @click="chartHandle(scope.row)">数据</el-button> <el-button link type="primary" @click="chartHandle(scope.row)">数据</el-button> <el-button link type="danger" size="mini" @click="handleDelete(scope.row.id)" v-hasPermi="['model:pre-item:delete']" >