Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
吴迪
gs1
Commits
b1aba396
Commit
b1aba396
authored
Dec 25, 2021
by
Lyan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
z资讯中心bug
parent
ff3dfe77
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
54 additions
and
10 deletions
+54
-10
DepthTopics.vue
src/views/News/DepthTopics.vue
+0
-1
index.vue
src/views/News/index.vue
+54
-9
No files found.
src/views/News/DepthTopics.vue
View file @
b1aba396
...
@@ -45,7 +45,6 @@ export default {
...
@@ -45,7 +45,6 @@ export default {
const
params
=
{
const
params
=
{
page
:
page
,
page
:
page
,
limit
:
this
.
tableResult
.
pageSize
,
limit
:
this
.
tableResult
.
pageSize
,
classId
:
9
};
};
const
listRes
=
const
listRes
=
await
this
.
$api
.
news
.
sdztList
(
params
);
await
this
.
$api
.
news
.
sdztList
(
params
);
...
...
src/views/News/index.vue
View file @
b1aba396
...
@@ -76,7 +76,7 @@
...
@@ -76,7 +76,7 @@
</div>
</div>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-lg-8"
>
<div
class=
"col-lg-8"
>
<img
src=
"../../assets/image/news/sdzt-tp1.png"
alt=
""
/>
<img
src=
"../../assets/image/news/sdzt-tp1.png"
alt=
""
@
click=
"goDepth"
/>
</div>
</div>
<div
class=
"col-lg-4"
>
<div
class=
"col-lg-4"
>
<ul
v-if=
"depthList.length > 0"
>
<ul
v-if=
"depthList.length > 0"
>
...
@@ -96,14 +96,14 @@
...
@@ -96,14 +96,14 @@
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-lg-4"
>
<div
class=
"col-lg-4"
>
<ul
v-if=
"videoList.length > 0"
>
<ul
v-if=
"videoList.length > 0"
>
<li
v-for=
"(tmp, i) in videoList"
:key=
"i"
@
click=
"goInfo(tmp.id)"
>
<li
v-for=
"(tmp, i) in videoList"
:key=
"i"
@
click=
"g
etVide
oInfo(tmp.id)"
>
<span></span><span>
{{
tmp
.
title
}}
</span>
<span></span><span>
{{
tmp
.
title
}}
</span>
</li>
</li>
</ul>
</ul>
<span
v-else
>
暂无数据
</span>
<span
v-else
>
暂无数据
</span>
</div>
</div>
<div
class=
"col-lg-8"
>
<div
class=
"col-lg-8"
>
<img
src=
"../../assets/image/news/jcsp-tp1.png"
alt=
""
/>
<img
src=
"../../assets/image/news/jcsp-tp1.png"
alt=
""
@
click=
"goVideo"
/>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -137,6 +137,7 @@
...
@@ -137,6 +137,7 @@
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
mapMutations
}
from
"vuex"
;
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -288,21 +289,20 @@ export default {
...
@@ -288,21 +289,20 @@ export default {
that
.
centerList
=
result
that
.
centerList
=
result
})
})
// 精彩视频
// 精彩视频
this
.
initListFn
(
7
,
10
).
then
(
function
(
result
)
{
this
.
videoListFn
()
that
.
videoList
=
result
})
//地方动态
//地方动态
this
.
initListFn
(
6
,
7
).
then
(
function
(
result
)
{
this
.
initListFn
(
6
,
7
).
then
(
function
(
result
)
{
that
.
localList
=
result
that
.
localList
=
result
})
})
//深度专题
//深度专题
this
.
initListFn
(
7
,
9
).
then
(
function
(
result
)
{
this
.
depthListFn
();
that
.
depthList
=
result
})
//top
//top
this
.
newsTop10
()
this
.
newsTop10
()
},
},
methods
:{
methods
:{
...
mapMutations
({
setMatche
:
"setMatche"
,
}),
goNewPic
(){
goNewPic
(){
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'/News/PicNews'
,
path
:
'/News/PicNews'
,
...
@@ -351,6 +351,32 @@ export default {
...
@@ -351,6 +351,32 @@ export default {
}
}
},
},
async
depthListFn
()
{
const
params
=
{
page
:
1
,
limit
:
7
,
};
const
listRes
=
await
this
.
$api
.
news
.
sdztList
(
params
);
const
{
returnCode
,
data
}
=
listRes
;
if
(
returnCode
===
"0"
)
{
this
.
depthList
=
data
.
list
}
},
async
videoListFn
()
{
const
params
=
{
page
:
1
,
limit
:
7
,
};
const
listRes
=
await
this
.
$api
.
news
.
jcspList
(
params
);
const
{
returnCode
,
data
}
=
listRes
;
if
(
returnCode
===
"0"
)
{
this
.
videoList
=
data
.
list
}
},
// 详情
// 详情
goInfo
(
id
){
goInfo
(
id
){
console
.
log
(
id
,
'id'
)
console
.
log
(
id
,
'id'
)
...
@@ -359,6 +385,7 @@ export default {
...
@@ -359,6 +385,7 @@ export default {
});
});
window
.
open
(
link
.
href
,
'_blank'
)
window
.
open
(
link
.
href
,
'_blank'
)
},
},
// top列表
// top列表
async
newsTop10
()
{
async
newsTop10
()
{
const
policyListRes
=
const
policyListRes
=
...
@@ -370,6 +397,24 @@ export default {
...
@@ -370,6 +397,24 @@ export default {
}
}
},
},
getVideoInfo
(
id
,
directpath
){
if
(
directpath
&&
directpath
!==
''
&&
directpath
.
length
>
0
){
window
.
open
(
directpath
,
'_blank'
);
}
else
{
const
matche
=
[
{
name
:
"精彩视频"
,
path
:
"/News/Video"
,
}
];
this
.
setMatche
(
matche
);
let
link
=
this
.
$router
.
resolve
({
path
:
`/News/msgVideo?id=
${
id
}
`
,
});
window
.
open
(
link
.
href
,
'_blank'
)
}
}
}
}
};
};
</
script
>
</
script
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment