askin vor 2 Jahren
Ursprung
Commit
ccbd84875d
52 geänderte Dateien mit 1839 neuen und 476 gelöschten Zeilen
  1. 120 121
      sources/client/vrv-moblie/config/api.js
  2. 35 2
      sources/client/vrv-moblie/pages/dataCurve/dataCurve.vue
  3. 16 6
      sources/client/vrv-moblie/pages/device/deviceInfo/deviceInfo.vue
  4. 24 2
      sources/client/vrv-moblie/pages/parameterSetting/parameterSetting.vue
  5. 360 23
      sources/client/vrv-moblie/pages/runningState/runningState.vue
  6. 240 75
      sources/client/vrv-moblie/pages/systemParameter/systemParameter.vue
  7. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map
  8. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map
  9. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/components/best-gauge/best-gauge.js.map
  10. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/alarm/alarm.js.map
  11. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/alarmRecord/alarmRecord.js.map
  12. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/dataCurve/dataCurve.js.map
  13. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/device/device.js.map
  14. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/device/deviceInfo/deviceInfo.js.map
  15. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/login/login.js.map
  16. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/maintenanceRecord/maintenanceRecord.js.map
  17. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/operator/operator.js.map
  18. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/operator/operatorInfo/operatorInfo.js.map
  19. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/operatorLog/operatorLog.js.map
  20. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/parameterSetting/parameterSetting.js.map
  21. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/power/power.js.map
  22. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/project/project.js.map
  23. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/project/projectEdit/projectEdit.js.map
  24. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/project/projectInfo/projectInfo.js.map
  25. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/rolePower/rolePower.js.map
  26. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/roleShowPower/roleShowPower.js.map
  27. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/runningState/runningState.js.map
  28. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/staticProject/staticProject.js.map
  29. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/systemParameter/systemParameter.js.map
  30. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/systemSet/systemSet.js.map
  31. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/user/user.js.map
  32. 71 72
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/app.json
  33. 7 8
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/common/vendor.js
  34. 37 4
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/dataCurve/dataCurve.js
  35. 13 3
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/device/deviceInfo/deviceInfo.js
  36. 24 2
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/parameterSetting/parameterSetting.js
  37. 331 2
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/runningState/runningState.js
  38. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/runningState/runningState.wxml
  39. 7 1
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/runningState/runningState.wxss
  40. 159 2
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/systemParameter/systemParameter.js
  41. 1 1
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/systemParameter/systemParameter.wxml
  42. 8 1
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/systemParameter/systemParameter.wxss
  43. 18 1
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/project.config.json
  44. 27 0
      sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/project.private.config.json
  45. 1 1
      sources/client/vrv-platform/src/views/project/list.vue
  46. 0 1
      sources/server/vrv/run/application.pid
  47. 26 15
      sources/server/vrv/vrv-core-api/src/main/java/com/kuyuntech/vrv/coreapi/service/core/DeviceParamService.java
  48. 3 9
      sources/server/vrv/vrv-core-service/src/main/java/com/kuyuntech/vrv/coreservice/dao/core/DeviceParamDao.java
  49. 93 64
      sources/server/vrv/vrv-core-service/src/main/java/com/kuyuntech/vrv/coreservice/service/core/impl/DeviceParamServiceImpl.java
  50. 164 0
      sources/server/vrv/vrv-platform/src/main/java/com/kuyuntech/vrv/platform/configuration/core/MqttConfiguration.java
  51. 11 34
      sources/server/vrv/vrv-platform/src/main/java/com/kuyuntech/vrv/platform/controller/core/DeviceParamController.java
  52. 17 0
      sources/server/vrv/vrv-platform/src/main/java/com/kuyuntech/vrv/platform/util/core/CompareParamValue.java

+ 120 - 121
sources/client/vrv-moblie/config/api.js

@@ -4,126 +4,125 @@ const root = "http://127.0.0.1:9999";
 //接口auth
 const api = {
 
-        user: {
-            list: `${root}/user/list`,
-            add: `${root}/user/add`,
-            update: `${root}/user/update`,
-            detail: `${root}/user/detail`,
-            delete: `${root}/user/delete`,
-            batchDelete: `${root}/user/batchDelete`,
-            bindRole: `${root}/user/bindRole`,
-            bindOperator: `${root}/user/bindOperator`,
-        },
-        operator: {
-            list: `${root}/operator/list`,
-            add: `${root}/operator/add`,
-            update: `${root}/operator/update`,
-            detail: `${root}/operator/detail`,
-            delete: `${root}/operator/delete`,
-            batchDelete: `${root}/operator/batchDelete`
-        },
-        project: {
-            list: `${root}/project/list`,
-            operatorList: `${root}/project/operatorList`,
-            add: `${root}/project/add`,
-            update: `${root}/project/update`,
-            detail: `${root}/project/detail`,
-            delete: `${root}/project/delete`,
-            batchDelete: `${root}/project/batchDelete`
-        },
-        gateway: {
-            list: `${root}/gateway/list`,
-            add: `${root}/gateway/add`,
-            update: `${root}/gateway/update`,
-            detail: `${root}/gateway/detail`,
-            delete: `${root}/gateway/delete`,
-            batchDelete: `${root}/gateway/batchDelete`
-        },
-        device: {
-            list: `${root}/device/list`,
-            add: `${root}/device/add`,
-            update: `${root}/device/update`,
-            detail: `${root}/device/detail`,
-            delete: `${root}/device/delete`,
-            batchDelete: `${root}/device/batchDelete`,
-        },
-        deviceParam: {
-            list: `${root}/deviceParam/list`,
-            add: `${root}/deviceParam/add`,
-            update: `${root}/deviceParam/update`,
-            detail: `${root}/deviceParam/detail`,
-            delete: `${root}/deviceParam/delete`,
-            batchDelete: `${root}/deviceParam/batchDelete`,
-        },
-        deviceAlarmRecord: {
-            list: `${root}/deviceAlarmRecord/list`,
-            add: `${root}/deviceAlarmRecord/add`,
-            update: `${root}/deviceAlarmRecord/update`,
-            detail: `${root}/deviceAlarmRecord/detail`,
-            delete: `${root}/deviceAlarmRecord/delete`,
-            batchDelete: `${root}/deviceAlarmRecord/batchDelete`,
-        },
-        deviceAlarmConfig: {
-            list: `${root}/deviceAlarmConfig/list`,
-            add: `${root}/deviceAlarmConfig/add`,
-            update: `${root}/deviceAlarmConfig/update`,
-            detail: `${root}/deviceAlarmConfig/detail`,
-            delete: `${root}/deviceAlarmConfig/delete`,
-            batchDelete: `${root}/deviceAlarmConfig/batchDelete`,
-        },
-        deviceAlarmRepairRecord: {
-            list: `${root}/deviceAlarmRepairRecord/list`,
-            add: `${root}/deviceAlarmRepairRecord/add`,
-            update: `${root}/deviceAlarmRepairRecord/update`,
-            detail: `${root}/deviceAlarmRepairRecord/detail`,
-            delete: `${root}/deviceAlarmRepairRecord/delete`,
-            batchDelete: `${root}/deviceAlarmRepairRecord/batchDelete`,
-        },
-        operatorLog: {
-            list: `${root}/operatorLog/list`,
-            add: `${root}/operatorLog/add`,
-            update: `${root}/operatorLog/update`,
-            detail: `${root}/operatorLog/detail`,
-            delete: `${root}/operatorLog/delete`,
-            batchDelete: `${root}/operatorLog/batchDelete`,
-        },
-        auth: {
-            verifyCode: `${root}/auth/verifyCode`,
-            login: `${root}/auth/login`,
-            updateUserPassword: `${root}/auth/updateUserPassword`,
-            userInfo: `${root}/auth/userInfo`,
-            logout: `${root}/auth/logout`,
-        },
-        role: {
-            list: `${root}/role/list`,
-            add: `${root}/role/add`,
-            update: `${root}/role/update`,
-            detail: `${root}/role/detail`,
-            delete: `${root}/role/delete`,
-        },
-        power: {
-            list: `${root}/power/list`,
-            add: `${root}/power/add`,
-            update: `${root}/power/update`,
-            detail: `${root}/power/detail`,
-            delete: `${root}/power/delete`,
-        },
-        rolePower: {
-            list: `${root}/rolePower/list`,
-            add: `${root}/rolePower/add`,
-            update: `${root}/rolePower/update`,
-            detail: `${root}/rolePower/detail`,
-            delete: `${root}/rolePower/delete`,
-        },
-        menu: {}
-    }
-;
+	user: {
+		list: `${root}/user/list`,
+		add: `${root}/user/add`,
+		update: `${root}/user/update`,
+		detail: `${root}/user/detail`,
+		delete: `${root}/user/delete`,
+		batchDelete: `${root}/user/batchDelete`,
+		bindRole: `${root}/user/bindRole`,
+		bindOperator: `${root}/user/bindOperator`,
+	},
+	operator: {
+		list: `${root}/operator/list`,
+		add: `${root}/operator/add`,
+		update: `${root}/operator/update`,
+		detail: `${root}/operator/detail`,
+		delete: `${root}/operator/delete`,
+		batchDelete: `${root}/operator/batchDelete`
+	},
+	project: {
+		list: `${root}/project/list`,
+		operatorList: `${root}/project/operatorList`,
+		add: `${root}/project/add`,
+		update: `${root}/project/update`,
+		detail: `${root}/project/detail`,
+		delete: `${root}/project/delete`,
+		batchDelete: `${root}/project/batchDelete`
+	},
+	gateway: {
+		list: `${root}/gateway/list`,
+		add: `${root}/gateway/add`,
+		update: `${root}/gateway/update`,
+		detail: `${root}/gateway/detail`,
+		delete: `${root}/gateway/delete`,
+		batchDelete: `${root}/gateway/batchDelete`
+	},
+	device: {
+		list: `${root}/device/list`,
+		add: `${root}/device/add`,
+		update: `${root}/device/update`,
+		detail: `${root}/device/detail`,
+		delete: `${root}/device/delete`,
+		batchDelete: `${root}/device/batchDelete`,
+	},
+	deviceParam: {
+		list: `${root}/deviceParam/list`,
+		add: `${root}/deviceParam/add`,
+		update: `${root}/deviceParam/update`,
+		updateParam: `${root}/deviceParam/updateParam`,
+		detail: `${root}/deviceParam/detail`,
+		delete: `${root}/deviceParam/delete`,
+		batchDelete: `${root}/deviceParam/batchDelete`,
+	},
+	deviceAlarmRecord: {
+		list: `${root}/deviceAlarmRecord/list`,
+		add: `${root}/deviceAlarmRecord/add`,
+		update: `${root}/deviceAlarmRecord/update`,
+		detail: `${root}/deviceAlarmRecord/detail`,
+		delete: `${root}/deviceAlarmRecord/delete`,
+		batchDelete: `${root}/deviceAlarmRecord/batchDelete`,
+	},
+	deviceAlarmConfig: {
+		list: `${root}/deviceAlarmConfig/list`,
+		add: `${root}/deviceAlarmConfig/add`,
+		update: `${root}/deviceAlarmConfig/update`,
+		detail: `${root}/deviceAlarmConfig/detail`,
+		delete: `${root}/deviceAlarmConfig/delete`,
+		batchDelete: `${root}/deviceAlarmConfig/batchDelete`,
+	},
+	deviceAlarmRepairRecord: {
+		list: `${root}/deviceAlarmRepairRecord/list`,
+		add: `${root}/deviceAlarmRepairRecord/add`,
+		update: `${root}/deviceAlarmRepairRecord/update`,
+		detail: `${root}/deviceAlarmRepairRecord/detail`,
+		delete: `${root}/deviceAlarmRepairRecord/delete`,
+		batchDelete: `${root}/deviceAlarmRepairRecord/batchDelete`,
+	},
+	operatorLog: {
+		list: `${root}/operatorLog/list`,
+		add: `${root}/operatorLog/add`,
+		update: `${root}/operatorLog/update`,
+		detail: `${root}/operatorLog/detail`,
+		delete: `${root}/operatorLog/delete`,
+		batchDelete: `${root}/operatorLog/batchDelete`,
+	},
+	auth: {
+		verifyCode: `${root}/auth/verifyCode`,
+		login: `${root}/auth/login`,
+		updateUserPassword: `${root}/auth/updateUserPassword`,
+		userInfo: `${root}/auth/userInfo`,
+		logout: `${root}/auth/logout`,
+	},
+	role: {
+		list: `${root}/role/list`,
+		add: `${root}/role/add`,
+		update: `${root}/role/update`,
+		detail: `${root}/role/detail`,
+		delete: `${root}/role/delete`,
+	},
+	power: {
+		list: `${root}/power/list`,
+		add: `${root}/power/add`,
+		update: `${root}/power/update`,
+		detail: `${root}/power/detail`,
+		delete: `${root}/power/delete`,
+	},
+	rolePower: {
+		list: `${root}/rolePower/list`,
+		add: `${root}/rolePower/add`,
+		update: `${root}/rolePower/update`,
+		detail: `${root}/rolePower/detail`,
+		delete: `${root}/rolePower/delete`,
+	},
+	menu: {}
+};
 
