瀏覽代碼

智慧农场谷歌版本

wang_xy 3 年之前
父節點
當前提交
395b27d57e

+ 6 - 0
leiSP-admin/src/main/java/com/LeispApplication.java

@@ -1,5 +1,10 @@
 package com;
 
+import com.business.tools.CommonConfig;
+import com.dahua.sdk.client.DHClientTool;
+import com.dahua.sdk.client.DahuaDomainService;
+import com.dahua.sdk.client.common.SchemeEnum;
+import org.mybatis.spring.annotation.MapperScan;
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
 import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
@@ -16,6 +21,7 @@ public class LeispApplication
     {
         // System.setProperty("spring.devtools.restart.enabled", "false");
         SpringApplication.run(LeispApplication.class, args);
+        DHClientTool.createService(SchemeEnum.HTTPS, CommonConfig.SERVER_IP, CommonConfig.SERVER_PORT_HTTPS, CommonConfig.USERNAME, CommonConfig.PASSWORD);
         System.out.println("**********SOOKA 管理系統 启动成功********* \n" +
                 "   _____  ____   ____  _  __                 _____ _____  \n" +
                 "  / ____|/ __ \\ / __ \\| |/ /    /\\    ___   / ____|  __ \\ \n" +

+ 2 - 0
leiSP-admin/src/main/resources/application.yml

@@ -5,6 +5,8 @@ server:
   servlet:
     # 应用的访问路径
     context-path: /zhnc
+    session:
+      timeout: PT30M
   tomcat:
     # tomcat的URI编码
     uri-encoding: UTF-8

+ 1 - 2
leiSP-admin/src/main/resources/static/css/login.min.css

@@ -13,9 +13,8 @@ body.signin {
 }
 
 .signinpanel {
-    width:fit-content;
-    display: flex;
     margin: 13% auto;
+    width: 100%;
 }
 
 .signinpanel .logopanel {

+ 41 - 2
leiSP-admin/src/main/resources/static/zhnc/bigdata/css/zhnc_dsj.css

@@ -1,6 +1,10 @@
 @charset "utf-8";
 /* CSS Document */
-
+*{
+	box-sizing: content-box;
+	-moz-box-sizing: inherit;
+	-webkit-box-sizing: inherit;
+}
 body{
 	background:#01020c;
 	padding: 0.5%;
@@ -70,8 +74,12 @@ body::-webkit-scrollbar{
 	}
 .yunying{
 	width: 1111px;
+	#width: 1100px;
+	*width: 1100px;
+	width: 1100px/0;
 	float:left;
 	padding:1%;
+
 	}
 .whole img{
 	display:block;
@@ -97,7 +105,7 @@ body::-webkit-scrollbar{
 	float:left;
 	height:200px;
 	position:relative;
-	margin:0 15px 0 0;
+	margin:0 10px 0 0;
 	}
 .tjds_tj{
 	width:340px;
@@ -225,3 +233,34 @@ body::-webkit-scrollbar{
 	height: 130px;
 
 }
+
+/* IE10+ */
+@media screen and ( -ms-high-contrast: active), ( -ms-high-contrast: none)  {
+	.yunying{
+		width: 1120px!important;
+	}
+	.cpyx_tj{
+		margin-right:10px;
+	}
+	.tjds_tj{
+		width:338px;
+	}
+	.kcltj{
+		width:1510px;
+	}
+	body{
+		-ms-scroll-chaining: chained;
+		-ms-overflow-style: none;
+		-ms-content-zooming: zoom;
+		-ms-scroll-rails: none;
+		-ms-content-zoom-limit-min: 100%;
+		-ms-content-zoom-limit-max: 500%;
+		-ms-scroll-snap-type: proximity;
+		-ms-scroll-snap-points-x: snapList(100%, 200%, 300%, 400%, 500%);
+		-ms-overflow-style: none;
+		overflow: auto;
+	}
+	.cpyx_tj {
+		margin: 0 10px 0 0;
+	}
+}

文件差異過大導致無法顯示
+ 25 - 22
leiSP-admin/src/main/resources/static/zhnc/bigdata/js/echarts.min.js


+ 45 - 0
leiSP-admin/src/main/resources/static/zhnc/syweb/css/zhncksh.css

@@ -1,4 +1,9 @@
 @charset "utf-8";
+*{
+	box-sizing: content-box;
+	-moz-box-sizing: inherit;
+	-webkit-box-sizing: inherit;
+}
 *,html,body{
 	margin: 0px;
 	padding: 0px;
@@ -1073,3 +1078,43 @@ ul li,dl dt,dl dd{
 /* 弹框 结束 */
 
 /* 可视化首页 结束*/
+/* IE10+ */
+@media screen and ( -ms-high-contrast: active), ( -ms-high-contrast: none)  {
+
+	.con_left,.jb_list,.right_table,.tk2_right{
+		-ms-scroll-chaining: chained;
+		-ms-overflow-style: none;
+		-ms-content-zooming: zoom;
+		-ms-scroll-rails: none;
+		-ms-content-zoom-limit-min: 100%;
+		-ms-content-zoom-limit-max: 500%;
+		-ms-scroll-snap-type: proximity;
+		-ms-scroll-snap-points-x: snapList(100%, 200%, 300%, 400%, 500%);
+		-ms-overflow-style: none;
+		overflow: auto;
+	}
+	.tk_div .tk_con .tk_right .sp_list{
+		-ms-scroll-chaining: chained;
+		-ms-overflow-style: none;
+		-ms-content-zooming: zoom;
+		-ms-scroll-rails: none;
+		-ms-content-zoom-limit-min: 100%;
+		-ms-content-zoom-limit-max: 500%;
+		-ms-scroll-snap-type: proximity;
+		-ms-scroll-snap-points-x: snapList(100%, 200%, 300%, 400%, 500%);
+		-ms-overflow-style: none;
+		overflow: auto;
+	}
+	.tk_div .tk_con .tk_left .tk_dl{
+		-ms-scroll-chaining: chained;
+		-ms-overflow-style: none;
+		-ms-content-zooming: zoom;
+		-ms-scroll-rails: none;
+		-ms-content-zoom-limit-min: 100%;
+		-ms-content-zoom-limit-max: 500%;
+		-ms-scroll-snap-type: proximity;
+		-ms-scroll-snap-points-x: snapList(100%, 200%, 300%, 400%, 500%);
+		-ms-overflow-style: none;
+		overflow: auto;
+	}
+}

+ 1 - 1
leiSP-admin/src/main/resources/templates/login.html

@@ -35,7 +35,7 @@
 </head>
 <body class="signin">
 <div class="signinpanel">
-    <div class="row" style="width: fit-content">
+    <div class="row" style="width: 360px;display: block;margin: 0px auto;">
         <!--<div class="col-sm-7">
             <div class="signin-info">
                 <div class="logopanel m-b">

+ 369 - 140
leiSP-admin/src/main/resources/templates/main.html

@@ -2,6 +2,7 @@
 <html lang="zh" xmlns:th="http://www.thymeleaf.org">
 <head>
     <meta charset="utf-8">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
     <title>index</title>
     <link th:href="@{/zhnc/zhnc_index.css}" rel="stylesheet"/>
     <script th:src="@{/zhnc/syweb/js/jquery-1.11.0.min.js}" type="text/javascript"></script>
@@ -43,175 +44,403 @@
         </a>
         <div id="slkc"></div>
         <script>
+
             // 基于准备好的dom,初始化echarts实例
             var myChart = echarts.init(document.getElementById('slkc'));
-            const dataList = [45,9,53,23,14];
+            var xData2 =['青绿饲料','干粗饲料','能量饲料','蛋白质饲料','饲料添加剂'];
+            var data1 = [45,9,53,23,14];
+            var data2 = [100,100,100,100,100];
+            option = {
+                //backgroundColor: '#000',
+                tooltip: {
+                    trigger: 'item',
+                },
+                grid:{
+                    left:50,
+                    bottom:65
+                },
+                xAxis: {
+                    data: xData2,
+                    axisTick: {
+                        show: false
+                    },
+                    axisLine: {
+                        show: false
+                    },
+                    axisLabel: {
+                        interval:0,
+                        textStyle: {
+                            color: '#333',
+                            fontSize:12,
+                        },
+                        margin: 20, //刻度标签与轴线之间的距离。
+                    },
 
-            let yData = [];
-            let yTopData = [];
-            dataList.forEach((item, number) => {
-                if (item <= 30) {
-                    yData.push({
-                        value: item,
-                        itemStyle: {
-                            normal: {
-                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
-                                    {
+                },
+                yAxis: {
+                    splitLine: {
+                        show: false,
+                    },
+                    axisTick: {
+                        show: false
+                    },
+                    axisLine: {
+                        show: false
+                    },
+                    axisLabel: {
+                        textStyle: {
+                            color: '#333',
+                            fontSize:14,
+                        },
+                    }
+                },
+                series: [
+                    {//三个最低下的圆片
+                        "name": "",
+                        "type": "pictorialBar",
+                        "symbolSize": [25, 10],
+                        "symbolOffset": [0,5],
+                        "z": 12,
+                        itemStyle:{
+                            opacity:1,
+                            color: function(params) {
+                                var a = params.name.slice(0, 2);
+                                if (a === '青绿饲料') {
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
                                         offset: 0,
-                                        color: '#FFC1C5',
-                                        opacity: 0.85
-                                    },
-                                    {
+                                        color: '#FF9A22' // 0% 处的颜色
+                                    }, {
                                         offset: 1,
-                                        color: '#FF383F',
-                                        opacity: 0.79
-                                    }
-                                ])
-                            }
-                        },
-                    });
-                    yTopData.push({
-                        value: item,
-                        itemStyle: {
-                            normal: {
-                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
-                                    {
+                                        color: '#FFD56E'// 100% 处的颜色
+                                    }], false)
+                                }else if (a === '干粗饲料' || a === '能量饲料') {
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
                                         offset: 0,
-                                        color: '#FFC1C5',
-                                        opacity: 0.85
-                                    },
-                                    {
+                                        color: '#00EC28' // 0% 处的颜色
+                                    }, {
                                         offset: 1,
-                                        color: '#FF383F',
-                                        opacity: 0.79
-                                    }
-                                ])
+                                        color: '#5DF076'// 100% 处的颜色
+                                    }], false)
+                                }else if (a === '蛋白质饲料' || a === '饲料添加剂') {
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
+                                        offset: 0,
+                                        color: '#12B9DB' // 0% 处的颜色
+                                    }, {
+                                        offset: 1,
+                                        color: '#6F8EF2'// 100% 处的颜色
+                                    }], false)
+
                             }
-                        },
-                        label: {
-                            normal: {
-                                show: true,
-                                position: 'top',
-                                color: '#FF6162',
-                                fontWeight: 'bold'
                             }
                         },
-                    })
-                }else {
-                    yData.push({
-                        value: item,
-                        itemStyle: {
-                            normal: {
-                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
-                                    {
+                        "data": [1,1,1,1,1]
+                    },
+
+
+                    //下半截柱状图
+                    {
+                        name: '2020',
+                        type: 'bar',
+                        barWidth: 25,
+                        barGap: '-100%',
+                        itemStyle: {//lenged文本
+                            opacity:.7,
+                            color: function(params){
+                                var a = params.name.slice(0,2);
+                                if(a === '青绿饲料'){
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
                                         offset: 0,
-                                        color: '#93C3FF',
-                                        opacity: 0.85
-                                    },
-                                    {
+                                        color: '#FF9A22' // 0% 处的颜色
+                                    }, {
                                         offset: 1,
-                                        color: '#246CFF',
-                                        opacity: 0.79
-                                    }
-                                ])
-                            }
-                        },
-                    });
-                    yTopData.push({
-                        value: item,
-                        itemStyle: {
-                            normal: {
-                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
-                                    {
+                                        color:  '#FFD56E'// 100% 处的颜色
+                                    }], false)
+                                }else if(a === '干粗饲料' || a === '能量饲料'){
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
                                         offset: 0,
-                                        color: '#93C3FF',
-                                        opacity: 0.85
-                                    },
-                                    {
+                                        color: '#00EC28' // 0% 处的颜色
+                                    }, {
                                         offset: 1,
-                                        color: '#246CFF',
-                                        opacity: 0.79
-                                    }
-                                ])
-                            }
-                        },
-                        label: {
-                            normal: {
-                                show: true,
-                                position: 'top',
-                                color: '#246CFF',
-                                fontWeight: 'bold'
+                                        color:  '#5DF076'// 100% 处的颜色
+                                    }], false)
+                                }else if(a === '蛋白质饲料' || a === '饲料添加剂') {
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
+                                        offset: 0,
+                                        color: '#12B9DB' // 0% 处的颜色
+                                    }, {
+                                        offset: 1,
+                                        color: '#6F8EF2'// 100% 处的颜色
+                                    }], false)
+                                }
                             }
                         },
