|
@@ -0,0 +1,111 @@
|
|
|
+<template>
|
|
|
+ <div class="base-container">
|
|
|
+ <fnHeader :hideSwitch="true" :hideShadow="true"></fnHeader>
|
|
|
+ <div class="content">
|
|
|
+ <div class="left">
|
|
|
+ <div class="btn" @click="goBack">
|
|
|
+ <el-icon><ArrowLeftBold /></el-icon>
|
|
|
+ 返回
|
|
|
+ </div>
|
|
|
+ <div class="left-cont">
|
|
|
+ <chart-box name="气象预警" arrow="left" color="yellow">
|
|
|
+ <template #title-right>
|
|
|
+ <div class="button">123</div>
|
|
|
+ </template>
|
|
|
+ </chart-box>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="right">
|
|
|
+ <div class="excute-title">执行农事区域</div>
|
|
|
+ <div ref="mapRef" class="bottom-map"></div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script setup>
|
|
|
+import { onMounted, ref } from "vue";
|
|
|
+import fnHeader from "@/components/fnHeader.vue";
|
|
|
+import FarmMap from "./farmMap";
|
|
|
+import chartBox from "@/components/chartBox.vue";
|
|
|
+import { useRouter, useRoute } from "vue-router";
|
|
|
+import { useStore } from "vuex";
|
|
|
+let store = useStore();
|
|
|
+let farmMap = new FarmMap();
|
|
|
+
|
|
|
+const router = useRouter();
|
|
|
+const route = useRoute();
|
|
|
+const mapRef = ref();
|
|
|
+onMounted(() => {
|
|
|
+ getList();
|
|
|
+ farmMap.initMap("POINT(113.61448114737868 23.585550924763083)", mapRef.value);
|
|
|
+});
|
|
|
+
|
|
|
+const workList = ref([]);
|
|
|
+const getList = () => {
|
|
|
+ VE_API.order.fetchWorkList().then(({ data }) => {
|
|
|
+ // data[0].orderStatus = data[0].orderStatus + 1
|
|
|
+ // && (ROLETYPE.value == '0' || ROLETYPE.value == '3')
|
|
|
+ if (route.query.data && JSON.parse(route.query.data)?.farmWorkId) {
|
|
|
+ data = data.find((item) => item.farmWorkLibId === JSON.parse(route.query.data)?.farmWorkId);
|
|
|
+ workList.value = [data];
|
|
|
+ } else {
|
|
|
+ workList.value = data;
|
|
|
+ }
|
|
|
+ console.log("dtafds,", data);
|
|
|
+ });
|
|
|
+};
|
|
|
+
|
|
|
+const currentComponent = ref("prescriptionBox");
|
|
|
+
|
|
|
+const goBack = () => {
|
|
|
+ router.go(-1);
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss" scoped>
|
|
|
+.base-container {
|
|
|
+ width: 100%;
|
|
|
+ height: 100vh;
|
|
|
+ color: #fff;
|
|
|
+ position: relative;
|
|
|
+ box-sizing: border-box;
|
|
|
+ z-index: 1;
|
|
|
+ background: #000;
|
|
|
+
|
|
|
+ .content {
|
|
|
+ width: 100%;
|
|
|
+ height: calc(100% - 74px - 48px);
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ box-sizing: border-box;
|
|
|
+ .left {
|
|
|
+ width: 473px;
|
|
|
+ height: 100%;
|
|
|
+ padding-top: 10px;
|
|
|
+ box-sizing: border-box;
|
|
|
+ .btn {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ border: 1px solid rgba(255, 255, 255, 0.78);
|
|
|
+ border-radius: 4px;
|
|
|
+ padding: 13px;
|
|
|
+ margin-bottom: 13px;
|
|
|
+ }
|
|
|
+ .left-cont {
|
|
|
+ // border-radius: 8px;
|
|
|
+ // border: 1px solid #555555;
|
|
|
+ // box-sizing: border-box;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .right {
|
|
|
+ width: calc(100% - 473px);
|
|
|
+ height: 100%;
|
|
|
+ .bottom-map {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|