diff --git a/src/api/http.js b/src/api/http.js new file mode 100644 index 0000000..7400b1c --- /dev/null +++ b/src/api/http.js @@ -0,0 +1,18 @@ +import { service } from '../utils/request'; + +export const http = { + get(params = {}, url){ + return service({ url, method: "get", params}); + }, + post(data = {}, url){ + return service({ url, method: "post", data }); + }, + put(data = {}, url){ + return service({ url, method: "put", data }); + }, + delete(data = {}, url){ + return service({url,method: "delete",data}); + } +} + + diff --git a/src/components/ChooseList.vue b/src/components/ChooseList.vue new file mode 100644 index 0000000..69dddbc --- /dev/null +++ b/src/components/ChooseList.vue @@ -0,0 +1,174 @@ + + + + + + diff --git a/src/components/popupView.vue b/src/components/popupView.vue new file mode 100644 index 0000000..40e534d --- /dev/null +++ b/src/components/popupView.vue @@ -0,0 +1,226 @@ + + + + + diff --git a/src/pages/map/index.vue b/src/pages/map/index.vue index 4a2dfe3..def5d07 100644 --- a/src/pages/map/index.vue +++ b/src/pages/map/index.vue @@ -20,7 +20,6 @@
-
@@ -123,6 +122,10 @@ async function fetchUnfinishedEvents() { const res = await getEventUnfinished({ eventCategory, areaCode }); console.log('未完成预警事件:', res); const list = Array.isArray(res) ? res : (res.data || []); + list.forEach(item => { + item.jd = 104.39013; + item.wd = 31.1244028; + }); markers.value = list; nextTick(() => { addMapMarkers(list); @@ -149,7 +152,7 @@ function getMarkerColor(eventLevel) { function addMapMarkers(list) { if (!window.map || !list || list.length === 0) return; - const validList = list.filter(item => item.longitude && item.latitude); + const validList = list.filter(item => item.jd && item.wd); validList.forEach(item => { const color = getMarkerColor(item.eventLevel); @@ -162,13 +165,14 @@ function addMapMarkers(list) { icon.style.cssText = 'color:#fff;font-size:18px;font-weight:bold;line-height:1;'; el.appendChild(icon); - const marker = window.map.Marker(el, [item.longitude, item.latitude], { anchor: 'bottom' }); + const marker = window.map.Marker(el, [item.jd, item.wd], { anchor: 'bottom' }); el.addEventListener('click', () => { + console.log('点击了标记', item); selectedMarker.value = { id: item.id, type: activeAlertType.value, - title: item.eventType || item.title || '预警事件', + title: item.msg || item.eventType || item.title || '预警事件', location: item.siteName || item.location || '', time: item.eventTime || item.time || '', rawData: item diff --git a/src/pages/my/index.vue b/src/pages/my/index.vue index a821bac..1c09f23 100644 --- a/src/pages/my/index.vue +++ b/src/pages/my/index.vue @@ -23,11 +23,11 @@
{{ stats.violationCount }}
-
违章预警
+
违规任务
{{ stats.trafficCount }}
-
路况预警
+
路况任务
{{ stats.completedCount }}
@@ -62,7 +62,7 @@ 执法点位
@@ -94,23 +94,29 @@ + + + + \ No newline at end of file diff --git a/src/pages/violationAlerts/detail.vue b/src/pages/violationAlerts/detail.vue index 6d9d6a3..9c1afda 100644 --- a/src/pages/violationAlerts/detail.vue +++ b/src/pages/violationAlerts/detail.vue @@ -3,7 +3,7 @@ @@ -48,30 +48,6 @@ - -
-
- {{allDetail.clickTime}} - 【定位打卡】 -
- -
- 打卡账号: - 21515800 -
- -
- - {{allDetail.clickAddress}} -
- - -
- 处罚结果 - 未拦截成功 -
-
- @@ -134,6 +110,30 @@ + +
+
+ {{allDetail.clickTime}} + 【定位打卡】 +
+ +
+ 打卡账号: + 21515800 +
+ +
+ + {{allDetail.clickAddress}} +
+ + +
+ 处罚结果 + 未拦截成功 +
+
+
定位打卡 @@ -145,11 +145,11 @@
- +