215 lines
7.5 KiB
Vue
215 lines
7.5 KiB
Vue
<template>
|
||
<div class="calculate">
|
||
<el-container class="container">
|
||
<el-header class="header">
|
||
<div class="headerMain">
|
||
<div class="namePart">
|
||
<span>名称:</span>
|
||
<el-input></el-input>
|
||
</div>
|
||
<div class="statusPart">
|
||
<span>状态:</span>
|
||
<el-select></el-select>
|
||
<el-button type="primary" plain>查询</el-button>
|
||
</div>
|
||
<el-button type="success" plain>注册/更新</el-button>
|
||
</div>
|
||
</el-header>
|
||
<el-main class="main">
|
||
<div class="modulesList">
|
||
<div class="moduleItem" :class="item.status === 1 ? 'runItem' : 'stopItem'" v-for="item in moduleList" :key="item.id">
|
||
<div class="itemMain">
|
||
<div class="header-main">
|
||
<div class="title">
|
||
{{ item.title }}
|
||
</div>
|
||
<div class="version">{{ '版本:' + item.version }}</div>
|
||
<div class="updateTime">{{ '更新于:' + item.updateTime }}</div>
|
||
</div>
|
||
<div class="main-main">
|
||
{{ item.desc }}
|
||
</div>
|
||
<div class="footer-main">
|
||
{{ '任务周期:' + item.taskRange }}
|
||
</div>
|
||
</div>
|
||
<div class="itemAside">
|
||
<el-button :type="item.status === 1 ? 'success' : ''">查看</el-button>
|
||
<el-button v-if="item.status === 2" type="success">激活</el-button>
|
||
<el-button v-if="item.status === 1" type="danger">禁用</el-button>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</el-main>
|
||
</el-container>
|
||
</div>
|
||
</template>
|
||
|
||
<script setup lang="ts">
|
||
import { ref } from 'vue'
|
||
const moduleList = ref([
|
||
{
|
||
id: 1,
|
||
status: 1,
|
||
title: '风场统计量实时计算模块',
|
||
version: '1.0.0',
|
||
updateTime: '2022-01-01 12:35:56',
|
||
desc: '此脚本以风场为单位,包含:全场总有功功率、全场总无功功率、全场平均风速等。',
|
||
taskRange: '0/5****?',
|
||
},
|
||
{
|
||
id: 2,
|
||
status: 2,
|
||
title: '单机组统计量实时计算模块',
|
||
version: '1.0.1',
|
||
updateTime: '2022-01-01 12:35:56',
|
||
desc: '此脚本以机组为单位,计算各机组的实时计算量,包含:有功可增量、有功可减量、4GC有功指令等',
|
||
taskRange: '0/5****?',
|
||
},
|
||
])
|
||
</script>
|
||
|
||
<style scoped lang="scss">
|
||
.calculate {
|
||
width: 100%;
|
||
height: 100%;
|
||
padding: 10px;
|
||
.container {
|
||
width: 100%;
|
||
height: 100%;
|
||
.header {
|
||
width: 100%;
|
||
height: 80px;
|
||
.headerMain {
|
||
width: 100%;
|
||
height: 100%;
|
||
padding: 20px;
|
||
display: flex;
|
||
align-items: center;
|
||
border-radius: 10px;
|
||
border: 1px solid #2f9e44;
|
||
.namePart {
|
||
display: flex;
|
||
align-items: center;
|
||
width: 350px;
|
||
margin-left: 30px;
|
||
.el-input {
|
||
width: 300px;
|
||
height: 40px;
|
||
}
|
||
}
|
||
.statusPart {
|
||
margin-left: 30px;
|
||
display: flex;
|
||
align-items: center;
|
||
width: 500px;
|
||
span {
|
||
display: flex;
|
||
width: 42px;
|
||
}
|
||
.el-select {
|
||
width: 300px;
|
||
}
|
||
:deep(.el-select__wrapper) {
|
||
width: 300px;
|
||
height: 40px;
|
||
}
|
||
.el-button {
|
||
margin-left: 20px;
|
||
width: 100px;
|
||
height: 40px;
|
||
}
|
||
}
|
||
.el-button {
|
||
margin-left: auto;
|
||
margin-right: 20px;
|
||
width: 100px;
|
||
height: 40px;
|
||
}
|
||
}
|
||
}
|
||
.main {
|
||
width: 100%;
|
||
height: calc(100% - 80px);
|
||
.modulesList {
|
||
width: 100%;
|
||
// min-height: 200px;
|
||
// height: 100%;
|
||
padding: 20px;
|
||
border-radius: 10px;
|
||
border: 1px solid #2f9e44;
|
||
overflow-y: auto;
|
||
max-height: 100%;
|
||
.moduleItem {
|
||
margin-top: 20px;
|
||
display: flex;
|
||
width: 100%;
|
||
min-height: 170px;
|
||
padding: 10px 20px;
|
||
border-radius: 20px;
|
||
border: 1px solid #333;
|
||
&:nth-child(1) {
|
||
margin-top: 0;
|
||
}
|
||
.itemMain {
|
||
min-width: 700px;
|
||
width: 90%;
|
||
height: 100%;
|
||
.header-main {
|
||
display: flex;
|
||
align-items: center;
|
||
width: 100%;
|
||
height: 50px;
|
||
.title {
|
||
font-size: 28px;
|
||
font-weight: bold;
|
||
}
|
||
.version {
|
||
margin-left: 30px;
|
||
min-width: 100px;
|
||
color: #2f9e44;
|
||
}
|
||
.updateTime {
|
||
margin-left: 30px;
|
||
color: #2f9e44;
|
||
}
|
||
}
|
||
.main-main {
|
||
display: flex;
|
||
align-items: center;
|
||
height: 50px;
|
||
color: #1d74c1;
|
||
}
|
||
.footer-main {
|
||
display: flex;
|
||
align-items: center;
|
||
height: 50px;
|
||
color: #ee9a24;
|
||
}
|
||
}
|
||
.itemAside {
|
||
display: flex;
|
||
flex-direction: column;
|
||
justify-content: center;
|
||
align-items: center;
|
||
width: 10%;
|
||
min-width: 100px;
|
||
.el-button {
|
||
margin: 10px 0;
|
||
width: 80px;
|
||
height: 40px;
|
||
}
|
||
}
|
||
}
|
||
.runItem {
|
||
background-color: #b2f2bb;
|
||
}
|
||
.stopItem {
|
||
background-color: #e9ecef;
|
||
}
|
||
}
|
||
}
|
||
}
|
||
}
|
||
</style>
|