Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
project-online-fi
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
project-online-fi
Commits
8213e9f5
提交
8213e9f5
authored
1月 11, 2023
作者:
matian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fi的tab修改
上级
f3d5dc92
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
147 行增加
和
61 行删除
+147
-61
4.js
data/src/goods/4.js
+0
-0
5.js
data/src/goods/5.js
+30
-0
shop.js
data/src/shop.js
+20
-6
CourseList.vue
src/modules/shop/components/CourseList.vue
+5
-1
CourseListItem.vue
src/modules/shop/components/CourseListItem.vue
+4
-0
Index.vue
src/modules/shop/views/Index.vue
+84
-52
shop.ts
src/stores/shop.ts
+4
-2
没有找到文件。
data/src/goods/4.js
0 → 100644
浏览文件 @
8213e9f5
差异被折叠。
点击展开。
data/src/goods/5.js
0 → 100644
浏览文件 @
8213e9f5
export
default
[
{
category
:
'free_course'
,
id
:
'5-1'
,
title
:
'如何全年持续成交大客户'
,
desc
:
'首席教练与一线实战伙伴,线上针对前线问题,共同研讨持续成交大客户的秘诀。有方法、有工具,有案例,有刨析。'
,
for_people
:
'从事金融服务业销售人员'
,
image_url
:
'https://webapp-pub.ezijing.com/project_online/fi/paam_banner.png'
,
type
:
'课程'
,
price
:
0
,
lecturer_list
:
[
{
name
:
'张伟'
,
avatar
:
''
,
title_list
:
[
'清华五道口金融学院硕士生导师首席经济学家'
,
'清华五道口金融学院硕士生导师首席经济学家'
]
}
],
course_card
:
'知名导师专家'
,
course_compulsory
:
6
,
course_elective
:
5
,
course_chapter
:
'56'
,
course_total_hour
:
'80'
,
course_hour
:
'8课时'
,
course_id
:
'7016965100288344064'
,
class_id
:
'7017001355222974464'
,
total_price_desc
:
'课程费用12000元/人,考试费/认证费/教材费合计980元/人'
,
sku_id
:
'7014130543629434880'
,
spu_id
:
'7014130542861877248'
}
]
data/src/shop.js
浏览文件 @
8213e9f5
...
@@ -6,16 +6,30 @@ export const SHOP_FILTERS = [
...
@@ -6,16 +6,30 @@ export const SHOP_FILTERS = [
value
:
''
value
:
''
},
},
{
{
label
:
'
PAAP(Ⅰ)认证系列课程
'
,
label
:
'
免费小课
'
,
value
:
'
PAAP(Ⅰ)
'
value
:
'
free_course
'
},
},
{
{
label
:
'
PAAP(Ⅱ)认证系列课程
'
,
label
:
'
系统小课
'
,
value
:
'
PAAP(Ⅱ)
'
value
:
'
system_course
'
},
},
{
{
label
:
'PAAM认证系列课程'
,
label
:
'PAA系列课程'
,
value
:
'PAAM'
value
:
'PAA'
,
children
:
[
{
label
:
'PAAP(Ⅰ)认证系列课程'
,
value
:
'PAAP(Ⅰ)'
},
{
label
:
'PAAP(Ⅱ)认证系列课程'
,
value
:
'PAAP(Ⅱ)'
},
{
label
:
'PAAM认证系列课程'
,
value
:
'PAAM'
}
]
},
},
{
{
label
:
'PRP'
,
label
:
'PRP'
,
...
...
src/modules/shop/components/CourseList.vue
浏览文件 @
8213e9f5
...
@@ -12,7 +12,11 @@ const page = reactive({ size: 10, currentPage: 1 })
...
@@ -12,7 +12,11 @@ const page = reactive({ size: 10, currentPage: 1 })
// 筛选之后的数据
// 筛选之后的数据
const
courseFilterList
=
$computed
(()
=>
{
const
courseFilterList
=
$computed
(()
=>
{
return
props
.
courseList
.
filter
((
item
:
any
)
=>
item
.
category
===
props
.
type
||
props
.
type
===
''
)
if
(
props
.
type
===
'PAA'
)
{
return
props
.
courseList
}
else
{
return
props
.
courseList
.
filter
((
item
:
any
)
=>
item
.
category
===
props
.
type
||
props
.
type
===
''
)
}
})
})
// 当前页的数据
// 当前页的数据
...
...
src/modules/shop/components/CourseListItem.vue
浏览文件 @
8213e9f5
...
@@ -111,6 +111,7 @@ const handleBuy = (courseItem: any) => {
...
@@ -111,6 +111,7 @@ const handleBuy = (courseItem: any) => {
position
:
absolute
;
position
:
absolute
;
top
:
10px
;
top
:
10px
;
right
:
10px
;
right
:
10px
;
text-align
:
center
;
}
}
}
}
.con_right
{
.con_right
{
...
@@ -190,6 +191,7 @@ const handleBuy = (courseItem: any) => {
...
@@ -190,6 +191,7 @@ const handleBuy = (courseItem: any) => {
line-height
:
32px
;
line-height
:
32px
;
color
:
#e2971d
;
color
:
#e2971d
;
cursor
:
pointer
;
cursor
:
pointer
;
text-align
:
center
;
}
}
.btn_buy
{
.btn_buy
{
width
:
96px
;
width
:
96px
;
...
@@ -202,6 +204,7 @@ const handleBuy = (courseItem: any) => {
...
@@ -202,6 +204,7 @@ const handleBuy = (courseItem: any) => {
color
:
#ffffff
;
color
:
#ffffff
;
margin-left
:
20px
;
margin-left
:
20px
;
cursor
:
pointer
;
cursor
:
pointer
;
text-align
:
center
;
}
}
}
}
}
}
...
@@ -241,6 +244,7 @@ const handleBuy = (courseItem: any) => {
...
@@ -241,6 +244,7 @@ const handleBuy = (courseItem: any) => {
position
:
absolute
;
position
:
absolute
;
top
:
10px
;
top
:
10px
;
right
:
10px
;
right
:
10px
;
text-align
:
center
;
}
}
}
}
.con_right
{
.con_right
{
...
...
src/modules/shop/views/Index.vue
浏览文件 @
8213e9f5
...
@@ -2,11 +2,13 @@
...
@@ -2,11 +2,13 @@
import
CourseList
from
'../components/CourseList.vue'
import
CourseList
from
'../components/CourseList.vue'
import
{
useShopStore
}
from
'@/stores/shop'
import
{
useShopStore
}
from
'@/stores/shop'
import
{
useDevice
}
from
'@/composables/useDevice'
import
{
useDevice
}
from
'@/composables/useDevice'
const
{
mobile
}
=
useDevice
()
const
{
mobile
}
=
useDevice
()
const
shopStore
=
useShopStore
()
const
shopStore
=
useShopStore
()
const
handleTabClick
=
(
tab
:
any
)
=>
{
const
activeIndex
=
ref
(
'1'
)
if
(
tab
.
index
===
'4'
)
{
const
type
=
ref
(
''
)
const
handleClickTab
=
(
val
:
any
)
=>
{
type
.
value
=
val
if
(
val
===
'PRP'
)
{
window
.
open
(
'https://prp.ezijing.com'
)
window
.
open
(
'https://prp.ezijing.com'
)
window
.
location
.
reload
()
window
.
location
.
reload
()
}
}
...
@@ -18,14 +20,31 @@ const handleTabClick = (tab: any) => {
...
@@ -18,14 +20,31 @@ const handleTabClick = (tab: any) => {
<img
src=
"https://webapp-pub.ezijing.com/project_online/fi/shop_banner.jpg"
class=
"shop_banner"
/>
<img
src=
"https://webapp-pub.ezijing.com/project_online/fi/shop_banner.jpg"
class=
"shop_banner"
/>
<div
class=
"shop_con"
>
<div
class=
"shop_con"
>
<div
class=
"con_tab"
>
<div
class=
"con_tab"
>
<el-tabs
class=
"my-tabs"
@
tab-click=
"handleTabClick"
>
<el-menu
:default-active=
"activeIndex"
mode=
"horizontal"
>
<el-tab-pane
v-for=
"(item, index) in shopStore.filters"
:key=
"index"
lazy
>
<el-menu-item
index=
"1"
@
click=
"handleClickTab(shopStore.filters[0].value)"
<template
#
label
>
>
{{
shopStore
.
filters
[
0
].
label
}}
{{
item
.
label
}}
</el-menu-item>
</
template
>
<el-menu-item
index=
"2"
@
click=
"handleClickTab(shopStore.filters[1].value)"
<CourseList
:type=
"item.value"
:courseList=
"shopStore.shopList"
:key=
"index"
/>
>
{{
shopStore
.
filters
[
1
].
label
}}
</el-tab-pane>
</el-menu-item>
</el-tabs>
<el-menu-item
index=
"3"
@
click=
"handleClickTab(shopStore.filters[2].value)"
>
{{
shopStore
.
filters
[
2
].
label
}}
</el-menu-item>
<el-sub-menu
index=
"4"
>
<template
#
title
>
{{
shopStore
.
filters
[
3
].
label
}}
</
template
>
<el-menu-item
:index=
"'4' + index"
v-for=
"(item, index) in shopStore.filters[3]?.children"
:key=
"index"
@
click=
"handleClickTab(item.value)"
>
{{ item.label }}
</el-menu-item
>
</el-sub-menu>
<el-menu-item
index=
"5"
@
click=
"handleClickTab(shopStore.filters[4].value)"
>
{{ shopStore.filters[4].label }}
</el-menu-item>
</el-menu>
<CourseList
:type=
"type"
:courseList=
"shopStore.shopList"
/>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -57,49 +76,33 @@ const handleTabClick = (tab: any) => {
...
@@ -57,49 +76,33 @@ const handleTabClick = (tab: any) => {
box-sizing
:
border-box
;
box-sizing
:
border-box
;
.con_tab
{
.con_tab
{
margin-bottom
:
20px
;
margin-bottom
:
20px
;
:deep
(
.my-tabs
)
{
:deep
(
.el-menu
)
{
text-align
:
center
;
box-shadow
:
0px
3px
18px
rgba
(
0
,
0
,
0
,
0
.1
);
box-sizing
:
border-box
;
border-radius
:
10px
;
.
el-tabs__active-bar
,
width
:
1200px
;
.
el-tabs__nav-wrap
:
:
after
{
height
:
76px
;
display
:
none
;
display
:
flex
;
}
justify-content
:
space-around
;
.el-tabs__nav
{
align-items
:
center
;
background
:
#ffffff
;
border-radius
:
6px
;
box-shadow
:
0px
3px
18px
rgba
(
0
,
0
,
0
,
0
.1
);
}
border-radius
:
10px
;
width
:
1200px
;
height
:
76px
;
display
:
flex
;
justify-content
:
space-around
;
align-items
:
center
;
border-radius
:
6px
;
}
.el-tabs__content
{
overflow
:
inherit
;
}
.el-tabs__nav-scroll
{
display
:
flex
;
align-items
:
center
;
justify-content
:
space-around
;
}
.el-tabs__item
{
:deep
(
.el-menu-item
)
{
display
:
flex
;
display
:
flex
;
align-items
:
center
;
align-items
:
center
;
justify-content
:
space-around
;
justify-content
:
space-around
;
padding
:
9px
31px
10px
26px
;
padding
:
9px
31px
10px
26px
;
border-radius
:
6px
;
border-radius
:
6px
;
border-bottom
:
none
;
border-bottom
:
none
;
font-size
:
18px
;
font-size
:
18px
;
font-weight
:
400
;
font-weight
:
400
;
color
:
#535353
;
color
:
#535353
;
box-sizing
:
border-box
;
box-sizing
:
border-box
;
height
:
50px
;
&
.is-active
{
&
.is-active
{
background-color
:
#e8c484
;
background-color
:
#e8c484
;
color
:
#ffffff
;
color
:
#ffffff
;
}
}
}
}
}
}
}
...
@@ -181,4 +184,33 @@ const handleTabClick = (tab: any) => {
...
@@ -181,4 +184,33 @@ const handleTabClick = (tab: any) => {
overflow
:
scroll
;
overflow
:
scroll
;
white-space
:
nowrap
;
white-space
:
nowrap
;
}
}
:deep
(
.el-dropdown
)
{
span
{
font-size
:
18px
;
}
}
:deep
(
.el-menu--horizontal
>
.el-menu-item.is-active
)
{
background-color
:
#e8c484
;
color
:
#fff
!
important
;
border-bottom
:
none
;
}
:deep
(
.el-sub-menu
)
{
font-size
:
18px
;
font-weight
:
400
;
color
:
#535353
;
}
:deep
(
.el-sub-menu__title
)
{
font-size
:
18px
;
font-weight
:
400
;
color
:
#535353
;
}
:deep
(
.el-menu--horizontal
>
.el-sub-menu.is-active
.el-sub-menu__title
)
{
background-color
:
#e8c484
;
color
:
#fff
!
important
;
border-bottom
:
none
;
border-radius
:
6px
;
}
:deep
(
.el-menu--horizontal
>
.el-sub-menu
.el-sub-menu__title
:hover
)
{
color
:
#535353
!
important
;
}
</
style
>
</
style
>
src/stores/shop.ts
浏览文件 @
8213e9f5
...
@@ -3,6 +3,7 @@ import { useUserStore } from './user'
...
@@ -3,6 +3,7 @@ import { useUserStore } from './user'
interface
ShopFilter
{
interface
ShopFilter
{
label
:
string
label
:
string
value
:
string
value
:
string
children
?:
any
courseList
:
any
courseList
:
any
}
}
type
ShopListItem
=
Record
<
string
,
any
>
type
ShopListItem
=
Record
<
string
,
any
>
...
@@ -37,12 +38,13 @@ export const useShopStore = defineStore('shop', () => {
...
@@ -37,12 +38,13 @@ export const useShopStore = defineStore('shop', () => {
// 相关推荐商品列表
// 相关推荐商品列表
const
shopRelatedList
=
computed
(()
=>
{
const
shopRelatedList
=
computed
(()
=>
{
return
shopList
.
value
.
filter
(
item
=>
item
.
category
!==
shopItem
.
value
?.
category
&&
item
.
type
===
'课程包'
)
return
shopList
.
value
.
filter
(
item
=>
item
.
category
!==
shopItem
.
value
?.
category
&&
item
.
type
===
'课程包'
)
})
})
const
shopRelatedListOther
=
computed
(()
=>
{
const
shopRelatedListOther
=
computed
(()
=>
{
return
shopList
.
value
.
filter
(
return
shopList
.
value
.
filter
(
(
item
:
ShopListItem
)
=>
item
.
category
===
shopItem
.
value
?.
category
&&
item
.
id
!==
shopItem
.
value
?.
id
&&
item
.
type
===
'课程'
(
item
:
ShopListItem
)
=>
item
.
category
===
shopItem
.
value
?.
category
&&
item
.
id
!==
shopItem
.
value
?.
id
&&
item
.
type
===
'课程'
)
)
})
})
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论