Merge branch 'main' of http://175.6.124.250:3100/luozhun/policeSecurity
This commit is contained in:
commit
875b026a3e
|
@ -1,6 +1,6 @@
|
|||
.nameTitle {
|
||||
position: absolute;
|
||||
top: 277rpx;
|
||||
top: 19%;
|
||||
left: 55px;
|
||||
height: 125rpx;
|
||||
background-color: #fff;
|
||||
|
|
|
@ -1,57 +1,94 @@
|
|||
<template>
|
||||
<view>
|
||||
<view class="swiperDemo">
|
||||
<nut-swiper ref="swiperRef" pagination-visible pagination-color="#e53e31" :auto-play="3000" :init-page="0">
|
||||
<nut-swiper-item v-for="(item, index) in list" :key="index" style="height: 200px">
|
||||
<image :src="item" alt="" style="height: 100%; width: 100%" draggable="false"/>
|
||||
</nut-swiper-item>
|
||||
</nut-swiper>
|
||||
<view class="search" id="search">
|
||||
<nut-input v-model="valueInput" @input="searchInput" placeholder="请进行搜索"></nut-input>
|
||||
<view v-if="valueInput">
|
||||
<ul>
|
||||
<li v-for="item in searchResults" :key="item.id">{{item}}</li>
|
||||
</ul>
|
||||
</view>
|
||||
<view class="swiperDemoItem">
|
||||
<view class="swiperDemoIndex"></view>
|
||||
<view>请选择</view>
|
||||
</view>
|
||||
<!--九宫格-->
|
||||
<view>
|
||||
<view class="subModule">
|
||||
<view class="subModuleItem" v-for="item in subModuleList" :key="item.id" @click="subNavigation(item.url)">
|
||||
<view class="subModuleIndex">
|
||||
<image :src="item.icon"></image>
|
||||
</view>
|
||||
<view style=" font-size: 12px;color: #414141;margin-top: 9px">{{ item.name }}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view v-else >
|
||||
没有找到相关结果
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import {ref} from 'vue'
|
||||
import Taro from "@tarojs/taro";
|
||||
import icon from '@/assets/images/project.png'
|
||||
import './index.scss'
|
||||
const list = ref([process.env.TARO_APP_MINIO_URL + '/police-security/2024/11/5/dunpai.jpg',process.env.TARO_APP_MINIO_URL + '/police-security/2024/11/5/xingqiu.jpg'])
|
||||
const swiperRef = ref() //轮播图
|
||||
const subModuleList = ref([
|
||||
import { ref} from "vue";
|
||||
const valueInput = ref('')
|
||||
// '齐家园','刘德华','张学友','黎明','家具城','左岸春天','麦德龙商城','世纪酒店','四方小学','海洋半岛'
|
||||
const list = ref([])
|
||||
const dataList = ref([
|
||||
{
|
||||
id: 0,
|
||||
icon: icon,
|
||||
name: '企事业单位',
|
||||
url: '/subPages/police/myEnterprisesUnit/myEnterprisesUnit'
|
||||
id:0,
|
||||
value:'齐家园'
|
||||
},
|
||||
{
|
||||
id: 1,
|
||||
icon: icon,
|
||||
name: '警保风采',
|
||||
url: ''
|
||||
id:1,
|
||||
value:'刘德华'
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
icon: icon,
|
||||
name: '待定',
|
||||
url: ''
|
||||
id:2,
|
||||
value:'张学友'
|
||||
},{
|
||||
id:3,
|
||||
value:'黎明'
|
||||
},
|
||||
{
|
||||
id:4,
|
||||
value:'家具城'
|
||||
},
|
||||
{
|
||||
id:5,
|
||||
value:'左岸春天'
|
||||
},
|
||||
{
|
||||
id:6,
|
||||
value:'麦德龙商城'
|
||||
},
|
||||
{
|
||||
id:7,
|
||||
value:'世纪酒店'
|
||||
},
|
||||
{
|
||||
id:8,
|
||||
value:'四方小学'
|
||||
},
|
||||
{
|
||||
id:9,
|
||||
value:'海洋半岛'
|
||||
},
|
||||
{
|
||||
id:10,
|
||||
value:'育英小学'
|
||||
},
|
||||
{
|
||||
id:11,
|
||||
value:'明德小学'
|
||||
},{
|
||||
id:12,
|
||||
value:'希望小学'
|
||||
}
|
||||
])
|
||||
|
||||
const subNavigation = async (url: string) => Taro.navigateTo({url})
|
||||
|
||||
const searchResults = ref([])
|
||||
const searchInput = (e:any)=>{
|
||||
valueInput.value = e.target.value
|
||||
if (!valueInput.value) {
|
||||
searchResults.value = []
|
||||
return [];
|
||||
}else{
|
||||
dataList.value.map((item)=>{
|
||||
return list.value.push(item.value)
|
||||
})
|
||||
searchResults.value = list.value.filter(item =>
|
||||
item.toLowerCase().includes(valueInput.value.toLowerCase())
|
||||
);
|
||||
}
|
||||
// console.log(searchResults.value)
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
</style>
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
</view>
|
||||
<!-- 用户信息 -->
|
||||
<view class="userIndex">
|
||||
<view class="exit" v-for="item in datalist" :key="item.value">
|
||||
<view class="exit" v-for="item in datalist" :key="item.value" @click="addExit(item.value)">
|
||||
<view class="exitItem">
|
||||
<!-- <view class="exitItemIndex">-->
|
||||
<!-- <image :src="item.url" mode="scaleToFill" class="image" />-->
|
||||
|
@ -28,20 +28,30 @@
|
|||
</view>
|
||||
</view>
|
||||
<!-- 退出弹框-->
|
||||
<nut-dialog
|
||||
content="是否退出登录?"
|
||||
v-model:visible="visible" @cancel="visible = false" @ok="onOk"
|
||||
/>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import './index.scss'
|
||||
import {ref} from "vue";
|
||||
import {useUserStore} from "@/store/userStore";
|
||||
import {useTabBarStore} from "@/store/tabBarStore"
|
||||
import Taro from "@tarojs/taro";
|
||||
|
||||
const {setSelected} = useTabBarStore()
|
||||
const {resetUserInfo} = useUserStore()
|
||||
const visible = ref<boolean>(false)
|
||||
const datalist = ref([
|
||||
{
|
||||
value: 1,
|
||||
value: 0,
|
||||
name: '简介',
|
||||
},
|
||||
{
|
||||
value: 0,
|
||||
value: 1,
|
||||
name: '退出登录',
|
||||
},
|
||||
{
|
||||
|
@ -53,4 +63,18 @@ const datalist = ref([
|
|||
name: '意见收集',
|
||||
},
|
||||
])
|
||||
const addExit = (index:number)=>{
|
||||
switch (index) {
|
||||
case 1:
|
||||
visible.value = true
|
||||
break;
|
||||
}
|
||||
}
|
||||
const onOk = ()=>{
|
||||
resetUserInfo()
|
||||
setSelected(0)
|
||||
Taro.navigateTo({
|
||||
url: "/pages/login/login",
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
.nameTitle {
|
||||
position: absolute;
|
||||
top: 277rpx;
|
||||
top: 19%;
|
||||
left: 55px;
|
||||
height: 125rpx;
|
||||
background-color: #fff;
|
||||
|
@ -26,6 +26,9 @@
|
|||
margin-left: -8px;
|
||||
}
|
||||
}
|
||||
.nameTitle .itemSchool:nth-child(4) {
|
||||
border-right: none;
|
||||
}
|
||||
.swiperDemoItem {
|
||||
color: #3886d0;
|
||||
display: flex;
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
</view>
|
||||
<!-- 用户信息 -->
|
||||
<view class="userIndex">
|
||||
<view class="exit" v-for="item in datalist" :key="item.value">
|
||||
<view class="exit" v-for="item in datalist" :key="item.value" @click="addExit(item.value)">
|
||||
<view class="exitItem">
|
||||
<!-- <view class="exitItemIndex">-->
|
||||
<!-- <image :src="item.url" mode="scaleToFill" class="image" />-->
|
||||
|
@ -27,20 +27,30 @@
|
|||
</view>
|
||||
</view>
|
||||
<!-- 退出弹框-->
|
||||
<nut-dialog
|
||||
content="是否退出登录?"
|
||||
v-model:visible="visible" @cancel="visible = false" @ok="onOk"
|
||||
/>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import './index.scss'
|
||||
import {ref} from "vue";
|
||||
import {useUserStore} from "@/store/userStore";
|
||||
import {useTabBarStore} from "@/store/tabBarStore"
|
||||
import Taro from "@tarojs/taro";
|
||||
|
||||
const {setSelected} = useTabBarStore()
|
||||
const {resetUserInfo} = useUserStore()
|
||||
const visible = ref<boolean>(false)
|
||||
const datalist = ref([
|
||||
{
|
||||
value: 1,
|
||||
value: 0,
|
||||
name: '小程序简介',
|
||||
},
|
||||
{
|
||||
value: 0,
|
||||
value: 1,
|
||||
name: '退出登录',
|
||||
},
|
||||
{
|
||||
|
@ -52,4 +62,20 @@ const datalist = ref([
|
|||
name: '意见收集',
|
||||
},
|
||||
])
|
||||
|
||||
const addExit = (index:number)=>{
|
||||
switch (index) {
|
||||
case 1:
|
||||
visible.value = true
|
||||
break;
|
||||
}
|
||||
}
|
||||
const onOk = ()=>{
|
||||
resetUserInfo()
|
||||
setSelected(0)
|
||||
Taro.navigateTo({
|
||||
url: "/pages/login/login",
|
||||
});
|
||||
}
|
||||
|
||||
</script>
|
||||
|
|
|
@ -25,11 +25,11 @@
|
|||
<view class="exit" v-for="item in starRating" :key="item.snowFlakeId" @click="Onrating(item.name, item.snowFlakeId)">
|
||||
<view class="exitItem">
|
||||
<text style="margin-left: 30rpx; font-size: 16px">
|
||||
<text>{{ item.name }}({{ item.totalScore }}分) </text>
|
||||
<text>{{ item.name }}({{ item?.totalScore }}分) </text>
|
||||
</text>
|
||||
</view>
|
||||
<view style="margin-right: 30rpx; display: flex; align-items: center">
|
||||
<view v-if="item.currentScore > 0" style="color: #ff0000"> -{{ item.currentScore }}</view>
|
||||
<view v-if="item.currentScore > 0" style="color: #ff0000"> -{{ item?.currentScore }}</view>
|
||||
<IconFont name="arrow-right"></IconFont>
|
||||
</view>
|
||||
</view>
|
||||
|
|
|
@ -17,16 +17,13 @@ page {
|
|||
}
|
||||
|
||||
.project {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
flex-flow: wrap;
|
||||
text-align: center;
|
||||
//display: flex;
|
||||
//justify-content: space-between;
|
||||
//flex-flow: wrap;
|
||||
//text-align: center;
|
||||
|
||||
view {
|
||||
width: 45%;
|
||||
height: 100rpx;
|
||||
border: 1px solid #cccccc;
|
||||
line-height: 100rpx;
|
||||
width: 100%;
|
||||
margin: 8px 0 8px 0;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<view v-if="number !== 0" class="myProjectItem" v-for="(item, index) in myProjectList" :key="index">
|
||||
<view style="display: flex; justify-content: space-between">
|
||||
<text>{{ item?.name }}</text>
|
||||
<!--<text>进行中</text>-->
|
||||
<text>单位类型:{{ item?.type.label }}</text>
|
||||
</view>
|
||||
<view class="myProjectIndex"
|
||||
>地址:
|
||||
|
@ -15,7 +15,16 @@
|
|||
</view>
|
||||
<view class="project">
|
||||
<view @click="projectClick(item?.name, serviceProject)" v-for="(serviceProject, index) in item.serviceProjectList" :key="index">
|
||||
{{ serviceProject.name }}
|
||||
<view style="border: 1px solid #cccccc;color: #9b9b9f">
|
||||
<view style="display: flex; justify-content: space-between">
|
||||
<text>项目名称:{{serviceProject.name}}</text>
|
||||
<text>项目类型:{{serviceProject.type.label}}</text>
|
||||
</view>
|
||||
<view style="display: flex; justify-content: space-between">
|
||||
<text>项目负责人:{{serviceProject.projectManagerMiniProgramUserInfo?.name?serviceProject.projectManagerMiniProgramUserInfo?.name:'无分配项目经理'}}</text>
|
||||
</view>
|
||||
<view>责任单位:{{serviceProject.securityUnitName}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
|
|
@ -61,7 +61,7 @@
|
|||
<text>职位:{{ item.workPost ? item.workPost : '创建者' }}</text>
|
||||
</view>
|
||||
<view style="display: flex;justify-content: space-between">
|
||||
<text>保安证件:{{ item.securityNumber ? item.securityNumber : '125241256451' }}</text>
|
||||
<text>保安证件:{{ item.securityNumber ? item.securityNumber : '无' }}</text>
|
||||
<text>出生年月:{{ dayjs(item.dateOfBirth).format('YYYY-MM-DD') }}</text>
|
||||
</view>
|
||||
<view style="display: flex;justify-content: space-between">
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
:key="i"
|
||||
style="margin-bottom: 20rpx"
|
||||
shape="button"
|
||||
>{{ items.name }}</nut-checkbox
|
||||
>{{ items.name}}</nut-checkbox
|
||||
>
|
||||
</nut-checkbox-group>
|
||||
</view>
|
||||
|
|
|
@ -15,6 +15,7 @@ export interface MyProjectList {
|
|||
securityUnitId: string;
|
||||
street?: string;
|
||||
streetName?: string;
|
||||
type?:any
|
||||
}
|
||||
|
||||
export interface ContactPersonInfo {
|
||||
|
@ -30,17 +31,18 @@ export interface ServiceProjectList {
|
|||
name?: string;
|
||||
remark?: string;
|
||||
securityUserTotal?: number;
|
||||
securityUnitName?:string;
|
||||
serviceArea?: number;
|
||||
snowFlakeId?: string;
|
||||
staffTotal?: number;
|
||||
type?: string;
|
||||
type?: any;
|
||||
projectManagerMiniProgramUserInfo?: ProgramUserInfo
|
||||
}
|
||||
|
||||
export interface ProgramUserInfo {
|
||||
idCard: null
|
||||
name: string
|
||||
telephone: string
|
||||
idCard?: null
|
||||
name?: string
|
||||
telephone?: string
|
||||
}
|
||||
|
||||
export interface ServiceProjectSecurityUserPagerVo {
|
||||
|
|
|
@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|||
import com.changhu.common.annotation.JsonBody;
|
||||
import com.changhu.common.exception.MessageException;
|
||||
import com.changhu.common.pojo.vo.SelectNodeVo;
|
||||
import com.changhu.module.management.pojo.entity.EnterprisesUnit;
|
||||
import com.changhu.module.management.pojo.params.EnterprisesUnitSaveOrUpdateParams;
|
||||
import com.changhu.module.management.pojo.queryParams.EnterprisesUnitPagerQueryParams;
|
||||
import com.changhu.module.management.pojo.vo.EnterprisesUnitPagerVo;
|
||||
|
@ -58,4 +59,10 @@ public class EnterprisesUnitController {
|
|||
return enterprisesUnitService.queryListByAdministrativeDivisionCodes(administrativeDivisionCodes);
|
||||
}
|
||||
|
||||
@Operation(summary = "企事业单位地图点位")
|
||||
@GetMapping("/mapPoint")
|
||||
public List<EnterprisesUnit> mapPoint() {
|
||||
return enterprisesUnitService.list();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -1,13 +1,89 @@
|
|||
<template>
|
||||
<div style="width: 100vw;height: 100vh">
|
||||
<map-container/>
|
||||
<div class="container">
|
||||
<div class="header">
|
||||
<h1>地图页面标题</h1>
|
||||
</div>
|
||||
<MapContainer class="map-container" ref="mapRef" :map-options="mapOptions" :init-callback="initMap">
|
||||
<div class="left-panel panel">
|
||||
<h2>左侧统计面板</h2>
|
||||
<!-- 添加你的统计数据 -->
|
||||
</div>
|
||||
<div class="right-panel panel">
|
||||
<h2>右侧统计面板</h2>
|
||||
<!-- 添加你的统计数据 -->
|
||||
</div>
|
||||
</MapContainer>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import MapContainer from "@/components/aMap/MapContainer.vue";
|
||||
import {ref} from "vue";
|
||||
import {ComponentExposed} from "vue-component-type-helpers";
|
||||
import api from "@/axios";
|
||||
|
||||
const mapRef = ref<ComponentExposed<typeof MapContainer>>(null)
|
||||
const mapOptions: AMap.MapOptions = {
|
||||
// 是否为3D地图模式
|
||||
viewMode: "3D",
|
||||
// 初始化地图级别
|
||||
zoom: 16,
|
||||
mapStyle: 'amap://styles/darkblue'
|
||||
}
|
||||
|
||||
const initMap = async () => {
|
||||
const {data} = await api.get<any[]>('/enterprisesUnit/mapPoint')
|
||||
mapRef.value?.mapInstance?.clearMap()
|
||||
const markers = data.map(item => {
|
||||
if (!item.point) {
|
||||
return null;
|
||||
}
|
||||
return new AMap.Marker({
|
||||
position: item.point
|
||||
})
|
||||
}).filter(Boolean)
|
||||
mapRef.value.mapInstance.add(markers)
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.container {
|
||||
position: relative;
|
||||
height: 100vh;
|
||||
}
|
||||
|
||||
.header {
|
||||
background-color: rgba(255, 255, 255, 0.7);
|
||||
color: #333;
|
||||
text-align: center;
|
||||
padding: 20px;
|
||||
position: absolute;
|
||||
top: 20px;
|
||||
left: 0;
|
||||
right: 0;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.map-container {
|
||||
height: 100%;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.panel {
|
||||
background-color: rgba(255, 255, 255, 0.7);
|
||||
padding: 20px;
|
||||
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
||||
position: absolute;
|
||||
top: 100px; /* 调整顶部距离以避免与标题重叠 */
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.left-panel {
|
||||
left: 10px;
|
||||
}
|
||||
|
||||
.right-panel {
|
||||
right: 10px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -87,7 +87,7 @@ const saveOrUpdateEnterprisesUnit = (params: _FormType, callback: Function) => {
|
|||
placeholder={'请输入详细地址'}
|
||||
autocomplete="off"
|
||||
onFocus={() => {
|
||||
if (!_mapRef.value.mapInstance) {
|
||||
if (!_mapRef.value?.mapInstance) {
|
||||
message.error('地图组件尚未初始化成功 请重新打开页面')
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue