surprise
2023-12-29 18377dc5d61caf3a6a0835e17015ac2601f8709d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
<!DOCTYPE html>
<html lang="en">
 
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="viewport"
        content="width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no">
    <title>视域分析</title>
    <link href="../SmartEarthSDK/Workers/layui/css/layui.css" rel="stylesheet" />
    <link href="./css/AnalysisContour.css" rel="stylesheet" />
 
    <style type="text/css">
        /* .layui-btn {
            padding: 0 30px;
        } */
 
        .layui-btn+.layui-btn {
            margin-left: 20px;
        }
 
        .demo-slider {
            display: inline-block !important;
            width: 173px !important;
        }
 
        .color {
            width: 100%;
            float: left;
        }
 
        .top {
            margin-top: 10px;
        }
 
        /*#test-form-input {
            margin-left: 100px!important;
        }
        */
        /*#test-form {
            /*position: absolute;
            top: 0px;
            right: 0px;
            width: 37px;
        margin-left:1px 0 1px!important;
        width: 39px;
        height: 39px;
        }*/
 
        .layui-form-label {
            font-weight: bold !important;
            font-size: 15px;
        }
 
        .lab {
            margin-right: 43px;
        }
 
        label {
            font-weight: bold;
        }
 
        .layui-input-block {
            margin-left: 105px;
            min-height: 36px;
            margin-top: -24px;
        }
 
        .layui-colorpicker {
            margin-top: 1px;
            margin-right: 59px;
        }
 
        .smallbtn {
            display: inline-block;
            position: absolute;
            right: 0;
            top: 0px;
        }
 
        .layui-form-item {
            width: 100% !important;
        }
        .addview {
            background:rgba(0, 168, 255, 0.16) !important
        }
    </style>
 
</head>
 
<body>
    <div class="layui-form-item" style="margin-top: 20px!important;">
        <label class="layui-form-label " style="margin-left:-26px; width:100px;color: white;">视点高度</label>
        <div class="layui-input-inline">
            <input id="height" value="1.7" type="text" lay-verify="pass" autocomplete="off" placeholder="请输入相对高度"
                onkeyup="value=value.replace(/[^\d\.]/g,'')" class="layui-input ">
            <span class="iptline" style="color: white;">(米)</span>
        </div>
    </div>
    <div class="layui-form-item" style="margin-top: 10px!important;">
        <!-- //style="margin-top: 1px; width: 130px!important; height: 39px;" -->
        <label class="layui-form-label " style="margin-left:-26px; width:100px;color: white;">可见颜色</label>
        <div class="layui-input-inline">
            <!--//style="width: 120px;"-->
            <input type="text" value="" placeholder="请选择颜色" class="layui-input" id="visibleArea-input">
 
            <div id="visibleArea" class="smallbtn"></div>
        </div>
 
    </div>
    <div class="layui-form-item" style="margin-top: 10px!important;">
        <!-- //style="margin-top: 1px; width: 130px!important; height: 39px;" -->
        <label class="layui-form-label " style="margin-left:-26px; width:100px;color: white;">不可见颜色</label>
        <div class="layui-input-inline">
            <!--//style="width: 120px;"-->
            <input type="text" value="" placeholder="请选择颜色" class="layui-input" id="unVisibleArea-input">
 
            <div id="unVisibleArea" class="smallbtn"></div>
        </div>
 
    </div>
    <div class="layui-item" style="margin-top: 8px!important;margin: 3px auto 0;text-align: center;">
        <button type="button" class="layui-btn  layui-btn-normal layui-btn-lg addview" onclick="addViewshed()">添加视点
        </button>
        <!-- <button type="button" class="layui-btn   layui-btn-lg " onclick="clearViewshed()">清除视域
        </button> -->
 
    </div>
    <script src="../jquery-2.0.3.js"></script>
    <script src="../SmartEarthSDK/Workers/layui/layui.js"></script>
    <script src="./js/layuiAnalysis.js"></script>
    <script>
        var height = 0;
        $('#height').on('input propertychange', function (event) {
            var value = this.value;
            if (value === '') {
                height = 0;
            } else {
                value = value.replace(/[^\d\.]/g, '');
                height = parseFloat(value);
            }
        });
 
        function addViewshed() {
            parent.addViewshed(height);
        }
 
        function clearViewshed() {
            parent.clearnViewshed();
        }
    </script>
 
</body>
 
</html>