PC-20230501XVZZ\Administrator 1 an în urmă
părinte
comite
b1e7a7f232

+ 3 - 3
src/views/miaoqing/components/hczb.vue

@@ -91,7 +91,7 @@
 					normal: {
 						label: {
 							show: true,
-							position: 'outside',
+							position: 'inside',
 							color: '#ddd',
 							formatter: function(params) {
 								var percent = 0;
@@ -157,9 +157,9 @@
 				},
 				legend: {
 					icon: "circle",
-					orient: 'vertical',
+					orient: 'horizontal',
 					x: 'left',
-					y: 20,
+					y: 'top',
 					data: ['天牛', '布甲', '黑翅蛾', '隐翅虫'],
 					right: 20,
 					bottom: 15,

+ 20 - 6
src/views/test/components/cqjcyj.vue

@@ -2,6 +2,12 @@
 	import haichong1 from '@/assets/images/haichong1.png';
 	import haichong2 from '@/assets/images/haichong2.png';
 	import haichong3 from '@/assets/images/haichong3.png';
+	
+	import {
+		inject
+	} from "vue";
+	const getMapInstance = inject("getMapInstance");
+	jt3d = getMapInstance();
 </script>
 <template>
 	<!-- <img src="@/assets/images/haichong1.png"/> -->
@@ -23,6 +29,7 @@
 </template>
 
 <script>
+	let jt3d = undefined;
 	import {
 		Store
 	} from '@/store/index'
@@ -50,7 +57,7 @@
 				var LocateUtil = new this.jt3dSDK.LocateUtil(window["viewer"]);
 				let Drawtools = new this.jt3dSDK.DrawTools(window.viewer)
 				//_createCircle
-				PointObject.addBillboard([120.624, 36.9158, 0], {
+				PointObject.addBillboard([117.47464039,36.33623582, 0], {
 					billboard: {
 						imgUrl: 'jt3dSDK/imgs/jijing1.png',
 						scale: 0.2,
@@ -82,11 +89,18 @@
 							"<span style='width:100rem'>流量:</span>" + "<span>80m³/h</span>" +
 							"</div>";
 						html += "</div>";
-						let popup = new that.jt3dSDK.PopupWindow.HtmlWindow(window["viewer"], [120.624,
-							36.9158
-						], "设备信息", html, 50);
-						// this.createCircle()
-						// Drawtools._createCircle( Cesium.Cartesian3.fromDegrees(120.623, 36.9157),'dynamicCircle')
+						let popup = new that.jt3dSDK.PopupWindow.HtmlWindow(window["viewer"], [117.47464039,36.33623582], "设备信息", html, 50);
+						let circleObject = new this.jt3dSDK.CircleObject(jt3d._viewer);
+						circleObject.drawCircle([117.47464039,36.33623582], 50, {
+							// color: [255, 255, 0, 0.8]
+							color: [255, 0, 0, 1],
+							outline: true,
+							outlineColor: [255, 255, 255, 1],
+							outlineWidth: 20,
+							CircleType: 'DynamicCircle',
+							count: 2,
+							duration: 4000
+						})
 					})
 				})
 			}