添加:帮助中心 - 新

This commit is contained in:
wuhui_zzw 2023-10-26 17:42:59 +08:00
parent acf449b906
commit 84c9de585f
6 changed files with 240 additions and 3 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

View File

@ -2648,6 +2648,15 @@ const routes = [
foot: true
}
},
{
path: "/member/new_help/index",
component:()=>import("../views/member/new_help/index"),
name: "new_help",
meta: {
title: "帮助中心",
foot: true
}
},
{
path: "/member/tool/about_us",
component:()=>import("../views/member/tool/about_us"),
@ -2657,9 +2666,6 @@ const routes = [
foot: true
}
},
// score
{
path: "/member/integral_activity",

View File

@ -0,0 +1,231 @@
<template>
<div>
<c-title :hide="false" text="帮助中心" tolink="detailed"></c-title>
<div class="content-box">
<!--顶部内容-->
<div class="top">
<img class="top-img" src="../../../assets/images/new_help/top_img.jpg" />
</div>
<!--搜索&工具-->
<div class="main-content">
<div class="search-content">
<van-search v-model="search_value" background="#f5f5f7" show-action placeholder="请输入搜索关键词">
<template #action>
<div @click="getList">搜索</div>
</template>
</van-search>
</div>
<div class="tool-content">
<div class="block-title">常用工具</div>
<div class="tool-list">
<div class="block" v-for="(item,index) in tool" :key="index" @click="clickTool(item.name)">
<img class="block-img" :src="item.icon" />
<div class="block-title">{{ item.title }}</div>
</div>
</div>
</div>
</div>
<!--问题列表-->
<div class="question-content" v-if="Object.values(question_list).length > 0">
<div class="block-title">常用工具</div>
<div class="question-list">
<van-cell
v-for="(item,index) in Object.values(question_list)"
:key="index"
class="list-cell"
:title="item.title"
is-link
@click="showQuestionDetail(item)"
/>
</div>
</div>
</div>
<!--弹出框-->
<van-popup v-model="show" position="bottom" :style="{ 'min-height': '70%' }" round closeable>
<div class="show-content">
<div class="show-title">{{ show_title }}</div>
<div class="show-text" v-html="show_content"></div>
</div>
</van-popup>
</div>
</template>
<script>
export default {
data() {
return {
info: {},
question_list: {},
//
search_value: '',
//
tool: [
{ title: '官方客服',name: 'customer_service',icon: require('../../../assets/images/new_help/2.png')},
{ title: '意见反馈',name: 'feedback',icon: require('../../../assets/images/new_help/3.png')},
{ title: '用户问卷',name: 'questionnaire',icon: require('../../../assets/images/new_help/4.png')},
],
//
show: false,
show_title: '',
show_content: '',
};
},
activated() {
this.getData();
this.getList();
},
methods: {
//
getData() {
let _this = this;
$http.get("plugin.help-center.api.content.home-info", {}, "加载中...").then((res) => {
if (parseInt(res.result) === 1) {
_this.info = res.data;
}
}).catch((error) => {});
},
//
getList() {
let _this = this;
$http.get("plugin.help-center.api.content.question-list", { search_text: _this.search_value }, "加载中...").then((res) => {
if (parseInt(res.result) === 1) {
_this.question_list = res.data;
}
}).catch((error) => {});
},
//
clickTool(name){
let _this = this;
if(name === 'customer_service') window.location.href = 'tel://' + _this.info.customer_service_tel;
else if(name === 'feedback') _this.$router.push(_this.fun.getUrl("DiyForm",{ id: _this.info.feedback_id }));
else if(name === 'questionnaire') _this.$router.push(_this.fun.getUrl("DiyForm",{ id: _this.info.questionnaire_id }));
},
//
showQuestionDetail(item){
this.show_title = item.title;
this.show_content = item.content;
this.show = true;
}
},
};
</script>
<style lang="scss" scoped>
.content-box {
width: 100vw !important;
min-height: calc(100vh - 40px);
.block-title {
width: 100%;
height: 35px;
line-height: 30px;
border-bottom: 1px solid #ebedf0;
text-align: left;
font-size: 14px;
font-weight: bold;
}
.top {
width: 100vw;
display: flex;
.top-img {
width: 100%;
}
}
.main-content {
width: 100vw !important;
padding-top: 10px;
background: #FFFFFF;
position: relative;
top: -15px;
border-top-right-radius: 15px;
border-top-left-radius: 15px;
.search-content {
width: 100%;
padding: 10px 15px;
::v-deep .van-search {
padding: 0 !important;
}
::v-deep .van-search__content {
background-color: #f5f5f7 !important;
}
}
.tool-content {
width: 100%;
padding: 10px 15px;
.tool-list {
width: 100%;
display: inline-flex;
flex-direction: row;
flex-wrap: nowrap;
align-items: center;
justify-content: space-around;
padding-top: 20px;
padding-bottom: 10px;
.block {
.block-img {
width: 30px;
height: 30px;
}
.block-title {
height: 30px;
line-height: 30px;
text-align: center;
font-size: 14px;
font-weight: 500;
}
}
}
}
}
.question-content {
width: 100%;
background: #FFFFFF;
.block-title{
padding: 10px 15px;
height: 50px;
border-bottom: none!important;
}
.list-cell{
border-top: 1px solid #ebedf0;
padding: 6px 15px;
::v-deep .van-cell__title {
text-align: left;
font-size: 14px;
font-weight: 500;
}
}
.list-cell:last-child{
border: none!important;
}
}
}
.show-content {
width: 100vw;
padding: 15px 20px;
.show-title {
height: 35px;
line-height: 24px;
font-size: 15px;
font-weight: bold;
}
.show-text {
text-align: left;
}
}
</style>