-                    })
-                }
-            });
-
-
-
-
 
+                        data: data1
+                    },
 
-            option = {
-                backgroundColor: 'rgb(255, 255, 255)',
-                color: ['#1A64F8'],
-                tooltip: {
-                    trigger: 'axis',
-                    axisPointer: {
-                        type: 'none'
+                    { // 替代柱状图 默认不显示颜色,是最下方柱图(邮件营销)的value值 - 20
+                        type: 'bar',
+                        barWidth:25,
+                        barGap: '-100%',
+                        stack: '',
+                        itemStyle: {
+                            color: 'transparent'
+                        },
+                        data: data1
                     },
-                    formatter: function(prams) {
-                        return prams[0].name + ':' + prams[0].value
-                    }
-                },
-                grid: {
-                    left: '8%',
-                    right: '2%',
-                    top: '10%',
-                    bottom: '20%'
-                },
-                xAxis: [
+
                     {
-                        type: 'category',
-                        data: ['青绿饲料','干粗饲料','能量饲料','蛋白质饲料','饲料添加剂'],
-                        axisTick: {
-                            alignWithLabel: true
+                        "name": "", //头部
+                        "type": "pictorialBar",
+                        "symbolSize": [25, 10],
+                        "symbolOffset": [0, -5],
+                        "z": 12,
+                        "symbolPosition": "end",
+                        itemStyle:{
+                            color:'#2e76c0',
+                            opacity:1,
                         },
-                        axisLabel: {
-                            rotate: -0,
-                            color: '#333',
-                            interval: 0,
-                            margin: 20,
-                            align: 'center'
-                        }
-                    }
-                ],
-                yAxis: {
-                   type: 'value'
-                },
-                series: [
+                        "data": data2
+                    },
+
                     {
-                        name: '',
-                        type: 'pictorialBar',
-                        symbolSize: [30, 10],
-                        symbolOffset: [0, -5],
-                        symbolPosition: 'end',
-                        z: 12,
-                        data: yTopData
+                        "name": "",
+                        "type": "pictorialBar",
+                        "symbolSize": [25, 10],
+                        "symbolOffset": [0, -5],
+                        "z": 12,
+                        itemStyle:{
+                            opacity:1,
+                            color: function(params){
+                                var a = params.name.slice(0,2);
+                                if(a === '青绿饲料'){
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
+                                        offset: 0,
+                                        color: '#FF9A22' // 0% 处的颜色
+                                    }, {
+                                        offset: 1,
+                                        color:  '#FFD56E'// 100% 处的颜色
+                                    }], false)
+                                }else if(a === '干粗饲料' || a === '能量饲料'){
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
+                                        offset: 0,
+                                        color: '#00EC28' // 0% 处的颜色
+                                    }, {
+                                        offset: 1,
+                                        color:  '#5DF076'// 100% 处的颜色
+                                    }], false)
+                                }else if(a === '蛋白质饲料' || a === '饲料添加剂'){
+                                    return new echarts.graphic.LinearGradient(0, 0, 0, 0, 1, [{
+                                        offset: 0,
+                                        color: '#12B9DB' // 0% 处的颜色
+                                    }, {
+                                        offset: 1,
+                                        color:  '#6F8EF2'// 100% 处的颜色
+                                    }], false)
+                                }
+                            }
+                        },
+                        "symbolPosition": "end",
+                        "data": data1
                     },
+
                     {
+                        name: '',
                         type: 'bar',
-                        showBackground: true,
-                        backgroundStyle: {
-                            color: 'rgba(216, 229, 247, 0.55)',
-                            borderRadius: [6, 6, 0, 0]
+                        barWidth: 25,
+                        barGap: '-100%',
+                        z:0,
+                        itemStyle: {
+                            color: '#2e76c0',
+                            opacity:.7,
                         },
-                        barWidth: '30',
-                        data: yData
+
+                        data: data2
                     }
+
+
                 ]
+            };
+            if(option){
+                myChart.setOption(option);
             }
-            myChart.setOption(option);
+
+
+
+
+            //
+            //
+            //
+            //
+            // // 基于准备好的dom,初始化echarts实例
+            // var myChart = echarts.init(document.getElementById('slkc'));
+            // const dataList = [45,9,53,23,14];
+            //
+            // let yData = [];
+            // let yTopData = [];
+            // dataList.forEach((item, number) => {
+            //     if (item <= 30) {
+            //         yData.push({
+            //             value: item,
+            //             itemStyle: {
+            //                 normal: {
+            //                     color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+            //                         {
+            //                             offset: 0,
+            //                             color: '#FFC1C5',
+            //                             opacity: 0.85
+            //                         },
+            //                         {
+            //                             offset: 1,
+            //                             color: '#FF383F',
+            //                             opacity: 0.79
+            //                         }
+            //                     ])
+            //                 }
+            //             }
+            //         });
+            //         yTopData.push({
+            //             value: item,
+            //             itemStyle: {
+            //                 normal: {
+            //                     color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+            //                         {
+            //                             offset: 0,
+            //                             color: '#FFC1C5',
+            //                             opacity: 0.85
+            //                         },
+            //                         {
+            //                             offset: 1,
+            //                             color: '#FF383F',
+            //                             opacity: 0.79
+            //                         }
+            //                     ])
+            //                 }
+            //             },
+            //             label: {
+            //                 normal: {
+            //                     show: true,
+            //                     position: 'top',
+            //                     color: '#FF6162',
+            //                     fontWeight: 'bold'
+            //                 }
+            //             }
+            //         })
+            //     }else {
+            //         yData.push({
+            //             value: item,
+            //             itemStyle: {
+            //                 normal: {
+            //                     color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+            //                         {
+            //                             offset: 0,
+            //                             color: '#93C3FF',
+            //                             opacity: 0.85
+            //                         },
+            //                         {
+            //                             offset: 1,
+            //                             color: '#246CFF',
+            //                             opacity: 0.79
+            //                         }
+            //                     ])
+            //                 }
+            //             }
+            //         });
+            //         yTopData.push({
+            //             value: item,
+            //             itemStyle: {
+            //                 normal: {
+            //                     color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
+            //                         {
+            //                             offset: 0,
+            //                             color: '#93C3FF',
+            //                             opacity: 0.85
+            //                         },
+            //                         {
+            //                             offset: 1,
+            //                             color: '#246CFF',
+            //                             opacity: 0.79
+            //                         }
+            //                     ])
+            //                 }
+            //             },
+            //             label: {
+            //                 normal: {
+            //                     show: true,
+            //                     position: 'top',
+            //                     color: '#246CFF',
+            //                     fontWeight: 'bold'
+            //                 }
+            //             }
+            //         })
+            //     }
+            // });
+            //
+            //
+            //
+            //
+            //
+            //
+            // option = {
+            //     backgroundColor: 'rgb(255, 255, 255)',
+            //     color: ['#1A64F8'],
+            //     tooltip: {
+            //         trigger: 'axis',
+            //         axisPointer: {
+            //             type: 'none'
+            //         },
+            //         formatter: function(prams) {
+            //             return prams[0].name + ':' + prams[0].value
+            //         }
+            //     },
+            //     grid: {
+            //         left: '8%',
+            //         right: '2%',
+            //         top: '10%',
+            //         bottom: '20%'
+            //     },
+            //     xAxis: [
+            //         {
+            //             type: 'category',
+            //             data: ['青绿饲料','干粗饲料','能量饲料','蛋白质饲料','饲料添加剂'],
+            //             axisTick: {
+            //                 alignWithLabel: true
+            //             },
+            //             axisLabel: {
+            //                 rotate: -0,
+            //                 color: '#333',
+            //                 interval: 0,
+            //                 margin: 20,
+            //                 align: 'center'
+            //             }
+            //         }
+            //     ],
+            //     yAxis: {
+            //        type: 'value'
+            //     },
+            //     series: [
+            //         {
+            //             name: '',
+            //             type: 'pictorialBar',
+            //             symbolSize: [30, 10],
+            //             symbolOffset: [0, -5],
+            //             symbolPosition: 'end',
+            //             z: 12,
+            //             data: yTopData
+            //         },
+            //         {
+            //             type: 'bar',
+            //             showBackground: true,
+            //             backgroundStyle: {
+            //                 color: 'rgba(216, 229, 247, 0.55)',
+            //                 borderRadius: [6, 6, 0, 0]
+            //             },
+            //             barWidth: '30',
+            //             data: yData
+            //         }
+            //     ]
+            // }
+            // myChart.setOption(option);
 
         </script>
         <div class="slkc_txt">

