Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
project-www-h5
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
project-www-h5
Commits
1e08f1c4
提交
1e08f1c4
authored
4月 24, 2021
作者:
王鹏飞
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增新闻页面
上级
98167ad9
隐藏空白字符变更
内嵌
并排
正在显示
11 个修改的文件
包含
267 行增加
和
65 行删除
+267
-65
Link.vue
components/Link.vue
+17
-0
Search.vue
components/Search.vue
+3
-3
TreeItem.vue
components/TreeItem.vue
+4
-10
NewsItem.vue
components/about/NewsItem.vue
+40
-7
Banner.vue
components/home/Banner.vue
+6
-6
Degree.vue
components/home/Degree.vue
+22
-14
Post.vue
components/home/Post.vue
+14
-12
Service.vue
components/home/Service.vue
+38
-11
nuxt.config.js
nuxt.config.js
+3
-0
_id.vue
pages/about/news/_id.vue
+101
-0
index.vue
pages/about/news/index.vue
+19
-2
没有找到文件。
components/Link.vue
0 → 100644
浏览文件 @
1e08f1c4
<
template
>
<div>
<!-- 外部链接跳转 -->
<a
:href=
"item.href"
target=
"_blank"
v-if=
"item.href"
><slot
/></a>
<!-- 站内跳转 -->
<nuxt-link
:to=
"item.path"
v-else-if=
"item.path"
><slot
/></nuxt-link>
<!-- 事件 -->
<span
v-else-if=
"item.onClick"
@
click=
"item.onClick"
><slot
/></span>
<template
v-else
><slot
/></
template
>
</div>
</template>
<
script
>
export
default
{
props
:
{
item
:
{
type
:
Object
}
}
}
</
script
>
components/Search.vue
浏览文件 @
1e08f1c4
...
@@ -4,9 +4,7 @@
...
@@ -4,9 +4,7 @@
<h2
class=
"hot-search__title"
>
热门搜索
</h2>
<h2
class=
"hot-search__title"
>
热门搜索
</h2>
<ul
class=
"hot-search__list"
>
<ul
class=
"hot-search__list"
>
<li
v-for=
"(item, index) in hotList"
:key=
"index"
>
<li
v-for=
"(item, index) in hotList"
:key=
"index"
>
<nuxt-link
:to=
"item.path"
v-if=
"item.path"
>
{{
item
.
name
}}
</nuxt-link>
<app-link
:item=
"item"
>
{{
item
.
name
}}
</app-link>
<a
:href=
"item.href"
v-else-if=
"item.href"
target=
"_blank"
>
{{
item
.
name
}}
</a>
<template
v-else
>
{{
item
.
name
}}
</
template
>
</li>
</li>
</ul>
</ul>
</div>
</div>
...
@@ -14,7 +12,9 @@
...
@@ -14,7 +12,9 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
AppLink
from
'@/components/Link'
export
default
{
export
default
{
components
:
{
AppLink
},
data
()
{
data
()
{
return
{
return
{
hotList
:
[
hotList
:
[
...
...
components/TreeItem.vue
浏览文件 @
1e08f1c4
...
@@ -2,13 +2,7 @@
...
@@ -2,13 +2,7 @@
<li
class=
"tree-item"
>
<li
class=
"tree-item"
>
<div
class=
"cell"
:class=
"
{ bold: isFolder }" @click="toggle">
<div
class=
"cell"
:class=
"
{ bold: isFolder }" @click="toggle">
<div
class=
"cell-title"
>
<div
class=
"cell-title"
>
<!-- 站内跳转 -->
<app-link
:item=
"item"
>
{{
item
.
name
}}
</app-link>
<nuxt-link
:to=
"item.path"
v-if=
"item.path"
>
{{
item
.
name
}}
</nuxt-link>
<!-- 外部链接跳转 -->
<a
:href=
"item.href"
target=
"_blank"
v-else-if=
"item.href"
>
{{
item
.
name
}}
</a>
<!-- 事件 -->
<div
@
click=
"item.onClick"
v-else-if=
"item.onClick"
>
{{
item
.
name
}}
</div>
<template
v-else
>
{{
item
.
name
}}
</
template
>
</div>
</div>
<div
class=
"cell-icon"
v-if=
"isFolder"
>
<div
class=
"cell-icon"
v-if=
"isFolder"
>
<van-icon
name=
"arrow-up"
v-if=
"isOpen"
/>
<van-icon
name=
"arrow-up"
v-if=
"isOpen"
/>
...
@@ -23,10 +17,10 @@
...
@@ -23,10 +17,10 @@
<
script
>
<
script
>
import
AppLink
from
'@/components/Link'
export
default
{
export
default
{
props
:
{
props
:
{
item
:
Object
},
item
:
Object
components
:
{
AppLink
},
},
data
:
function
()
{
data
:
function
()
{
return
{
return
{
isOpen
:
false
isOpen
:
false
...
...
components/about/NewsItem.vue
浏览文件 @
1e08f1c4
<
template
>
<
template
>
<div
class=
"news-item"
>
<div
class=
"news-item"
>
<div
class=
"news-item-pic"
></div>
<nuxt-link
:to=
"`/about/news/$
{item.id}`">
<div
class=
"news-item-content"
>
<img
:src=
"item.photo_uri"
class=
"news-item-pic"
v-if=
"item.photo_uri"
/>
<div
class=
"news-item-content__date"
></div>
<div
class=
"news-item-content"
>
<div
class=
"news-item-content__title"
></div>
<div
class=
"news-item-content__date"
>
{{
formatDate
(
item
.
created_time
)
}}
</div>
</div>
<div
class=
"news-item-content__title"
>
{{
item
.
title
}}
</div>
<div
class=
"news-item-content__text"
>
{{
item
.
summary
}}
</div>
</div>
</nuxt-link>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
props
:
{
item
:
{
type
:
Object
}
},
props
:
{
item
:
{
type
:
Object
}
},
methods
:
{}
methods
:
{
formatDate
(
value
)
{
const
date
=
new
Date
(
value
)
return
date
.
getFullYear
()
+
'/'
+
date
.
getMonth
()
+
1
+
'/'
+
date
.
getDate
()
}
}
}
}
</
script
>
</
script
>
<
style
lang=
"scss"
>
<
style
lang=
"scss"
>
.news-item
{
.news-item
{
margin-bottom
:
0
.1rem
;
background-color
:
#fff
;
background-color
:
#fff
;
}
}
.news-item-pic
{
.news-item-pic
{
height
:
2
.99rem
;
display
:
block
;
width
:
100%
;
// height: 2.99rem;
object-fit
:
cover
;
}
.news-item-content
{
padding
:
0
.18rem
;
}
.news-item-content__date
{
font-size
:
0
.1rem
;
color
:
#aa1941
;
line-height
:
0
.16rem
;
}
.news-item-content__title
{
margin-top
:
0
.1rem
;
font-size
:
0
.14rem
;
font-weight
:
500
;
color
:
#333
;
line-height
:
0
.24rem
;
}
.news-item-content__text
{
margin-top
:
0
.2rem
;
font-size
:
0
.1rem
;
color
:
#424242
;
line-height
:
0
.2rem
;
}
}
</
style
>
</
style
>
components/home/Banner.vue
浏览文件 @
1e08f1c4
<
template
>
<
template
>
<van-swipe
class=
"my-swipe"
:autoplay=
"3000"
indicator-color=
"white"
>
<van-swipe
class=
"my-swipe"
:autoplay=
"3000"
indicator-color=
"white"
>
<template
v-for=
"(item, index) in list"
>
<template
v-for=
"(item, index) in list"
>
<van-swipe-item
:key=
"index"
><img
:src=
"item.src"
class=
"banner-img"
/></van-swipe-item>
<van-swipe-item
:key=
"index"
>
<nuxt-link
:to=
"`/about/news/$
{item.id}`">
<img
:src=
"item.photo_uri"
class=
"banner-img"
/></nuxt-link>
</van-swipe-item>
</
template
>
</
template
>
</van-swipe>
</van-swipe>
</template>
</template>
...
@@ -13,11 +15,9 @@ export default {
...
@@ -13,11 +15,9 @@ export default {
list
:
[]
list
:
[]
}
}
},
},
fetch
()
{
async
fetch
()
{
this
.
list
=
[
const
params
=
{
page
:
1
,
per_page
:
100
,
type
:
69
,
project_id
:
1013
}
{
src
:
'/images/banner.png'
,
href
:
''
},
this
.
list
=
await
this
.
$axios
.
$get
(
'/api/zws/v1/cms/news'
,
{
params
}).
then
(
res
=>
res
)
{
src
:
'/images/banner.png'
,
href
:
''
}
]
}
}
}
}
</
script
>
</
script
>
...
...
components/home/Degree.vue
浏览文件 @
1e08f1c4
...
@@ -15,8 +15,10 @@
...
@@ -15,8 +15,10 @@
<template
v-for=
"(item, index) in data"
>
<template
v-for=
"(item, index) in data"
>
<ul
class=
"tab-right"
:key=
"index"
v-if=
"indexActive === index"
>
<ul
class=
"tab-right"
:key=
"index"
v-if=
"indexActive === index"
>
<li
:key=
"cIndex + 'c'"
v-for=
"(cItem, cIndex) in item.content"
>
<li
:key=
"cIndex + 'c'"
v-for=
"(cItem, cIndex) in item.content"
>
<img
:src=
"cItem.icon"
class=
"icon"
/>
<app-link
:item=
"cItem"
>
<div
class=
"text"
v-html=
"cItem.text"
></div>
<img
:src=
"cItem.icon"
class=
"icon"
/>
<div
class=
"text"
v-html=
"cItem.text"
></div>
</app-link>
</li>
</li>
</ul>
</ul>
</
template
>
</
template
>
...
@@ -24,7 +26,10 @@
...
@@ -24,7 +26,10 @@
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
AppLink
from
'@/components/Link'
export
default
{
export
default
{
components
:
{
AppLink
},
data
()
{
data
()
{
return
{
return
{
indexActive
:
0
,
indexActive
:
0
,
...
@@ -36,7 +41,7 @@ export default {
...
@@ -36,7 +41,7 @@ export default {
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/e624ed7af7b49a9e04e7ac2ec95db7e1.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/e624ed7af7b49a9e04e7ac2ec95db7e1.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/8b32a69e26a4d20eaddc8bb3d6f4ccc5.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/8b32a69e26a4d20eaddc8bb3d6f4ccc5.png'
,
text
:
'海外留学<br />SHMS'
,
text
:
'海外留学<br />SHMS'
,
path
:
''
onClick
:
this
.
showTips
}
}
]
]
},
},
...
@@ -47,25 +52,25 @@ export default {
...
@@ -47,25 +52,25 @@ export default {
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/69fc809f95bd7985e13827a6dcd4dcd1.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/69fc809f95bd7985e13827a6dcd4dcd1.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/ac6cde3fb04de4c3478d02e7572fe9c9.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/ac6cde3fb04de4c3478d02e7572fe9c9.png'
,
text
:
'金融硕士<br />MSF'
,
text
:
'金融硕士<br />MSF'
,
path
:
'
'
href
:
'https://kelley.ezijing.com
'
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/ac66fee3cad3cca2b4b38ef3cceed9dc.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/ac66fee3cad3cca2b4b38ef3cceed9dc.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/8fe0f6c8995847dee420e70a21da4d3f.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/8fe0f6c8995847dee420e70a21da4d3f.png'
,
text
:
'教育学硕士
<br />MED
'
,
text
:
'教育学硕士
MED<br />(早教-蒙台梭利)
'
,
path
:
'
'
href
:
'https://cu.ezijing.com
'
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/aa2c06a74a470cbee1443e66bb6bc981.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/aa2c06a74a470cbee1443e66bb6bc981.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/db8ca58d8032f32a77a7a9deea9b417b.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/db8ca58d8032f32a77a7a9deea9b417b.png'
,
text
:
'应用心理学<br />硕士MAP'
,
text
:
'应用心理学<br />硕士MAP'
,
path
:
'
'
href
:
'https://ciis.ezijing.com
'
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/70748b8e679e7b3f40310635d9f3bae7.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/70748b8e679e7b3f40310635d9f3bae7.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/49f4eb2509433e42555754f74a4dcae2.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/49f4eb2509433e42555754f74a4dcae2.png'
,
text
:
'未来金融<br />领袖计划'
,
text
:
'未来金融<br />领袖计划'
,
path
:
'
'
href
:
'https://cfflp.ezijing.com
'
}
}
]
]
},
},
...
@@ -76,19 +81,19 @@ export default {
...
@@ -76,19 +81,19 @@ export default {
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/17ef11bc534aadf1d8e3b94fd6d4350f.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/17ef11bc534aadf1d8e3b94fd6d4350f.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/0d2ea39ee5d40200a6f513db2e9b88de.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/0d2ea39ee5d40200a6f513db2e9b88de.png'
,
text
:
'通用MBA'
,
text
:
'通用MBA'
,
path
:
''
onClick
:
this
.
showTips
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/a23695e5428a3d5e0a2f47f7d36ebb14.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/a23695e5428a3d5e0a2f47f7d36ebb14.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/a2c4b8a1f799b35f04ed618f7b47b9c1.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/a2c4b8a1f799b35f04ed618f7b47b9c1.png'
,
text
:
'金融MBA'
,
text
:
'金融MBA'
,
path
:
'
'
href
:
'https://sofia.ezijing.com
'
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/709ab2dd245369c16631a8d9ebe67006.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/709ab2dd245369c16631a8d9ebe67006.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/29917e1f3d47ca9381b5e0c397e1f082.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/29917e1f3d47ca9381b5e0c397e1f082.png'
,
text
:
'酒店与旅游工
<br/>商
管理MBA'
,
text
:
'酒店与旅游工
商<br/>
管理MBA'
,
path
:
'
'
href
:
'https://shms.ezijing.com
'
}
}
]
]
},
},
...
@@ -99,13 +104,13 @@ export default {
...
@@ -99,13 +104,13 @@ export default {
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/841ff657ca26c0f26da3e24d799ae2a5.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/841ff657ca26c0f26da3e24d799ae2a5.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/5785a4d37264a8293b956a3f065f11cf.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/5785a4d37264a8293b956a3f065f11cf.png'
,
text
:
'心理学博士<br/>(即将推出)'
,
text
:
'心理学博士<br/>(即将推出)'
,
path
:
''
onClick
:
this
.
showTips
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/aebf1f65a324cff54eb9466bf2fd0b66.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/aebf1f65a324cff54eb9466bf2fd0b66.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/526bebd1d9279c19895c5c4f1a3cfcce.png'
,
iconActive
:
'https://zws-imgs-pub.ezijing.com/static/public/526bebd1d9279c19895c5c4f1a3cfcce.png'
,
text
:
'工商管理学博士<br/>(即将推出)'
,
text
:
'工商管理学博士<br/>(即将推出)'
,
path
:
''
onClick
:
this
.
showTips
}
}
]
]
}
}
...
@@ -115,6 +120,9 @@ export default {
...
@@ -115,6 +120,9 @@ export default {
methods
:
{
methods
:
{
changeIndex
(
n
)
{
changeIndex
(
n
)
{
this
.
indexActive
=
n
this
.
indexActive
=
n
},
showTips
()
{
this
.
$notify
({
type
:
'primary'
,
message
:
'暂未开通,尽请期待'
})
}
}
}
}
}
}
...
...
components/home/Post.vue
浏览文件 @
1e08f1c4
<
template
>
<
template
>
<card
title=
"项目公告"
>
<card
title=
"项目公告"
>
<template
#
header-aside
><nuxt-link
to=
""
>
查看更多+
</nuxt-link></
template
>
<template
#
header-aside
><nuxt-link
to=
"
/about/news
"
>
查看更多+
</nuxt-link></
template
>
<div
class=
"future"
>
<div
class=
"future"
>
<div
class=
"future-left"
>
即将开始的
<br
/>
课程日期
</div>
<div
class=
"future-left"
>
即将开始的
<br
/>
课程日期
</div>
<div
class=
"future-right"
>
<div
class=
"future-right"
>
...
@@ -11,13 +11,15 @@
...
@@ -11,13 +11,15 @@
</div>
</div>
</div>
</div>
<div
class=
"list"
>
<div
class=
"list"
>
<div
class=
"list-item"
v-for=
"(item, index) in list"
:key=
"index"
>
<nuxt-link
:to=
"`/about/news/${item.id}`"
v-for=
"(item, index) in list"
:key=
"index"
>
<div
class=
"list-item__date"
>
<div
class=
"list-item"
>
<p
class=
"t1"
>
{{ formatMD(item.created_time) }}
</p>
<div
class=
"list-item__date"
>
<p
class=
"t2"
>
{{ formatYY(item.created_time) }}
</p>
<p
class=
"t1"
>
{{ formatMD(item.created_time) }}
</p>
<p
class=
"t2"
>
{{ formatYY(item.created_time) }}
</p>
</div>
<div
class=
"list-item__title"
>
{{ item.title }}
</div>
</div>
</div>
<div
class=
"list-item__title"
>
{{ item.title }}
</div>
</nuxt-link>
</div>
</div>
</div>
</card>
</card>
</template>
</template>
...
@@ -32,10 +34,7 @@ export default {
...
@@ -32,10 +34,7 @@ export default {
{
title
:
'KELLEY商学院金融硕士(MSF)开学典礼'
,
created_time
:
'2020-01-22 14:41:08'
},
{
title
:
'KELLEY商学院金融硕士(MSF)开学典礼'
,
created_time
:
'2020-01-22 14:41:08'
},
{
title
:
'酒店管理HMBA报名截止日'
,
created_time
:
'2020-01-22 14:41:08'
}
{
title
:
'酒店管理HMBA报名截止日'
,
created_time
:
'2020-01-22 14:41:08'
}
],
],
list
:
[
list
:
[]
{
title
:
'清华、交大等名校本硕博齐聚,全美第一在线金融硕士盛大开学!'
,
created_time
:
'2020-01-22 14:41:08'
},
{
title
:
'紫荆·国际金融人才论坛重磅发布“中国未来金融领袖计划”'
,
created_time
:
'2020-01-22 14:41:08'
}
]
}
}
},
},
methods
:
{
methods
:
{
...
@@ -55,7 +54,10 @@ export default {
...
@@ -55,7 +54,10 @@ export default {
return
date
.
getMonth
()
+
1
+
'/'
+
date
.
getDate
()
return
date
.
getMonth
()
+
1
+
'/'
+
date
.
getDate
()
}
}
},
},
fetch
()
{}
async
fetch
()
{
const
params
=
{
page
:
1
,
per_page
:
100
,
type
:
75
,
project_id
:
1013
}
this
.
list
=
await
this
.
$axios
.
$get
(
'/api/zws/v1/cms/news'
,
{
params
}).
then
(
res
=>
res
)
}
}
}
</
script
>
</
script
>
...
...
components/home/Service.vue
浏览文件 @
1e08f1c4
...
@@ -3,39 +3,63 @@
...
@@ -3,39 +3,63 @@
<div
class=
"service-hd"
>
教育服务
</div>
<div
class=
"service-hd"
>
教育服务
</div>
<ul
class=
"service-bd"
>
<ul
class=
"service-bd"
>
<li
v-for=
"(item, index) in data"
:key=
"index"
>
<li
v-for=
"(item, index) in data"
:key=
"index"
>
<img
:src=
"item.icon"
class=
"icon"
/>
<app-link
:item=
"item"
>
<div
class=
"text"
v-html=
"item.text"
></div>
<img
:src=
"item.icon"
class=
"icon"
/>
<div
class=
"text"
v-html=
"item.text"
></div>
</app-link>
</li>
</li>
</ul>
</ul>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
AppLink
from
'@/components/Link'
export
default
{
export
default
{
components
:
{
AppLink
},
data
()
{
data
()
{
return
{
return
{
data
:
[
data
:
[
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
e624ed7af7b49a9e04e7ac2ec95db7e1
.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
3118a654ec7f92a52b7d04f2f1f5989a
.png'
,
text
:
'1+X'
,
text
:
'1+X'
,
path
:
'
'
href
:
'https://x.ezijing.com
'
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
e624ed7af7b49a9e04e7ac2ec95db7e1
.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
7bea5e01e4e4c92e104bb1d73d313500
.png'
,
text
:
'专业共建'
,
text
:
'专业共建'
,
path
:
''
onClick
:
this
.
showTips
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
e624ed7af7b49a9e04e7ac2ec95db7e1
.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
6db512b8b2b4501651e6f9bc520d7379
.png'
,
text
:
'校企合作'
,
text
:
'校企合作'
,
path
:
''
onClick
:
this
.
showTips
},
},
{
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
e624ed7af7b49a9e04e7ac2ec95db7e1
.png'
,
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/
0e5522064d9070290b3d541a485d469f
.png'
,
text
:
'产业学院'
,
text
:
'产业学院'
,
path
:
''
onClick
:
this
.
showTips
},
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/0912f621abe188ccc84df6520a8fecf9.png'
,
text
:
'双高建设'
,
onClick
:
this
.
showTips
},
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/6cf5b6010dd7d35a80d4acc270db8a86.png'
,
text
:
'在线教育<br />解决方案'
,
onClick
:
this
.
showTips
},
{
icon
:
'https://zws-imgs-pub.ezijing.com/static/public/9603456c7edb101ec5469f92e9e21553.png'
,
text
:
'更多'
,
onClick
:
this
.
showTips
}
}
]
]
}
}
},
methods
:
{
showTips
()
{
this
.
$notify
({
type
:
'primary'
,
message
:
'暂未开通,尽请期待'
})
}
}
}
}
}
</
script
>
</
script
>
...
@@ -53,8 +77,11 @@ export default {
...
@@ -53,8 +77,11 @@ export default {
}
}
.service-bd
{
.service-bd
{
display
:
flex
;
display
:
flex
;
overflow-x
:
auto
;
overflow-y
:
hidden
;
-webkit-overflow-scrolling
:
touch
;
li
{
li
{
width
:
0
.78rem
;
min-
width
:
0
.78rem
;
height
:
1
.1rem
;
height
:
1
.1rem
;
background
:
#fff
;
background
:
#fff
;
cursor
:
pointer
;
cursor
:
pointer
;
...
...
nuxt.config.js
浏览文件 @
1e08f1c4
...
@@ -6,6 +6,9 @@ if (process.env.NODE_ENV === 'production') {
...
@@ -6,6 +6,9 @@ if (process.env.NODE_ENV === 'production') {
}
}
export
default
{
export
default
{
...
config
,
...
config
,
axios
:
{
baseURL
:
'https://project-api.ezijing.com'
},
// Global page headers: https://go.nuxtjs.dev/config-head
// Global page headers: https://go.nuxtjs.dev/config-head
head
:
{
head
:
{
title
:
'紫荆教育-在线MBA课程-MBA在线课程-专业金融在线教育品牌'
,
title
:
'紫荆教育-在线MBA课程-MBA在线课程-专业金融在线教育品牌'
,
...
...
pages/about/news/_id.vue
0 → 100644
浏览文件 @
1e08f1c4
<
template
>
<div>
<tab-nav
active=
"3"
></tab-nav>
<div
class=
"main-content news-detail"
>
<div
class=
"back"
@
click=
"back"
>
<
返回
</div>
<div
class=
"date"
>
{{
formatDate
(
data
.
created_time
)
}}
</div>
<h1
class=
"title"
>
{{
data
.
title
}}
</h1>
<div
v-html=
"data.content"
></div>
</div>
<div
class=
"related"
>
<h2
class=
"title"
>
相关推荐
</h2>
<news-item
v-for=
"item in list"
:item=
"item"
:key=
"item.id"
></news-item>
<div
class=
"more"
><nuxt-link
to=
"/about/news"
>
查看更多
</nuxt-link></div>
</div>
</div>
</
template
>
<
script
>
import
TabNav
from
'@/components/about/TabNav'
import
NewsItem
from
'@/components/about/NewsItem'
export
default
{
components
:
{
TabNav
,
NewsItem
},
data
()
{
return
{
data
:
{},
list
:
[]
}
},
computed
:
{
pid
()
{
return
this
.
$route
.
params
.
id
}
},
async
asyncData
({
$axios
,
params
})
{
// 新闻详情
const
data
=
await
$axios
.
$get
(
`/api/zws/v1/cms/news/
${
params
.
id
}
`
).
then
(
res
=>
res
)
// 相关推荐
const
requestParams
=
{
page
:
1
,
per_page
:
100
,
type
:
74
,
project_id
:
1013
}
const
list
=
await
$axios
.
$get
(
'/api/zws/v1/cms/news'
,
{
params
:
requestParams
}).
then
(
res
=>
res
)
return
{
data
,
list
}
},
methods
:
{
formatDate
(
value
)
{
const
date
=
new
Date
(
value
)
return
date
.
getFullYear
()
+
'/'
+
date
.
getMonth
()
+
1
+
'/'
+
date
.
getDate
()
},
back
()
{
this
.
$router
.
back
()
}
}
}
</
script
>
<
style
lang=
"scss"
>
.news-detail
{
padding
:
0
.2rem
0
.15rem
;
background-color
:
#fff
;
border-top
:
1px
solid
#e6e6e6
;
.back
{
font-size
:
0
.1rem
;
color
:
#424242
;
cursor
:
pointer
;
}
.date
{
margin-top
:
0
.15rem
;
font-size
:
0
.1rem
;
color
:
#9b9b9b
;
}
.title
{
margin
:
0
.1rem
0
;
padding
:
0
0
0
.1rem
;
border-bottom
:
1px
solid
#e6e6e6
;
}
img
{
display
:
block
;
max-width
:
100%
;
height
:
auto
;
margin
:
0
auto
;
}
}
.related
{
margin
:
0
0
.15rem
;
.title
{
padding
:
0
.2rem
0
;
font-size
:
0
.14rem
;
color
:
#333
;
}
.more
{
margin
:
0
.1rem
auto
0
.2rem
;
width
:
0
.82rem
;
height
:
0
.2rem
;
font-size
:
0
.1rem
;
color
:
#424242
;
line-height
:
0
.2rem
;
text-align
:
center
;
border
:
1px
solid
#d3d3d3
;
border-radius
:
0
.04rem
;
}
}
</
style
>
pages/about/news/index.vue
浏览文件 @
1e08f1c4
...
@@ -5,16 +5,33 @@
...
@@ -5,16 +5,33 @@
src=
"https://zws-imgs-pub.ezijing.com/static/public/a72ef577c9bae694c6bfc33e5bfc93af.png"
src=
"https://zws-imgs-pub.ezijing.com/static/public/a72ef577c9bae694c6bfc33e5bfc93af.png"
class=
"main-banner"
class=
"main-banner"
/>
/>
<div
class=
"news-list"
>
<news-item
v-for=
"item in list"
:item=
"item"
:key=
"item.id"
></news-item>
</div>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
TabNav
from
'@/components/about/TabNav'
import
TabNav
from
'@/components/about/TabNav'
import
NewsItem
from
'@/components/about/NewsItem'
export
default
{
export
default
{
props
:
{
acitve
:
String
},
props
:
{
acitve
:
String
},
components
:
{
TabNav
}
components
:
{
TabNav
,
NewsItem
},
data
()
{
return
{
list
:
[]
}
},
async
asyncData
({
$axios
})
{
const
params
=
{
page
:
1
,
per_page
:
100
,
type
:
74
,
project_id
:
1013
}
const
list
=
await
$axios
.
$get
(
'/api/zws/v1/cms/news'
,
{
params
}).
then
(
res
=>
res
)
return
{
list
}
}
}
}
</
script
>
</
script
>
<
style
>
<
style
lang=
"scss"
>
.news-list
{
margin
:
0
.2rem
0
.15rem
;
}
</
style
>
</
style
>
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论