Bläddra i källkod

Merge branch 'master' of http://git.ycjcjy.com/nanyang/machinery-admin

李志伟 3 år sedan
förälder
incheckning
beb44fa8fa

Binär
src/assets/images/screen/statis-icon1.gif Visa fil


Binär
src/assets/images/screen/statis-icon2.gif Visa fil


Binär
src/assets/images/screen/statis-icon3.gif Visa fil


Binär
src/assets/images/screen/statis-icon4.gif Visa fil


+ 13
- 8
src/components/GeoMap/VideoModel.jsx Visa fil

@@ -1,12 +1,12 @@
1 1
 import { Modal, Button } from 'antd';
2
-import React, { useEffect, useState } from 'react';
2
+import React, { useEffect, useMemo, useState } from 'react';
3 3
 
4 4
 export default (props) => {
5
-  const { width = 600, height = 480, machineryRef, visible, toggleVisible } = props;
5
+  const { width = 600, machineryRef, visible, toggleVisible } = props;
6 6
 
7
-  const [url, setURL] = useState(
8
-    'https://yz-offical.oss-cn-shanghai.aliyuncs.com/%E7%9C%81%E5%8F%98%E7%94%B5%E5%9F%B9%E8%AE%AD%E5%9F%BA%E5%9C%B0%E8%A7%86%E9%A2%91%20A%20copy.mov',
9
-  );
7
+  const [url, setURL] = useState();
8
+
9
+  const TitleHolder = useMemo(() => <div>这是标题占位</div>, []);
10 10
 
11 11
   const handleCancel = () => {
12 12
     toggleVisible(false);
@@ -16,18 +16,23 @@ export default (props) => {
16 16
     // 隐藏的时候取消视频播放
17 17
     if (!visible) {
18 18
       setURL(undefined);
19
+    } else {
20
+      setURL(
21
+        'https://yz-offical.oss-cn-shanghai.aliyuncs.com/%E7%9C%81%E5%8F%98%E7%94%B5%E5%9F%B9%E8%AE%AD%E5%9F%BA%E5%9C%B0%E8%A7%86%E9%A2%91%20A%20copy.mov',
22
+      );
19 23
     }
20 24
   }, [visible]);
21 25
 
22 26
   return (
23 27
     <Modal
24
-      width={width}
28
+      wrapClassName="geo-map-modal"
29
+      title={TitleHolder}
30
+      width={width + 4}
25 31
       footer={null}
26 32
       visible={visible}
27 33
       onCancel={handleCancel}
28
-      bodyStyle={{ padding: 0 }}
29 34
     >
30
-      <video style={{ display: 'block' }} width={width} height={height} controls src={url}>
35
+      <video style={{ display: 'block' }} width={width} controls src={url}>
31 36
         您的浏览器不支持 video 。
32 37
       </video>
33 38
     </Modal>

+ 155
- 0
src/components/GeoMap/global.less Visa fil

@@ -0,0 +1,155 @@
1
+.geo-map-modal {
2
+  .ant-modal-header,
3
+  .ant-modal-content {
4
+    background: transparent;
5
+  }
6
+
7
+  .ant-modal-header {
8
+    color: rgba(0, 0, 0, 0);
9
+  }
10
+
11
+  .ant-modal-body {
12
+    padding: 0;
13
+    border: 2px solid #0bdaff;
14
+  }
15
+
16
+  .ant-modal-close {
17
+    top: 8px;
18
+    right: -16px;
19
+  }
20
+
21
+  .ant-modal-close-x {
22
+    color: #0bdaff;
23
+    font-size: 24px;
24
+  }
25
+}
26
+
27
+.geo-map-marker-label {
28
+  display: inline-block;
29
+  padding: 20px;
30
+  background: rgba(0, 0, 0, 0.4);
31
+}
32
+
33
+.geo-map-marker-label-text {
34
+  font-size: 24px;
35
+  line-height: 24px;
36
+  background-image: linear-gradient(180deg, #fca790 0%, #e63404 93.84765625%);
37
+  background-clip: text;
38
+  -webkit-text-fill-color: transparent;
39
+}
40
+
41
+// 合作社的样式----Start----
42
+
43
+.geo-map-rural-box {
44
+  padding: 18px;
45
+  font-weight: 800;
46
+  font-size: 12px;
47
+  background: rgba(3, 3, 3, 0.3);
48
+
49
+  border: 1px solid rgba(61, 129, 240, 0.5);
50
+  border-radius: 4px;
51
+}
52
+
53
+.borderBox {
54
+  background-image: linear-gradient(360deg, #fca790 0%, #e63404 93.84765625%);
55
+  background-clip: text;
56
+  -webkit-text-fill-color: transparent;
57
+}
58
+.geo-map-rural-text-span {
59
+  word-spacing: 19px;
60
+}
61
+// 合作社的样式----End----
62
+
63
+// 农机监控----Start----
64
+.SquareBox-box-carsMarker {
65
+  position: relative;
66
+  // height: 100%;
67
+  background: rgba(3, 3, 3, 0.3);
68
+  border: 1px solid rgba(61, 129, 240, 0.5);
69
+  border-radius: 4px;
70
+}
71
+.SquareBox-body-carsMarker {
72
+  height: 100%;
73
+  padding: 11px;
74
+  color: #fff;
75
+  // background: rgba(8, 40, 90, 0.4);
76
+  background: rgba(3, 3, 3, 0.3);
77
+  border: 2px solid rgba(61, 129, 240, 0.5);
78
+}
79
+.border_corner-carsMarker {
80
+  position: absolute;
81
+  width: 4px;
82
+  height: 4px;
83
+  background-color: #67ffff;
84
+  border-radius: 50%;
85
+}
86
+.border_corner_left_top-left {
87
+  top: 0;
88
+  left: -2px;
89
+  border-right: none;
90
+  border-bottom: none;
91
+}
92
+.border_corner_right_top-right {
93
+  top: 0;
94
+  right: -2px;
95
+  border-bottom: none;
96
+  border-left: none;
97
+}
98
+.border_corner_left_bottom-left {
99
+  bottom: 0;
100
+  left: -2px;
101
+  border-top: none;
102
+  border-right: none;
103
+}
104
+.border_corner_right_bottom-right {
105
+  right: -2px;
106
+  bottom: 0;
107
+  border-top: none;
108
+  border-left: none;
109
+}
110
+// 合作社的样式----End----
111
+
112
+// 农机监控信息----Start----
113
+
114
+//上部
115
+.map-top-border {
116
+  width: 100%;
117
+}
118
+
119
+.map-top-cars {
120
+  width: 7vw;
121
+}
122
+
123
+.map-top-start {
124
+  position: absolute;
125
+  top: 6.8vh;
126
+  left: 3.4vw;
127
+  // position: relative;
128
+  // top: 0px;
129
+  // left: 60px;
130
+}
131
+.map-top-stop {
132
+  position: absolute;
133
+  right: 1vw;
134
+  bottom: 8vh;
135
+}
136
+
137
+//底部
138
+.map-button-border {
139
+  font-weight: 800;
140
+  font-size: 12px;
141
+}
142
+.carsName {
143
+  margin-top: 15px;
144
+  background-image: linear-gradient(360deg, #fca790 0%, #e63404 93.84765625%);
145
+  background-clip: text;
146
+  -webkit-text-fill-color: transparent;
147
+}
148
+.map-button-border-carsRural {
149
+  display: flex;
150
+  justify-content: space-between;
151
+  > span {
152
+    font-weight: 800;
153
+  }
154
+}
155
+// 合作社的样式----End----

+ 1
- 0
src/components/GeoMap/index.jsx Visa fil

@@ -5,6 +5,7 @@ import { useMarker, useMarkerVisible } from './marker';
5 5
 import Styles from './style.less';
6 6
 import RadioGroup from '../ScreenBox/Radio/RadioGroup';
7 7
 import VideoModel from './VideoModel';
8
+import './global.less';
8 9
 
9 10
 export default (props) => {
10 11
   const { machineTypeList, orgList, machineList } = props;

+ 0
- 130
src/global.less Visa fil

@@ -88,133 +88,3 @@ ol {
88 88
   background: transparent;
89 89
   border: none;
90 90
 }
91
-
92
-.geo-map-marker-label {
93
-  display: inline-block;
94
-  padding: 20px;
95
-  background: rgba(0, 0, 0, 0.4);
96
-}
97
-
98
-.geo-map-marker-label-text {
99
-  font-size: 24px;
100
-  line-height: 24px;
101
-  background-image: linear-gradient(180deg, #fca790 0%, #e63404 93.84765625%);
102
-  background-clip: text;
103
-  -webkit-text-fill-color: transparent;
104
-}
105
-
106
-// 合作社的样式----Start----
107
-
108
-.geo-map-rural-box {
109
-  padding: 18px;
110
-  font-weight: 800;
111
-  font-size: 12px;
112
-  background: rgba(3, 3, 3, 0.3);
113
-
114
-  border: 1px solid rgba(61, 129, 240, 0.5);
115
-  border-radius: 4px;
116
-}
117
-
118
-.borderBox {
119
-  background-image: linear-gradient(360deg, #fca790 0%, #e63404 93.84765625%);
120
-  background-clip: text;
121
-  -webkit-text-fill-color: transparent;
122
-}
123
-.geo-map-rural-text-span {
124
-  word-spacing: 19px;
125
-}
126
-// 合作社的样式----End----
127
-
128
-// 农机监控----Start----
129
-.SquareBox-box-carsMarker {
130
-  position: relative;
131
-  // height: 100%;
132
-  background: rgba(3, 3, 3, 0.3);
133
-  border: 1px solid rgba(61, 129, 240, 0.5);
134
-  border-radius: 4px;
135
-}
136
-.SquareBox-body-carsMarker {
137
-  height: 100%;
138
-  padding: 11px;
139
-  color: #fff;
140
-  // background: rgba(8, 40, 90, 0.4);
141
-  background: rgba(3, 3, 3, 0.3);
142
-  border: 2px solid rgba(61, 129, 240, 0.5);
143
-}
144
-.border_corner-carsMarker {
145
-  position: absolute;
146
-  width: 4px;
147
-  height: 4px;
148
-  background-color: #67ffff;
149
-  border-radius: 50%;
150
-}
151
-.border_corner_left_top-left {
152
-  top: 0;
153
-  left: -2px;
154
-  border-right: none;
155
-  border-bottom: none;
156
-}
157
-.border_corner_right_top-right {
158
-  top: 0;
159
-  right: -2px;
160
-  border-bottom: none;
161
-  border-left: none;
162
-}
163
-.border_corner_left_bottom-left {
164
-  bottom: 0;
165
-  left: -2px;
166
-  border-top: none;
167
-  border-right: none;
168
-}
169
-.border_corner_right_bottom-right {
170
-  right: -2px;
171
-  bottom: 0;
172
-  border-top: none;
173
-  border-left: none;
174
-}
175
-// 合作社的样式----End----
176
-
177
-// 农机监控信息----Start----
178
-
179
-//上部
180
-.map-top-border {
181
-  width: 100%;
182
-}
183
-
184
-.map-top-cars {
185
-  width: 7vw;
186
-}
187
-
188
-.map-top-start {
189
-  position: absolute;
190
-  top: 6.8vh;
191
-  left: 3.4vw;
192
-  // position: relative;
193
-  // top: 0px;
194
-  // left: 60px;
195
-}
196
-.map-top-stop {
197
-  position: absolute;
198
-  right: 1vw;
199
-  bottom: 8vh;
200
-}
201
-
202
-//底部
203
-.map-button-border {
204
-  font-weight: 800;
205
-  font-size: 12px;
206
-}
207
-.carsName {
208
-  margin-top: 15px;
209
-  background-image: linear-gradient(360deg, #fca790 0%, #e63404 93.84765625%);
210
-  background-clip: text;
211
-  -webkit-text-fill-color: transparent;
212
-}
213
-.map-button-border-carsRural {
214
-  display: flex;
215
-  justify-content: space-between;
216
-  > span {
217
-    font-weight: 800;
218
-  }
219
-}
220
-// 合作社的样式----End----