+ 4 - 0
leiSP-framework/src/main/java/com/sooka/framework/config/ShiroConfig.java

@@ -295,6 +295,10 @@ public class ShiroConfig
         // 不需要拦截的访问
         filterChainDefinitionMap.put("/login", "anon,captchaValidate");
         filterChainDefinitionMap.put("/phoneHtml", "anon,captchaValidate");
+        // 不需要拦截的访问
+        filterChainDefinitionMap.put("/ksh", "anon,captchaValidate");
+        filterChainDefinitionMap.put("/bigData", "anon,captchaValidate");
+        filterChainDefinitionMap.put("/website", "anon,captchaValidate");
         // 注册相关
         filterChainDefinitionMap.put("/register", "anon,captchaValidate");
         // 系统权限列表

+ 15 - 0
mybusiness/pom.xml

@@ -98,6 +98,21 @@
             <scope>provided</scope>
         </dependency>
 
+        <dependency>
+            <groupId>com.google.code.gson</groupId>
+            <artifactId>gson</artifactId>
+            <version>1.7.1</version>
+        </dependency>
+        <dependency>
+            <groupId>log4j</groupId>
+            <artifactId>log4j</artifactId>
+            <version>1.2.17</version>
+        </dependency>
+        <dependency>
+            <groupId>org.bouncycastle</groupId>
+            <artifactId>bcprov-jdk15on</artifactId>
+            <version>1.61</version>
+        </dependency>
         <!--websocket-->
         <dependency>
             <groupId>org.springframework.boot</groupId>

+ 65 - 0
mybusiness/src/main/java/com/business/zhnc/syWeb/controller/SyWebController.java

@@ -1,17 +1,35 @@
 package com.business.zhnc.syWeb.controller;
 
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
+import com.business.tools.CommonConfig;
+import com.business.zhnc.staffInfo.domain.SyglStaffInfo;
+import com.business.zhnc.staffInfo.service.ISyglStaffInfoService;
+import com.business.zhnc.video.HlsVideoVo;
+import com.business.zhnc.video.MTSVideoDemo;
+import com.business.zhnc.video.RealTimeVideoXo;
+import com.dahua.sdk.client.DHClientTool;
+import com.dahua.sdk.client.DahuaDomainService;
+import com.dahua.sdk.client.common.SchemeEnum;
+import com.sooka.common.annotation.Log;
 import com.sooka.common.core.controller.BaseController;
+import com.sooka.common.core.domain.AjaxResult;
+import com.sooka.common.enums.BusinessType;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
 import org.springframework.ui.ModelMap;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.ResponseBody;
 
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+
 /**
  * 溯源web
  * @author wang_xy
@@ -54,4 +72,51 @@ public class SyWebController extends BaseController {
         return prefix + "/ksh_t1";
     }
 
+
+
+    /**
+     * 获取摄像头hls地址
+     */
+    @GetMapping("/findVideo")
+    @ResponseBody
+    public AjaxResult addSave(String channelId){
+        AjaxResult ajaxResult = new AjaxResult();
+        //准备请求参数
+        JSONArray array = new JSONArray();
+        for (int i = 0; i < channelId.split(",").length; i++) {
+            HlsVideoVo hv = new HlsVideoVo();
+            hv.setDevicecode(channelId.split(",")[i]);
+            hv.setChnSeq("0");
+            hv.setStreamType("1");
+            array.add(hv);
+        }
+        JSONObject json = new JSONObject();
+        json.put("hlsBeanXoList",array);
+        Object res = MTSVideoDemo.startVideo(json);
+
+        ajaxResult.put("data",JSONObject.parseObject(res.toString()).getJSONObject("data").getJSONArray("urls"));
+        return ajaxResult;
+    }
+
+
+    /**
+     * 获取摄像头hls地址
+     */
+    @GetMapping("/operateDirect")
+    @ResponseBody
+    public AjaxResult operateDirect(String channelId,String direct){
+        AjaxResult ajaxResult = new AjaxResult();
+        //准备请求参数
+        JSONObject json = new JSONObject();
+        json.put("stepY","2");
+        json.put("extend","");
+        json.put("direct",direct);
+        json.put("channelId",channelId+"$1$0$0");
+        json.put("stepX","2");
+        json.put("command","1");
+        Object res = MTSVideoDemo.operateDirect(json);
+        ajaxResult.put("data",res);
+        return ajaxResult;
+    }
+
 }

文件差異過大導致無法顯示
+ 450 - 756
mybusiness/src/main/resources/templates/bigData/bigData.html


+ 368 - 213
mybusiness/src/main/resources/templates/ksh/ksh.html

@@ -2,6 +2,7 @@
 <html lang="zh" xmlns:th="http://www.thymeleaf.org">
 	<head>
 		<meta charset="utf-8">
+        <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
 		<title>智慧养殖可视化系统</title>
         <link rel="shortcut icon" href="../static/sooka.ico" th:href="@{sooka.ico}"/>
 		<link th:href="@{/zhnc/syweb/css/zhncksh.css}"  rel="stylesheet"/>
@@ -18,6 +19,14 @@
         <script th:src="@{/zhnc/bigdata/js/echarts.min.js}"></script>
         <script type="text/javascript"
                 src="http://api.map.baidu.com/api?v=3.0&ak=PlhFWpA02aoURjAOpnWcRGqw7AI8EEyO"></script>
+
+        <script th:src="@{/zhnc/hls.min.js}"></script>
+        <!--<script th:src="@{/zhnc/website/lib/polyfill.min.js}"></script>-->
+        <!--&lt;!&ndash; import Vue.js &ndash;&gt;-->
+        <!--<script th:src="@{/zhnc/website/lib/vue.js}"></script>-->
+        <!--&lt;!&ndash; import iView &ndash;&gt;-->
+        <!--<script th:src="@{/zhnc/website/lib/iview.js}" ></script>-->
+        <!--<script th:src="@{/zhnc/website/lib/DHWs.js}"></script>-->
 	</head>
     <style>
         /*地图标题*/
@@ -116,6 +125,30 @@
         .txtk input.gb_btn:hover{
             background: #980505;
         }
+        .ptz .btn {
+            width: 30%;
+            height: 3em;
+            background: transparent;
+            border: solid 1px #00ffea;
+            color: #00ffea;
+            border-radius: 5px;
+            cursor: pointer;
+            margin-bottom: 3px;
+        }
+        .ptz .btn:hover {
+            background: #008f81;
+            color: #fff;
+        }
+        .tab_tit i{
+            color: #ffffff;
+            font-weight: normal;
+            margin-right: 20px;
+            cursor: pointer;
+        }
+        .tab_tit i.on{
+            color: #00ffea;
+            font-weight: 900;
+        }
     </style>
 	<body>
 
@@ -131,7 +164,7 @@
 		</div>
 		<!-- 头部结束 -->
 
-		<!-- 中间内容  开始 -->*
+		<!-- 中间内容  开始 -->
 		<div class="map" id="container"></div>
         <!-- 左侧开始 -->
         <div class="con_left">
@@ -490,8 +523,16 @@
                 <div class="tk_right fl">
                     <div class="ncxq_div" style="height: 610px;">
                         <!--<img th:src="@{/zhnc/syweb/images/zhnctk_46.png}"  style="width:100%;height:100%"/>-->
