Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
project-online-pc
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
project-online-pc
Commits
ec5f7d2a
提交
ec5f7d2a
authored
6月 18, 2021
作者:
王鹏飞
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
bug fixes
上级
1cf4ea4c
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
12 行增加
和
13 行删除
+12
-13
ArticleList.vue
components/ArticleList.vue
+3
-5
ArticleListItem.vue
components/ArticleListItem.vue
+1
-0
Link.vue
components/Link.vue
+4
-4
TreeItem.vue
components/base/h5/TreeItem.vue
+2
-1
index.vue
components/layout/index.vue
+2
-2
course.vue
pages/about/course.vue
+0
-1
没有找到文件。
components/ArticleList.vue
浏览文件 @
ec5f7d2a
<
template
>
<div
class=
"article-list"
>
<article-list-item
v-for=
"(item, index) in dataList"
:data=
"item"
:to=
"to
"
:key=
"index"
></article-list-item>
<article-list-item
v-for=
"(item, index) in dataList"
:data=
"item"
v-bind=
"$attrs
"
:key=
"index"
></article-list-item>
<el-pagination
class=
"article-list-pagination"
layout=
"prev, pager, next"
...
...
@@ -19,14 +19,13 @@ import ArticleListItem from './ArticleListItem.vue'
export
default
{
name
:
'ArticleList'
,
components
:
{
ArticleListItem
},
inheritAttrs
:
false
,
props
:
{
remote
:
{
type
:
Object
,
default
:
()
=>
({})
},
// 是否含有翻页
hasPagination
:
{
type
:
Boolean
,
default
:
true
},
// 每页多少条数据
limit
:
{
type
:
Number
,
default
:
20
},
// 页面跳转地址
to
:
{
type
:
[
Function
,
String
,
Object
]
}
limit
:
{
type
:
Number
,
default
:
20
}
},
data
()
{
return
{
...
...
@@ -74,7 +73,6 @@ export default {
delete
params
[
key
]
}
}
console
.
log
(
params
)
this
.
loading
=
true
return
httpRequest
(
params
)
.
then
(
res
=>
{
...
...
components/ArticleListItem.vue
浏览文件 @
ec5f7d2a
...
...
@@ -18,6 +18,7 @@ import AppLink from '@/components/Link'
export
default
{
name
:
'ArticleItem'
,
components
:
{
AppLink
},
inheritAttrs
:
false
,
props
:
{
data
:
{
type
:
Object
,
required
:
true
}
},
methods
:
{
formatDate
(
value
)
{
...
...
components/Link.vue
浏览文件 @
ec5f7d2a
<
template
>
<div>
<div
class=
"app-link"
>
<!-- 外部链接跳转 -->
<a
:href=
"href"
:target=
"target"
v-if=
"href"
><slot
/></a>
<!-- 站内跳转 -->
<nuxt-link
:to=
"path"
v-else-if=
"path"
><slot
/></nuxt-link>
<!-- 事件 -->
<div
v-else-if=
"
item.onClick"
@
click=
"item
.onClick"
><slot
/></div>
<div
v-else-if=
"
data.onClick"
@
click=
"data
.onClick"
><slot
/></div>
<template
v-else
><slot
/></
template
>
</div>
</template>
...
...
@@ -15,7 +15,7 @@ export default {
name
:
'Link'
,
props
:
{
data
:
{
type
:
Object
,
default
:
()
=>
({})
},
to
:
{
type
:
[
Function
,
String
,
Object
]
}
,
to
:
[
String
,
Object
,
Function
]
,
target
:
{
type
:
String
,
default
:
'_blnak'
}
},
computed
:
{
...
...
@@ -23,7 +23,7 @@ export default {
return
this
.
data
.
href
||
this
.
data
.
uri
},
path
()
{
if
(
Array
.
isArray
(
this
.
to
)
)
{
if
(
typeof
this
.
to
===
'function'
)
{
return
this
.
to
(
this
.
data
)
}
return
this
.
data
.
path
||
this
.
to
...
...
components/base/h5/TreeItem.vue
浏览文件 @
ec5f7d2a
...
...
@@ -18,10 +18,11 @@
<
script
>
import
TreeItem
from
'./TreeItem'
import
AppLink
from
'@/components/Link'
export
default
{
name
:
'TreeItem'
,
props
:
{
item
:
Object
},
components
:
{
TreeItem
},
components
:
{
TreeItem
,
AppLink
},
data
:
function
()
{
return
{
isOpen
:
false
...
...
components/layout/index.vue
浏览文件 @
ec5f7d2a
...
...
@@ -3,8 +3,8 @@
</
template
>
<
script
>
import
PC
from
'./pc'
import
H5
from
'./h5'
import
PC
from
'./pc
/Index
'
import
H5
from
'./h5
/Index
'
export
default
{
components
:
{
PC
,
H5
},
computed
:
{
...
...
pages/about/course.vue
浏览文件 @
ec5f7d2a
...
...
@@ -30,7 +30,6 @@ export default {
},
data
()
{
return
{
pageOptions
,
courseData
:
[
{
title
:
this
.
$t
(
'setCourse.tit1'
),
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论