章志文 1 周之前
父節點
當前提交
0414f6a1b1

+ 2 - 1
.env.development

@@ -18,4 +18,5 @@ VITE_PWA = false
 VITE_API_URL = /api
 
 # 开发环境跨域代理,支持配置多个
-VITE_PROXY = [["/api","http://192.168.43.77:18088"]]
+# VITE_PROXY = [["/api","http://192.168.43.77:18088"]]
+VITE_PROXY = [["/api","http://192.168.127.123:18088"]]

+ 15 - 3
src/views/alarm/allDevice/index.vue

@@ -698,8 +698,6 @@ const showControl = () => {
 watch(isDark, () => { showDevice(), showPeriod(), showWeather(), showElement(), showControl() });
 
 onMounted(() => {
-
-
 	// getFTP()
 	// getCertificate()
 	getPlatforms()
@@ -708,9 +706,23 @@ onMounted(() => {
 	// showWeather()
 	// showElement()
 	// showControl()
-
 })
+let intervalId;
 
+onActivated(() => {
+	intervalId = setInterval(() => {
+		// getList();
+		weatherInfo()
+		getCertificate();
+		getFTP();
+		getDeviceStatus();
+		getArrive();
+	}, 600 * 1000);
+});
+
+onDeactivated(() => {
+	clearInterval(intervalId);
+});
 </script>
 <style scoped lang="scss">
 .el-row .el-col {

+ 2 - 2
src/views/alarm/singleStationData/index.vue

@@ -77,11 +77,11 @@
 
 								<div style="font-weight: bold;">危险天气</div>
 								<div v-if="!weatherInfoArr || weatherInfoArr.length <= 0"
-									style="text-align: center;margin-top: 15px;padding-bottom: 20px;color: red;font-weight: bold;">
+									style="text-align: center;margin-top: 15px;padding-bottom: 20px;font-weight: bold;">
 									无</div>
 								<div v-else v-for="item in weatherInfoArr" :key="item"
 									style="text-align: center;margin-top: 15px;padding-bottom: 20px;color: red;font-weight: bold;">
-									{{ findLabelByValue(dataTypeList, item.data_type) }}-{{ item.data_value }}</div>
+									{{ findLabelByValue(dataTypeList, item.data_type) }}{{ item.data_value }}</div>
 
 							</div>
 						</div>

+ 126 - 63
src/views/analysis/featureCurves/index.vue

@@ -21,8 +21,8 @@
 						<el-date-picker v-model="dateRange" value-format="YYYY-MM-DD HH:mm"
 							:format="value1 ? 'YYYY-MM-DD' : 'YYYY-MM-DD HH:mm'"
 							:type="value1 ? 'daterange' : 'datetimerange'" range-separator="-" start-placeholder="开始时间"
-							end-placeholder="结束时间" :disabled-date="disabledDate"
-							@focus="handleFocus" @calendar-change="handleChange" @change="handleDateChange"
+							end-placeholder="结束时间" :disabled-date="disabledDate" @focus="handleFocus"
+							@calendar-change="handleChange" @change="handleDateChange"
 							:default-time="[new Date(2000, 1, 1, 0, 0), new Date(2000, 1, 1, new Date().getHours(), 0)]"
 							style="width: 300px;"></el-date-picker>
 					</div>
@@ -43,32 +43,32 @@
 		</div>
 		<div class="main_list">
 			<el-row :gutter="15">
-				<template v-if="array.length>0">
-					<el-col :xs="24" :sm="12" :md="8" :lg="8">
-					<div class="chart_item zhuti">
-						<div style="font-weight: bold;" class="item_title">
-							<span>2分钟平均风向 ( ° )/2分钟平均风速 ( m/s )</span>
+				<template v-if="array.length > 0">
+					<el-col :xs="24" :sm="12" :md="8" :lg="8" v-if="windLineArr && windLineArr.length > 0">
+						<div class="chart_item zhuti">
+							<div style="font-weight: bold;" class="item_title">
+								<span>2分钟平均风向 ( ° )/2分钟平均风速 ( m/s )</span>
+							</div>
+							<div class="mt5">
+								<div ref="wind" class="ve-ring" style="height: 330px"></div>
+							</div>
 						</div>
-						<div class="mt5">
-							<div ref="wind" class="ve-ring" style="height: 330px"></div>
+					</el-col>
+					<el-col :xs="24" :sm="12" :md="8" :lg="8" v-for="(item, index) in array" :key="item.data_id">
+						<div class="chart_item zhuti">
+							<div style="font-weight: bold;" class="item_title">
+								<span>{{ item.data_name }} ( {{ item.data_unit ? item.data_unit : '' }} )</span>
+							</div>
+							<div class="mt5">
+								<div :id="'Access' + index" class="ve-ring" style="height: 330px"></div>
+							</div>
 						</div>
-					</div>
-				</el-col>
-				<el-col :xs="24" :sm="12" :md="8" :lg="8" v-for="(item, index) in array" :key="item.data_id">
-					<div class="chart_item zhuti">
-						<div style="font-weight: bold;" class="item_title">
-							<span>{{ item.data_name }} ( {{ item.data_unit ? item.data_unit : '' }} )</span>
-						</div>
-						<div class="mt5">
-							<div :id="'Access' + index" class="ve-ring" style="height: 330px"></div>
-						</div>
-					</div>
-				</el-col>
+					</el-col>
 
 				</template>
 				<el-col :span="24" v-else>
-					<div class="chart_item zhuti">
-						<el-empty description="暂无数据" />
+					<div class="chart_item zhuti nodata">
+						<el-empty style="height: 100%;" description="暂无数据" />
 					</div>
 				</el-col>
 
@@ -219,12 +219,8 @@
 					<div class="selected-list-c">
 						<template v-for="(item, index) in copiedCustomizeColumns" :key="item.id">
 							<div :class="selectedItemIndex === index ? 'selected-item-tag-active' : 'selected-item-tag'"
-								@click="changeSelected(index)"
-                   draggable="true"
-                   @dragstart="dragStart($event, index)"
-                   @dragover.prevent
-                   @drop="drop($event, index)"
-              >{{ item.data_name }}</div>
+								@click="changeSelected(index)" draggable="true" @dragstart="dragStart($event, index)"
+								@dragover.prevent @drop="drop($event, index)">{{ item.data_name }}</div>
 						</template>
 					</div>
 					<div class="button-container">
@@ -254,29 +250,29 @@ import { getDataItemList, getPlatformList, getRgDataList, getTacRecordList } fro
 import { Platform } from "@/api/interface";
 import { parseTime } from '@/utils/index';
 import { isToday, isWithinThirtyMinutes, getTimeStamp, getStamp, isDateFuture, isDateRangeWithinDays } from "@/utils/dateTime";
-import {useUserStore} from "@/stores/modules/user";
+import { useUserStore } from "@/stores/modules/user";
 const value1 = ref(true)
-const dateRange = ref<[any, any]>([parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00',  parseTime(new Date(), '{y}-{m}-{d} {h}') + ':00']);
+const dateRange = ref<[any, any]>([parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d} {h}') + ':00']);
 const changetype = (e) => {
 	if (!e) {
 		dateRange.value = [parseTime(getTimeStamp(1), '{y}-{m}-{d} {h}:{i}'), parseTime(new Date(), '{y}-{m}-{d} {h}:{i}')]
-	}else {
+	} else {
 		dateRange.value = [parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d} {h}') + ':00'];
 	}
 	getHistoryList()
 }
 
 const dragStart = (event, index) => {
-  event.dataTransfer.effectAllowed = 'move';
-  // 保存当前拖动的元素索引
-  event.dataTransfer.setData('text/plain', index.toString());
+	event.dataTransfer.effectAllowed = 'move';
+	// 保存当前拖动的元素索引
+	event.dataTransfer.setData('text/plain', index.toString());
 };
 
 const drop = (event, index) => {
-  const draggedIndex = parseInt(event.dataTransfer.getData('text/plain'));
-  // 移动数组中的元素来更新顺序
-  const draggedItem = copiedCustomizeColumns.value.splice(draggedIndex, 1)[0];
-  copiedCustomizeColumns.value.splice(index, 0, draggedItem);
+	const draggedIndex = parseInt(event.dataTransfer.getData('text/plain'));
+	// 移动数组中的元素来更新顺序
+	const draggedItem = copiedCustomizeColumns.value.splice(draggedIndex, 1)[0];
+	copiedCustomizeColumns.value.splice(index, 0, draggedItem);
 };
 
 const handleDateRangeChange = (newVal) => {
@@ -302,16 +298,16 @@ const handleDateChange = async (e) => {
 	} else {
 		if (!value1.value) {
 			// if (isWithinThirtyMinutes(e[0], e[1])) {
-				// 获取参数
-				getHistoryList()
+			// 获取参数
+			getHistoryList()
 
 			// } else {
 			// 	ElMessage.error("分钟模式下时间间隔不能大于3小时");
 			// }
 		} else {
 			// if (isDateRangeWithinDays(e[0], e[1], 7)) {
-				await handleDateRangeChange(e)
-				getHistoryList()
+			await handleDateRangeChange(e)
+			getHistoryList()
 			// } else {
 			// 	ElMessage.error("正点模式下时间间隔不能大于7天");
 			// }
@@ -540,14 +536,58 @@ const toggleSelection = (item) => {
 	if (item.isSelected) {
 		//添加
 		copiedCustomizeColumns.value.push(item)
+		if (item.data_id == 1) {
+			historyColumns.value.push({
+				data_r_table: "SHI_SHI_LIU_YAO_SU_SHU_JU",
+				data_id: 2,
+				data_type: "风",
+				data_item: "ER_FEN_ZHONG_PING_JUN_FENG_XIANG",
+				data_name: "2分钟风向",
+				data_unit: "°",
+				data_h_table: "LI_SHI_LIU_YAO_SU_SHU_JU",
+				data_value: "",
+				data_order: 0,
+				data_condition: 0
+			})
+
+		} else if (item.data_id == 2) {
+			historyColumns.value.push({
+				data_id: 1,
+				data_r_table: "SHI_SHI_LIU_YAO_SU_SHU_JU",
+				data_type: "风",
+				data_name: "2分钟风速",
+				data_item: "ER_FEN_ZHONG_PING_JUN_FENG_SU",
+				data_unit: "m/s",
+				data_h_table: "LI_SHI_LIU_YAO_SU_SHU_JU",
+				data_value: "",
+				data_order: 0,
+				data_condition: 0
+			})
+		}
 	} else {
 		//删除
 		copiedCustomizeColumns.value = copiedCustomizeColumns.value.filter(column => column.data_id !== item.data_id);
+		historyColumns.value = historyColumns.value.filter(column => column.data_id !== item.data_id);
+		if (item.data_id == 1) {
+			historyColumns.value = historyColumns.value.filter(column => column.data_id !== 2);
+			copiedCustomizeColumns.value = copiedCustomizeColumns.value.filter(column => column.data_id !== 2);
+
+		} else if (item.data_id == 2) {
+			historyColumns.value = historyColumns.value.filter(column => column.data_id !== 1);
+			copiedCustomizeColumns.value = copiedCustomizeColumns.value.filter(column => column.data_id !== 1);
+
+		}
 	}
 
 }
 const handleSetting = () => {
-	copiedCustomizeColumns.value = [...customizeColumns.value]
+	copiedCustomizeColumns.value = [...customizeColumns.value, ...historyColumns.value].reduce((acc, item) => {
+		if (!acc.some(existingItem => existingItem.data_id === item.data_id)) {
+			acc.push(item);
+		}
+		return acc;
+	}, []);
+	// copiedCustomizeColumns.value = [...customizeColumns.value]
 	elementList.value.forEach(element => {
 		const column = copiedCustomizeColumns.value.find(col => col.data_id === element.data_id);
 		if (column) {
@@ -606,7 +646,7 @@ const pageable = ref({
 	pageNum: 1,
 
 });
-let historyColumns = [
+let historyColumns = ref([
 	{
 		data_id: 202,
 		data_r_table: "SHI_SHI_LIU_YAO_SU_SHU_JU",
@@ -668,8 +708,21 @@ let historyColumns = [
 		data_order: 0,
 		data_condition: 0,
 		isSelected: true
+	},
+	{
+		data_r_table: "SHI_SHI_LIU_YAO_SU_SHU_JU",
+		data_id: 106,
+		data_type: "温湿度",
+		data_item: "XIANG_DUI_SHI_DU",
+		data_name: "相对湿度",
+		data_unit: "%",
+		data_h_table: "LI_SHI_LIU_YAO_SU_SHU_JU",
+		data_value: "",
+		data_order: 0,
+		data_condition: 0,
+		isSelected: true
 	}
-]
+])
 
 // 查询自动站列表
 const queryas = ref<Platform>({
@@ -680,7 +733,7 @@ const queryas = ref<Platform>({
 
 
 const userStore = useUserStore();
-const platformList =ref<any>(computed(() => userStore.stations))
+const platformList = ref<any>(computed(() => userStore.stations))
 const selectPlatform = ref()
 
 const getPlatforms = async () => {
@@ -759,10 +812,11 @@ const Access = () => {
 						formatter: function (value) {
 							return value.replace(/ /g, '\n');
 						},
+						// interval: 0,
 					},
 					axisLine: {
-					onZero: false    //-----------重点
-				}
+						onZero: false    //-----------重点
+					}
 				},
 				yAxis: {
 					// min: minData1,
@@ -813,17 +867,17 @@ const tempLineArr = ref()
 const humidityLineArr = ref()
 const pressureLineArr = ref()
 const getHistoryList = async () => {
-	if (isDateFuture(dateRange.value[0]) ||isDateFuture(dateRange.value[1])) {
+	if (isDateFuture(dateRange.value[0]) || isDateFuture(dateRange.value[1])) {
 		ElMessage.error("不得选择未来的时间");
 		return false;
 	}
-	const arr = [...customizeColumns.value, ...historyColumns].reduce((acc, item) => {
+	const arr = [...customizeColumns.value, ...historyColumns.value].reduce((acc, item) => {
 		if (!acc.some(existingItem => existingItem.data_id === item.data_id)) {
 			acc.push(item);
 		}
 		return acc;
 	}, []);
-	const { data } = await getDataItemList({ ...pageable.value,  as_code_list: [pageable.value.as_code], data_items: arr, data_type: false, time_space: value1.value ? 60 : 1, end_time: getStamp(dateRange.value[1]), begin_time: getStamp(dateRange.value[0]) });
+	const { data } = await getDataItemList({ ...pageable.value, as_code_list: [pageable.value.as_code], data_items: arr, data_type: false, time_space: value1.value ? 60 : 1, end_time: getStamp(dateRange.value[1]), begin_time: getStamp(dateRange.value[0]) });
 	timeArr.value = data.list?.map(item => {
 		return formatDate(item.data_time_i, 1)
 	})
@@ -853,22 +907,27 @@ const getHistoryList = async () => {
 	});
 	array.value = Object.values(resultMap);
 	nextTick(() => {
-		if (array.value.length>0) Access();
+		if (array.value.length > 0) Access();
 	});
 	// console.log(array.value, 'array');
 
 
+	if (arr.some(item => item.data_id === 1)) {
+		windLineArr.value = data.list?.map(item => {
+			return {
+				value: item[1],
+				symbolRotate: adjustValue(item[2]),
+				symbolRotateStr: item[2]
+			}
+		})
+
+		nextTick(() => {
+			if (array.value.length > 0) showWind()
+		})
+	} else {
+		windLineArr.value = []
+	}
 
-	windLineArr.value = data.list?.map(item => {
-		return {
-			value: item[1],
-			symbolRotate: adjustValue(item[2]),
-			symbolRotateStr: item[2]
-		}
-	})
-	nextTick(()=>{
-		if (array.value.length>0) showWind()
-	})
 };
 function adjustValue(value) {
 	if (value === 'C') {
@@ -1307,4 +1366,8 @@ onMounted(() => {
 .el-button.is-link {
 	height: 32px;
 }
+
+.nodata {
+	height: calc(100vh - 220px);
+}
 </style>

+ 1 - 1
src/views/analysis/lightningArea/index.vue

@@ -29,7 +29,7 @@
 				</el-form-item>
 				<el-form-item>
 					<div>
-						<el-button type="primary" @click="handleDateChange">查询</el-button>
+						<el-button type="primary" @click="handleDateChange(dateRange)">查询</el-button>
 						<el-button plain @click="resetForm">重置</el-button>
 					</div>
 				</el-form-item>

+ 74 - 25
src/views/analysis/rainfall/index.vue

@@ -16,13 +16,18 @@
 				</el-form-item>
 				<el-form-item label="观测时间:" prop="base">
 					<div>
-						<el-switch v-model="value1" @change="changetype" class="ml-2" inline-prompt active-text="日"
-							inactive-text="小时" style="margin-right: 10px;" />
+						<!-- <el-switch v-model="value1" @change="changetype" class="ml-2" inline-prompt active-text="日"
+							inactive-text="小时" style="margin-right: 10px;" /> -->
+						<el-select v-model="value1" placeholder="Select"  @change="changetype"  style="width: 160px;margin-right: 20px;">
+							<el-option label="日数据" :value="1440" />
+							<el-option label="正点数据" :value="60" />
+							<el-option label="分钟数据" :value="1" />
+						</el-select>
 						<el-date-picker v-model="dateRange" value-format="YYYY-MM-DD HH:mm"
-							:format="value1 ? 'YYYY-MM-DD' : 'YYYY-MM-DD HH:mm'"
-							:type="value1 ? 'daterange' : 'datetimerange'" range-separator="-" start-placeholder="开始时间"
-							end-placeholder="结束时间" :disabled-date="disabledDate" @focus="handleFocus"
-							@calendar-change="handleChange" @change="handleDateChange"
+							:format="value1 === 1440 ? 'YYYY-MM-DD' : 'YYYY-MM-DD HH:mm'"
+							:type="value1 === 1440 ? 'daterange' : 'datetimerange'" range-separator="-"
+							start-placeholder="开始时间" end-placeholder="结束时间" :disabled-date="disabledDate"
+							@focus="handleFocus" @calendar-change="handleChange" @change="handleDateChange"
 							:default-time="[new Date(2000, 1, 1, 0, 0), new Date(2000, 1, 1, new Date().getHours(), 0)]"
 							style="width: 300px;"></el-date-picker>
 					</div>
@@ -40,8 +45,8 @@
 				<el-col :span="24">
 					<div class="chart_item zhuti">
 						<div style="font-weight: bold;" class="item_title">
-							<span v-if="value1">降水量(mm)</span>
-							<span v-else>小时累计降水量 ({{ isFANDOU ? '翻斗' : '称重'}})(mm)</span>
+							<span>降水量(mm)</span>
+							<!-- <span v-else>小时累计降水量 ({{ isFANDOU ? '翻斗' : '称重'}})(mm)</span> -->
 						</div>
 						<div class="mt5">
 							<div ref="data" class="data_box"></div>
@@ -64,15 +69,25 @@ import { Platform } from "@/api/interface";
 import { parseTime } from '@/utils/index';
 import { isToday, isWithinThirtyMinutes, getTimeStamp, getStamp, isWithin24Hours, isDateFuture, isDateRangeWithinDays } from "@/utils/dateTime";
 import { useUserStore } from "@/stores/modules/user";
-const value1 = ref(true)
+const value1 = ref(1440)
 const dateRange = ref<[any, any]>([parseTime(new Date(getTimeStamp(5)), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00']);
 const changetype = (e) => {
-	if (!e) {
-		dateRange.value = [parseTime(getTimeStamp(2), '{y}-{m}-{d} {h}:{i}'), parseTime(new Date(), '{y}-{m}-{d} {h}') + ':00']
-	} else {
-		dateRange.value = [parseTime(new Date(getTimeStamp(5)), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00']
+	console.log(e);
+	if (e == 1440) {
+	    dateRange.value = [parseTime(new Date(getTimeStamp(5)), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00']
+	}else if (e == 60) {
+	    dateRange.value = [parseTime(getTimeStamp(2), '{y}-{m}-{d} {h}:{i}'), parseTime(new Date(), '{y}-{m}-{d} {h}') + ':00']
+	}else {
+		dateRange.value = [parseTime(getTimeStamp(1), '{y}-{m}-{d} {h}:{i}'), parseTime(new Date(), '{y}-{m}-{d} {h}:{i}')]
 	}
 	getHistoryList()
+
+	
+	// if (!e) {
+	// 	dateRange.value = [parseTime(getTimeStamp(2), '{y}-{m}-{d} {h}:{i}'), parseTime(new Date(), '{y}-{m}-{d} {h}') + ':00']
+	// } else {
+	// 	dateRange.value = [parseTime(new Date(getTimeStamp(5)), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00']
+	// }
 }
 const handleDateRangeChange = (newVal) => {
 	const [startDate, endDate] = newVal;
@@ -95,7 +110,7 @@ const handleDateChange = async (e) => {
 	if (isDateFuture(e[0]) || isDateFuture(e[1])) {
 		ElMessage.error("不得选择未来的时间");
 	} else {
-		if (!value1.value) {
+		if (value1.value !== 1440) {
 			// if (isWithin24Hours(e[0], e[1])) {
 			// 获取参数
 			getHistoryList()
@@ -173,7 +188,31 @@ let historyColumns = [
 		data_order: 0,
 		data_condition: 0,
 		isSelected: true
-	},
+	}, {
+		data_id: 301,
+		data_r_table: "SHI_SHI_LIU_YAO_SU_SHU_JU",
+		data_type: "降水",
+		data_name: "分钟降水量(翻斗)",
+		data_item: "FEN_ZHONG_JIANG_SHUI_LIANG_FAN_DOU",
+		data_unit: "mm",
+		data_h_table: "LI_SHI_LIU_YAO_SU_SHU_JU",
+		data_value: "",
+		data_order: 0,
+		data_condition: 0,
+		isSelected: true
+	}, {
+		data_r_table: "SHI_SHI_LIU_YAO_SU_SHU_JU",
+		data_id: 311,
+		data_type: "降水",
+		data_item: "FEN_ZHONG_JIANG_SHUI_LIANG_CHENG_ZHONG",
+		data_name: "分钟降水量(称重)",
+		data_unit: "mm",
+		data_h_table: "LI_SHI_LIU_YAO_SU_SHU_JU",
+		data_value: "",
+		data_order: 0,
+		data_condition: 0,
+		isSelected: true
+	}
 ]
 
 // 查询自动站列表
@@ -218,7 +257,8 @@ function formatDate(timestamp, type) {
 const timeArr = ref()
 const dayArr = ref()
 const hourArr1 = ref()
-const isFANDOU=ref(false)
+const minArr = ref()
+const isFANDOU = ref(false)
 
 const getHistoryList = async () => {
 	if (isDateFuture(dateRange.value[0]) || isDateFuture(dateRange.value[1])) {
@@ -226,7 +266,7 @@ const getHistoryList = async () => {
 		return false;
 	}
 
-	const { data } = await getDataItemList({ ...pageable.value, as_code_list: [pageable.value.as_code], data_items: historyColumns, time_space: value1.value ? 1440 : 60, end_time: getStamp(dateRange.value[1]), begin_time: getStamp(dateRange.value[0]) });
+	const { data } = await getDataItemList({ ...pageable.value, as_code_list: [pageable.value.as_code], data_items: historyColumns, time_space: value1.value, end_time: getStamp(dateRange.value[1]), begin_time: getStamp(dateRange.value[0]) });
 	timeArr.value = data.list?.map(item => {
 		return formatDate(item.data_time_i, 1)
 	})
@@ -242,12 +282,21 @@ const getHistoryList = async () => {
 			return '0.0'
 		}
 	})
-	isFANDOU.value = data.list.some(item => {
-		// 尝试将项转换为数字,如果转换失败(例如,对于 '--'),则返回 NaN  
-		const number = Number(item[302]);
-		// 检查是否是一个有效的数字且大于 10  
-		return !isNaN(number) && number > 0;
-	});
+	minArr.value = data.list?.map(item => {
+		if (item[311] !== '0.0' && item[311] !== '--' && item[311] !== '/') {
+			return item[311]
+		} else if (item[301] !== '0.0' && item[301] !== '--' && item[311] !== '/') {
+			return item[301]
+		} else {
+			return '0.0'
+		}
+	})
+	// isFANDOU.value = data.list?.some(item => {
+	// 	// 尝试将项转换为数字,如果转换失败(例如,对于 '--'),则返回 NaN  
+	// 	const number = Number(item[302]);
+	// 	// 检查是否是一个有效的数字且大于 10  
+	// 	return !isNaN(number) && number > 0;
+	// });
 
 
 
@@ -269,7 +318,7 @@ const isDark = computed(() => globalStore.isDark);
 // resetForm
 const resetForm = () => {
 	dateRange.value = [parseTime(new Date(getTimeStamp(5)), '{y}-{m}-{d}') + ' 00:00', parseTime(new Date(), '{y}-{m}-{d}') + ' 00:00']
-	value1.value = true
+	value1.value = 1440
 	pageable.value.as_code = platformList.value[0].as_code
 	getHistoryList()
 };
@@ -334,7 +383,7 @@ const showData = () => {
 				type: 'bar',
 				barWidth: '50%',
 				color: '#88c1ff',
-				data: value1.value ? dayArr.value : hourArr1.value
+				data: value1.value===1440 ? dayArr.value : value1.value===60? hourArr1.value:minArr.value
 			}
 		]
 	};

+ 6 - 6
src/views/analysis/windSpeed/index.vue

@@ -373,11 +373,11 @@ const showData = () => {
 					},
 				},
 				{ name: 'NNW', max: windInfo.value.max },
-				{ name: 'NW°', max: windInfo.value.max },
+				{ name: 'NW', max: windInfo.value.max },
 				{ name: 'WNW', max: windInfo.value.max },
-				{ name: 'W°', max: windInfo.value.max },
+				{ name: 'W', max: windInfo.value.max },
 				{ name: 'WSW', max: windInfo.value.max },
-				{ name: 'WS°', max: windInfo.value.max },
+				{ name: 'WS', max: windInfo.value.max },
 				{ name: 'SSW', max: windInfo.value.max },
 				{ name: 'S', max: windInfo.value.max },
 				{ name: 'SSE', max: windInfo.value.max },
@@ -462,11 +462,11 @@ const showWind = () => {
 					},
 				},
 				{ name: 'NNW', max: windInfo.value.speedMax },
-				{ name: 'NW°', max: windInfo.value.speedMax },
+				{ name: 'NW', max: windInfo.value.speedMax },
 				{ name: 'WNW', max: windInfo.value.speedMax },
-				{ name: 'W°', max: windInfo.value.speedMax },
+				{ name: 'W', max: windInfo.value.speedMax },
 				{ name: 'WSW', max: windInfo.value.speedMax },
-				{ name: 'WS°', max: windInfo.value.speedMax },
+				{ name: 'WS', max: windInfo.value.speedMax },
 				{ name: 'SSW', max: windInfo.value.speedMax },
 				{ name: 'S', max: windInfo.value.speedMax },
 				{ name: 'SSE', max: windInfo.value.speedMax },

+ 16 - 16
src/views/system/stations/components/translation.vue

@@ -54,11 +54,11 @@
           <el-col :span="14">
             <div class="disposition-title" style="margin-top: 0px">其它</div>
             <div style="display: flex;align-items: center">
-              <el-checkbox disabled v-model="platformInfo.fybsjjgList[0]" label="风演变时间间隔【>m/s】" />
+              <el-checkbox disabled v-model="platformInfo.fybsjjgList[0]" true-value="1" false-value="0" label="风演变时间间隔【>m/s】" />
               <el-input disabled v-model="platformInfo.fybsjjgList[1]" style="width: 80px;margin-left: 5px" />
             </div>
             <div style="display: flex;align-items: center;margin-top: 10px">
-              <el-checkbox  disabled v-model="platformInfo.mfbqytjList[0]" label="毛发表启用条件【<℃】" />
+              <el-checkbox  disabled v-model="platformInfo.mfbqytjList[0]" true-value="1" false-value="0" label="毛发表启用条件【<℃】" />
               <el-input disabled v-model="platformInfo.mfbqytjList[1]" style="width: 80px;margin-left: 16px" />
               <div style="margin-left: 10px">系数1</div>
               <el-input disabled v-model="platformInfo.mfsdbdxhgxsList[0]" style="width: 80px;margin-left: 5px" />
@@ -70,23 +70,23 @@
               <el-input disabled v-model="platformInfo.mfsdbdxhgxsList[3]" style="width: 80px;margin-left: 5px" />
             </div>
             <div style="display: flex;align-items: center;margin-top: 10px">
-              <el-checkbox disabled v-model="platformInfo.fxcgqzbpcList[0]" label="风向传感器指北偏差" />
+              <el-checkbox disabled v-model="platformInfo.fxcgqzbpcList[0]" :true-value="1" :false-value="0" label="风向传感器指北偏差" />
               <el-input disabled v-model="platformInfo.fxcgqzbpcList[1]" style="width: 80px;margin-left: 38px" />
             </div>
             <el-row :gutter="20" style="margin-top: 10px">
               <el-col :span="12">
-                <el-checkbox disabled v-model="platformInfo.lbszdfxhqx" label="雷暴所在方向和去向" />
+                <el-checkbox disabled v-model="platformInfo.lbszdfxhqx" :true-value="1" :false-value="0" label="雷暴所在方向和去向" />
               </el-col>
               <el-col :span="12">
-                <el-checkbox disabled v-model="platformInfo.jyyszdfxhqx" label="积雨云所在方向和去向" />
+                <el-checkbox disabled v-model="platformInfo.jyyszdfxhqx" :true-value="1" :false-value="0" label="积雨云所在方向和去向" />
               </el-col>
             </el-row>
             <el-row :gutter="20" style="margin-top: 10px">
               <el-col :span="12">
-                <el-checkbox disabled v-model="platformInfo.ljszdfxhqx" label="龙卷所在方向和去向" />
+                <el-checkbox disabled v-model="platformInfo.ljszdfxhqx" :true-value="1||'1'" :false-value="0" label="龙卷所在方向和去向" />
               </el-col>
               <el-col :span="12">
-                <el-checkbox disabled v-model="platformInfo.bdy300mdyszdfxhqx" label="不大于300米低云所在的方向和去向" />
+                <el-checkbox disabled v-model="platformInfo.bdy300mdyszdfxhqx" :true-value="1" :false-value="0" label="不大于300米低云所在的方向和去向" />
               </el-col>
             </el-row>
             <div class="disposition-title" style="margin-top: 20px">设置干湿表型号</div>
@@ -157,10 +157,10 @@ const platformInfo=ref<any>({
   mfbqytjList:['',''],
   mfsdbdxhgxsList:['',''],
   fxcgqzbpcList:['',''],
-  lbszdfxhqx:'',
-  jyyszdfxhqx:'',
-  ljszdfxhqx:'',
-  bdy300mdyszdfxhqx:'',
+  lbszdfxhqx:1,
+  jyyszdfxhqx:1,
+  ljszdfxhqx:1,
+  bdy300mdyszdfxhqx:1,
   typeList:[{
     
   }]
@@ -172,11 +172,11 @@ const getPlatformListInfo = async () => {
     fybsjjgList:dataInfo?.fybsjjg?.split('|'),
     mfbqytjList:dataInfo?.mfbqytj?.split('|'),
     mfsdbdxhgxsList:dataInfo?.mfsdbdxhgxs?.split('|'),
-    fxcgqzbpcList:dataInfo?.fxcgqzbpc?.split('|'),
-    lbszdfxhqx:dataInfo?.lbszdfxhqs,
-    jyyszdfxhqx:dataInfo?.jyyszdfxhqs,
-    ljszdfxhqx:dataInfo?.ljszdfxhqs,
-    bdy300mdyszdfxhqx:dataInfo?.bdy300mdyszdfxhqs,
+    fxcgqzbpcList:[dataInfo?.fxcgqzbpc?1:0,dataInfo?.fxcgqzbpc],
+    lbszdfxhqx:dataInfo?.lbszdfxhqx,
+    jyyszdfxhqx:dataInfo?.jyyszdfxhqx,
+    ljszdfxhqx:dataInfo?.ljszdfxhqx,
+    bdy300mdyszdfxhqx:dataInfo?.bdy300mdyszdfxhqx,
     typeList:[{
       name:'球状干湿表(自然通风速度)',
       nofrozen:dataInfo?.qzgsb_zrtfsd?.split('|')[1],

+ 5 - 1
src/views/system/stations/components/verificationCertificate.vue

@@ -72,7 +72,7 @@
                 <el-radio-button v-for="(item, index) in seTypeList" :key="index" :label="item.name" :value="item.name"
                   plain />
               </template>
-              <el-radio-button  label="p" value="p" disabled
+              <el-radio-button v-else label="p" value="p" disabled
                   plain />
 
             </el-radio-group>
@@ -328,6 +328,7 @@ const handleUpdate = async (row?: any) => {
     acc[cal_probeid].push(item);
     return acc;
   }, {});
+  
 
   if (groupedData) {
     seTypeList.value = Object.keys(groupedData).map(key => ({
@@ -335,6 +336,7 @@ const handleUpdate = async (row?: any) => {
       list: groupedData[key]
     }));
   }
+  
   seTypeList.value.forEach(item => {
     item.list?.forEach(obj => {
       obj.cal_param_list = obj.cal_param.split(',').map(pair => {
@@ -343,6 +345,8 @@ const handleUpdate = async (row?: any) => {
       });
     });
   });
+  console.log(row,stationCal.value,list.value,groupedData,seTypeList.value);
+
   selectInfo.value = seTypeList.value[0]
   instrumentForm.value.type = seTypeList?.value[0]?.name
   instrumentForm.value.element = seTypeList?.value[0]?.list[0].cal_condition