Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
center-psp-show-h5
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
center-psp-show-h5
Commits
746d6c38
提交
746d6c38
authored
4月 20, 2022
作者:
matian
浏览文件
操作
浏览文件
下载
差异文件
Merge remote-tracking branch 'origin/master'
上级
f13153a2
2cf608cf
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
122 行增加
和
40 行删除
+122
-40
AdmissionGuide.vue
src/modules/home/components/AdmissionGuide.vue
+7
-4
ExamStrategy.vue
src/modules/home/components/ExamStrategy.vue
+75
-2
LearningMap.vue
src/modules/home/components/LearningMap.vue
+4
-3
Menu.vue
src/modules/home/components/Menu.vue
+20
-20
QueryView.vue
src/modules/home/components/QueryView.vue
+2
-2
Questions.vue
src/modules/home/components/Questions.vue
+5
-2
types.ts
src/modules/home/types.ts
+1
-0
Index.vue
src/modules/home/views/Index.vue
+8
-7
没有找到文件。
src/modules/home/components/AdmissionGuide.vue
浏览文件 @
746d6c38
...
@@ -25,13 +25,14 @@ function showTips() {
...
@@ -25,13 +25,14 @@ function showTips() {
<div
class=
"admission-left"
>
<div
class=
"admission-left"
>
<h2>
解释文档
</h2>
<h2>
解释文档
</h2>
<div
class=
"box"
>
<div
class=
"box"
>
<ul>
<ul
v-if=
"docs.length"
>
<li
v-for=
"item in docs"
:key=
"item.id"
@
click=
"handleViewDoc(item)"
>
<li
v-for=
"item in docs"
:key=
"item.id"
@
click=
"handleViewDoc(item)"
>
<p>
{{
item
.
title
}}
</p>
<p>
{{
item
.
title
}}
</p>
<span>
{{
item
.
pv
}}
</span>
<span>
{{
item
.
pv
}}
</span>
<van-icon
name=
"arrow"
/>
<van-icon
name=
"arrow"
/>
</li>
</li>
</ul>
</ul>
<van-empty
description=
"暂无内容"
v-else
/>
</div>
</div>
</div>
</div>
<div
class=
"admission-right"
>
<div
class=
"admission-right"
>
...
@@ -66,6 +67,7 @@ function showTips() {
...
@@ -66,6 +67,7 @@ function showTips() {
.admission-left
{
.admission-left
{
padding
:
0
.1rem
;
padding
:
0
.1rem
;
width
:
3
.33rem
;
width
:
3
.33rem
;
margin-right
:
0
.2rem
;
background
:
url(https://webapp-pub.ezijing.com/project/prp-h5/admission_bg.png)
no-repeat
;
background
:
url(https://webapp-pub.ezijing.com/project/prp-h5/admission_bg.png)
no-repeat
;
background-size
:
contain
;
background-size
:
contain
;
box-sizing
:
border-box
;
box-sizing
:
border-box
;
...
@@ -108,9 +110,10 @@ function showTips() {
...
@@ -108,9 +110,10 @@ function showTips() {
}
}
}
}
.admission-right
{
.admission-right
{
flex
:
1
;
.box
{
.box
{
padding
:
0
.22rem
0
.2rem
;
padding
:
0
.22rem
0
.2rem
;
width
:
3
.33rem
;
//
width: 3.33rem;
height
:
2
.01rem
;
height
:
2
.01rem
;
background
:
#fff
;
background
:
#fff
;
border-radius
:
0
.2rem
;
border-radius
:
0
.2rem
;
...
@@ -139,11 +142,11 @@ function showTips() {
...
@@ -139,11 +142,11 @@ function showTips() {
}
}
.box-test
{
.box-test
{
background
:
#fff
url(https://webapp-pub.ezijing.com/project/prp-h5/admission_1.png)
no-repeat
right
bottom
;
background
:
#fff
url(https://webapp-pub.ezijing.com/project/prp-h5/admission_1.png)
no-repeat
right
bottom
;
background-size
:
50%
;
background-size
:
1
.7rem
1
.36rem
;
}
}
.box-notice
{
.box-notice
{
background
:
#fff
url(https://webapp-pub.ezijing.com/project/prp-h5/admission_2.png)
no-repeat
right
bottom
;
background
:
#fff
url(https://webapp-pub.ezijing.com/project/prp-h5/admission_2.png)
no-repeat
right
bottom
;
background-size
:
50%
;
background-size
:
1
.7rem
1
.36rem
;
}
}
}
}
.admission-box
{
.admission-box
{
...
...
src/modules/home/components/ExamStrategy.vue
浏览文件 @
746d6c38
<
script
setup
lang=
"ts"
></
script
>
<
script
setup
lang=
"ts"
>
import
{
useRouter
}
from
'vue-router'
import
type
{
IDocItem
}
from
'../types'
defineProps
<
{
docs
:
IDocItem
[]
}
>
()
const
router
=
useRouter
()
function
handleViewDoc
(
data
:
IDocItem
)
{
router
.
push
(
'/learn/doc/'
+
data
.
id
)
}
</
script
>
<
template
>
<
template
>
<AppCard
title=
"考试攻略"
id=
"exam"
></AppCard>
<AppCard
title=
"考试攻略"
id=
"exam"
>
<div
class=
"box"
>
<h2>
解释文档
</h2>
<ul
v-if=
"docs.length"
>
<li
v-for=
"item in docs"
:key=
"item.id"
@
click=
"handleViewDoc(item)"
>
<p>
{{
item
.
title
}}
</p>
<span>
{{
item
.
pv
}}
</span>
<van-icon
name=
"arrow"
/>
</li>
</ul>
<van-empty
description=
"暂无内容"
v-else
/>
</div>
</AppCard>
</
template
>
</
template
>
<
style
lang=
"scss"
scoped
>
.box
{
margin-top
:
0
.28rem
;
padding
:
0
.2rem
;
background
:
#fff
;
border-radius
:
0
.2rem
;
overflow
:
hidden
;
box-sizing
:
border-box
;
h2
{
margin-bottom
:
0
.15rem
;
font-size
:
0
.26rem
;
font-weight
:
600
;
color
:
#4e4e4e
;
}
ul
{
display
:
grid
;
grid-template-columns
:
1fr
1fr
;
column-gap
:
0
.2rem
;
row-gap
:
0
.2rem
;
}
li
{
height
:
0
.75rem
;
padding
:
0
0
.14rem
;
display
:
flex
;
align-items
:
center
;
font-size
:
0
.2rem
;
color
:
#adadad
;
background
:
#f7f7f7
;
border-radius
:
0
.1rem
;
cursor
:
pointer
;
overflow
:
hidden
;
}
p
{
flex
:
1
;
font-size
:
0
.24rem
;
color
:
#4e4e4e
;
white-space
:
nowrap
;
text-overflow
:
ellipsis
;
overflow
:
hidden
;
}
span
{
min-width
:
0
.44rem
;
font-size
:
0
.2rem
;
color
:
#c6c6c6
;
padding
:
0
0
.1rem
;
}
}
</
style
>
src/modules/home/components/LearningMap.vue
浏览文件 @
746d6c38
...
@@ -34,18 +34,19 @@ function showTips() {
...
@@ -34,18 +34,19 @@ function showTips() {
title-inactive-color=
"#4E4E4E"
title-inactive-color=
"#4E4E4E"
line-height=
"0"
line-height=
"0"
>
>
<van-tab
title=
"解释文档"
>
<van-tab
title=
"解释文档"
v-if=
"docs.length"
>
<div
class=
"learn-box learn-docs"
>
<div
class=
"learn-box learn-docs"
>
<ul>
<ul
v-if=
"docs.length"
>
<li
v-for=
"item in docs"
:key=
"item.id"
@
click=
"handleViewDoc(item)"
>
<li
v-for=
"item in docs"
:key=
"item.id"
@
click=
"handleViewDoc(item)"
>
<p>
{{ item.title }}
</p>
<p>
{{ item.title }}
</p>
<span>
{{ item.pv }}
</span>
<span>
{{ item.pv }}
</span>
<van-icon
name=
"arrow"
/>
<van-icon
name=
"arrow"
/>
</li>
</li>
</ul>
</ul>
<van-empty
description=
"暂无内容"
v-else
/>
</div>
</div>
</van-tab>
</van-tab>
<van-tab
title=
"学前测评"
>
<van-tab
title=
"学前测评"
v-if=
"false"
>
<div
class=
"learn-box learn-test"
>
<div
class=
"learn-box learn-test"
>
<h2>
查漏补缺 建立系统概念
</h2>
<h2>
查漏补缺 建立系统概念
</h2>
<p>
了解PRP学习前系统专业知识的情况
</p>
<p>
了解PRP学习前系统专业知识的情况
</p>
...
...
src/modules/home/components/Menu.vue
浏览文件 @
746d6c38
...
@@ -16,27 +16,27 @@ const menus: Array<{
...
@@ -16,27 +16,27 @@ const menus: Array<{
path
:
'#learning'
,
path
:
'#learning'
,
name
:
'学习地图'
,
name
:
'学习地图'
,
icon
:
'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_2.png'
icon
:
'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_2.png'
},
{
path
:
'#query'
,
name
:
'权益查看'
,
icon
:
'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_3.png'
},
{
path
:
'#team'
,
name
:
'荣誉总榜'
,
icon
:
'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_4.png'
},
{
path
:
'#exam'
,
name
:
'考试攻略'
,
icon
:
'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_6.png'
},
{
path
:
'#qa'
,
name
:
'陪伴问答'
,
icon
:
'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_5.png'
}
}
// {
// path: '#query',
// name: '权益查看',
// icon: 'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_3.png'
// },
// {
// path: '#team',
// name: '荣誉总榜',
// icon: 'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_4.png'
// },
// {
// path: '#exam',
// name: '考试攻略',
// icon: 'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_6.png'
// },
// {
// path: '#qa',
// name: '陪伴问答',
// icon: 'https://webapp-pub.ezijing.com/project/prp-h5/home_menu_5.png'
// }
]
]
</
script
>
</
script
>
...
...
src/modules/home/components/QueryView.vue
浏览文件 @
746d6c38
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
<div
class=
"query"
>
<div
class=
"query"
>
<div
class=
"query-left"
>
<div
class=
"query-left"
>
<div
class=
"box box-avatar"
>
<div
class=
"box box-avatar"
>
<router-link
to=
"/query?active=
0
"
>
<router-link
to=
"/query?active=
2
"
>
<h2>
<h2>
<img
<img
src=
"https://webapp-pub.ezijing.com/project/prp-h5/query_icon_1.png"
src=
"https://webapp-pub.ezijing.com/project/prp-h5/query_icon_1.png"
...
@@ -28,7 +28,7 @@
...
@@ -28,7 +28,7 @@
</router-link>
</router-link>
</div>
</div>
<div
class=
"box"
>
<div
class=
"box"
>
<router-link
to=
"/query?active=
2
"
>
<router-link
to=
"/query?active=
0
"
>
<h2>
<h2>
<img
<img
src=
"https://webapp-pub.ezijing.com/project/prp-h5/query_icon_3.png"
src=
"https://webapp-pub.ezijing.com/project/prp-h5/query_icon_3.png"
...
...
src/modules/home/components/Questions.vue
浏览文件 @
746d6c38
...
@@ -3,7 +3,7 @@ import { Toast } from 'vant'
...
@@ -3,7 +3,7 @@ import { Toast } from 'vant'
import
PublishItem
from
'@/components/PublishItem.vue'
import
PublishItem
from
'@/components/PublishItem.vue'
import
{
createQuestionComment
}
from
'../api'
import
{
createQuestionComment
}
from
'../api'
defineProps
<
{
data
:
any
}
>
()
defineProps
<
{
data
:
{
total
:
0
;
list
:
[]
}
}
>
()
// 评论
// 评论
const
onSubmitComment
=
(
data
:
any
,
action
:
string
)
=>
{
const
onSubmitComment
=
(
data
:
any
,
action
:
string
)
=>
{
...
@@ -33,7 +33,10 @@ const onSubmitComment = (data: any, action: string) => {
...
@@ -33,7 +33,10 @@ const onSubmitComment = (data: any, action: string) => {
<template
#
header-aside
>
<template
#
header-aside
>
<div
class=
"button"
><router-link
to=
"/qa/publish"
>
发表问答
</router-link></div>
<div
class=
"button"
><router-link
to=
"/qa/publish"
>
发表问答
</router-link></div>
</
template
>
</
template
>
<PublishItem
v-for=
"item in data.list"
:data=
"item"
:key=
"item.id"
@
submitComment=
"onSubmitComment"
></PublishItem>
<
template
v-if=
"data.list?.length"
>
<PublishItem
v-for=
"item in data.list"
:data=
"item"
:key=
"item.id"
@
submitComment=
"onSubmitComment"
></PublishItem>
</
template
>
<van-empty
description=
"暂无内容"
v-else
/>
</AppCard>
</AppCard>
</template>
</template>
...
...
src/modules/home/types.ts
浏览文件 @
746d6c38
...
@@ -5,6 +5,7 @@ export interface HomeInfo {
...
@@ -5,6 +5,7 @@ export interface HomeInfo {
admission_guide_docs
:
IDocItem
[]
admission_guide_docs
:
IDocItem
[]
admission_guide_videos
:
IVideoItem
[]
admission_guide_videos
:
IVideoItem
[]
learning_map_docs
:
IDocItem
[]
learning_map_docs
:
IDocItem
[]
exam_strategy_docs
:
IDocItem
[]
questions
:
any
questions
:
any
}
}
...
...
src/modules/home/views/Index.vue
浏览文件 @
746d6c38
...
@@ -7,16 +7,17 @@ import Menu from '../components/Menu.vue'
...
@@ -7,16 +7,17 @@ import Menu from '../components/Menu.vue'
import
AdmissionGuide
from
'../components/AdmissionGuide.vue'
import
AdmissionGuide
from
'../components/AdmissionGuide.vue'
import
LearningMap
from
'../components/LearningMap.vue'
import
LearningMap
from
'../components/LearningMap.vue'
import
QueryView
from
'../components/QueryView.vue'
import
QueryView
from
'../components/QueryView.vue'
//
import ExamStrategy from '../components/ExamStrategy.vue'
import
ExamStrategy
from
'../components/ExamStrategy.vue'
//
import TeamRanking from '../components/TeamRanking.vue'
import
TeamRanking
from
'../components/TeamRanking.vue'
//
import Questions from '../components/Questions.vue'
import
Questions
from
'../components/Questions.vue'
const
data
=
ref
<
HomeInfo
>
({
const
data
=
ref
<
HomeInfo
>
({
banner
:
[],
banner
:
[],
admission_guide_docs
:
[],
admission_guide_docs
:
[],
admission_guide_videos
:
[],
admission_guide_videos
:
[],
learning_map_docs
:
[],
learning_map_docs
:
[],
questions
:
{}
exam_strategy_docs
:
[],
questions
:
{
total
:
0
,
list
:
[]
}
})
})
// 获取首页数据
// 获取首页数据
const
fetchHomeData
=
()
=>
{
const
fetchHomeData
=
()
=>
{
...
@@ -39,9 +40,9 @@ onMounted(() => {
...
@@ -39,9 +40,9 @@ onMounted(() => {
<!-- 权益查看 -->
<!-- 权益查看 -->
<QueryView></QueryView>
<QueryView></QueryView>
<!-- 荣誉总榜 -->
<!-- 荣誉总榜 -->
<
!--
<TeamRanking></TeamRanking>
--
>
<
TeamRanking></TeamRanking
>
<!-- 考试攻略 -->
<!-- 考试攻略 -->
<
!--
<ExamStrategy></ExamStrategy>
--
>
<
ExamStrategy
:docs=
"data.exam_strategy_docs"
></ExamStrategy
>
<!-- 陪伴问答 -->
<!-- 陪伴问答 -->
<
!--
<Questions
:data=
"data.questions"
></Questions>
--
>
<
Questions
:data=
"data.questions"
></Questions
>
</
template
>
</
template
>
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论