基地地图初步完成

master
贾肃 5 months ago
parent a86b26c5b4
commit 2464fbc9de
  1. 19
      src/assets/icons/svg/local.svg
  2. 9
      src/assets/icons/svg/password.svg
  3. 5
      src/assets/icons/svg/remind.svg
  4. 6
      src/assets/icons/svg/user.svg
  5. BIN
      src/assets/images/login-bg.png
  6. 48
      src/components/Hamburger/index.vue
  7. 39
      src/layout/components/Navbar.vue
  8. 14
      src/router/index.js
  9. 2
      src/settings.js
  10. 78
      src/views/login.vue
  11. 58
      src/views/system/base/baseRightControl.vue
  12. 43
      src/views/system/base/mapMarkers.vue
  13. 70
      src/views/system/base/massifMap.vue

@ -0,0 +1,19 @@
<svg width="37" height="39" viewBox="0 0 37 39" fill="none" xmlns="http://www.w3.org/2000/svg">
<g id="Frame 43">
<g id="Subtract" filter="url(#filter0_d_37_85871)">
<path fill-rule="evenodd" clip-rule="evenodd" d="M18.1644 32.4141C18.1644 32.4141 30.2987 21.2499 30.2987 14.5483C30.2987 7.84675 24.866 2.41406 18.1644 2.41406C11.4629 2.41406 6.03018 7.84675 6.03018 14.5483C6.03018 21.2499 18.1644 32.4141 18.1644 32.4141ZM18.1645 17.4143C20.4787 17.4143 22.3547 15.5382 22.3547 13.224C22.3547 10.9098 20.4787 9.03378 18.1645 9.03378C15.8502 9.03378 13.9742 10.9098 13.9742 13.224C13.9742 15.5382 15.8502 17.4143 18.1645 17.4143Z" fill="white"/>
</g>
</g>
<defs>
<filter id="filter0_d_37_85871" x="3.03018" y="2.41406" width="30.2685" height="36" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset dy="3"/>
<feGaussianBlur stdDeviation="1.5"/>
<feComposite in2="hardAlpha" operator="out"/>
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"/>
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_37_85871"/>
<feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_37_85871" result="shape"/>
</filter>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