-                        <iframe src="http://121.37.83.100:40005/dahua/cn/video-tk1.html" id="iframeVideo-tk1" style="width: 100%;height: 100%;overflow:hidden;"></iframe>
-                        <!--<iframe src="http://localhost:8082/dahua/cn/video-tk1.html" id="iframeVideo-tk1" style="width: 100%;height: 100%;overflow:hidden;"></iframe>-->
+                        <!--<iframe src="http://121.37.83.100:40005/dahua/cn/video-tk1.html" id="iframeVideo-tk1" style="width: 100%;height: 100%;overflow:hidden;"></iframe>-->
+                        <!--<iframe src="http://localhost:9090/dahua/cn/video-tk1.html" id="iframeVideo-tk1" style="width: 100%;height: 100%;overflow:hidden;"></iframe>-->
+                        <!--<iframe src="http://localhost:9090/dahua/demo/index.html" style="width: 100%;height: 100%;overflow:hidden;"></iframe>-->
+                        <!--<video id="openVideo" style="width: 500px;height: 500px;">-->
+                            <!--<source src="http://222.161.138.120:7086/live/cameraid/1000029%240/substream/1.m3u8"  type="application/x-mpegURL">-->
+                        <!--</video>-->
+                        <!--<video id="openVideo" class="video-js vjs-default-skin" x-webkit-airplay="allow" poster="" webkit-playsinline playsinline x5-video-player-type="h5" x5-video-player-fullscreen="true" preload="auto">-->
+                            <!--<source src="http://222.161.138.120:7086/live/cameraid/1000029%240/substream/1.m3u8"  type="application/x-mpegURL">-->
+                        <!--</video>-->
+                        <video id="openVideo" controls width="100%"></video>
                     </div>
 
                 </div>
@@ -539,18 +580,34 @@
                 <div class="tk_right fl">
                     <div class="sp_div">
                         <!--<img th:src="@{/zhnc/syweb/images/zhnctk_03.png}" style="width:100%;height:100%"/>-->
-                        <iframe src="http://121.37.83.100:40005/dahua/cn/video.html" id="iframeVideo" style="width: 100%;height: 100%;overflow:hidden;"></iframe>
+                        <!--<iframe src="" id="iframeVideo" style="width: 100%;height: 100%;overflow:hidden;"></iframe>-->
                         <!--<iframe src="http://localhost:8082/dahua/cn/video.html" id="iframeVideo" style="width: 100%;height: 100%;overflow:hidden;"></iframe>-->
+                        <div id="alone">
+                            <video id="openVideo-tk2" controls width="80%"  style="float: left"></video>
+                            <div style="float: left;width: 18%;margin-left: 12px;" class="ptz">
+                                <button type="button" onclick="OperateDirect('5')" class="btn">左上</button>
+                                <button type="button" onclick="OperateDirect('1')" class="btn">上</button>
+                                <button type="button" onclick="OperateDirect('7')" class="btn">右上</button>
+                            </div>
+                            <div style="float: left;width: 18%;margin-left: 12px;" class="ptz">
+                                <button type="button" onclick="OperateDirect('3')" class="btn">左</button>
+                                <button class="btn">自动</button>
+                                <button type="button" onclick="OperateDirect('4')" class="btn">右</button>
+                            </div>
+                            <div style="float: left;width: 18%;margin-left: 12px;" class="ptz">
+                                <button type="button" onclick="OperateDirect('6')" class="btn">左下</button>
+                                <button type="button" onclick="OperateDirect('2')" class="btn">下</button>
+                                <button type="button" onclick="OperateDirect('8')" class="btn">右下</button>
+                            </div>
+                        </div>
+                        <div id="group" style="display: none;">
+
+                        </div>
                     </div>
+
                     <div class="sp_list">
-                        <h5 class="sp_tit">摄像头列表</h5>
-                        <ul class="sp_ul" id="tantou">
-                            <li>
-                                <a><i></i>牛舍监控探头1</a>
-                            </li>
-                            <li th:each="tt : ${list}">
-                                <a th:onclick="goPlugIn([[${tt.ip}]],[[${tt.port}]],[[${tt.account}]],[[${tt.password}]])"><i></i>端口[[${tt.port}]]的探头</a>
-                            </li>
+                        <h5 class="sp_tit tab_tit"><i class="qiehuan on">摄像头列表</i><i class="qiehuan">组织</i></h5>
+                        <ul class="sp_ul tab_ul" id="tantou">
                         </ul>
                     </div>
                     <div class="clear"></div>
@@ -619,7 +676,7 @@
                 <!-- 底部 横条按钮 开始 -->
                 <div class="tk_hbtn">
                     <input type="button" value="确定" class="btn_qd fr" onclick="hideMessage();"/>
-                    <input type="button" value="返回" class="btn_qx fr" onclick="$('#tk_div1').show();hideMessage();sendMessagetk1()"/>
+                    <input type="button" value="返回" class="btn_qx fr" onclick="$('#tk_div1').show();hideMessage();"/>
                 </div>
                 <!-- 底部 横条按钮 结束 -->
 
@@ -790,7 +847,7 @@
                 <!-- 底部 横条按钮 开始 -->
                 <div class="tk_hbtn">
                     <input type="button" value="确定" class="btn_qd fr" onclick="$('#tk_div3').hide()"/>
-                    <input type="button" value="返回" class="btn_qx fr" onclick="sendMessage();$('#tk_div3').hide();"/>
+                    <input type="button" value="返回" class="btn_qx fr" onclick="showTkDiv2();$('#tk_div3').hide();"/>
                 </div>
                 <!-- 底部 横条按钮 结束 -->
 
@@ -807,10 +864,12 @@
             <input type="button" value="关闭" class="gb_btn"/>
         </div>
 	</body>
-
     <script type="text/javascript">
-        var niushe = ['固定牛舍1','固定牛舍2','固定牛舍3','活动牛舍1','活动牛舍2','活动牛舍3','活动牛舍4','活动牛舍5','隔离牛舍1','隔离牛舍2','','','','',''];
-        var ports = ["8011","8012","8013","8014","8015","8016","8017","8018","8019","8020","8021","8022","8023","8024","8025","8026","8027","8028","8029","8030","8111","8112","8113","8114","8115","8116","8117","8118"];
+        var niushe = ['固定牛舍1', '固定牛舍2', '固定牛舍3', '活动牛舍1', '活动牛舍2', '活动牛舍3', '活动牛舍4', '活动牛舍5', '隔离牛舍1', '隔离牛舍2', '', '', '', '', ''];
+        var ports = ["1000034", "1000035", "1000036", "1000037", "1000038", "1000039", "1000040", "1000041", "1000042", "1000043", "1000044", "1000045", "1000046", "1000047", "1000048", "1000049", "1000050", "1000051", "1000052", "1000053", "1000020", "1000021", "1000022", "1000023", "1000024", "1000025", "1000026", "1000027"];
+        var sxtUrl = "http://121.37.83.100:40005/";
+        var connalId = "";
+        var aloneOrGroup = "";
         // webSocket
 
         // var websocket = null;
@@ -850,95 +909,95 @@
 
         // webSocketend
 
-        var oneIndex=0;
-        var errorIndex=0;
-        var errorTwoIndex=0;
+        var oneIndex = 0;
+        var errorIndex = 0;
+        var errorTwoIndex = 0;
 
         var map = new BMap.Map("container");
-        map.centerAndZoom(new BMap.Point(129.77637582701928, 43.00009148769267),12);
+        map.centerAndZoom(new BMap.Point(129.77637582701928, 43.00009148769267), 12);
         map.enableScrollWheelZoom();
-		var mapStyle ={
-			style : 'midnight',
-		};
-		map.setMapStyle(mapStyle);
+        var mapStyle = {
+            style: 'midnight',
+        };
+        map.setMapStyle(mapStyle);
 
-        var longitude = [129.5464786,129.83889789051372,129.82078805143257,129.80842736761528,129.81690737162947,130.02215221454924,129.99714338915146,129.99728711803306];//经度
-        var latitude = [42.9837084,42.899784486382835,43.10065511842016,43.0820096348773,43.07726834614238,43.00051348484174,43.02603888101937,42.99449974985549];//纬度
-        var niucount = [3000,2800,2960,2940,2800,2920,2920,2950];//牛只数量
-        var fzr = ['张凯','张国刚','钱峰','孙长江','赵明','冯启年','徐腾飞','牛东'];//负责人
-        var nvname = ['清茶牧业牛场','原生态黄牛养殖场','全牛园养殖场','长青绿牧场','平安牧场','犇犇牛业养殖场','腾飞牧业','绿色养殖场'];//牛场名称
+        var longitude = [129.5464786, 129.83889789051372, 129.82078805143257, 129.80842736761528, 129.81690737162947, 130.02215221454924, 129.99714338915146, 129.99728711803306];//经度
+        var latitude = [42.9837084, 42.899784486382835, 43.10065511842016, 43.0820096348773, 43.07726834614238, 43.00051348484174, 43.02603888101937, 42.99449974985549];//纬度
+        var niucount = [3000, 2800, 2960, 2940, 2800, 2920, 2920, 2950];//牛只数量
+        var fzr = ['张凯', '张国刚', '钱峰', '孙长江', '赵明', '冯启年', '徐腾飞', '牛东'];//负责人
+        var nvname = ['清茶牧业牛场', '原生态黄牛养殖场', '全牛园养殖场', '长青绿牧场', '平安牧场', '犇犇牛业养殖场', '腾飞牧业', '绿色养殖场'];//牛场名称
 