-export default Object.assign(
-    {
-        $base: {
-            root: root,
-        },
-    },
-    api
+export default Object.assign({
+		$base: {
+			root: root,
+		},
+	},
+	api
 )

+ 35 - 2
sources/client/vrv-moblie/pages/dataCurve/dataCurve.vue

@@ -70,20 +70,25 @@
 		data() {
 			let _width = uni.upx2px(350);
 			return {
+				formData: {
+					WD_1: '',
+					SD_1: '',
+				},
+
 				cWidth: '',
 				cHeight: '', //画布的宽高
 
 				//仪表盘部分
 				gaugeOption: { //定义参数
 					id: 'gaugeId0',
-					value: 75.8,
+					value: '',
 					axisTickLength: 2 //该属性与axisTick互斥,存在axisTickLength并大于0,axisTick就无效
 				},
 
 				gaugeOption2: { //定义参数
 					name: 'CK01排风湿度显示',
 					id: 'gaugeId1',
-					value: 60.5,
+					value: '',
 					unit: '%',
 					axisTickLength: 2 //该属性与axisTick互斥,存在axisTickLength并大于0,axisTick就无效
 				},
@@ -111,6 +116,9 @@
 		},
 
 		onLoad() {
+			this.getWD_1()
+			this.getSD_1()
+
 			this.cWidth = uni.upx2px(702);
 			this.cHeight = uni.upx2px(500); //设置宽高
 			_self = this //声明this
@@ -216,6 +224,31 @@
 				});
 			},
 
+			async getWD_1(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "206",
+				};
+
+				let res = await uni.$http.get(url, data);
+				console.log('form发生了submit事件')
+
+				this.gaugeOption.value = res.data.data.deviceParam.value;
+			},
+			async getSD_1(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "284",
+				};
+
+				let res = await uni.$http.get(url, data);
+				console.log('form发生了submit事件')
+
+				this.gaugeOption2.value = res.data.data.deviceParam.value;
+			},
+
 		}
 
 	}

+ 16 - 6
sources/client/vrv-moblie/pages/device/deviceInfo/deviceInfo.vue

@@ -72,14 +72,20 @@
 	export default {
 		data() {
 			return {
-
+				code: '',
 			}
 		},
 		onLoad(e) {
 			console.log(e);
+
 		},
 		methods: {
-			parameterSetting() {
+
+			parameterSetting(e) {
+				let vm = this;
+				var code = this.code.code
+				console.log(code);
+
 				uni.navigateTo({
 					url: '/pages/parameterSetting/parameterSetting',
 				});
@@ -93,22 +99,26 @@
 
 			alarmRecord() {
 				uni.navigateTo({
-					url: '/pages/alarmRecord/alarmRecord'
+					url: '/pages/alarmRecord/alarmRecord',
 				});
 			},
 			maintenanceRecord() {
 				uni.navigateTo({
-					url: '/pages/maintenanceRecord/maintenanceRecord'
+					url: '/pages/maintenanceRecord/maintenanceRecord',
 				});
 			},
 			dataCurve() {
 				uni.navigateTo({
-					url: '/pages/dataCurve/dataCurve'
+					url: '/pages/dataCurve/dataCurve',
 				});
 			},
 			runningState() {
+				let vm = this;
+				var code = this.code.code
+				console.log(code);
+
 				uni.navigateTo({
-					url: '/pages/runningState/runningState'
+					url: '/pages/runningState/runningState',
 				});
 			}
 		}

+ 24 - 2
sources/client/vrv-moblie/pages/parameterSetting/parameterSetting.vue

@@ -156,15 +156,37 @@
 	export default {
 		data() {
 			return {
-
+				deviceParams: [],
 			}
 		},
+		onLoad(e) {
+			console.log(e);
+
+			this.list(e)
+		},
 		methods: {
 			back() {
 				uni.navigateTo({
 					url: '/pages/device/deviceInfo/deviceInfo'
 				})
-			}
+			},
+
+			async list(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.list;
+				// let data = {
+				// 	code: this.formData.code,
+				// };
+
+				let res = await uni.$http.get(url);
+				console.log('form发生了submit事件')
+
+				console.log(res);
+
+				this.deviceParams = res.data.data.deviceParams;
+				console.log(res.data.data.deviceParams);
+
+			},
 		}
 	}
 </script>

+ 360 - 23
sources/client/vrv-moblie/pages/runningState/runningState.vue

@@ -4,19 +4,19 @@
 			<view class="shang">
 				<view class="shangItem">
 					<text>冷水阀</text>
-					<text>94%</text>
+					<text>{{formData.LSF}}%</text>
 				</view>
 				<view class="shangItem">
 					<text style="margin-left: 6rpx;">电加热</text>
 					<view class="buttonItem">
-						<button class="but">一</button>
-						<button class="but">二</button>
-						<button class="but">三</button>
+						<button class="but" :class="{'active-but': formData.YJDJR_QT == 0}">一</button>
+						<button class="but" :class="{'active-but': formData.EJDJR_QT == 0}">二</button>
+						<button class="but" :class="{'active-but': formData.SJDJR_QT == 0}">三</button>
 					</view>
 				</view>
 				<view class="shangItem">
 					<text>加湿器</text>
-					<text>0%</text>
+					<text>{{formData.JSF}}%</text>
 				</view>
 
 			</view>
@@ -29,29 +29,29 @@
 				<view class="xiaItem">
 					<text>初效滤网</text>
 					<view class="xiaBut">
-						<button class="xiaButton">正常</button>
+						<button class="xiaButton">{{ formData.LWDS_CX === '0' ? '正常' : '报警' }}</button>
 					</view>
 				</view>
 				<view class="xiaItem">
 					<text>热水阀</text>
-					<text>87%</text>
+					<text>{{formData.RSF}}%</text>
 				</view>
 				<view class="xiaItem">
 					<text>高温报警</text>
 					<view class="xiaBut">
-						<button class="xiaButton">正常</button>
+						<button class="xiaButton"> {{ formData.GW_BJ === '0' ? '正常' : '报警' }}</button>
 					</view>
 				</view>
 				<view class="xiaItem">
 					<text>缺风压差</text>
 					<view class="xiaBut">
-						<button class="xiaButton">正常</button>
+						<button class="xiaButton">{{ formData.QFYC_BJ === '0' ? '正常' : '报警' }}</button>
 					</view>
 				</view>
 				<view class="xiaItem">
 					<text>中效滤网</text>
 					<view class="xiaBut">
-						<button class="xiaButton">正常</button>
+						<button class="xiaButton">{{ formData.LWDS_ZX === '0' ? '正常' : '报警' }}</button>
 					</view>
 				</view>
 
@@ -65,15 +65,15 @@
 			<view class="param">
 				<view class="paramItem">
 					<text class="name">温度</text>
-					<text class="value">22.5℃</text>
+					<text class="value">{{formData.WD_1}}℃</text>
 				</view>
 				<view class="paramItem">
 					<text class="name">湿度</text>
-					<text class="value">59.7%</text>
+					<text class="value">{{formData.SD_1}}%</text>
 				</view>
 				<view class="paramItem">
 					<text class="name">含湿量</text>
-					<text class="value">10.2g/kg</text>
+					<text class="value">{{formData.HSL}}g/kg</text>
 				</view>
 
 			</view>
@@ -86,15 +86,15 @@
 			<view class="param">
 				<view class="paramItem">
 					<text class="name">温度</text>
-					<text class="value">22.5℃</text>
+					<text class="value">{{formData.WD_2}}℃</text>
 				</view>
 				<view class="paramItem">
 					<text class="name">湿度</text>
-					<text class="value">59.7%</text>
+					<text class="value">{{formData.SD_2}}%</text>
 				</view>
 				<view class="paramItem">
 					<text class="name">含湿量</text>
-					<text class="value">10.2g/kg</text>
+					<text class="value">g/kg</text>
 				</view>
 
 			</view>
@@ -102,27 +102,27 @@
 
 		<view class="stop">
 			<view class="stopTiao">
-				<text class="stopTiaoText">停机延时:180S</text>
+				<text class="stopTiaoText">停机延时:{{formData.JZ_YSTZ}}s</text>
 			</view>
 			<view class="param">
 				<view class="paramItem1">
 					<text class="name1">排风温度设定</text>
-					<text class="value">22.5℃</text>
+					<text class="value">{{formData.WD_SD}}℃</text>
 				</view>
 				<view class="paramItem1">
 					<text class="name1">排风湿度设定</text>
-					<text class="value">55%</text>
+					<text class="value">{{formData.SD_SD}}%</text>
 				</view>
 				<view class="paramItem1">
 					<text class="name1">排风含湿量设定</text>
-					<text class="value">9.6g/kg</text>
+					<text class="value">{{formData.HSL_SD}}g/kg</text>
 				</view>
 
 			</view>
 		</view>
 
 		<view class="stopButton">
-			<button class="button">停止按钮</button>
+			<button class="button" @tap="stopAndStart" :class="{'KGJ_button': formData.JZ_KGJ == 1}">开关按钮</button>
 		</view>
 
 		<view class="anniu" @tap="back">
@@ -136,15 +136,345 @@
 	export default {
 		data() {
 			return {
-
+				deviceParams: [],
+
+				formData: {
+					RSF: '',
+					LSF: '',
+					JSF: '',
+					sn: 'CK1',
+					WD_1: '',
+					SD_1: '',
+					WD_2: '',
+					SD_2: '',
+					WD_SD: '',
+					SD_SD: '',
+					HSL: '',
+					HSL_SD: '',
+					JZ_YSTZ: '',
+					JZ_KGJ: '',
+					Id: '',
+					code: '',
+
+					GW_BJ: '0', //高温报警(0:正常,1:报警)
+					QFYC_BJ: '1', //缺风压差(0:正常,1:报警)
+					LWDS_CX: '0', //初效故障报警(0:正常,1:故障)
+					LWDS_ZX: '1', //中效故障报警(0:正常,1:故障)
+					YJDJR_QT: '', //一级电加热启停(0:停止,1:启动)
+					EJDJR_QT: '', //二级电加热启停(0:停止,1:启动)
+					SJDJR_QT: '', //三级电加热启停(0:停止,1:启动)
+
+					JZ_KGJ: '', //设备开关机(0:停止,1:启动)
+
+
+				}
 			}
 		},
+		onLoad(e) {
+			this.getWD_1()
+			this.getSD_1()
+			this.getHSL()
+			this.getWD_2()
+			this.getSD_2()
+			this.getYSTZ()
+			this.getWD_SD()
+			this.getSD_SD()
+			this.getHSL_SD()
+			this.getRSF()
+			this.getLSF()
+			this.getJSF()
+			this.getGWBJ()
+			this.getQFYC()
+			this.getCXLW()
+			this.getZXLW()
+			this.getYJDJR()
+			this.getEJDJR()
+			this.getSJDJR()
+			this.getJZ_KGJ()
+		},
 		methods: {
 			back() {
 				uni.navigateTo({
 					url: '/pages/device/deviceInfo/deviceInfo'
 				})
+			},
+
+			async list(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.list;
+				let data = {
+					sn: this.formData.sn,
+				};
+
+				let res = await uni.$http.get(url);
+
+				this.deviceParams = res.data.data.deviceParams;
+				console.log(res.data.data.deviceParams);
+
+			},
+
+			async getWD_1(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "206",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.WD_1 = res.data.data.deviceParam.value;
+				console.log(this.formData.WD_1);
+			},
+			async getSD_1(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "284",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.SD_1 = res.data.data.deviceParam.value;
+				console.log(this.formData.SD_1);
+			},
+
+			async getHSL(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "262",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.HSL = res.data.data.deviceParam.value;
+				console.log(this.formData.HSL);
+			},
+			async getWD_2(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "298",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.WD_2 = res.data.data.deviceParam.value;
+				console.log(this.formData.WD_2);
+			},
+			async getSD_2(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "299",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.SD_2 = res.data.data.deviceParam.value;
+				console.log(this.formData.SD_2);
+			},
+
+			async getYSTZ(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "217",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JZ_YSTZ = res.data.data.deviceParam.value;
+				console.log(this.formData.JZ_YSTZ);
+			},
+
+			async getWD_SD(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "287",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.WD_SD = res.data.data.deviceParam.value;
+				console.log(this.formData.WD_SD);
+			},
+			async getSD_SD(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "229",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.SD_SD = res.data.data.deviceParam.value;
+				console.log(this.formData.SD_SD);
+			},
+			async getHSL_SD(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "225",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.HSL_SD = res.data.data.deviceParam.value;
+				console.log(this.formData.HSL_SD);
+			},
+
+			async getRSF(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "215",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.RSF = res.data.data.deviceParam.value;
+				console.log(this.formData.RSF);
+			},
+			async getLSF(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "261",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.LSF = res.data.data.deviceParam.value;
+				console.log(this.formData.LSF);
+			},
+			async getJSF(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "211",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JSF = res.data.data.deviceParam.value;
+				console.log(this.formData.JSF);
+			},
+
+
+
+			async getGWBJ(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "285",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.GW_BJ = res.data.data.deviceParam.value;
+			},
+			async getQFYC(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "296",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.QFYC_BJ = res.data.data.deviceParam.value;
+			},
+			async getCXLW(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "274",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.LWDS_CX = res.data.data.deviceParam.value;
+			},
+			async getZXLW(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "293",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.LWDS_ZX = res.data.data.deviceParam.value;
+			},
+
+			async getYJDJR(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "214",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.YJDJR_QT = res.data.data.deviceParam.value;
+			},
+			async getEJDJR(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "210",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.EJDJR_QT = res.data.data.deviceParam.value;
+			},
+			async getSJDJR(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "212",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.SJDJR_QT = res.data.data.deviceParam.value;
+			},
+
+			async getJZ_KGJ(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "260",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JZ_KGJ = res.data.data.deviceParam.value;
+			},
+
+			async stopAndStart(e) {
+				this.formData.JZ_KGJ == 1 ? this.formData.JZ_KGJ = 0 : this.formData.JZ_KGJ = 1;
+
+
+				let vm = this;
+				let url = uni.$api.deviceParam.updateParam;
+				let data = {
+					id: "260",
+					value: this.formData.JZ_KGJ,
+					name: "JZ_KGJ",
+					sn: "CK1"
+				};
+
+				let res = await uni.$http.get(url, data);
+				console.log(res.data.data.value);
+
+
+
 			}
+
 		}
 	}
 </script>
@@ -185,7 +515,7 @@
 		display: flex;
 		flex-direction: column;
 		margin-left: 58rpx;
-		margin-right: 58rpx;
+		margin-right: 46rpx;
 	}
 
 	.paramItem1 {
@@ -302,12 +632,19 @@
 
 	}
 
+	.active-but {
+		background-color: #00ff99;
+	}
+
 	.xiaBut {
 		display: flex;
 		flex-direction: row;
 		font-size: 20rpx;
 		color: #444546;
 	}
+	.KGJ_button{
+		background-color: #00ff99;
+	}
 
 	.xiaButton {
 		width: 100rpx;

+ 240 - 75
sources/client/vrv-moblie/pages/systemParameter/systemParameter.vue

@@ -6,94 +6,101 @@
 				<view class="tiao"></view>
 			</view>
 
-			<view class="setmenu">
-				<view class="setItem">
-					<view class="text">
-						<text>排风温度修正</text>
-					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
-						<view class="danwei">
-							<text style="margin-left: 10rpx;">℃</text>
+			<form>
+				<view class="setmenu">
+					<view class="setItem">
+						<view class="text">
+							<text>排风温度修正</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.WD1_XZ" />
+							<view class="danwei">
+								<text style="margin-left: 10rpx;">℃</text>
+							</view>
 						</view>
 					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>排风湿度修正</text>
-					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
-						<view class="danwei"> <text style="margin-left: 14rpx;">%</text></view>
+					<view class="setItem">
+						<view class="text">
+							<text>排风湿度修正</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.SD1_XZ" />
+							<view class="danwei"> <text style="margin-left: 14rpx;">%</text></view>
+						</view>
 					</view>
-				</view>
 
-				<view class="setItem">
-					<view class="text">
-						<text>加热比例</text>
-					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
-					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>加热积分</text>
-					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
-					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>降温比例</text>
-					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
-					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>降温积分</text>
-					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
+					<view class="setItem">
+						<view class="text">
+							<text>加热比例</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.JR_P" />
+						</view>
 					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>加湿比例</text>
+					<view class="setItem">
+						<view class="text">
+							<text>加热积分</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.JR_I" />
+						</view>
 					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
+					<view class="setItem">
+						<view class="text">
+							<text>降温比例</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.ZL_P" />
+						</view>
 					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>加湿积分</text>
+					<view class="setItem">
+						<view class="text">
+							<text>降温积分</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.ZL_I" />
+						</view>
 					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
+					<view class="setItem">
+						<view class="text">
+							<text>加湿比例</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.JS_P" />
+						</view>
 					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>除湿比例</text>
+					<view class="setItem">
+						<view class="text">
+							<text>加湿积分</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.JS_I" />
+						</view>
 					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
+					<view class="setItem">
+						<view class="text">
+							<text>除湿比例</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.CS_P" />
+						</view>
 					</view>
-				</view>
-				<view class="setItem">
-					<view class="text">
-						<text>除湿积分</text>
+					<view class="setItem">
+						<view class="text">
+							<text>除湿积分</text>
+						</view>
+						<view class="input">
+							<input style="margin-left: 20rpx;" placeholder="请输入" v-model="formData.CS_I" />
+						</view>
 					</view>
-					<view class="input">
-						<input style="margin-left: 20rpx;" placeholder="请输入" />
+
+					<view class="stopButton">
+						<button class="button" @tap="edit">修改按钮</button>
 					</view>
+
 				</view>
 
-			</view>
+			</form>
 
 			<view class="anniu">
 				<image class="anniu" src="../../static/设备菜单/前往列表@2x.png" @tap="back"></image>
@@ -113,20 +120,178 @@
 	export default {
 		data() {
 			return {
-
+				formData: {
+					ZL_P: '0.0', //制冷回路增益P
+					ZL_I: '0.0', //制冷积分时间I
+					CS_P: '0.0', //除湿回路增益P
+					CS_I: '0.0', //除湿积分时间I
+					JR_P: '0.0', //加热回路增益P
+					JR_I: '0.0', //加热积分时间I
+					JS_P: '0.0', //加湿回路增益P
+					JS_I: '0.0', //加湿积分时间I
+					WD1_XZ: '0.0', //排风温度修正(单位为℃)
+					SD1_XZ: '0.0', //排风湿度修正(单位为%RH)
+				}
 			}
 		},
+
+		onLoad() {
+			this.getWDXZ()
+			this.getSDXZ()
+			this.getJR_I()
+			this.getJR_P()
+			this.getJW_I()
+			this.getJW_P()
+			this.getJS_I()
+			this.getJS_P()
+			this.getCS_I()
+			this.getCS_P()
+
+		},
+
 		methods: {
+			async edit(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.update;
+				let data = {
+					name: this.formData.name,
+				};
+				let res = await uni.$http.get(url, data);
+			
+				console.log(res);
+			
+			},
+			
 			back() {
 				uni.navigateTo({
 					url: '/pages/device/deviceInfo/deviceInfo'
 				})
+			},
+
+			async getWDXZ(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "232",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.WD1_XZ = res.data.data.deviceParam.value;
+			},
+			async getSDXZ(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "278",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.SD1_XZ = res.data.data.deviceParam.value;
+			},
+			async getJR_P(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "224",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JR_P = res.data.data.deviceParam.value;
+			},
+			async getJR_I(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "218",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JR_I = res.data.data.deviceParam.value;
+			},
+			async getJW_P(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "267",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.ZL_P = res.data.data.deviceParam.value;
+			},
+			async getJW_I(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "233",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.ZL_I = res.data.data.deviceParam.value;
+			},
+			async getJS_P(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "294",
+				};
+
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JS_P = res.data.data.deviceParam.value;
+			},
+			async getJS_I(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "290",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.JS_I = res.data.data.deviceParam.value;
+			},
+			async getCS_P(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "237",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.CS_P = res.data.data.deviceParam.value;
+			},
+			async getCS_I(e) {
+				let vm = this;
+				let url = uni.$api.deviceParam.detail;
+				let data = {
+					id: "216",
+				};
+
+				let res = await uni.$http.get(url, data);
+
+				this.formData.CS_I = res.data.data.deviceParam.value;
 			}
 		}
 	}
 </script>
 
 <style>
+	.button {
+		background: #007AFF;
+		color: white;
+		width: 654rpx;
+		margin-left: 24rpx;
+		margin-top: 44rpx;
+	}
+
 	.text {
 		margin-top: 40rpx;
 		margin-bottom: 16rpx;
@@ -164,7 +329,7 @@
 
 	.white {
 		width: 702rpx;
-		height: 1200rpx;
+		height: 1230rpx;
 		margin-left: 24rpx;
 		margin-top: 24rpx;
 		border-radius: 10rpx;

Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/common/vendor.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/components/best-gauge/best-gauge.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/alarm/alarm.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/alarmRecord/alarmRecord.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/dataCurve/dataCurve.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/device/device.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/device/deviceInfo/deviceInfo.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/login/login.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/maintenanceRecord/maintenanceRecord.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/operator/operator.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/operator/operatorInfo/operatorInfo.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/operatorLog/operatorLog.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/parameterSetting/parameterSetting.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/power/power.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/project/project.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/project/projectEdit/projectEdit.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/project/projectInfo/projectInfo.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/rolePower/rolePower.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/roleShowPower/roleShowPower.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/runningState/runningState.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/staticProject/staticProject.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/systemParameter/systemParameter.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/systemSet/systemSet.js.map


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/.sourcemap/mp-weixin/pages/user/user.js.map


+ 71 - 72
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/app.json

@@ -1,74 +1,73 @@
 {
-    "pages": [
-        "pages/operator/operator",
-        "pages/login/login",
-        "pages/operator/operatorInfo/operatorInfo",
-        "pages/device/device",
-        "pages/device/deviceInfo/deviceInfo",
-        "pages/staticProject/staticProject",
-        "pages/project/project",
-        "pages/project/projectInfo/projectInfo",
-        "pages/alarm/alarm",
-        "pages/operatorLog/operatorLog",
-        "pages/systemSet/systemSet",
-        "pages/error/error",
-        "pages/parameterSetting/parameterSetting",
-        "pages/systemParameter/systemParameter",
-        "pages/alarmRecord/alarmRecord",
-        "pages/maintenanceRecord/maintenanceRecord",
-        "pages/user/user",
-        "pages/rolePower/rolePower",
-        "pages/roleShowPower/roleShowPower",
-        "pages/runningState/runningState",
-        "pages/dataCurve/dataCurve",
-        "pages/power/power",
-        "pages/project/projectEdit/projectEdit"
-    ],
-    "subPackages": [],
-    "window": {
-        "navigationBarTextStyle": "black",
-        "navigationBarTitleText": "uni-app",
-        "navigationBarBackgroundColor": "#F8F8F8",
-        "backgroundColor": "#F8F8F8"
-    },
-    "tabBar": {
-        "color": "#7A7E83",
-        "selectedColor": "#3cc51f",
-        "borderStyle": "black",
-        "backgroundColor": "#ffffff",
-        "list": [
-            {
-                "pagePath": "pages/operator/operator",
-                "iconPath": "static/底部按钮/项目管理@2x.png",
-                "selectedIconPath": "static/底部按钮/项目管理@2x.png",
-                "text": "运营商管理"
-            },
-            {
-                "pagePath": "pages/project/project",
-                "iconPath": "static/底部按钮/项目管理@2x.png",
-                "selectedIconPath": "static/底部按钮/项目管理@2x.png",
-                "text": "项目管理"
-            },
-            {
-                "pagePath": "pages/alarm/alarm",
-                "iconPath": "static/底部按钮/报警管理@2x.png",
-                "selectedIconPath": "static/底部按钮/报警管理@2x.png",
-                "text": "报警管理"
-            },
-            {
-                "pagePath": "pages/operatorLog/operatorLog",
-                "iconPath": "static/底部按钮/操作日志@2x.png",
-                "selectedIconPath": "static/底部按钮/操作日志@2x.png",
-                "text": "操作日志"
-            },
-            {
-                "pagePath": "pages/systemSet/systemSet",
-                "iconPath": "static/底部按钮/系统设置@2x.png",
-                "selectedIconPath": "static/底部按钮/系统设置@2x.png",
-                "text": "系统设置"
-            }
-        ]
-    },
-    "usingComponents": {},
-    "sitemapLocation": "sitemap.json"
+  "pages": [
+    "pages/operator/operator",
+    "pages/login/login",
+    "pages/operator/operatorInfo/operatorInfo",
+    "pages/device/device",
+    "pages/device/deviceInfo/deviceInfo",
+    "pages/staticProject/staticProject",
+    "pages/project/project",
+    "pages/project/projectInfo/projectInfo",
+    "pages/alarm/alarm",
+    "pages/operatorLog/operatorLog",
+    "pages/systemSet/systemSet",
+    "pages/error/error",
+    "pages/parameterSetting/parameterSetting",
+    "pages/systemParameter/systemParameter",
+    "pages/alarmRecord/alarmRecord",
+    "pages/maintenanceRecord/maintenanceRecord",
+    "pages/user/user",
+    "pages/rolePower/rolePower",
+    "pages/roleShowPower/roleShowPower",
+    "pages/runningState/runningState",
+    "pages/dataCurve/dataCurve",
+    "pages/power/power",
+    "pages/project/projectEdit/projectEdit"
+  ],
+  "subPackages": [],
+  "window": {
+    "navigationBarTextStyle": "black",
+    "navigationBarTitleText": "uni-app",
+    "navigationBarBackgroundColor": "#F8F8F8",
+    "backgroundColor": "#F8F8F8"
+  },
+  "tabBar": {
+    "color": "#7A7E83",
+    "selectedColor": "#3cc51f",
+    "borderStyle": "black",
+    "backgroundColor": "#ffffff",
+    "list": [
+      {
+        "pagePath": "pages/operator/operator",
+        "iconPath": "static/底部按钮/项目管理@2x.png",
+        "selectedIconPath": "static/底部按钮/项目管理@2x.png",
+        "text": "运营商管理"
+      },
+      {
+        "pagePath": "pages/project/project",
+        "iconPath": "static/底部按钮/项目管理@2x.png",
+        "selectedIconPath": "static/底部按钮/项目管理@2x.png",
+        "text": "项目管理"
+      },
+      {
+        "pagePath": "pages/alarm/alarm",
+        "iconPath": "static/底部按钮/报警管理@2x.png",
+        "selectedIconPath": "static/底部按钮/报警管理@2x.png",
+        "text": "报警管理"
+      },
+      {
+        "pagePath": "pages/operatorLog/operatorLog",
+        "iconPath": "static/底部按钮/操作日志@2x.png",
+        "selectedIconPath": "static/底部按钮/操作日志@2x.png",
+        "text": "操作日志"
+      },
+      {
+        "pagePath": "pages/systemSet/systemSet",
+        "iconPath": "static/底部按钮/系统设置@2x.png",
+        "selectedIconPath": "static/底部按钮/系统设置@2x.png",
+        "text": "系统设置"
+      }
+    ]
+  },
+  "usingComponents": {}
 }

+ 7 - 8
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/common/vendor.js

@@ -1430,7 +1430,7 @@ function initData(vueOptions, context) {
     try {
       data = data.call(context); // 支持 Vue.prototype 上挂的数据
     } catch (e) {
-      if (Object({"NODE_ENV":"development","VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
+      if (Object({"VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
         console.warn('根据 Vue 的 data 函数初始化小程序 data 失败,请尽量确保 data 函数中不访问 vm 对象,否则可能影响首次数据渲染速度。', data);
       }
     }
@@ -2731,6 +2731,7 @@ var api = {
     list: "".concat(root, "/deviceParam/list"),
     add: "".concat(root, "/deviceParam/add"),
     update: "".concat(root, "/deviceParam/update"),
+    updateParam: "".concat(root, "/deviceParam/updateParam"),
     detail: "".concat(root, "/deviceParam/detail"),
     delete: "".concat(root, "/deviceParam/delete"),
     batchDelete: "".concat(root, "/deviceParam/batchDelete") },
@@ -2798,9 +2799,7 @@ var api = {
   menu: {} };var _default =
 
 
-
-Object.assign(
-{
+Object.assign({
   $base: {
     root: root } },
 
@@ -14679,7 +14678,7 @@ function type(obj) {
 
 function flushCallbacks$1(vm) {
     if (vm.__next_tick_callbacks && vm.__next_tick_callbacks.length) {
-        if (Object({"NODE_ENV":"development","VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
+        if (Object({"VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
             var mpInstance = vm.$scope;
             console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
                 ']:flushCallbacks[' + vm.__next_tick_callbacks.length + ']');
@@ -14700,14 +14699,14 @@ function nextTick$1(vm, cb) {
     //1.nextTick 之前 已 setData 且 setData 还未回调完成
     //2.nextTick 之前存在 render watcher
     if (!vm.__next_tick_pending && !hasRenderWatcher(vm)) {
-        if(Object({"NODE_ENV":"development","VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG){
+        if(Object({"VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG){
             var mpInstance = vm.$scope;
             console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + vm._uid +
                 ']:nextVueTick');
         }
         return nextTick(cb, vm)
     }else{
-        if(Object({"NODE_ENV":"development","VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG){
+        if(Object({"VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG){
             var mpInstance$1 = vm.$scope;
             console.log('[' + (+new Date) + '][' + (mpInstance$1.is || mpInstance$1.route) + '][' + vm._uid +
                 ']:nextMPTick');
@@ -14793,7 +14792,7 @@ var patch = function(oldVnode, vnode) {
     });
     var diffData = this.$shouldDiffData === false ? data : diff(data, mpData);
     if (Object.keys(diffData).length) {
-      if (Object({"NODE_ENV":"development","VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","BASE_URL":"/"}).VUE_APP_DEBUG) {
+      if (Object({"VUE_APP_NAME":"vrv-platform","VUE_APP_PLATFORM":"mp-weixin","NODE_ENV":"development","BASE_URL":"/"}).VUE_APP_DEBUG) {
         console.log('[' + (+new Date) + '][' + (mpInstance.is || mpInstance.route) + '][' + this._uid +
           ']差量更新',
           JSON.stringify(diffData));

Datei-Diff unterdrückt, da er zu groß ist
+ 37 - 4
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/dataCurve/dataCurve.js


+ 13 - 3
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/device/deviceInfo/deviceInfo.js

@@ -205,15 +205,21 @@ __webpack_require__.r(__webpack_exports__);
 var _default =
 {
   data: function data() {
-    return {};
-
+    return {
+      code: '' };
 
   },
   onLoad: function onLoad(e) {
     console.log(e);
+
   },
   methods: {
-    parameterSetting: function parameterSetting() {
+
+    parameterSetting: function parameterSetting(e) {
+      var vm = this;
+      var code = this.code.code;
+      console.log(code);
+
       uni.navigateTo({
         url: '/pages/parameterSetting/parameterSetting' });
 
@@ -241,6 +247,10 @@ var _default =
 
     },
     runningState: function runningState() {
+      var vm = this;
+      var code = this.code.code;
+      console.log(code);
+
       uni.navigateTo({
         url: '/pages/runningState/runningState' });
 

Datei-Diff unterdrückt, da er zu groß ist
+ 24 - 2
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/parameterSetting/parameterSetting.js


Datei-Diff unterdrückt, da er zu groß ist
+ 331 - 2
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/runningState/runningState.js


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/runningState/runningState.wxml


+ 7 - 1
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/runningState/runningState.wxss

@@ -28,7 +28,7 @@
 	display: flex;
 	flex-direction: column;
 	margin-left: 58rpx;
-	margin-right: 58rpx;
+	margin-right: 46rpx;
 }
 .paramItem1 {
 	display: flex;
@@ -130,12 +130,18 @@
 	margin-top: 5rpx;
 	font-size: 24rpx;
 }
+.active-but {
+	background-color: #00ff99;
+}
 .xiaBut {
 	display: flex;
 	flex-direction: row;
 	font-size: 20rpx;
 	color: #444546;
 }
+.KGJ_button{
+	background-color: #00ff99;
+}
 .xiaButton {
 	width: 100rpx;
 	height: 50rpx;

Datei-Diff unterdrückt, da er zu groß ist
+ 159 - 2
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/systemParameter/systemParameter.js


Datei-Diff unterdrückt, da er zu groß ist
+ 1 - 1
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/systemParameter/systemParameter.wxml


+ 8 - 1
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/pages/systemParameter/systemParameter.wxss

@@ -1,4 +1,11 @@
 
+.button {
+	background: #007AFF;
+	color: white;
+	width: 654rpx;
+	margin-left: 24rpx;
+	margin-top: 44rpx;
+}
 .text {
 	margin-top: 40rpx;
 	margin-bottom: 16rpx;
@@ -31,7 +38,7 @@
 }
 .white {
 	width: 702rpx;
-	height: 1200rpx;
+	height: 1230rpx;
 	margin-left: 24rpx;
 	margin-top: 24rpx;
 	border-radius: 10rpx;

+ 18 - 1
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/project.config.json

@@ -19,7 +19,24 @@
     "libVersion": "2.26.0",
     "appid": "wx95c3daeeb44f85f6",
     "projectname": "vrv-platform",
-    "condition": {},
+    "condition": {
+        "search": {
+            "current": -1,
+            "list": []
+        },
+        "conversation": {
+            "current": -1,
+            "list": []
+        },
+        "game": {
+            "current": -1,
+            "list": []
+        },
+        "miniprogram": {
+            "current": -1,
+            "list": []
+        }
+    },
     "editorSetting": {
         "tabIndent": "insertSpaces",
         "tabSize": 4

+ 27 - 0
sources/client/vrv-moblie/unpackage/dist/dev/mp-weixin/project.private.config.json

@@ -3,5 +3,32 @@
     "projectname": "vrv-platform",
     "setting": {
         "compileHotReLoad": true
+    },
+    "condition": {
+        "miniprogram": {
+            "list": [
+                {
+                    "name": "",
+                    "pathName": "pages/runningState/runningState",
+                    "query": "code=undefined",
+                    "launchMode": "default",
+                    "scene": null
+                },
+                {
+                    "name": "",
+                    "pathName": "pages/dataCurve/dataCurve",
+                    "query": "",
+                    "launchMode": "default",
+                    "scene": null
+                },
+                {
+                    "name": "",
+                    "pathName": "pages/systemParameter/systemParameter",
+                    "query": "",
+                    "launchMode": "default",
+                    "scene": null
+                }
+            ]
+        }
     }
 }

+ 1 - 1
sources/client/vrv-platform/src/views/project/list.vue

@@ -57,7 +57,7 @@
             </el-form-item>
 
 
-            <!--            编辑弹窗-->
+            <!--编辑弹窗-->
             <el-dialog title="项目" :visible.sync="dialogFormVisible" style="width: 70% ; margin-left: 300px ;">
               <el-form label-position="left" :model="formData" :rules="rules" ref="formData">
                 <el-row style="margin-left: 15px">

+ 0 - 1
sources/server/vrv/run/application.pid

@@ -1 +0,0 @@
-17892

+ 26 - 15
sources/server/vrv/vrv-core-api/src/main/java/com/kuyuntech/vrv/coreapi/service/core/DeviceParamService.java

@@ -2,32 +2,37 @@ package com.kuyuntech.vrv.coreapi.service.core;
 
 import com.kuyuntech.vrv.coreapi.bean.core.DeviceParamBean;
 import com.wbspool.fastboot.core.common.bean.PagerBean;
+
 import java.util.List;
 
 /**
  * DeviceParamService
- *
  */
-public interface DeviceParamService  {
+public interface DeviceParamService {
 
-    
 
     /**
      * 新增记录
+     *
      * @param deviceParamBean 新增参数
      * @return 如果成功返回对应bean,否则返回null
      */
-     DeviceParamBean add(DeviceParamBean deviceParamBean);
+    DeviceParamBean add(DeviceParamBean deviceParamBean);
 
     /**
      * 更新记录
+     *
      * @param deviceParamBean 更新参数
      * @return 如果成功返回对应bean,否则返回null
      */
-     DeviceParamBean update(DeviceParamBean deviceParamBean);
+    DeviceParamBean update(DeviceParamBean deviceParamBean);
+
+
+    DeviceParamBean updateParam(DeviceParamBean deviceParamBean);
 
     /**
      * 删除记录
+     *
      * @param deviceParamBean 删除参数
      * @return 如果成功返回对应bean,否则返回null
      */
@@ -35,6 +40,7 @@ public interface DeviceParamService  {
 
     /**
      * 查找一条记录
+     *
      * @param deviceParamBean 查找参数
      * @return 如果成功返回对应bean,否则返回null
      */
@@ -42,56 +48,61 @@ public interface DeviceParamService  {
 
     /**
      * 通过唯一标识查找记录
+     *
      * @param code 用户标识
      * @return 记录存在返回对应的bean,否则返回null
      */
-     DeviceParamBean find(String code);
+    DeviceParamBean find(String code);
 
     /**
      * 分页查找多条记录
+     *
      * @param deviceParamBean 查找参数
-     * @param pagerBean  分页参数
+     * @param pagerBean       分页参数
      * @return 记录存在返回对应的bean集合,否则返回空集合
      */
-     List<DeviceParamBean> findAll(DeviceParamBean deviceParamBean, PagerBean pagerBean);
-
+    List<DeviceParamBean> findAll(DeviceParamBean deviceParamBean, PagerBean pagerBean);
 
 
     /**
      * 查找所有记录
+     *
      * @param deviceParamBean 查找参数
      * @return 记录存在返回对应的bean集合,否则返回空集合
      */
-     List<DeviceParamBean> findAll(DeviceParamBean deviceParamBean);
+    List<DeviceParamBean> findAll(DeviceParamBean deviceParamBean);
 
 
     /**
      * 统计所有记录
+     *
      * @param deviceParamBean 统计参数
      * @return 记录存在返回对应的bean集合,否则返回空集合
      */
-     Long countAll(DeviceParamBean deviceParamBean);
+    Long countAll(DeviceParamBean deviceParamBean);
 
     /**
      * 分页查找多条记录
+     *
      * @param deviceParamBean 查询条件参数
-     * @param pagerBean 分页参数
+     * @param pagerBean       分页参数
      * @return 返回查询结果的Pager封装
      */
-     PagerBean<DeviceParamBean> findPager(DeviceParamBean deviceParamBean, PagerBean pagerBean);
+    PagerBean<DeviceParamBean> findPager(DeviceParamBean deviceParamBean, PagerBean pagerBean);
 
     /**
      * 批量删除
+     *
      * @param deviceParamBeans 批量删除元素集合
      */
-     void batchDelete(List<DeviceParamBean> deviceParamBeans);
+    void batchDelete(List<DeviceParamBean> deviceParamBeans);
 
     /**
      * 批量删除
+     *
      * @param codes 唯一标识集合
      */
     void batchDeleteByCodes(List<String> codes);
 
-    
 
 }

+ 3 - 9
sources/server/vrv/vrv-core-service/src/main/java/com/kuyuntech/vrv/coreservice/dao/core/DeviceParamDao.java

@@ -4,21 +4,15 @@ import com.kuyuntech.vrv.coreservice.domain.core.DeviceParam;
 import com.wbspool.fastboot.core.jpa.repository.FastbootRepository;
 
 
-
-
 /**
  * DeviceParamDao
- *
  */
-public interface DeviceParamDao extends FastbootRepository<DeviceParam,Long> {
+public interface DeviceParamDao extends FastbootRepository<DeviceParam, Long> {
 
-    
 
-   
-   DeviceParam findByCodeAndValid(String code, Short valid);
-   
+    DeviceParam findByCodeAndValid(String code, Short valid);
 
-   
+    DeviceParam findByIdAndValid(Long id,Short valid);
 
 
 }

+ 93 - 64
sources/server/vrv/vrv-core-service/src/main/java/com/kuyuntech/vrv/coreservice/service/core/impl/DeviceParamServiceImpl.java

@@ -4,49 +4,50 @@ package com.kuyuntech.vrv.coreservice.service.core.impl;
 import com.kuyuntech.vrv.coreapi.service.core.DeviceParamService;
 import com.kuyuntech.vrv.coreservice.dao.core.DeviceParamDao;
 import com.kuyuntech.vrv.coreservice.domain.core.DeviceParam;
+import org.apache.commons.lang3.StringUtils;
+import org.hibernate.criterion.MatchMode;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import com.kuyuntech.vrv.coreapi.bean.core.DeviceParamBean;
 import com.wbspool.fastboot.core.common.bean.PagerBean;
+
 import java.util.List;
+
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.BeanUtils;
 import org.hibernate.criterion.DetachedCriteria;
 import org.hibernate.criterion.Restrictions;
+
 import java.util.ArrayList;
 
 import com.wbspool.fastboot.core.jpa.service.AbstractFastbootService;
 import org.springframework.util.Assert;
-import static com.wbspool.fastboot.core.jpa.constant.DataValidTypes.*;
-
-
 
+import static com.wbspool.fastboot.core.jpa.constant.DataValidTypes.*;
 
 
 /**
-* DeviceParamService
-*
-*/
+ * DeviceParamService
+ */
 @Service("deviceParamService")
-@Transactional(rollbackFor = Exception.class,transactionManager = "vrvCoreServiceTransactionManager")
-public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam,DeviceParamBean> implements DeviceParamService {
+@Transactional(rollbackFor = Exception.class, transactionManager = "vrvCoreServiceTransactionManager")
+public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam, DeviceParamBean> implements DeviceParamService {
 
     private static final Logger logger = LoggerFactory.getLogger(DeviceParamServiceImpl.class);
 
     @Autowired
     DeviceParamDao deviceParamDao;
 
-    
 
     @Override
     public DeviceParamBean add(DeviceParamBean deviceParamBean) {
 
         DeviceParam deviceParam = new DeviceParam();
-        beanToDomain(deviceParamBean,deviceParam,"id");
+        beanToDomain(deviceParamBean, deviceParam, "id");
         deviceParamDao.save(deviceParam);
-        domainToBean(deviceParam,deviceParamBean);
+        domainToBean(deviceParam, deviceParamBean);
         return deviceParamBean;
 
     }
@@ -54,23 +55,47 @@ public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam,
     @Override
     public DeviceParamBean update(DeviceParamBean deviceParamBean) {
 
-        if(deviceParamBean == null ){
-            return null ;
+        if (deviceParamBean == null) {
+            return null;
+        }
+
+
+        DeviceParam deviceParam = deviceParamDao.findByCodeAndValid(deviceParamBean.getCode(), VALID);
+
+
+        if (deviceParam == null) {
+            return null;
+        }
+
+        beanToDomain(deviceParamBean, deviceParam, "id", "code", "version", "createTime", "updateTime", "valid");
+
+        deviceParamDao.save(deviceParam);
+
+        domainToBean(deviceParam, deviceParamBean);
+
+        return deviceParamBean;
+    }
+
+    @Override
+    public DeviceParamBean updateParam(DeviceParamBean deviceParamBean) {
+
+        if (deviceParamBean == null) {
+            return null;
         }
 
-        
-        DeviceParam deviceParam = deviceParamDao.findByCodeAndValid(deviceParamBean.getCode(),VALID);
-        
 
-        if(deviceParam == null){
+        DeviceParam deviceParam = deviceParamDao.findByIdAndValid(deviceParamBean.getId(), VALID);
+
+
+        if (deviceParam == null) {
             return null;
         }
 
-        beanToDomain(deviceParamBean,deviceParam,"id","code","version","createTime","updateTime","valid");
+        beanToDomain(deviceParamBean, deviceParam, "id", "code", "version", "createTime", "updateTime", "valid");
 
         deviceParamDao.save(deviceParam);
 
-        domainToBean(deviceParam,deviceParamBean);
+        domainToBean(deviceParam, deviceParamBean);
 
         return deviceParamBean;
     }
@@ -78,60 +103,58 @@ public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam,
     @Override
     public DeviceParamBean delete(DeviceParamBean deviceParamBean) {
 
-        if(deviceParamBean == null){
-            return null ;
+        if (deviceParamBean == null) {
+            return null;
         }
 
-        
-        DeviceParam deviceParam = deviceParamDao.findByCodeAndValid(deviceParamBean.getCode(),VALID);
-        
+
+        DeviceParam deviceParam = deviceParamDao.findByCodeAndValid(deviceParamBean.getCode(), VALID);
 
 
-        if(deviceParam == null){
+        if (deviceParam == null) {
             return null;
         }
 
-        
+
         deviceParam.setValid(INVALID);
         deviceParamDao.save(deviceParam);
-        
 
-        domainToBean(deviceParam,deviceParamBean);
+
+        domainToBean(deviceParam, deviceParamBean);
 
         return deviceParamBean;
     }
 
     @Override
     public DeviceParamBean find(DeviceParamBean deviceParamBean) {
-        if(deviceParamBean == null){
-            return null ;
+        if (deviceParamBean == null) {
+            return null;
         }
 
-        
-        DeviceParam deviceParam = deviceParamDao.findByCodeAndValid(deviceParamBean.getCode(),VALID);
-        
+
+        DeviceParam deviceParam = deviceParamDao.findByIdAndValid(deviceParamBean.getId(), VALID);
 
 
-        if(deviceParam == null){
-            return null ;
+        if (deviceParam == null) {
+            return null;
         }
-        BeanUtils.copyProperties(deviceParam,deviceParamBean);
+        BeanUtils.copyProperties(deviceParam, deviceParamBean);
         return deviceParamBean;
     }
 
     @Override
     public DeviceParamBean find(String code) {
-        return  this.find(DeviceParamBean.builder().code(code).build());
+        return this.find(DeviceParamBean.builder().code(code).build());
     }
 
     @Override
     public List<DeviceParamBean> findAll(DeviceParamBean deviceParamBean, PagerBean pagerBean) {
         List<DeviceParamBean> deviceParamBeans = new ArrayList<>();
         DetachedCriteria detachedCriteria = createListCriteria(deviceParamBean);
-        List<DeviceParam> deviceParams = deviceParamDao.findAll(detachedCriteria,pagerBean);
+        List<DeviceParam> deviceParams = deviceParamDao.findAll(detachedCriteria, pagerBean);
         for (DeviceParam deviceParam : deviceParams) {
             DeviceParamBean deviceParamBeanTemp = new DeviceParamBean();
-            domainToBean(deviceParam,deviceParamBeanTemp);
+            domainToBean(deviceParam, deviceParamBeanTemp);
             deviceParamBeans.add(deviceParamBeanTemp);
         }
         return deviceParamBeans;
@@ -139,17 +162,17 @@ public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam,
 
     @Override
     public List<DeviceParamBean> findAll(DeviceParamBean deviceParamBean) {
-       return  this.findAll(deviceParamBean,null);
+        return this.findAll(deviceParamBean, null);
     }
 
     @Override
-     public Long countAll(DeviceParamBean deviceParamBean) {
+    public Long countAll(DeviceParamBean deviceParamBean) {
         DetachedCriteria detachedCriteria = createListCriteria(deviceParamBean);
         return deviceParamDao.countAll(detachedCriteria);
     }
 
-     @Override
-     public PagerBean<DeviceParamBean> findPager(DeviceParamBean deviceParamBean, PagerBean pagerBean) {
+    @Override
+    public PagerBean<DeviceParamBean> findPager(DeviceParamBean deviceParamBean, PagerBean pagerBean) {
         List<DeviceParamBean> deviceParamBeans = this.findAll(deviceParamBean, pagerBean);
         Long count = this.countAll(deviceParamBean);
         PagerBean<DeviceParamBean> deviceParamPageBean = new PagerBean<>();
@@ -157,30 +180,38 @@ public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam,
         deviceParamPageBean.setItemCount(count.intValue());
         deviceParamPageBean.init();
         deviceParamPageBean.setItems(deviceParamBeans);
-        return  deviceParamPageBean ;
-     }
+        return deviceParamPageBean;
+    }
 
-     /**
-      * 创建列表查询条件
-      * @param deviceParamBean 查询参数
-      * @return
-      */
-     private static DetachedCriteria createListCriteria(DeviceParamBean deviceParamBean){
-         DetachedCriteria detachedCriteria = DetachedCriteria.forClass(DeviceParam.class);
-         detachedCriteria.add(Restrictions.eq("valid",VALID));
-         return  detachedCriteria;
-     }
+    /**
+     * 创建列表查询条件
+     *
+     * @param deviceParamBean 查询参数
+     * @return
+     */
+    private static DetachedCriteria createListCriteria(DeviceParamBean deviceParamBean) {
+        DetachedCriteria detachedCriteria = DetachedCriteria.forClass(DeviceParam.class);
 
+        if (deviceParamBean != null) {
+            if (StringUtils.isNotBlank(deviceParamBean.getSn())) {
+                detachedCriteria.add(Restrictions.eq("sn", deviceParamBean.getSn()));
+            }
+
+        }
+
+        detachedCriteria.add(Restrictions.eq("valid", VALID));
+        return detachedCriteria;
+    }
 
 
     @Override
     public void batchDelete(List<DeviceParamBean> deviceParamBean) {
-        if(deviceParamBean.isEmpty()){
-            return ;
+        if (deviceParamBean.isEmpty()) {
+            return;
         }
         List<String> codes = new ArrayList<>();
-       deviceParamBean.forEach((e) ->{
-          codes.add(e.getCode());
+        deviceParamBean.forEach((e) -> {
+            codes.add(e.getCode());
         });
         batchDeleteByCodes(codes);
 
@@ -190,17 +221,15 @@ public class DeviceParamServiceImpl extends AbstractFastbootService<DeviceParam,
     @Override
     public void batchDeleteByCodes(List<String> codes) {
 
-        if(codes.isEmpty()){
-        return ;
+        if (codes.isEmpty()) {
+            return;
         }
 
         for (String code : codes) {
-            Assert.notNull(this.delete(DeviceParamBean.builder().code(code).build()),"batch delete by codes error! ");
+            Assert.notNull(this.delete(DeviceParamBean.builder().code(code).build()), "batch delete by codes error! ");
         }
 
     }
 
-    
-
 
 }

+ 164 - 0
sources/server/vrv/vrv-platform/src/main/java/com/kuyuntech/vrv/platform/configuration/core/MqttConfiguration.java

@@ -1,8 +1,15 @@
 package com.kuyuntech.vrv.platform.configuration.core;
 
+import com.alibaba.fastjson.JSONObject;
+import com.kuyuntech.vrv.coreapi.bean.core.DeviceParamBean;
+import com.kuyuntech.vrv.coreapi.service.core.DeviceParamService;
+import com.kuyuntech.vrv.platform.readJson.Test;
+import com.kuyuntech.vrv.platform.util.core.CompareParamValue;
 import org.eclipse.paho.client.mqttv3.MqttConnectOptions;
+import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.Bean;
 import org.springframework.context.annotation.Configuration;
+import org.springframework.data.redis.core.RedisTemplate;
 import org.springframework.integration.annotation.ServiceActivator;
 import org.springframework.integration.channel.DirectChannel;
 import org.springframework.integration.core.MessageProducer;
@@ -14,8 +21,17 @@ import org.springframework.integration.mqtt.support.DefaultPahoMessageConverter;
 import org.springframework.messaging.MessageChannel;
 import org.springframework.messaging.MessageHandler;
 
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
 @Configuration
 public class MqttConfiguration {
+    @Autowired
+    private RedisTemplate redisTemplate;
+
+    @Autowired
+    private DeviceParamService deviceParamService;
 
     // 消费消息
 
@@ -69,6 +85,7 @@ public class MqttConfiguration {
     @ServiceActivator(inputChannel = "mqttInputChannel")
     public MessageHandler handler() {
         return message -> {
+
             String payload = message.getPayload().toString();
 
             // byte[] bytes = (byte[]) message.getPayload(); // 收到的消息是字节格式
@@ -82,6 +99,153 @@ public class MqttConfiguration {
                 System.out.println("采集器的消息:" + payload);
             } else {
                 System.out.println("丢弃消息:主题[" + topic + "],负载:" + payload);
+
+                //String转Json
+                JSONObject jsonObject = JSONObject.parseObject(payload);
+
+                String devices = jsonObject.getString("devices");
+
+                //取里面
+                List<Test> list = JSONObject.parseArray(devices, Test.class);
+
+                //CK1
+                String deviceId = list.get(0).getDeviceId();
+                //CK2
+                String deviceId2 = list.get(1).getDeviceId();
+
+                //取deviceData
+                HashMap<String, String> deviceData = list.get(0).getDeviceData();
+                //CK2的deviceData
+                HashMap<String, String> deviceData2 = list.get(1).getDeviceData();
+
+                //存入数据库的新增方法,将第一次读取到的数据存入数据库
+                DeviceParamBean deviceParamBean = new DeviceParamBean();
+
+                //先将数据存入redis,检验所有数据,如果出现数据改变,就执行update更新数据库,并更新redis
+
+                //用长度做判断
+                Long size = redisTemplate.opsForHash().size("paramKeyValue");
+                Long size2 = redisTemplate.opsForHash().size("paramKeyValueCK2");
+                System.out.println(size);
+                System.out.println(size2);
+
+                if (size == 0) {
+                    //遍历CK1数据
+                    for (Map.Entry<String, String> entry : deviceData.entrySet()) {
+
+                        String name = entry.getKey();
+                        String value = entry.getValue();
+
+                        //存入hash
+                        redisTemplate.opsForHash().put("paramKeyValue", name, value);
+
+                        System.out.println("CK1存入redis成功!");
+                    }
+                }
+
+                if (size2 == 0) {
+                    //遍历CK2数据
+                    for (Map.Entry<String, String> entry : deviceData2.entrySet()) {
+
+                        String name = entry.getKey();
+                        String value = entry.getValue();
+
+                        //存入hash
+                        redisTemplate.opsForHash().put("paramKeyValueCK2", name, value);
+
+                        System.out.println("CK2存入redis成功!");
+                    }
+                }
+
+                //遍历redis中hash的每一个键值对和mqtt传过来的数据进行比较
+
+                //获取paramKeyValue键值对
+                HashMap<String, String> paramKeyValue = (HashMap<String, String>) redisTemplate.opsForHash().entries("paramKeyValue");
+                HashMap<String, String> paramKeyValueCK2 = (HashMap<String, String>) redisTemplate.opsForHash().entries("paramKeyValueCK2");
+
+                System.out.println("----------------------------");
+                System.out.println(deviceData);
+                System.out.println(paramKeyValue);
+                System.out.println("----------------------------");
+                System.out.println(deviceData2);
+                System.out.println(paramKeyValueCK2);
+                System.out.println("----------------------------");
+
+                boolean result = CompareParamValue.CompareParamValue(paramKeyValue, deviceData);
+                boolean result2 = CompareParamValue.CompareParamValue(paramKeyValueCK2, deviceData2);
+
+                System.out.println("CK1比较的结果:" + result);
+                System.out.println("CK2比较的结果:" + result2);
+
+                //如果不相等,清除缓存,重新加入,并更新数据库
+                if (result == false) {
+                    //清除redis缓存
+                    redisTemplate.delete("paramKeyValue");
+
+                    //重新存入redis
+                    for (Map.Entry<String, String> entry : deviceData.entrySet()) {
+
+                        String name = entry.getKey();
+                        String value = entry.getValue();
+
+                        //存入hash
+                        redisTemplate.opsForHash().put("paramKeyValue", name, value);
+
+                        System.out.println("重新存入redis成功!");
+                    }
+
+                    //更新数据库
+                    for (Map.Entry<String, String> entry : deviceData.entrySet()) {
+                        deviceParamBean.setSn(deviceId);
+
+                        for (long i = 199; i < 298; i++) {
+                            deviceParamBean.setId(i);
+                        }
+
+                        String name = entry.getKey();
+                        String value = entry.getValue();
+
+                        deviceParamBean.setName(name);
+                        deviceParamBean.setValue(value);
+
+                        deviceParamBean = this.deviceParamService.updateParam(deviceParamBean);
+                    }
+                }
+
+                //如果不相等,清除缓存,重新加入,并更新数据库
+                if (result2 == false) {
+                    //清除redis缓存
+                    redisTemplate.delete("paramKeyValueCK2");
+
+                    //重新存入redis
+                    for (Map.Entry<String, String> entry : deviceData2.entrySet()) {
+
+                        String name = entry.getKey();
+                        String value = entry.getValue();
+
+                        //存入hash
+                        redisTemplate.opsForHash().put("paramKeyValueCK2", name, value);
+
+                        System.out.println("重新存入redis成功!");
+                    }
+
+                    //更新数据库
+                    for (Map.Entry<String, String> entry : deviceData2.entrySet()) {
+                        deviceParamBean.setSn(deviceId2);
+
+                        for (long i = 298; i < 300; i++) {
+                            deviceParamBean.setId(i);
+                        }
+
+                        String name = entry.getKey();
+                        String value = entry.getValue();
+
+                        deviceParamBean.setName(name);
+                        deviceParamBean.setValue(value);
+
+                        deviceParamBean = this.deviceParamService.updateParam(deviceParamBean);
+                    }
+                }
             }
 
         };

+ 11 - 34
sources/server/vrv/vrv-platform/src/main/java/com/kuyuntech/vrv/platform/controller/core/DeviceParamController.java

@@ -37,7 +37,7 @@ public class DeviceParamController {
     DeviceParamService deviceParamService;
 
     /**
-     * 新增参数
+     * 新增
      * TODO 待实现
      *
      * @param deviceParamBean 新增参数
@@ -45,31 +45,9 @@ public class DeviceParamController {
      */
     @RequestMapping
     @ParamErrorAutoResponse
-    public Object addParams(@Validated(ValidGroup.Add.class) DeviceParamBean deviceParamBean) {
-        String dataFromJsonFile = FileUtils.getDataFromJsonFile("C:\\Users\\askin\\IdeaProjects\\airconditioner\\sources\\server\\vrv\\vrv-platform\\src\\main\\resources\\static\\device-params.json");
-
-        JSONObject jsonObject = JSONObject.parseObject(dataFromJsonFile);
-
-        String devices = jsonObject.getString("devices");
-
-        //取里面
-        List<Test> list = JSONObject.parseArray(devices, Test.class);
-//        String deviceId = list.get(0).getDeviceId();
-//        int deviceState = list.get(0).getDeviceState();
-
-        HashMap<String, String> deviceData = list.get(0).getDeviceData();
-
-//        System.out.println(deviceId + "::" + deviceState);
-
-        for (Map.Entry<String, String> entry : deviceData.entrySet()) {
-            String name = entry.getKey();
-            String value = entry.getValue();
-
-            deviceParamBean.setName(name);
-            deviceParamBean.setValue(value);
+    public Object add(@Validated(ValidGroup.Add.class) DeviceParamBean deviceParamBean) {
 
-            deviceParamBean = this.deviceParamService.add(deviceParamBean);
-        }
+        deviceParamBean = this.deviceParamService.add(deviceParamBean);
 
 
         if (deviceParamBean == null) {
@@ -82,17 +60,17 @@ public class DeviceParamController {
 
 
     /**
-     * 新
+     * 
      * TODO 待实现
      *
-     * @param deviceParamBean 新参数
+     * @param deviceParamBean 新参数
      * @return
      */
     @RequestMapping
     @ParamErrorAutoResponse
-    public Object add(@Validated(ValidGroup.Add.class) DeviceParamBean deviceParamBean) {
+    public Object update(@Validated(ValidGroup.Update.class) DeviceParamBean deviceParamBean) {
 
-        deviceParamBean = this.deviceParamService.add(deviceParamBean);
+        deviceParamBean = this.deviceParamService.update(deviceParamBean);
 
 
         if (deviceParamBean == null) {
@@ -103,9 +81,8 @@ public class DeviceParamController {
 
     }
 
-
     /**
-     * 更新
+     * 自定义更新
      * TODO 待实现
      *
      * @param deviceParamBean 更新参数
@@ -113,16 +90,16 @@ public class DeviceParamController {
      */
     @RequestMapping
     @ParamErrorAutoResponse
-    public Object update(@Validated(ValidGroup.Update.class) DeviceParamBean deviceParamBean) {
+    public Object updateParam(@Validated(ValidGroup.Update.class) DeviceParamBean deviceParamBean) {
 
-        deviceParamBean = this.deviceParamService.update(deviceParamBean);
 
+        deviceParamBean = this.deviceParamService.updateParam(deviceParamBean);
 
         if (deviceParamBean == null) {
             return ResponseBean.serverError("操作失败!");
         }
 
-        return ResponseBean.success("操作成功!").addData("code", deviceParamBean.getCode());
+        return ResponseBean.success("操作成功!").addData("value", deviceParamBean.getValue());
 
     }
 

+ 17 - 0
sources/server/vrv/vrv-platform/src/main/java/com/kuyuntech/vrv/platform/util/core/CompareParamValue.java

@@ -0,0 +1,17 @@
+package com.kuyuntech.vrv.platform.util.core;
+
+import java.util.HashMap;
+
+public class CompareParamValue {
+    public static boolean CompareParamValue(HashMap<String, String> paramKeyValue, HashMap<String, String> deviceData) {
+
+        if (paramKeyValue == null || deviceData == null) {
+            return false;
+        }
+
+        boolean equals = paramKeyValue.equals(deviceData);
+
+        return equals;
+
+    }
+}