@ -1 +1,8 @@
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1575802846045" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2750" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><defs><style type="text/css"></style></defs><path d="M868.593046 403.832442c-30.081109-28.844955-70.037123-44.753273-112.624057-44.753273L265.949606 359.079168c-42.554188 0-82.510202 15.908318-112.469538 44.690852-30.236652 28.782533-46.857191 67.222007-46.857191 108.198258l0 294.079782c0 40.977273 16.619516 79.414701 46.702672 108.136859 29.959336 28.844955 70.069869 44.814672 112.624057 44.814672l490.019383 0c42.585911 0 82.696444-15.969717 112.624057-44.814672 30.082132-28.844955 46.579875-67.222007 46.579875-108.136859L915.172921 511.968278C915.171897 471.053426 898.675178 432.677397 868.593046 403.832442zM841.821309 806.049083c0 22.098297-8.882298 42.772152-25.099654 58.306964-16.154935 15.661701-37.81935 24.203238-60.752666 24.203238L265.949606 888.559285c-22.934339 0-44.567032-8.54256-60.877509-24.264637-16.186657-15.474436-25.067932-36.148291-25.067932-58.246589L180.004165 511.968278c0-22.035876 8.881274-42.772152 25.192775-58.307987 16.186657-15.536858 37.81935-24.139793 60.753689-24.139793l490.019383 0c22.933315 0 44.597731 8.602935 60.752666 24.139793 16.21838 15.535835 25.099654 36.272112 25.099654 58.307987L841.822332 806.049083zM510.974136 135.440715c114.914216 0 208.318536 89.75214 208.318536 200.055338l73.350588 0c0-149.113109-126.366036-270.496667-281.669124-270.496667-155.333788 0-281.699824 121.383558-281.699824 270.496667l73.350588 0C302.623877 225.193879 396.059919 135.440715 510.974136 135.440715zM474.299865 747.244792l73.350588 0L547.650453 629.576859l-73.350588 0L474.299865 747.244792z" p-id="2751"></path></svg> <svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<g id="Frame 1000003219">
<g id="Group 1000003113">
<path id="Vector" d="M25.2267 28.4231H23.8314H24.3841C24.8549 28.3978 25.2267 28.0368 25.2267 27.5936V28.4231ZM25.2165 15.5144V16.8094V16.2965C25.1892 15.8595 24.8003 15.5144 24.3226 15.5144H25.2165ZM5.77734 15.5018H7.17268H6.62C6.1492 15.5271 5.77734 15.888 5.77734 16.3313V15.5018ZM5.78076 28.4041V27.1091V27.6221C5.80805 28.059 6.19697 28.4041 6.67459 28.4041H5.78076ZM8.62259 7.51337C9.39361 7.51337 10.0213 8.09279 10.0213 8.81152V14.2194C10.0213 14.935 9.39702 15.5176 8.62259 15.5176C7.85158 15.5176 7.22385 14.9382 7.22385 14.2194V8.81152C7.22726 8.09595 7.85158 7.51337 8.62259 7.51337ZM12.9723 21.9577C12.9723 21.2421 13.5967 20.6595 14.3711 20.6595H16.6296C17.4006 20.6595 18.0283 21.239 18.0283 21.9577C18.0283 22.6733 17.404 23.2558 16.6296 23.2558H14.3711C13.6001 23.2527 12.9723 22.6733 12.9723 21.9577ZM22.4088 7.38672C23.1798 7.38672 23.8075 7.96614 23.8075 8.68487V9.42577C23.8075 10.1413 23.1832 10.7239 22.4088 10.7239C21.6377 10.7239 21.01 10.1445 21.01 9.42577V8.68487C21.0134 7.9693 21.6377 7.38672 22.4088 7.38672Z" fill="#00A37D"/>
<path id="Vector_2" d="M15.5171 3.59314C18.5534 3.59314 21.0131 5.87599 21.0131 8.69393H23.8072C23.8072 4.44486 20.0954 1 15.5171 1C10.9387 1 7.22694 4.44486 7.22694 8.69393H10.021C10.021 5.87599 12.4808 3.59314 15.5171 3.59314ZM28 29.2934V14.8617C27.884 13.8042 26.9424 12.9715 25.7859 12.9303H5.32328C4.04394 12.9303 3.00341 13.8929 3 15.0802V29.1478C3.13646 30.104 3.94842 30.8639 4.9753 31H26.1782C27.0993 30.8259 27.8226 30.1515 28 29.2934ZM5.79408 28.4037V15.5203H25.2093V28.4037H5.79408Z" fill="#00A37D"/>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

@ -0,0 +1,5 @@
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<g id="Icon / BellOutlined">
<path id="Vector" fill-rule="evenodd" clip-rule="evenodd" d="M19.125 18H18.5625V10.0312C18.5625 6.72422 16.118 3.99141 12.9375 3.53672V2.625C12.9375 2.10703 12.518 1.6875 12 1.6875C11.482 1.6875 11.0625 2.10703 11.0625 2.625V3.53672C7.88203 3.99141 5.4375 6.72422 5.4375 10.0312V18H4.875C4.46016 18 4.125 18.3352 4.125 18.75V19.5C4.125 19.6031 4.20937 19.6875 4.3125 19.6875H9.375C9.375 21.1359 10.5516 22.3125 12 22.3125C13.4484 22.3125 14.625 21.1359 14.625 19.6875H19.6875C19.7906 19.6875 19.875 19.6031 19.875 19.5V18.75C19.875 18.3352 19.5398 18 19.125 18ZM12 20.8125C11.3789 20.8125 10.875 20.3086 10.875 19.6875H13.125C13.125 20.3086 12.6211 20.8125 12 20.8125ZM7.125 10.0312V18H16.875V10.0312C16.875 8.72813 16.3687 7.50469 15.4477 6.58359C14.5266 5.6625 13.3031 5.15625 12 5.15625C10.6969 5.15625 9.47344 5.6625 8.55234 6.58359C7.63125 7.50469 7.125 8.72813 7.125 10.0312Z" fill="white"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

@ -1 +1,5 @@
<svg width="130" height="130" xmlns="http://www.w3.org/2000/svg"><path d="M63.444 64.996c20.633 0 37.359-14.308 37.359-31.953 0-17.649-16.726-31.952-37.359-31.952-20.631 0-37.36 14.303-37.358 31.952 0 17.645 16.727 31.953 37.359 31.953zM80.57 75.65H49.434c-26.652 0-48.26 18.477-48.26 41.27v2.664c0 9.316 21.608 9.325 48.26 9.325H80.57c26.649 0 48.256-.344 48.256-9.325v-2.663c0-22.794-21.605-41.271-48.256-41.271z" stroke="#979797"/></svg> <svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<g id="&#231;&#148;&#168;&#230;&#136;&#183;&#229;&#144;&#141; 1">
<path id="Vector" d="M16 5.33317C15.4747 5.33317 14.9546 5.43663 14.4693 5.63765C13.984 5.83867 13.543 6.13331 13.1716 6.50474C12.8001 6.87618 12.5055 7.31713 12.3045 7.80244C12.1035 8.28774 12 8.80788 12 9.33317C12 9.85846 12.1035 10.3786 12.3045 10.8639C12.5055 11.3492 12.8001 11.7902 13.1716 12.1616C13.543 12.533 13.984 12.8277 14.4693 13.0287C14.9546 13.2297 15.4747 13.3332 16 13.3332C17.0609 13.3332 18.0783 12.9117 18.8284 12.1616C19.5786 11.4115 20 10.394 20 9.33317C20 8.2723 19.5786 7.25489 18.8284 6.50474C18.0783 5.7546 17.0609 5.33317 16 5.33317ZM16 2.6665C16.8756 2.66659 17.7425 2.83913 18.5514 3.17428C19.3603 3.50943 20.0953 4.00061 20.7143 4.61979C21.3334 5.23897 21.8244 5.97402 22.1594 6.78298C22.4944 7.59193 22.6668 8.45894 22.6667 9.3345C22.6666 10.2101 22.494 11.077 22.1589 11.8859C21.8237 12.6948 21.3326 13.4298 20.7134 14.0488C20.0942 14.6679 19.3591 15.1589 18.5502 15.4939C17.7412 15.8289 16.8742 16.0013 15.9987 16.0012C14.2304 16.001 12.5346 15.2984 11.2843 14.0479C10.0341 12.7974 9.33182 11.1015 9.332 9.33317C9.33218 7.56488 10.0348 5.86909 11.2853 4.61885C12.5358 3.36861 14.2317 2.66633 16 2.6665ZM21.3333 18.6665C22.2088 18.6665 23.0757 18.8389 23.8846 19.174C24.6934 19.509 25.4283 20.0001 26.0474 20.6191C26.6664 21.2382 27.1575 21.9731 27.4925 22.7819C27.8276 23.5908 28 24.4577 28 25.3332V27.9998C27.9999 28.3534 27.8594 28.6925 27.6094 28.9425C27.3594 29.1925 27.0203 29.333 26.6667 29.333C26.3131 29.333 25.974 29.1925 25.7239 28.9425C25.4739 28.6925 25.3334 28.3534 25.3333 27.9998V25.3332C25.3333 24.2723 24.9119 23.2549 24.1618 22.5047C23.4116 21.7546 22.3942 21.3332 21.3333 21.3332H10.6667C9.6058 21.3332 8.58839 21.7546 7.83824 22.5047C7.08809 23.2549 6.66667 24.2723 6.66667 25.3332V27.9998C6.66661 28.3534 6.52611 28.6925 6.27607 28.9425C6.02603 29.1925 5.68692 29.333 5.33333 29.333C4.97975 29.333 4.64064 29.1925 4.3906 28.9425C4.14055 28.6925 4.00005 28.3534 4 27.9998V25.3332C4 24.4577 4.17244 23.5908 4.50747 22.7819C4.8425 21.9731 5.33356 21.2382 5.95262 20.6191C6.57168 20.0001 7.30661 19.509 8.11544 19.174C8.92428 18.8389 9.79119 18.6665 10.6667 18.6665H21.3333Z" fill="#00A37D"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 440 B

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