-        var icon0 = ctx+"zhnc/syweb/images/zhncksh_36.png";
-        var icon1 = ctx+"zhnc/syweb/images/zhncksh_36-1.png";
-        var icon2 = ctx+"zhnc/syweb/images/zhncksh_36-2.png";
-        var icon3 = ctx+"zhnc/syweb/images/zhncksh_36-3.png";
-        var icon4 = ctx+"zhnc/syweb/images/zhncksh_36-4.png";
-        var error = ctx+"zhnc/syweb/images/zhncksh_68.png";
-        var yanshi = ctx+"zhnc/syweb/images/zhnctk_45.png";
+        var icon0 = ctx + "zhnc/syweb/images/zhncksh_36.png";
+        var icon1 = ctx + "zhnc/syweb/images/zhncksh_36-1.png";
+        var icon2 = ctx + "zhnc/syweb/images/zhncksh_36-2.png";
+        var icon3 = ctx + "zhnc/syweb/images/zhncksh_36-3.png";
+        var icon4 = ctx + "zhnc/syweb/images/zhncksh_36-4.png";
+        var error = ctx + "zhnc/syweb/images/zhncksh_68.png";
+        var yanshi = ctx + "zhnc/syweb/images/zhnctk_45.png";
 
         for (var i = 0; i < longitude.length; i++) {
             var icon;
-            if(0<= niucount[i] && niucount[i]<3000) {
+            if (0 <= niucount[i] && niucount[i] < 3000) {
                 icon = new BMap.Icon(icon0, new BMap.Size(31, 39));
-            } else if (3000<= niucount[i] && niucount[i]<4000){
+            } else if (3000 <= niucount[i] && niucount[i] < 4000) {
                 icon = new BMap.Icon(icon1, new BMap.Size(31, 39));
-            } else if (4000<= niucount[i] && niucount[i]<5000){
+            } else if (4000 <= niucount[i] && niucount[i] < 5000) {
                 icon = new BMap.Icon(icon2, new BMap.Size(31, 39));
-            } else if (5000<= niucount[i] && niucount[i]<6000){
+            } else if (5000 <= niucount[i] && niucount[i] < 6000) {
                 icon = new BMap.Icon(icon3, new BMap.Size(31, 39));
-            } else if (6000<= niucount[i] && niucount[i]<7000){
+            } else if (6000 <= niucount[i] && niucount[i] < 7000) {
                 icon = new BMap.Icon(icon4, new BMap.Size(31, 39));
             }
 
-            if(i == 2){
+            if (i == 2) {
                 icon = new BMap.Icon(error, new BMap.Size(31, 39));
             }
-            if(nvname[i] == '清茶牧业牛场'){
+            if (nvname[i] == '清茶牧业牛场') {
                 icon = new BMap.Icon(yanshi, new BMap.Size(31, 26));
             }
             var P = new BMap.Point(longitude[i], latitude[i])
-            var MP = new BMap.Marker(P,{icon: icon});
+            var MP = new BMap.Marker(P, {icon: icon});
             map.addOverlay(MP);
             var sContent =
-                "<p>牛场名称:"+nvname[i]+"</p><br>" +
-                "<p>牛场规模:"+niucount[i]+"头</p><br>" +
-                "<p>负责人:"+fzr[i]+"</p><br>" +
+                "<p>牛场名称:" + nvname[i] + "</p><br>" +
+                "<p>牛场规模:" + niucount[i] + "头</p><br>" +
+                "<p>负责人:" + fzr[i] + "</p><br>" +
                 "<p>牛只种类:黄牛、牦牛、奶牛</p><br>";
-                if(i == 2){
-                    sContent+="<p style='color: red'>报警信息:牛场报警!!!</p><br>";
-                }
-            addClickHandler(sContent, MP,i);
+            if (i == 2) {
+                sContent += "<p style='color: red'>报警信息:牛场报警!!!</p><br>";
+            }
+            addClickHandler(sContent, MP, i);
         }
 
-        function addClickHandler(content, marker,index) {
+        function addClickHandler(content, marker, index) {
             // 创建信息窗口属性
             var opts = {
-                width : 100,     // 信息窗口宽度
+                width: 100,     // 信息窗口宽度
                 title: '<h4>牛舍信息</h4>'
             }
-            var infoWindow = new BMap.InfoWindow(content,opts);
+            var infoWindow = new BMap.InfoWindow(content, opts);
             marker.addEventListener('click', function () {
                 var tk_dl_one_html = "<dt>\n" +
                     "<span>编号</span>\n" +
                     "<span>牛舍名称</span>\n" +
-                    "<span>牛只数量</span>\n"+
-                    "<span>状态</span>"+
+                    "<span>牛只数量</span>\n" +
+                    "<span>状态</span>" +
                     "</dt>";
                 for (var i = 1; i <= 15; i++) {
-                    if(index == 2 && i==1){
-                        tk_dl_one_html+="<dd style='color: red'><a onclick=\"showTkDiv2("+index+","+i+")\">\n" +
-                            "            <span>0"+i+"</span>\n" +
-                            "            <span>"+niushe[i-1]+"</span>\n" +
-                            "            <span>"+(Math.ceil(Math.random()*50)+150)+"</span>\n";
-                        tk_dl_one_html+="<span >异常</span>";
-                    }else{
-                        tk_dl_one_html+="<dd ><a onclick=\"showTkDiv2("+index+","+i+")\">\n" +
-                            "            <span>0"+i+"</span>\n" +
-                            "            <span>"+niushe[i-1]+"</span>\n" +
-                            "            <span>"+(Math.ceil(Math.random()*50)+150)+"</span>\n";
-                        tk_dl_one_html+="<span style='color: green'>正常</span>";
+                    if (index == 2 && i == 1) {
+                        tk_dl_one_html += "<dd style='color: red'><a onclick=\"showTkDiv2(" + index + "," + i + ")\">\n" +
+                            "            <span>0" + i + "</span>\n" +
+                            "            <span>" + niushe[i - 1] + "</span>\n" +
+                            "            <span>" + (Math.ceil(Math.random() * 50) + 150) + "</span>\n";
+                        tk_dl_one_html += "<span >异常</span>";
+                    } else {
+                        tk_dl_one_html += "<dd ><a onclick=\"showTkDiv2(" + index + "," + i + ")\">\n" +
+                            "            <span>0" + i + "</span>\n" +
+                            "            <span>" + niushe[i - 1] + "</span>\n" +
+                            "            <span>" + (Math.ceil(Math.random() * 50) + 150) + "</span>\n";
+                        tk_dl_one_html += "<span style='color: green'>正常</span>";
                     }
-                    tk_dl_one_html+=" </a>\n" +
+                    tk_dl_one_html += " </a>\n" +
                         "            </dd>";
                 }
                 $("#tk_dl_one").html(tk_dl_one_html);
@@ -960,103 +1019,144 @@
          * @param index
          * @private
          */
-        function con_(index){
+        function con_(index) {
             var tk_dl_one_html = "<dt>\n" +
                 "<span>编号</span>\n" +
                 "<span>牛舍名称</span>\n" +
-                "<span>牛只数量</span>\n"+
-                "<span>状态</span>"+
+                "<span>牛只数量</span>\n" +
+                "<span>状态</span>" +
                 "</dt>";
             for (var i = 1; i <= 15; i++) {
-                if(index == 2 && i==1){
-                    tk_dl_one_html+="<dd style='color: red'><a onclick=\"showTkDiv2("+index+","+i+")\">\n" +
-                        "            <span>0"+i+"</span>\n" +
-                        "            <span>"+niushe[i-1]+"</span>\n" +
-                        "            <span>"+(Math.ceil(Math.random()*50)+150)+"</span>\n";
-                    tk_dl_one_html+="<span >异常</span>";
-                }else{
-                    tk_dl_one_html+="<dd ><a onclick=\"showTkDiv2("+index+","+i+")\">\n" +
-                        "            <span>0"+i+"</span>\n" +
-                        "            <span>"+niushe[i-1]+"</span>\n" +
-                        "            <span>"+(Math.ceil(Math.random()*50)+150)+"</span>\n";
-                    tk_dl_one_html+="<span style='color: green'>正常</span>";
+                if (index == 2 && i == 1) {
+                    tk_dl_one_html += "<dd style='color: red'><a onclick=\"showTkDiv2(" + index + "," + i + ")\">\n" +
+                        "            <span>0" + i + "</span>\n" +
+                        "            <span>" + niushe[i - 1] + "</span>\n" +
+                        "            <span>" + (Math.ceil(Math.random() * 50) + 150) + "</span>\n";
+                    tk_dl_one_html += "<span >异常</span>";
+                } else {
+                    tk_dl_one_html += "<dd ><a onclick=\"showTkDiv2(" + index + "," + i + ")\">\n" +
+                        "            <span>0" + i + "</span>\n" +
+                        "            <span>" + niushe[i - 1] + "</span>\n" +
+                        "            <span>" + (Math.ceil(Math.random() * 50) + 150) + "</span>\n";
+                    tk_dl_one_html += "<span style='color: green'>正常</span>";
                 }
-                tk_dl_one_html+=" </a>\n" +
+                tk_dl_one_html += " </a>\n" +
                     "            </dd>";
             }
             $("#tk_dl_one").html(tk_dl_one_html);
             $("#tk_div1").show();
             sendMessagetk1();
         }
-        var iframetk1 = document.getElementById("iframeVideo-tk1");
+
         function sendMessagetk1() {
-            var FormObj = iframetk1.contentWindow;
-            FormObj.postMessage({                 // 传过去的值
-                left: 585,
-                top: 170,
-                key: true,
-                ip: "111.26.169.125",
-                port: "8015",
-                account: "admin",
-                password: "admin123"
-            },'*');
+            var url = ctx+'/ksh/findVideo';
+            $.ajax({
+                dataType: 'json',
+                url: url,
+                data:{
+                    channelId:"1000029"
+                },
+                success: function (result) {
+                    var video = document.getElementById("openVideo");
+                    var hls = new Hls();
+                    hls.loadSource(result.data[0]);
+                    hls.attachMedia(video);
+                    hls.on(Hls.Events.MANIFEST_PARSED,function() {
+                        video.play();
+                    });
+                },
+                error: function (jqXHR, status, errorThrown) {
+                    console.log(status, errorThrown);
+                },
+                complete: function(XMLHttpRequest, textStatus) {
+                    console.log(textStatus);
+                }
+            });
         }
-        var iframe = document.getElementById("iframeVideo");
 
-        function sendMessage(){
-            var FormObj = iframe.contentWindow;
-            FormObj.postMessage({                 // 传过去的值
-                left: 600,
-                top: 175,
-                key: true,
-                ip: "111.26.169.125",
-                port: "8015",
-                account: "admin",
-                password: "admin123"
-            },'*');
+        function sendMessage() {
             $('#tk_div2').show();
         }
-        function goPlugIn(jIp,jPort,jUsername,jPassword) {
-            var jDeviceport = 8000;
-            // var url = 'http://localhost:8899/camera_id='+jIp+","+jPort+","+jUsername+","+jPassword+","+jDeviceport;
-            // window.location.href="http://"+jIp+":"+jPort+"/doc/page/preview.asp";
-            // $.ajax({
-            //     dataType: 'json',
-            //     url: url,
-            //     headers: {
-            //         'Access-Control-Allow-Origin': "*"
-            //     },
-            //     success: function (result) {
-            //         console.log(result);
-            //     },
-            //     error: function (jqXHR, status, errorThrown) {
-            //         console.log(status, errorThrown);
-            //     },
-            //     complete: function(XMLHttpRequest, textStatus) {
-            //         console.log(textStatus);
-            //     }
-            // });
-            var url = 'http://117.78.49.164:17000/camera2/cn/demo.html?camera_id='+jIp+","+jPort+","+jUsername+","+jPassword+","+jDeviceport;
-            window.location.href="openIE:"+url;
 
+        function goPlugIn(sbbh) {
+            var url = ctx+'/ksh/findVideo';
+            connalId=sbbh;
+            $.ajax({
+                dataType: 'json',
+                url: url,
+                data:{
+                    channelId:sbbh
+                },
+                success: function (result) {
+                    if(aloneOrGroup == 'group'){
+                        var html = "";
+                        for(var i=0;i<result.data.length;i++){
+                            html+="<video id=\"openVideo-tk2-"+i+"\" controls width=\"50%\" style=\"float: left;height: 200px;\"></video>";
+                        }
+                        $("#group").html(html);
+                        for(var i=0;i<result.data.length;i++){
+                            var video = document.getElementById("openVideo-tk2-"+i);
+                            var hls = new Hls();
+                            hls.loadSource(result.data[i]);
+                            hls.attachMedia(video);
+                        }
+                        for(var i=0;i<result.data.length;i++){
+                            var video = document.getElementById("openVideo-tk2-"+i);
+                            video.play();
+                        }
+                        $("#group").show();
+                        $("#alone").hide();
+                    }else{
+                        var video = document.getElementById("openVideo-tk2");
+                        var hls = new Hls();
+                        hls.loadSource(result.data[0]);
+                        hls.attachMedia(video);
+                        hls.on(Hls.Events.MANIFEST_PARSED,function() {
+                            video.play();
+                        });
+                        $("#alone").show();
+                        $("#group").hide();
+                    }
+                },
+                error: function (jqXHR, status, errorThrown) {
+                    console.log(status, errorThrown);
+                },
+                complete: function(XMLHttpRequest, textStatus) {
+                    console.log(textStatus);
+                }
+            });
         }
 
 
-        function hideMessage(){
-            $("#iframeVideo").attr('src','http://121.37.83.100:40005/dahua/cn/video.html');
-            // $("#iframeVideo").attr('src','http://localhost:8082/dahua/cn/video.html');
+        //摄像头移动方法
+        function OperateDirect(direct){
+            var url = ctx+'/ksh/operateDirect';
+            $.ajax({
+                dataType: 'json',
+                url: url,
+                data:{
+                    channelId:connalId,
+                    direct:direct
+                },
+                success: function (result) {
+                }
+            });
+        }
+
+
+        function hideMessage() {
             $('#tk_div2').hide();
         }
-        function hideMessagetk1(){
-            $("#iframeVideo-tk1").attr('src','http://121.37.83.100:40005/dahua/cn/video-tk1.html');
-            // $("#iframeVideo-tk1").attr('src','http://localhost:8082/dahua/cn/video-tk1.html');
+
+        function hideMessagetk1() {
             $('#tk_div1').hide();
         }
-        function showTkDiv2(index,er){
+
+        function showTkDiv2(index, er) {
             hideMessagetk1();
             sendMessage();
-            errorIndex=index;
-            errorTwoIndex=er;
+            errorIndex = index!=null?index:errorIndex;
+            errorTwoIndex = er!=null?er:errorTwoIndex;
             var tk_dl_two_html = "<dt>\n" +
                 "        <span>编号</span>\n" +
                 "        <span>品种</span>\n" +
@@ -1066,11 +1166,11 @@
                 "        <span>状态</span>\n" +
                 "        </dt>";
             for (var i = 1; i <= 16; i++) {
-                if (index == 2 && i == 1 && er==1) {
+                if (index == 2 && i == 1 && er == 1) {
                     tk_dl_two_html += "<dd style='color: red'><a onclick=\"showTkDiv3('1')\">\n" +
                         "            <span>0" + i + "</span>\n" +
                         "            <span>黄牛</span>\n" +
-                        "            <span>"+(Math.ceil(Math.random()*50)+200)+"</span>\n" +
+                        "            <span>" + (Math.ceil(Math.random() * 50) + 200) + "</span>\n" +
                         "            <span class='wdbh_error'>42.5</span>\n" +
                         "            <span>入驻</span>\n";
                     tk_dl_two_html += "<span >异常</span>";
@@ -1079,8 +1179,8 @@
                     tk_dl_two_html += "<dd><a onclick=\"showTkDiv3('0')\">\n" +
                         "            <span>0" + i + "</span>\n" +
                         "            <span>黄牛</span>\n" +
-                        "            <span>"+(Math.ceil(Math.random()*50)+200)+"</span>\n" +
-                        "            <span class='wdbh_"+i+"'>"+(Math.ceil(Math.random()*1)+38)+"."+(Math.ceil(Math.random()*9))+"</span>\n" +
+                        "            <span>" + (Math.ceil(Math.random() * 50) + 200) + "</span>\n" +
+                        "            <span class='wdbh_" + i + "'>" + (Math.ceil(Math.random() * 1) + 38) + "." + (Math.ceil(Math.random() * 9)) + "</span>\n" +
                         "            <span>入驻</span>\n";
                     tk_dl_two_html += "<span style='color: green'>正常</span>";
                     tk_dl_two_html += "</a></dd>";
@@ -1088,32 +1188,35 @@
             }
 
             $("#tk_dl_two").html(tk_dl_two_html);
-            var html = "<li>\n" +
-                "                    <a><i></i>牛舍监控探头1</a>\n" +
-                "                </li>";
-            if(er == 1){
-                for(var i = 0; i < 20; i++){
-                    html+="<li>\n" +
-                        "<a onclick=\"goPlugIn('222.161.138.120',ports[i],'admin','qingchamuye123')\"><i></i>端口"+ports[i]+"的探头</a>\n" +
+            var html = "";
+            if (errorTwoIndex == 1) {
+                for (var i = 0; i < 20; i++) {
+                    html += "<li>\n" +
+                        "<a onclick=\"goPlugIn('"+ports[i]+"')\"><i></i>端口" + ports[i] + "的探头</a>\n" +
                         "</li>";
                 }
-            }else if(er == 4){
-                for(var i = 20; i < 28; i++){
-                    html+="<li>\n" +
-                        "<a onclick=\"goPlugIn('222.161.138.120',ports[i],'admin','qingchamuye123')\"><i></i>端口"+ports[i]+"的探头</a>\n" +
+                goPlugIn(ports[0])
+            } else if (errorTwoIndex == 4) {
+                for (var i = 20; i < 28; i++) {
+                    html += "<li>\n" +
+                        "<a onclick=\"goPlugIn('" + ports[i] + "')\"><i></i>端口" + ports[i] + "的探头</a>\n" +
                         "</li>";
                 }
+                goPlugIn(ports[20])
+            } else {
+                $("#openVideo-tk2").attr("src","");
             }
             $("#tantou").html(html);
         }
-        function showTkDiv3(flag){
+
+        function showTkDiv3(flag) {
             $('#tk_div3').show();
             hideMessage();
-            if(flag=='1'){
+            if (flag == '1') {
                 $(".tk_twyc").show();
                 $("#errortw").show();
                 $("#successtw").hide();
-            }else{
+            } else {
                 $(".tk_twyc").hide();
                 $("#errortw").hide();
                 $("#successtw").show();
@@ -1122,70 +1225,122 @@
 
         setInterval(function () {
             for (var i = 1; i <= 16; i++) {
-                $(".wdbh_"+i).html((Math.ceil(Math.random()*1)+38)+"."+(Math.ceil(Math.random()*9)));
+                $(".wdbh_" + i).html((Math.ceil(Math.random() * 1) + 38) + "." + (Math.ceil(Math.random() * 9)));
             }
 
-            $(".wdbh_error").html((Math.ceil(Math.random()*3)+41)+"."+(Math.ceil(Math.random()*9)));
-        },2000);
+            $(".wdbh_error").html((Math.ceil(Math.random() * 3) + 41) + "." + (Math.ceil(Math.random() * 9)));
+        }, 2000);
 
         setInterval(function () {
-                $("#wd").html((Math.ceil(Math.random()*10)+15)+"."+(Math.ceil(Math.random()*9))+"°C");
-                $("#sd").html((Math.ceil(Math.random()*10)+55)+"%");
-                $("#eyht").html((Math.ceil(Math.random()*8)+45)+"."+(Math.ceil(Math.random()*9))+"mg/m³");
-                $("#gz").html((Math.ceil(Math.random()*10)+75)+"."+(Math.ceil(Math.random()*9))+"lx");
-                $("#lhq").html("0."+(Math.ceil(Math.random()*5)+10)+"mg/m³");
-        },3000);
+            $("#wd").html((Math.ceil(Math.random() * 10) + 15) + "." + (Math.ceil(Math.random() * 9)) + "°C");
+            $("#sd").html((Math.ceil(Math.random() * 10) + 55) + "%");
+            $("#eyht").html((Math.ceil(Math.random() * 8) + 45) + "." + (Math.ceil(Math.random() * 9)) + "mg/m³");
+            $("#gz").html((Math.ceil(Math.random() * 10) + 75) + "." + (Math.ceil(Math.random() * 9)) + "lx");
+            $("#lhq").html("0." + (Math.ceil(Math.random() * 5) + 10) + "mg/m³");
+        }, 3000);
 
-	</script>
 
-	<script type="text/javascript">
-		// 时间
-		myformatter(new Date());
-		    function myformatter(date){
-		        var y = date.getFullYear();
-		        var m = date.getMonth()+1;
-		        var d = date.getDate();
-		        var h = date.getHours();
-		        var min = date.getMinutes();
-		        var s = date.getSeconds();
-		        var str=y+'/'+(m<10?('0'+m):m)+'/'+(d<10?('0'+d):d)+'/  '+(h<10?('0'+h):h)+':'+(min<10?('0'+min):min)+':'+(s<10?('0'+s):s);
-		        jQuery(".time").html(str);
-		        setTimeout("myformatter(new Date());", 1000);
-		        return str;
-		    }
+        // 时间
+        myformatter(new Date());
 
-			$(function(){
-				// 地图点 显示隐藏
-				$(".map_ld1").hover(function(){
-					$(this).children(".xs_div").show();
-				},function(){
-					$(this).children(".xs_div").hide();
-				});
-				$(".map_ld3").hover(function(){
-					$(this).children(".xs_div").show();
-				},function(){
-					$(this).children(".xs_div").hide();
-				});
+        function myformatter(date) {
+            var y = date.getFullYear();
+            var m = date.getMonth() + 1;
+            var d = date.getDate();
+            var h = date.getHours();
+            var min = date.getMinutes();
+            var s = date.getSeconds();
+            var str = y + '/' + (m < 10 ? ('0' + m) : m) + '/' + (d < 10 ? ('0' + d) : d) + '/  ' + (h < 10 ? ('0' + h) : h) + ':' + (min < 10 ? ('0' + min) : min) + ':' + (s < 10 ? ('0' + s) : s);
+            jQuery(".time").html(str);
+            setTimeout("myformatter(new Date());", 1000);
+            return str;
+        }
 
-                // 弹框2TITTLE显示隐藏
-                $(".tk2_list ul li").hover(function(){
-                    $(this).children(".tk2_div").show();
-                },function(){
-                    $(this).children(".tk2_div").hide();
-                });
+        $(function () {
+            // 地图点 显示隐藏
+            $(".map_ld1").hover(function () {
+                $(this).children(".xs_div").show();
+            }, function () {
+                $(this).children(".xs_div").hide();
+            });
+            $(".map_ld3").hover(function () {
+                $(this).children(".xs_div").show();
+            }, function () {
+                $(this).children(".xs_div").hide();
+            });
 
-                // 二维码点击放大
-                $(".zhnc_ewm").on('click',function(){
-                    var ewmsrc = $(this).attr('src');
-                    $(".ewm_src img").attr('src', ewmsrc);
-                    $(".ewm_src").show();
-                });
-                $(".ewm_src span").on('click',function(){
-                    $(".ewm_src img").attr('src', '');
-                    $(".ewm_src").hide();
-                });
-			})
+            // 弹框2TITTLE显示隐藏
+            $(".tk2_list ul li").hover(function () {
+                $(this).children(".tk2_div").show();
+            }, function () {
+                $(this).children(".tk2_div").hide();
+            });
 
-	</script>
+            // 二维码点击放大
+            $(".zhnc_ewm").on('click', function () {
+                var ewmsrc = $(this).attr('src');
+                $(".ewm_src img").attr('src', ewmsrc);
+                $(".ewm_src").show();
+            });
+            $(".ewm_src span").on('click', function () {
+                $(".ewm_src img").attr('src', '');
+                $(".ewm_src").hide();
+            });
+
+
+            $(".qiehuan").on('click', function () {
+                var text = $(this).html();
+                $(".qiehuan").attr("class","qiehuan");
+                $(this).attr("class","qiehuan on");
+                if(text == "组织"){
+                    aloneOrGroup = "group";
+                    var html = "";
+                    if (errorTwoIndex == 1) {
+                        for (var i = 0; i < 20; i+=4) {
+                            var portsparam = ports[i]+","+ports[i+1]+","+ports[i+2]+","+ports[i+3];
+                            html += "<li>\n" +
+                                "<a onclick=\"goPlugIn('"+portsparam+"')\"><i></i>"+(i+1)+"-"+(i+4)+"探头</a>\n" +
+                                "</li>";
+                        }
+                        var oneports = ports[0]+","+ports[1]+","+ports[2]+","+ports[3];
+                        goPlugIn(oneports)
+                    } else if (errorTwoIndex == 4) {
+                        for (var i = 20; i < 28; i++) {
+                            var portsparam = ports[i]+","+ports[i+1]+","+ports[i+2]+","+ports[i+3];
+                            html += "<li>\n" +
+                                "<a onclick=\"goPlugIn('"+portsparam+"')\"><i></i>"+(i+1)+"-"+(i+4)+"探头</a>\n" +
+                                "</li>";
+                        }
+                        var oneports = ports[20]+","+ports[21]+","+ports[22]+","+ports[23];
+                        goPlugIn(oneports)
+                    } else {
+                        $("#openVideo-tk2").attr("src","");
+                    }
+                    $("#tantou").html(html);
+                }else {
+                    aloneOrGroup = "alone";
+                    var html = "";
+                    if (errorTwoIndex == 1) {
+                        for (var i = 0; i < 20; i++) {
+                            html += "<li>\n" +
+                                "<a onclick=\"goPlugIn('"+ports[i]+"')\"><i></i>" + ports[i] + "的探头</a>\n" +
+                                "</li>";
+                        }
+                        goPlugIn(ports[0])
+                    } else if (errorTwoIndex == 4) {
+                        for (var i = 20; i < 28; i++) {
+                            html += "<li>\n" +
+                                "<a onclick=\"goPlugIn('" + ports[i] + "')\"><i></i>" + ports[i] + "的探头</a>\n" +
+                                "</li>";
+                        }
+                        goPlugIn(ports[20])
+                    } else {
+                        $("#openVideo-tk2").attr("src","");
+                    }
+                    $("#tantou").html(html);
+                }
+            });
+        })
+    </script>
 
 </html>

+ 0 - 305
mybusiness/src/main/resources/templates/ksh/ksh_t1.html

@@ -1,305 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh" xmlns:th="http://www.thymeleaf.org">
-	<head>
-		<meta charset="utf-8">
-		<title>智慧养殖可视化</title>
-		<link th:href="@{/zhnc/syweb/css/zhncksh.css}" rel="stylesheet"/>
-		<link th:href="@{/zhnc/syweb/css/bootstrap-switch.css}" rel="stylesheet">
-		<script th:src="@{/zhnc/syweb/js/jquery-1.11.0.min.js}" type="text/javascript"></script>
-		<script th:src="@{/zhnc/syweb/js/jquery.min.js}"></script>
-		<script th:src="@{/zhnc/syweb/js/bootstrap.min.js}"></script>
-		<script th:src="@{/zhnc/syweb/js/highlight.js}"></script>
-		<script th:src="@{/zhnc/syweb/js/bootstrap-switch.js}"></script>
-		<script th:src="@{/zhnc/syweb/js/main.js}"></script>
-	</head>
-	<body>
-
-		<!-- 弹框1  开始 -->
-		<div class="tk_div">
-			<h1 class="tk_tit">>&nbsp;牛舍详情</h1>
-			<div class="tk_con clearfix">
-				<!-- 左侧 开始 -->
-				<div class="tk_left fl">
-					<ul class="tk_ul1">
-						<li>
-							<span><i></i>名称:</span><u>XXX牛舍</u>
-						</li>
-						<li>
-							<span><i></i>牛舍编号:</span><u>004</u>
-						</li>
-						<li>
-							<span><i></i>负责人:</span><u>张国刚</u>
-						</li>
-						<li>
-							<span><i></i>容纳牛只数:</span><u>1100</u>
-						</li>
-						<li>
-							<span><i></i>实际牛只数:</span><u>800</u>
-						</li>
-					</ul>
-					<dl class="tk_dl">
-						<dt>
-							<span>编号</span>
-							<span>品种</span>
-							<span>体重(公斤)</span>
-							<span>温度(°C)</span>
-							<span>认养/入驻</span>
-						</dt>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-						<dd><a>
-							<span>01</span>
-							<span>黄牛</span>
-							<span>300</span>
-							<span>38.5</span>
-							<span>入驻</span></a>
-						</dd>
-
-					</dl>
-				</div>
-			    <!-- 左侧 结束 -->
-				<!-- 右侧 开始 -->
-				<div class="tk_right fl">
-					<div class="sp_div">
-						<img th:src="@{/zhnc/syweb/images/zhnctk_03.png}" style="width:100%;height:100%"/>
-					</div>
-					<div class="sp_list">
-						<h5 class="sp_tit">摄像头列表</h5>
-						<ul class="sp_ul">
-							<li>
-								<a><i></i>牛舍监控探头1</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-							<li>
-								<a><i></i>牛舍监控探头2</a>
-							</li>
-						</ul>
-					</div>
-					<div class="clear"></div>
-
-					<div class="tk_ssjksj fl">
-						<h5 class="ssjksj_tit">实时监控数据</h5>
-						<div class="tk_padding clearfix">
-							<div class="tk_btn">
-								<span><img th:src="@{/zhnc/syweb/images/zhnctk_07.png}" /></span>
-								<div class="tk_txt">
-									<h4>温度</h4>
-									<h2>12.8°C</h2>
-								</div>
-							</div>
-							<div  class="tk_btn">
-								<span><img th:src="@{/zhnc/syweb/images/zhnctk_09.png}" /></span>
-								<div class="tk_txt">
-									<h4>湿度</h4>
-									<h2>18%</h2>
-								</div>
-							</div>
-							<div  class="tk_btn">
-								<span><img th:src="@{/zhnc/syweb/images/zhnctk_11.png}" /></span>
-								<div class="tk_txt">
-									<h4>二氧化碳</h4>
-									<h2>51.3ug/m³</h2>
-								</div>
-							</div>
-							<div  class="tk_btn">
-								<span><img th:src="@{/zhnc/syweb/images/zhnctk_34.png}" /></span>
-								<div class="tk_txt">
-									<h4>紫外线</h4>
-									<h2>17.6w/m²</h2>
-								</div>
-							</div>
-							<div  class="tk_btn">
-								<span><img th:src="@{/zhnc/syweb/images/zhnctk_28.png}" /></span>
-								<div class="tk_txt">
-									<h4>氧气</h4>
-									<h2>20.5</h2>
-								</div>
-							</div>
-							<div  class="tk_btn">
-								<span><img th:src="@{/zhnc/syweb/images/zhnctk_31.png}" /></span>
-								<div class="tk_txt">
-									<h4>太阳辐射</h4>
-									<h2>17.6w/m²</h2>
-								</div>
-							</div>
-						</div>
-					</div>
-
-					<div class="tk_znkz fl">
-						<h5 class="ssjksj_tit">智能控制</h5>
-						<div class="znkz_div clearfix">
-							<div class="znkz_btn">
-								<p class="znkz_fjkg">风机开关</p>
-								<input id="switch-offColor" type="checkbox" data-off-color="warning">
-							</div>
-							<div class="znkz_btn">
-								<p class="znkz_dkg">灯开关</p>
-								<input id="switch-offColor" type="checkbox" data-off-color="warning">
-							</div>
-							<div class="znkz_btn">
-								<p class="znkz_slkg">湿帘开关</p>
-								<input id="switch-offColor" type="checkbox" checked>
-							</div>
-							<div class="znkz_btn">
-								<p class="znkz_tckg">天窗开关</p>
-								<input id="switch-offColor" type="checkbox" data-off-color="warning">
-							</div>
-							<div class="znkz_btn">
-								<p class="znkz_tskg">投食开关</p>
-								<input id="switch-offColor" type="checkbox" data-off-color="warning">
-							</div>
-						</div>
-					</div>
-
-				</div>
-				<!-- 右侧 结束 -->
-				<!-- 底部 横条按钮 开始 -->
-				<div class="tk_hbtn">
-					<input type="button" value="确定" class="btn_qd fr"/>
-					<input type="button" value="取消" class="btn_qx fr"/>
-				</div>
-				<!-- 底部 横条按钮 结束 -->
-
-			</div>
-		</div>
-		<!-- 弹框1  结束 -->
-
-		<!-- 中间内容  结束 -->
-	</body>
-
-	<script type="text/javascript">
-
-
-			$(function(){
-
-
-				// 弹框2TITTLE显示隐藏
-				$(".tk2_list ul li").hover(function(){
-					$(this).children(".tk2_div").show();
-				},function(){
-					$(this).children(".tk2_div").hide();
-				});
-
-			})
-
-	</script>
-
-</html>

+ 0 - 236
mybusiness/src/main/resources/templates/ksh/ksh_t2.html

@@ -1,236 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh" xmlns:th="http://www.thymeleaf.org">
-	<head>
-		<meta charset="utf-8">
-		<title>智慧养殖可视化</title>
-		<link th:href="@{/zhnc/syweb/css/zhncksh.css}" rel="stylesheet"/>
-		<script th:src="@{/zhnc/syweb/js/jquery-1.11.0.min.js}" type="text/javascript"></script>
-	</head>
-	<body>
-
-		<!-- 弹框2 开始 -->
-		<div class="tk_div" id="tk_div2">
-			<h1 class="tk_tit">>&nbsp;牛只详情</h1>
-			<div class="tk_con clearfix">
-				<!-- 左侧 开始 -->
-				<div class="tk2_left">
-					<ul class="tk2_ul">
-						<li>
-							<span class="tit">编号:</span>
-							<span class="txt">001</span>
-							<span class="tit">牛舍编号:</span>
-							<span class="txt">001</span>
-							<span class="tit">是否认养:</span>
-							<span class="txt">否</span>
-							<span class="tit">是否入驻:</span>
-							<span class="txt">是</span>
-						</li>
-						<li>
-							<span class="tit">是否种牛:</span>
-							<span class="txt">否</span>
-							<span class="tit">初始体重:</span>
-							<span class="txt">10kg</span>
-							<span class="tit">品种:</span>
-							<span class="txt">黄牛</span>
-							<span class="tit">入舍月龄:</span>
-							<span class="txt">5个月</span>
-						</li>
-						<li>
-							<span class="tit">养殖开始时间:</span>
-							<span class="txt">2022年1/1</span>
-							<span class="tit">预计出舍时间:</span>
-							<span class="txt">2022年10/10</span>
-							<span class="tit">屠宰时间:</span>
-							<span class="txt">2022年10/10</span>
-							<span class="tit">生长周期:</span>
-							<span class="txt">5个月</span>
-						</li>
-						<li>
-							<span class="tit">养殖状态:</span>
-							<span class="txt">正常</span>
-							<span class="tit">采购成本:</span>
-							<span class="txt">1000元</span>
-						</li>
-						<li>
-							<span class="tit2">设备码:</span>
-							<span class="txt2"></span>
-							<span class="tit2">溯源二维码:</span>
-							<span class="txt2"></span>
-						</li>
-						<li>
-							<span class="txt3">
-								<img th:src="@{/zhnc/syweb/images/zhnctk_41.png"/>
-							</span>
-							<span class="txt3">
-								<img th:src="@{/zhnc/syweb/images/zhnctk_41.png"/>
-							</span>
-						</li>
-						<li>
-							<span class="tit">图片附件信息:</span>
-						</li>
-						<li>
-							<span class="txt4">
-								<img th:src="@{/zhnc/syweb/images/zhnctk_42.png"/>
-							</span>
-							<span class="txt4">
-								<img th:src="@{/zhnc/syweb/images/zhnctk_43.png"/>
-							</span>
-							<span class="txt4">
-								<img th:src="@{/zhnc/syweb/images/zhnctk_44.png"/>
-							</span>
-						</li>
-					</ul>
-					<p>
-						<span>月龄/年龄:5个月</span>
-						<span>体重:24kg</span>
-						<span>体温:36℃</span>
-					</p>
-				</div>
-				<!-- 左侧 结束 -->
-				<!-- 右侧 开始 -->
-				<div class="tk2_right">
-					<div class="tk2_list fl">
-						<h5 class="ssjksj_tit">疫病档案</h5>
-						<ul>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-								<div class="tk2_div">
-									<p>疫病名称:XXX病</p>
-									<p>时间:2022年1月10日</p>
-									<p>负责人:张国军</p>
-								</div>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-								<div class="tk2_div">
-									<p>疫病名称:XXX病</p>
-									<p>时间:2022年1月10日</p>
-									<p>负责人:张国军</p>
-								</div>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-								<div class="tk2_div">
-									<p>疫病名称:XXX病</p>
-									<p>时间:2022年1月10日</p>
-									<p>负责人:张国军</p>
-								</div>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-
-							<li>
-								<a><i></i>2022年1月3日疫病档案信息</a>
-							</li>
-						</ul>
-					</div>
-					<div class="tk2_list fr">
-						<h5 class="ssjksj_tit">用药档案</h5>
-							<ul>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-									<div class="tk2_div">
-										<p>疫病名称:XXX病</p>
-										<p>用药名称:XXX</p>
-										<p>时间:2022年1月10日</p>
-										<p>负责人:张国军</p>
-									</div>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-									<div class="tk2_div">
-										<p>疫病名称:XXX病</p>
-										<p>用药名称:XXX</p>
-										<p>时间:2022年1月10日</p>
-										<p>负责人:张国军</p>
-									</div>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-									<div class="tk2_div">
-										<p>疫病名称:XXX病</p>
-										<p>用药名称:XXX</p>
-										<p>时间:2022年1月10日</p>
-										<p>负责人:张国军</p>
-									</div>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-
-								<li>
-									<a><i></i>2022年1月3日疫病档案信息</a>
-								</li>
-							</ul>
-
-					</div>
-					<div class="clear"></div>
-				</div>
-				<!-- 右侧 结束 -->
-				<!-- 底部 横条按钮 开始 -->
-				<div class="tk_hbtn">
-					<input type="button" value="确定" class="btn_qd fr"/>
-				</div>
-				<!-- 底部 横条按钮 结束 -->
-
-			</div>
-		</div>
-		<!-- 弹框2 结束 -->
-
-	</body>
-
-	<script type="text/javascript">
-
-
-			$(function(){
-
-
-				// 弹框2TITTLE显示隐藏
-				$(".tk2_list ul li").hover(function(){
-					$(this).children(".tk2_div").show();
-				},function(){
-					$(this).children(".tk2_div").hide();
-				});
-
-			})
-
-	</script>
-
-</html>