Files
dvcp_v2_wechat_app/src/mods/AppServiceOnline/AppServiceOnline.vue
2022-02-15 16:26:32 +08:00

100 lines
1.9 KiB
Vue

<template>
<div class="servie">
<div class="serviceItem" v-for="(op,i) in list" :key="i" @click="toServiceList(op)" hover-class="bg-hover">
<img :src="op.icon"/>
<div class="fill flex1">
<div>{{ op.name }}</div>
<u-gap height="6"/>
<span>{{ op.desc }}</span>
</div>
<i class="iconfont">&#xe697;</i>
</div>
</div>
</template>
<script>
export default {
name:"AppServiceOnline",
appName:"网上办事",
data () {
return {
list: []
}
},
onLoad () {
this.getList()
},
methods: {
toServiceList(item) {
this.$linkTo(`./serviceList?id=${item.id}&title=${item.name}&subTitle=${item.desc}`)
},
getList() {
let size = 999
this.$instance.post("/app/zwspapprovalclassification/list-xcx", null, {
params: {
size
},
withoutToken: true
}).then(res => {
if (res.code === 0) {
this.list = res.data.records
}
})
}
}
}
</script>
<style lang="scss" scoped>
.servie {
min-height: 100vh;
background: #fff;
}
.serviceItem {
width: 100%;
height: 160px;
padding: 28px 40px 28px;
display: flex;
align-items: center;
box-sizing: border-box;
img {
width: 80px;
height: 80px;
}
.fill {
display: flex;
flex-direction: column;
font-size: 30px;
font-weight: 600;
color: #3C435C;
margin: 0 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
span {
display: block;
width: 100%;
margin-right: 20px;
font-size: 28px;
font-weight: 500;
color: #BEC1D0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
}
i {
font-size: 44px;
color: #979797;
}
}
</style>