| | |
| | | VITE_APP_IMG_BASEURL='https://www.huiwuyuntong.com/water-hydropower-beta/upload' |
| | | |
| | | #后端本地 |
| | | VITE_APP_PUBLIC_REQUEST_API = 'https://www.huiwuyuntong.com/water-hydropower-beta' |
| | | VITE_APP_PUBLIC_REQUEST_API = 'http://192.168.0.67:8036' |
| | |
| | | </div> |
| | | </div> |
| | | <div class="info-btn"> |
| | | <div class="fullScreen" @click="handleFullScreen(index)"> |
| | | <div class="fullScreen" v-if="item.url" @click="handleFullScreen(index)"> |
| | | <img src="@/assets/images/flow/screenIconWhite.png" alt="" /> |
| | | 全屏 |
| | | </div> |
| | |
| | | .info-btn { |
| | | width: 15%; |
| | | padding: 1rem 0; |
| | | display: flex; |
| | | align-items: flex-end; |
| | | flex-direction: column; |
| | | justify-content: space-between; |
| | | position: relative; |
| | | :deep(.el-button) { |
| | | color: #fff; |
| | | background: rgba(94, 229, 92, 0.6); |
| | | border-radius: 4px 4px 4px 4px; |
| | | border: 1px solid rgba(94, 229, 92, 0.6); |
| | | position: absolute; |
| | | bottom: 1rem; |
| | | } |
| | | .fullScreen{ |
| | | width: 100%; |
| | |
| | | import { getGraphicData } from '@/api/screen/graphic/index.js' |
| | | import { debounce } from '@/utils/tool.js' |
| | | |
| | | const deepCOnfig = [ |
| | | { label: '10米', value: 10 }, |
| | | { label: '20米', value: 20 }, |
| | | { label: '30米', value: 30 }, |
| | | { label: '40米', value: 40 }, |
| | | { label: '50米', value: 50 }, |
| | | { label: '60米', value: 60 }, |
| | | { label: '70米', value: 70 }, |
| | | { label: '80米', value: 80 }, |
| | | { label: '90米', value: 90 }, |
| | | { label: '100米', value: 100 }, |
| | | ] |
| | | |
| | | const menuList = ref([]) |
| | | const timeType = ref(1) //时间类型 1日 2周 3月 4季 5年 |
| | | const showTime = ref(moment().format('YYYY-MM-DD')); //展示时间 |
| | | const timeValue = ref(moment().format('YYYY-MM-DD')) //处理后得时间 |
| | | const searchVal = ref() |
| | | const tempDeep = ref(50) |
| | | const graphicRef = ref(null) |
| | | const chartsRef = ref([]) //动态生成图表ref |
| | | const chartData = ref([]) |
| | |
| | | yAxis: { |
| | | type: 'value', |
| | | name: unit, |
| | | max: 40, |
| | | min: 0, |
| | | nameTextStyle: { |
| | | color: '#fff', |
| | | fontSize: '1rem' |
| | |
| | | pointId: point, |
| | | pointName: searchVal.value, |
| | | dataTime: timeValue.value, |
| | | waterLevel: tempDeep.value |
| | | } |
| | | getGraphicData(data).then(async res => { |
| | | chartData.value = res.data |
| | |
| | | v-model="showTime" |
| | | type="date" |
| | | placeholder="选择时间" |
| | | style="width: 15rem" |
| | | style="width: 12rem" |
| | | @change="getTime" |
| | | /> |
| | | <el-date-picker |
| | |
| | | type="week" |
| | | format="YYYY年 ww[周]" |
| | | placeholder="选择时间" |
| | | style="width: 15rem" |
| | | style="width: 12rem" |
| | | @change="getTime" |
| | | /> |
| | | <el-date-picker |
| | |
| | | v-model="showTime" |
| | | type="month" |
| | | placeholder="选择时间" |
| | | style="width: 15rem" |
| | | style="width: 12rem" |
| | | @change="getTime" |
| | | /> |
| | | <Quarter |
| | |
| | | placeholder="选择时间" |
| | | :default-value="showTime" |
| | | clearable |
| | | style="width: 15rem" |
| | | style="width: 12rem" |
| | | @change="getTime" |
| | | /> |
| | | <el-date-picker |
| | |
| | | v-model="showTime" |
| | | type="year" |
| | | placeholder="选择时间" |
| | | style="width: 15rem" |
| | | style="width: 12rem" |
| | | @change="getTime" |
| | | /> |
| | | <div class="name">深度</div> |
| | | <el-select v-model="tempDeep" style="width: 10rem"> |
| | | <el-option |
| | | v-for="item in deepCOnfig" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value" |
| | | /> |
| | | </el-select> |
| | | <el-input v-model="searchVal" style="width: 15rem" clearable placeholder="请输入监测点名称"/> |
| | | <el-button @click="() => getChartData()"> |
| | | <el-icon> |
| | |
| | | |
| | | const menuList = ref([]) |
| | | const monitorList = ref([]) |
| | | const selectDeep = ref([]) |
| | | const monitorConfig = ref({}) |
| | | const userType = ref(getUserType()) |
| | | const monitorRef = ref() |
| | |
| | | } |
| | | pointApi().search(data).then(res => { |
| | | //0-未报警, 1-下限报警, 2-上限报警 |
| | | monitorList.value = res.data.list.filter(el => el.parentId !== 0).map(item => { |
| | | monitorList.value = res.data.list.filter(el => el.parentId !== 0).map((item, index) => { |
| | | selectDeep.value[index] = item?.dataList[0].code |
| | | return { |
| | | ...item, |
| | | errorType: Number(item.waterTemperature) < Number(item.lowWaterLevel) ? 1 : Number(item.waterTemperature) > Number(item.tallWaterLevel) ? 2 : 0 |
| | |
| | | <div class="item-data"> |
| | | <div class="data"> |
| | | <div class="name">水温:</div> |
| | | <div class="val"><span>{{ item.waterTemperature }}</span>°C</div> |
| | | <div class="val"><span>{{ item?.dataList?.find(f => f.code === selectDeep[index]).value }}</span>°C</div> |
| | | </div> |
| | | <div class="data"> |
| | | <div class="name">水位:</div> |
| | | <div class="val"><span>{{ item.waterLevel }}</span>m</div> |
| | | <div class="val"> |
| | | <el-select |
| | | v-model="selectDeep[index]" |
| | | class="val-select" |
| | | placeholder="Select" |
| | | style="width: 12rem" |
| | | > |
| | | <el-option |
| | | v-for="item in item?.dataList" |
| | | :key="item.code" |
| | | :label='item.code' |
| | | :value="item.code" |
| | | /> |
| | | </el-select>m |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="item-status"> |
| | |
| | | <div class="item-btn"> |
| | | <el-button size="large" type="success" @click="setMonitorData(item)">应用</el-button> |
| | | </div> |
| | | <div class="item-error" v-if="[1,2].includes(item.errorType)"> |
| | | <img src="@/assets/images/warning.png" alt="" /> |
| | | <div v-if="item.errorType === 1">水温达到下限值</div> |
| | | <div v-else-if="item.errorType === 2">水温达到上限值</div> |
| | | </div> |
| | | <!-- <div class="item-error" v-if="[1,2].includes(item.errorType)">--> |
| | | <!-- <img src="@/assets/images/warning.png" alt="" />--> |
| | | <!-- <div v-if="item.errorType === 1">水温达到下限值</div>--> |
| | | <!-- <div v-else-if="item.errorType === 2">水温达到上限值</div>--> |
| | | <!-- </div>--> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | font-size: 22px; |
| | | |
| | | .val { |
| | | span { |
| | | span{ |
| | | display: inline-block; |
| | | font-size: 30px; |
| | | padding: 0 30px; |
| | | } |
| | | .val-select{ |
| | | padding: 0 30px; |
| | | :deep(.el-select__wrapper){ |
| | | background-color: transparent; |
| | | box-shadow: none; |
| | | border-radius: 0; |
| | | border-bottom: 1px solid #fff; |
| | | font-size: 20px; |
| | | .el-select__caret{ |
| | | color: #fff; |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | import moment from "moment"; |
| | | |
| | | const cascaderOption = { label: 'pointName', value: 'id', children: 'childrenList', expandTrigger: 'hover', emitPath: false }; //级联选择器配置 |
| | | const deepCOnfig = [ |
| | | { label: '10米', value: 10 }, |
| | | { label: '20米', value: 20 }, |
| | | { label: '30米', value: 30 }, |
| | | { label: '40米', value: 40 }, |
| | | { label: '50米', value: 50 }, |
| | | { label: '60米', value: 60 }, |
| | | { label: '70米', value: 70 }, |
| | | { label: '80米', value: 80 }, |
| | | { label: '90米', value: 90 }, |
| | | { label: '100米', value: 100 }, |
| | | ] |
| | | |
| | | |
| | | const menuList = ref([]) |
| | | const pointId = ref('') |
| | |
| | | value: moment().format('YYYY-MM-DD'), |
| | | data: [] |
| | | }) |
| | | |
| | | const tempDeep = ref(50) |
| | | const wenduChartRef = ref() |
| | | const shuiweiChartRef = ref() |
| | | let wenduCharts = null; |
| | |
| | | const data = { |
| | | type: wendu.type, |
| | | dataTime: wendu.value, |
| | | pointId: pointId.value |
| | | pointId: pointId.value, |
| | | waterLevel: tempDeep.value |
| | | } |
| | | getStatisticsData(data).then(res => { |
| | | wendu.data = res.data |
| | |
| | | <div class="item-t"> |
| | | <div class="name">水温汇总统计</div> |
| | | <div class="select"> |
| | | <el-cascader size="large" v-model="pointId" :options="menuList" :show-all-levels="false" :props="cascaderOption" clearable @change="getTempData" /> |
| | | <el-select v-model="tempDeep" style="width: 10rem"> |
| | | <el-option |
| | | v-for="item in deepCOnfig" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value" |
| | | /> |
| | | </el-select> |
| | | <el-cascader v-model="pointId" :options="menuList" :show-all-levels="false" :props="cascaderOption" clearable @change="getTempData" /> |
| | | <el-radio-group v-model="wendu.type" @change="handleSelectType('wendu')"> |
| | | <el-radio :value="1">日</el-radio> |
| | | <el-radio :value="3">月</el-radio> |
| | |
| | | color: #fff; |
| | | } |
| | | .select{ |
| | | :deep(.el-select) { |
| | | width: 8rem; |
| | | margin-right: 2rem; |
| | | .el-select__wrapper{ |
| | | background-color: transparent; |
| | | box-shadow: none; |
| | | border: 1px solid #fff; |
| | | } |
| | | .el-select__placeholder{ |
| | | color: #fff; |
| | | } |
| | | } |
| | | :deep(.el-cascader){ |
| | | width: 12rem; |
| | | margin-right: 2rem; |
| | | .el-input__wrapper{ |
| | | background-color: transparent; |