曲靖服务调整
This commit is contained in:
165
src/project/qujing/AppModules/AppModules.vue
Normal file
165
src/project/qujing/AppModules/AppModules.vue
Normal file
@@ -0,0 +1,165 @@
|
||||
<template>
|
||||
<div class="wrapper">
|
||||
<div class="header" :class="{sticky:isFixed}">
|
||||
<div class="status-bar" :style="{height: statusBarHeight + 'px'}"></div>
|
||||
<div class="nav-bar">
|
||||
<h2>服务</h2>
|
||||
</div>
|
||||
</div>
|
||||
<div class="liner"/>
|
||||
<div class="body" v-if="list">
|
||||
<div class="card" v-for="(obj,key) in list" :key="key">
|
||||
<div class="title">{{ $dict.getLabel('homeConfigMenuType', key) }}</div>
|
||||
<u-grid :col="4" hover-class="text-hover">
|
||||
<u-grid-item
|
||||
v-for="(item, index) in obj" :key="index" class="grid-item" :custom-style="{padding:'9px 0'}"
|
||||
@click="handleClick(item)">
|
||||
<img :src="item.pictureUrl" alt=""/>
|
||||
<div class="grid-text">{{ item.name }}</div>
|
||||
</u-grid-item>
|
||||
</u-grid>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {mapActions, mapState} from "vuex";
|
||||
|
||||
export default {
|
||||
name: "AppModules",
|
||||
appName: "服务",
|
||||
customNavigation: true,
|
||||
computed: {
|
||||
...mapState(['user', 'token']),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
list: null,
|
||||
isFixed: false,
|
||||
statusBarHeight: 20,
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
this.statusBarHeight = uni.getSystemInfoSync().statusBarHeight;
|
||||
this.$dict.load("homeConfigMenuType").then(() => {
|
||||
this.getList()
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
...mapActions(['authCheck']),
|
||||
handleClick({type, appId, modulePath, url, checkType, corpId}) {
|
||||
if (checkType == 3 && this.user.partyStatusForWX != 2) { //张硕让改的
|
||||
return this.$u.toast('您还不是党员,暂时无法使用该功能')
|
||||
}
|
||||
//先判读是不是系统应用
|
||||
if (type != "0") {
|
||||
if (type == "1") {
|
||||
uni.navigateToMiniProgram({appId});
|
||||
} else if (type == "2") {
|
||||
uni.navigateTo({url: "/subPages/h5/webview?link=" + url});
|
||||
} else if (type == "3") {
|
||||
this.$linkTo(url);
|
||||
} else if (type == "4") {
|
||||
uni.openCustomerServiceChat({
|
||||
extInfo: {url: url},
|
||||
corpId: corpId,
|
||||
fail: () => {
|
||||
this.$u.toast('请使用普通微信打开小程序进行咨询');
|
||||
}
|
||||
});
|
||||
}
|
||||
} else if (type && type == "0") {
|
||||
uni.showLoading({title: '正在进入应用...'})
|
||||
this.authCheck({checkType, modulePath}).finally(() => uni.hideLoading())
|
||||
}
|
||||
},
|
||||
getList() {
|
||||
this.$instance.post("/app/appminihomeconfig/listAll", null, {withoutToken: true}).then(res => {
|
||||
if (res?.data) {
|
||||
this.list = res.data.all;
|
||||
}
|
||||
})
|
||||
},
|
||||
onPageScroll(params) {
|
||||
this.isFixed = params.scrollTop > 60;
|
||||
}
|
||||
},
|
||||
|
||||
onShareAppMessage() {
|
||||
return {
|
||||
title: '欢迎使用数字乡村治理服务一体化平台~',
|
||||
path: `/pages/AppModules/AppModules`
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.header {
|
||||
position: fixed;
|
||||
left: 0;
|
||||
top: 0;
|
||||
z-index: 0;
|
||||
width: 100%;
|
||||
opacity: 0;
|
||||
transition: all 0.2s ease;
|
||||
|
||||
&.sticky {
|
||||
z-index: 1111;
|
||||
opacity: 1;
|
||||
background: #F4F5FA;
|
||||
}
|
||||
|
||||
.nav-bar {
|
||||
position: relative;
|
||||
height: 88px;
|
||||
line-height: 88px;
|
||||
color: #333;
|
||||
font-size: 34px;
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.liner {
|
||||
height: 192px;
|
||||
background: linear-gradient(360deg, #F3F6F9 0%, #F4F5FA 100%);
|
||||
}
|
||||
|
||||
.body {
|
||||
.card {
|
||||
width: 686px;
|
||||
min-height: 304px;
|
||||
background: #FFFFFF;
|
||||
box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.02);
|
||||
border-radius: 16px;
|
||||
margin: 0 auto 24px;
|
||||
box-sizing: border-box;
|
||||
padding: 32px;
|
||||
|
||||
.title {
|
||||
font-size: 34px;
|
||||
font-weight: 600;
|
||||
color: #333333;
|
||||
line-height: 48px;
|
||||
margin-bottom: 36px;
|
||||
}
|
||||
|
||||
.grid-item {
|
||||
img {
|
||||
width: 108px;
|
||||
height: 108px;
|
||||
object-fit: fill;
|
||||
}
|
||||
|
||||
.grid-text {
|
||||
font-size: 26px;
|
||||
font-weight: 400;
|
||||
color: #333333;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
BIN
src/project/qujing/AppModules/service.png
Normal file
BIN
src/project/qujing/AppModules/service.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.8 KiB |
BIN
src/project/qujing/AppModules/service_selected.png
Normal file
BIN
src/project/qujing/AppModules/service_selected.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.8 KiB |
Reference in New Issue
Block a user