@ -1,21 +1,21 @@
<template> <template>
<div style="padding: 0 15px;"> <div style="padding: 0 15px;background: #16745e" @contextmenu.prevent.stop="toggleClick" @click="showDrawer = !showDrawer" >
<i-menu-unfold-one @contextmenu.prevent.stop="toggleClick" @click="showDrawer = !showDrawer" class="hamburger" <i-menu-unfold-one class="hamburger"
:class="{'is-active':isActive}" theme="outline" size="22" :fill="fill"/> :class="{'is-active':isActive}" theme="outline" size="22" :fill="fill"/>
<div> <div>
<left-drawer v-model="showDrawer"> <left-drawer v-model="showDrawer" :width="drawerWidth">
<div> <div>
<div class="classify" style="margin-top: 0;"> <div class="classify" style="margin: 0 0 10px 0;">
<i-system theme="outline" size="24" fill="#333"/> <i-chart-line theme="outline" size="24" fill="#338572"/>
<el-link style="color: #000000 !important;font-size: 16px" @click="openRouter('/index')"></el-link> <el-link style="color: #000000 !important;font-size: 16px" @click="openRouter('/index')"></el-link>
</div> </div>
<div v-if="true" v-for="item in menuList" :key="item.label"> <div v-if="true" v-for="item in menuList" :key="item.label" class="menu-type">
<div class="classify"> <div class="classify">
<i-system theme="outline" size="24" fill="#333"/> <icon-park v-if="item.icon" :type="item.icon" size="24" fill="#338572"/>
{{ item.label }} {{ item.label }}
</div> </div>
<div class="children"> <div class="children">
<el-row v-if="item.children" :gutter="20"> <el-row v-if="item.children" :gutter="10">
<el-col v-for="child in item.children" :key="child.label" :span="8"> <el-col v-for="child in item.children" :key="child.label" :span="8">
<div class="children-item"> <div class="children-item">
<el-link @click="openRouter(child.href)">{{ child.label }}</el-link> <el-link @click="openRouter(child.href)">{{ child.label }}</el-link>
@ -27,11 +27,11 @@
<div v-else v-for="item in sidebarRouters" :key="item.path"> <div v-else v-for="item in sidebarRouters" :key="item.path">
<div v-if="!item.hidden && item.redirect !== '/index'"> <div v-if="!item.hidden && item.redirect !== '/index'">
<div class="classify"> <div class="classify">
<i-system theme="outline" size="24" fill="#333"/> <icon-park :type="item.icon" size="24" fill="#333"/>
{{ item.meta?.title }} {{ item.meta?.title }}
</div> </div>
<div class="children"> <div class="children">
<el-row v-if="item.children" :gutter="20"> <el-row v-if="item.children" :gutter="10">
<el-col v-for="child in item.children" :key="child.path" :span="8"> <el-col v-for="child in item.children" :key="child.path" :span="8">
<div class="children-item"> <div class="children-item">
<el-link @click="openRouter(`${item.path}/${child.path}`)">{{ child.meta?.title }}</el-link> <el-link @click="openRouter(`${item.path}/${child.path}`)">{{ child.meta?.title }}</el-link>
@ -51,6 +51,8 @@
import usePermissionStore from "@/store/modules/permission.js"; import usePermissionStore from "@/store/modules/permission.js";
import {isExternal} from "@/utils/validate.js"; import {isExternal} from "@/utils/validate.js";
import LeftDrawer from "@/components/LeftDrawer/index.vue"; import LeftDrawer from "@/components/LeftDrawer/index.vue";
import {IconPark} from '@icon-park/vue-next/es/all';
import useAppStore from "@/store/modules/app.js";
defineProps({ defineProps({
isActive: { isActive: {
@ -65,18 +67,19 @@ defineProps({
const emit = defineEmits(['toggleClick']) const emit = defineEmits(['toggleClick'])
const showDrawer = ref(false) const showDrawer = ref(false)
const permissionStore = usePermissionStore() const permissionStore = usePermissionStore()
const appStore = useAppStore()
const drawerWidth= computed(()=>appStore.device === 'mobile'?'100%':'30%')
const sidebarRouters = computed(() => permissionStore.sidebarRouters); const sidebarRouters = computed(() => permissionStore.sidebarRouters);
const menuList = ref([ const menuList = ref([
{ {
label: '基础数据管理', children: [ label: '基础数据管理',icon:'data', children: [
{label: '育种基地管理'}, {label: '育种基地管理'},
{label: '数据采集设备管理'}, {label: '数据采集设备管理'},
{label: '作物品种管理'}, {label: '作物品种管理'},
] ]
}, },
{ {
label: '环境数据', children: [ label: '环境数据',icon:'pure-natural', children: [
{label: '基地地图',href:'/system/base/mapMarkers'}, {label: '基地地图',href:'/system/base/mapMarkers'},
{label: '地块管理',href:'/system/base/baseTable'}, {label: '地块管理',href:'/system/base/baseTable'},
{label: '土壤数据'}, {label: '土壤数据'},
@ -85,14 +88,14 @@ const menuList = ref([
] ]
}, },
{ {
label: '表型数据', children: [ label: '表型数据',icon:'chart-pie', children: [
{label: '原始数据管理'}, {label: '原始数据管理'},
{label: '表型数据管理'}, {label: '表型数据管理'},
{label: '植株表型数据'}, {label: '植株表型数据'},
] ]
}, },
{ {
label: '基因型数据', children: [ label: '基因型数据',icon:'chart-pie', children: [
{label: '基因型数据管理'}, {label: '基因型数据管理'},
] ]
}, },
@ -132,13 +135,24 @@ const toggleClick = () => {
.classify { .classify {
display: flex; display: flex;
align-items: center; align-items: center;
margin-top: 20px; font-weight: 500;
font-size: 16px;
color: #333333;
line-height: 19px;
font-style: normal;
text-transform: none;
.i-icon { .i-icon {
margin-right: 5px; margin-right: 5px;
} }
} }
.children{
margin-left: 28px;
}
.children-item { .children-item {
margin-top: 10px; margin-top: 10px;
} }
.menu-type{
padding: 10px 0;
border-bottom: 1px solid #EEF8F5;
}
</style> </style>

@ -1,7 +1,7 @@
<template> <template>
<div class="navbar"> <div class="navbar">
<hamburger :fill="iconColor" id="hamburger-container" :is-active="appStore.sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" /> <hamburger :fill="iconColor" id="hamburger-container" :is-active="appStore.sidebar.opened" class="hamburger-container" @toggleClick="toggleSideBar" />
<div style="float: left;line-height: 50px;">{{title}}</div> <div class="system-title">{{title}}</div>
<breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!settingsStore.topNav && false" /> <breadcrumb id="breadcrumb-container" class="breadcrumb-container" v-if="!settingsStore.topNav && false" />
<top-nav id="topmenu-container" class="topmenu-container" v-if="settingsStore.topNav" /> <top-nav id="topmenu-container" class="topmenu-container" v-if="settingsStore.topNav" />
@ -12,7 +12,7 @@
<i-tv class="right-menu-item" theme="outline" size="24" :fill="iconColor"/> <i-tv class="right-menu-item" theme="outline" size="24" :fill="iconColor"/>
</el-tooltip> </el-tooltip>
<div class="right-menu-item"> <div class="right-menu-item">
<i-remind theme="outline" size="22" :fill="iconColor"/> <svg-icon class-name="remind" style="height: 22px;width: 22px;" icon-class="remind"/>
</div> </div>
<el-tooltip v-if="false" content="源码地址" effect="dark" placement="bottom"> <el-tooltip v-if="false" content="源码地址" effect="dark" placement="bottom">
<ruo-yi-git id="ruoyi-git" class="right-menu-item hover-effect" /> <ruo-yi-git id="ruoyi-git" class="right-menu-item hover-effect" />
@ -50,7 +50,9 @@
</template> </template>
</el-dropdown> </el-dropdown>
<div class="right-menu-item" v-else> <div class="right-menu-item" v-else>
<i-me theme="outline" size="24" :fill="iconColor"/> <div class="avatar-wrapper">
<img :src="userStore.avatar" class="user-avatar" />
</div>
<div style="margin-left: 3px">{{userStore.name}}</div> <div style="margin-left: 3px">{{userStore.name}}</div>
<div @click="logout" class="logout-button"> <div @click="logout" class="logout-button">
退出 退出
@ -82,7 +84,9 @@ const userStore = useUserStore()
const settingsStore = useSettingsStore() const settingsStore = useSettingsStore()
const title = defaultSettings.title const title = defaultSettings.title
const theme = computed(() => settingsStore.theme); const theme = computed(() => settingsStore.theme);
const iconColor = computed(() => findTextColor(theme.value)) //
// const iconColor = computed(() => findTextColor(theme.value))
const iconColor = ref('#FFFFFF')
function toggleSideBar() { function toggleSideBar() {
appStore.toggleSideBar() appStore.toggleSideBar()
} }
@ -184,16 +188,27 @@ function setLayout() {
.avatar-container { .avatar-container {
margin-right: 10px; margin-right: 10px;
position: relative;
margin-left: 20px;
&:after {
content: "";
height: 25px;
background: #FFFFFF;
box-sizing: border-box;
position: absolute;
left: -10px;
top: 12px;
width: 1px;
}
.avatar-wrapper { .avatar-wrapper {
margin-top: 5px; margin-top: 5px;
position: relative; position: relative;
.user-avatar { .user-avatar {
cursor: pointer; cursor: pointer;
width: 40px; width: 25px;
height: 40px; height: 25px;
border-radius: 10px; border-radius: 50%;
} }
i { i {
@ -208,13 +223,17 @@ function setLayout() {
} }
.logout-button{ .logout-button{
margin-left: 10px; margin-left: 10px;
border: 1px solid #FFFFFF; background: #16745e;
//border: 1px solid #FFFFFF;
border-radius: 5px; border-radius: 5px;
font-size: 14px; font-size: 14px;
line-height: 20px; line-height: 20px;
padding: 2px 10px; padding: 5px 10px;
// //
cursor: pointer; cursor: pointer;
} }
.system-title{
float: left;line-height: 50px;margin-left: 20px
}
} }
</style> </style>

@ -83,8 +83,22 @@ export const constantRoutes = [
meta: { title: '个人中心', icon: 'user' } meta: { title: '个人中心', icon: 'user' }
} }
] ]
},
{
path: '/system/base',
component: Layout,
hidden: true,
redirect: 'noredirect',
children: [
{
path: 'massifMap/:baseId(\\d+)',
component: () => import('@/views/system/base/massifMap'),
name: 'massifMap',
meta: { title: '基地地块' }
} }
] ]
},
]
// 动态路由,基于用户权限动态去加载 // 动态路由,基于用户权限动态去加载
export const dynamicRoutes = [ export const dynamicRoutes = [

@ -14,7 +14,7 @@ export default {
/** /**
* 初始主题色 * 初始主题色
*/ */
theme: '#567722', theme: '#09a882',
/** /**
* 是否显示顶部导航 * 是否显示顶部导航
*/ */

@ -1,8 +1,14 @@
<template> <template>
<div class="login" :class="loginClass"> <div class="login">
<el-form ref="loginRef" :model="loginForm" :rules="loginRules" class="login-form"> <el-form ref="loginRef" :model="loginForm" :rules="loginRules" class="login-form">
<h3 class="title">甘蔗育种大数据平台</h3> <div class="title-top">
<el-divider content-position="center">欢迎登录</el-divider> <div class="title">甘蔗育种大数据平台</div>
<div class="title-divider">
<div class="title-divider-left"></div>
<div class="title-divider-text">欢迎登录</div>
<div class="title-divider-right"></div>
</div>
</div>
<el-form-item prop="username"> <el-form-item prop="username">
<el-input <el-input
v-model="loginForm.username" v-model="loginForm.username"
@ -48,8 +54,10 @@
<img :src="codeUrl" @click="getCode" class="login-code-img"/> <img :src="codeUrl" @click="getCode" class="login-code-img"/>
</div> </div>
</el-form-item> </el-form-item>
<el-checkbox v-model="loginForm.rememberMe" style="margin:0px 0px 25px 0px;"></el-checkbox> <el-form-item>
<el-form-item style="width:60%;margin: 20px auto"> <el-checkbox v-model="loginForm.rememberMe" class="remember"></el-checkbox>
</el-form-item>
<el-form-item>
<el-button <el-button
round round
:loading="loading" :loading="loading"
@ -186,29 +194,66 @@ getCookie();
// //
background-position: center; background-position: center;
// //
background-image: url("../assets/images/v2_rxo8qp.png") ; background-image: url("../assets/images/login-bg.png");
background-size: cover; background-size: cover;
} }
//pc //pc
.desktop { .desktop {
justify-content: flex-end; justify-content: flex-end;
.el-form { .el-form {
position: absolute; position: absolute;
right: 10%; right: 10%;
} }
} }
.title-top {
margin-bottom: 80px;
}
.title-divider {
&-left{
width: 130px;
height: 0px;
border: 1px solid;
border-image: linear-gradient(90deg, rgba(0, 0, 0, 0.01), rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.35)) 1 1;
}
&-right{
width: 130px;
height: 0px;
border: 1px solid;
border-image: linear-gradient(270deg, rgba(0, 0, 0, 0.01), rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.35)) 1 1;
}
&-text{
margin: 0 20px;
font-weight: 600;
font-size: 18px;
background-image: linear-gradient(to right, #9d9696, #615959);
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
display: flex;
align-items: center;
justify-content: space-between;
}
.title { .title {
font-size: 32px;
font-weight: 700; font-weight: 700;
margin: 20px auto 50px auto; margin: 20px auto 10px auto;
text-align: center; text-align: center;
color: #707070; background-image: linear-gradient(to left, #547B14, #2A8362);
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
} }
.login-form { .login-form {
border-radius: 6px; border-radius: 6px;
background: #ffffff; //background: #ffffff;
width: 400px; width: 450px;
padding: 25px 25px 5px 25px; padding: 25px 25px 5px 25px;
.el-input { .el-input {
@ -221,9 +266,18 @@ getCookie();
.input-icon { .input-icon {
height: 39px; height: 39px;
width: 14px; width: 20px;
margin-left: 0px; margin-left: 0px;
} }
.remember{
flex: 1;
justify-content: flex-end;
}
:deep(.el-input__wrapper){
height: 50px;
border-radius: 25px;
padding: 1px 20px;
}
} }
.login-tip { .login-tip {
@ -251,7 +305,7 @@ getCookie();
font-weight: 600; font-weight: 600;
width: 100%; width: 100%;
text-align: center; text-align: center;
color: #fff; color: #09a882;
font-family: Arial; font-family: Arial;
font-size: 18px; font-size: 18px;
letter-spacing: 1px; letter-spacing: 1px;

@ -10,7 +10,7 @@ const router = useRouter()
const toBaseTable = () => { const toBaseTable = () => {
router.push('/system/base/baseTable') router.push('/system/base/baseTable')
} }
const control = ref({ const control = reactive({
// //
dataType:1, dataType:1,
// //
@ -58,7 +58,7 @@ const control = ref({
</template> </template>
</el-dropdown> </el-dropdown>
<el-dropdown class="operate" trigger="click" :hide-on-click="false"> <el-dropdown class="operate" trigger="click" :hide-on-click="false">
<div class="map-type map-option"> <div class="map-type">
<i-filter theme="outline" size="22" fill="#333"/> <i-filter theme="outline" size="22" fill="#333"/>
地图选项 地图选项
<el-icon class="el-icon--right"> <el-icon class="el-icon--right">
@ -66,30 +66,29 @@ const control = ref({
</el-icon> </el-icon>
</div> </div>
<template #dropdown> <template #dropdown>
<div> <div class="map-option">
地图类型 地图类型
<el-dropdown-item> <el-dropdown-item disabled>
卫星地图 卫星地图 <el-checkbox :model-value="control.dataType === 1"></el-checkbox>
</el-dropdown-item> </el-dropdown-item>
地块 地块
<el-dropdown-item @click="control.massifLabel = !control.massifLabel">
<el-dropdown-item> 显示地块标签 <el-checkbox :model-value="control.massifLabel"></el-checkbox>
显示地块标签
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item> <el-dropdown-item @click="control.massifGrid = !control.massifGrid">
显示网格地块 显示网格地块 <el-checkbox :model-value="control.massifGrid"></el-checkbox>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item> <el-dropdown-item @click="control.showRidge = !control.showRidge">
显示垄 显示垄 <el-checkbox :model-value="control.showRidge"></el-checkbox>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item> <el-dropdown-item @click="control.ridgeLabel = !control.ridgeLabel">
显示垄标签 显示垄标签 <el-checkbox :model-value="control.ridgeLabel"></el-checkbox>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item> <el-dropdown-item @click="control.showPlant = !control.showPlant">
显示植株 显示植株 <el-checkbox :model-value="control.showPlant"></el-checkbox>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item> <el-dropdown-item @click="control.plantLabel = !control.plantLabel">
显示植株标签 显示植株标签 <el-checkbox :model-value="control.plantLabel"></el-checkbox>
</el-dropdown-item> </el-dropdown-item>
</div> </div>
</template> </template>
@ -104,18 +103,26 @@ const control = ref({
color: var(--el-text-color-regular); color: var(--el-text-color-regular);
// //
cursor: pointer; cursor: pointer;
width: 115px; width: 125px;
background: #FFFFFF; background: #FFFFFF;
padding: 5px; padding: 5px 10px;
display: flex; display: flex;
align-items: center; align-items: center;
border-radius: 5px; //
opacity:0.8;
border-radius: 20px;
.i-icon { .i-icon {
margin-right: 5px; margin-right: 5px;
} }
} }
.map-option{
border-radius: 10px;
padding: 10px;
}
.map-option :deep(.el-dropdown-menu__item){
justify-content: space-between;
width: 150px;
}
.right-control { .right-control {
position: absolute; position: absolute;
right: 20px; right: 20px;
@ -143,4 +150,9 @@ const control = ref({
background: var(--el-dropdown-menuItem-hover-color); background: var(--el-dropdown-menuItem-hover-color);
} }
} }
:deep(.el-select__wrapper){
border-radius: 20px;
//
opacity:0.8;
}
</style> </style>

@ -2,20 +2,28 @@
<script setup> <script setup>
import {ElAmap, useGeolocation ,lazyAMapApiLoaderInstance} from "@vuemap/vue-amap"; import {ElAmap, useGeolocation ,lazyAMapApiLoaderInstance} from "@vuemap/vue-amap";
import BaseRightControl from "@/views/system/base/baseRightControl.vue"; import BaseRightControl from "@/views/system/base/baseRightControl.vue";
const router = useRouter()
const maxHeight = ref(window.innerHeight - 100); const maxHeight = ref(window.innerHeight - 100);
const zoom = ref(13); const zoom = ref(13);
const center = ref([ const center = ref([
116.338461, 116.338461,
39.97947 39.97947
]); ]);
const markerPosition = ref([ const baseList = ref([
116.338461, {
39.97947 baseId:1,
position:[116.338461, 39.97947],
label:'测试',
}
]) ])
// 1 2
const showType = ref(1)
// //
const clickBase = ref(null) const clickBase = ref(null)
const clickMarker = (value) => {
clickBase.value = value
router.push({path:'/system/base/massifMap/'+value.baseId})
console.log(value);
}
onBeforeMount(() => { onBeforeMount(() => {
// //
// lazyAMapApiLoaderInstance.then(() => { // lazyAMapApiLoaderInstance.then(() => {
@ -55,12 +63,18 @@ const selectPoi = ({poi}) => {
<el-amap-control-tool-bar :visible="true" /> <el-amap-control-tool-bar :visible="true" />
<!--比例尺--> <!--比例尺-->
<el-amap-control-scale :visible="true" /> <el-amap-control-scale :visible="true" />
<!-- 点标记--> <!--灵活点标记-->
<el-amap-marker <el-amap-marker
:position="markerPosition" v-for="item in baseList"
title="当前位置" :position="item.position"
label="当前位置" :title="item.label"
/> :label="{content:item.label,offset:[5,0]}"
:visible="true"
:draggable="false"
@click="clickMarker(item)"
>
<svg-icon class-name="local-icon" icon-class="local"/>
</el-amap-marker>
<!--搜索控件--> <!--搜索控件-->
<el-amap-search-box <el-amap-search-box
:visible="false" :visible="false"
@ -86,4 +100,13 @@ const selectPoi = ({poi}) => {
pointer-events: all; pointer-events: all;
} }
} }
.local-icon{
width: 30px;
height: 30px;
}
:deep(.amap-marker-label){
border: none;
border-radius: 5px;
padding: 5px 10px;
}
</style> </style>

@ -0,0 +1,70 @@
<!--基地点坐标-->
<script setup>
import {ElAmap, useGeolocation ,lazyAMapApiLoaderInstance} from "@vuemap/vue-amap";
import BaseRightControl from "@/views/system/base/baseRightControl.vue";
const router = useRouter()
const route = useRoute();
const maxHeight = ref(window.innerHeight - 100);
const zoom = ref(13);
onMounted(()=>{
console.log(route.params);
})
const center = ref([
116.338461,
39.97947
]);
//
const selectPoi = ({poi}) => {
center.value = poi.location.toArray()
}
</script>
<template>
<div class="app-container" :style="{height:maxHeight+'px'}">
<el-amap
:center="center"
:zoom="zoom"
>
<!--卫星云图-->
<el-amap-layer-satellite :visible="true" />
<!--定位控件-->
<el-amap-control-geolocation :visible="false"/>
<!--地图缩放控件-->
<el-amap-control-tool-bar :visible="true" />
<!--比例尺-->
<el-amap-control-scale :visible="true" />
<!--搜索控件-->
<el-amap-search-box
:visible="false"
:debounce="1000"
@select="selectPoi"
/>
<div class="top-block">
<base-right-control />
</div>
</el-amap>
</div>
</template>
<style scoped lang="scss">
.top-block{
position: absolute;
top: 0;
width: 100%;
height: 100%;
pointer-events:none;//none穿西
.operate{
//
pointer-events: all;
}
}
.local-icon{
width: 30px;
height: 30px;
}
:deep(.amap-marker-label){
border: none;
border-radius: 5px;
padding: 5px 10px;
}
</style>
Loading…
Cancel
Save