Commit 7cb46791 authored by 郭铭瑶's avatar 郭铭瑶 🤘

调整弹窗字号

parent 85a74bdb
......@@ -109,7 +109,6 @@ export default {
/** 地图直接点击楼栋获取数据 */
async getBuildingDetail({ commit }: Method, id: string) {
if (state.showFilterDrawer) return
commit('SET_SHOW_BUILDING_DETAIL', false)
commit('SET_LOADING', true)
const building =
......@@ -122,6 +121,12 @@ export default {
commit('SET_LOADING', false)
return
}
if (state.showFilterDrawer) {
// 筛选侧边栏展开的情况下直接点击地图楼栋
commit('SET_BUILDING_DETAIL_BY_NEXT', building)
commit('SET_LOADING', false)
return
}
const floors = await getFloors(building)
commit('SET_BUILDING_DETAIL', { building, floors })
commit('SET_SHOW_BUILDING_DETAIL', true)
......
......@@ -60,4 +60,7 @@ export default {
) {
state.buildingDetail = data
},
SET_BUILDING_DETAIL_BY_NEXT(state: GlobalStateProps, data: any) {
state.buildingDetailByNext = data
},
}
......@@ -65,4 +65,5 @@ export default {
building: any
floors: any[]
},
buildingDetailByNext: {},
}
......@@ -27,12 +27,13 @@ const style = `
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
font-size: .11rem;
}
.pop-container > p {
margin-bottom: .04rem;
padding: 0 .02rem;
}
.title {
.pop-container .title {
font-size: .13rem;
font-family: PingFangMedium, 'Avenir', Helvetica, Arial, sans-serif;
}
......@@ -41,7 +42,7 @@ const style = `
flex-wrap: wrap;
margin: .05rem 0;
}
.tag {
.pop-container .tag {
display: inline-block;
border-radius: .04rem;
font-size: .1rem;
......@@ -143,7 +144,6 @@ const style = `
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
font-size: .11rem;
}
.pop-container .wrapper > .item p {
font-family: PingFangMedium, 'Avenir', Helvetica, Arial, sans-serif;
......
......@@ -108,7 +108,7 @@
</template>
<script lang="ts" setup>
import { computed, onMounted, PropType, ref } from 'vue'
import { computed, onMounted, PropType, ref, watch } from 'vue'
import store from '@/store'
import dot from '@images/dot.svg'
import { ArrowForward, ArrowBack, ArrowDown } from '@vicons/ionicons5'
......@@ -238,6 +238,14 @@ const buildingNext = async (building: any) => {
setBuilding(building, true)
showBuildingDetail.value = true
}
watch(
() => store.state.buildingDetailByNext,
(building) => {
if (!building) return
buildingNext(building)
},
{ deep: true },
)
</script>
<style lang="stylus" scoped>
......
......@@ -220,11 +220,8 @@ const setTab = (val: string) => {
curTab.value = val
}
const fetchTags = async (
type: string,
): Promise<
{ key: string; name: string; count: number; checked: boolean }[]
> => {
type Tags = { key: string; name: string; count: number; checked: boolean }[]
const fetchTags = async (type: string): Promise<Tags> => {
const res = await useFetchTag({
keys: '标签名称',
q: `paths @ "所属模块" && string == "${type}"`,
......@@ -243,16 +240,12 @@ const fetchTags = async (
}),
)
}
const organization = ref<
{ key: string; name: string; count: number; checked: boolean }[]
>([])
const organization = ref<Tags>([])
const getOrgTags = async () => {
organization.value = await fetchTags('党组织')
}
const member = ref<
{ key: string; name: string; count: number; checked: boolean }[]
>([])
const member = ref<Tags>([])
const getMemberTags = async () => {
member.value = await fetchTags('党员')
}
......
......@@ -21,6 +21,7 @@ export default defineConfig({
},
},
server: {
port: 3001,
proxy: {
'/api': {
target: 'https://survey.maicedata.com/api/data/',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment