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
9316fefa
Commit
9316fefa
authored
May 30, 2024
by
田爽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
推荐专题问题,政策法规闪动问题
parent
b766981d
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
74 additions
and
14 deletions
+74
-14
Standard.vue
src/views/Knowledge/Standard.vue
+11
-1
Statute.vue
src/views/Knowledge/Statute.vue
+11
-1
Statuteinfo.vue
src/views/Knowledge/Statuteinfo.vue
+21
-8
list2.vue
src/views/News/comps/list2.vue
+28
-2
msg.vue
src/views/News/msg.vue
+2
-1
viewsub.vue
src/views/News/viewsub.vue
+1
-1
No files found.
src/views/Knowledge/Standard.vue
View file @
9316fefa
...
...
@@ -65,7 +65,7 @@ export default {
}
},
getInfo
(
id
,
directpath
){
async
getInfo
(
id
,
directpath
){
const
matche
=
[
{
name
:
"标准文献"
,
...
...
@@ -76,6 +76,16 @@ export default {
if
(
directpath
!==
''
&&
directpath
.
length
>
0
){
window
.
open
(
directpath
,
'_blank'
);
}
else
{
const
params
=
{
id
:
id
,
token
:
this
.
$route
.
query
.
token
||
''
};
const
policyInfoRes
=
await
this
.
$api
.
knowledge
.
policyInfo
(
params
);
const
{
returnCode
,
data
,
returnMsg
}
=
policyInfoRes
;
if
(
returnCode
===
"0"
)
{
localStorage
.
setItem
(
"statute"
+
id
,
JSON
.
stringify
(
policyInfoRes
));
localStorage
.
setItem
(
"isstaList"
+
id
,
1
);
}
let
link
=
this
.
$router
.
resolve
({
path
:
`/Knowledge/Statuteinfo?id=
${
id
}
`
,
});
...
...
src/views/Knowledge/Statute.vue
View file @
9316fefa
...
...
@@ -116,7 +116,7 @@ export default {
},
getInfo
(
id
,
directpath
,
type
){
async
getInfo
(
id
,
directpath
,
type
){
// const matche=[]
// if(type===1){
// matche = [
...
...
@@ -140,6 +140,16 @@ export default {
if
(
directpath
&&
directpath
!==
''
&&
directpath
.
length
>
0
){
window
.
open
(
directpath
,
'_blank'
);
}
else
{
const
params
=
{
id
:
id
,
token
:
this
.
$route
.
query
.
token
||
''
};
const
policyInfoRes
=
await
this
.
$api
.
knowledge
.
policyInfo
(
params
);
const
{
returnCode
,
data
,
returnMsg
}
=
policyInfoRes
;
if
(
returnCode
===
"0"
)
{
localStorage
.
setItem
(
"statute"
+
id
,
JSON
.
stringify
(
policyInfoRes
));
localStorage
.
setItem
(
"isstaList"
+
id
,
1
);
}
let
link
=
this
.
$router
.
resolve
({
path
:
`/Knowledge/Statuteinfo?id=
${
id
}
`
,
});
...
...
src/views/Knowledge/Statuteinfo.vue
View file @
9316fefa
<
template
>
<div
class=
"org container"
v-loading=
"loading"
>
<div
class=
"org container"
>
<breadcrumb
/>
<div
class=
"row status-container"
v-loading=
"loading"
>
<div
class=
"row status-container"
>
<p
class=
"title-style"
v-html=
"title"
></p>
<div
class=
"showHtml"
v-html=
"content"
></div>
<div
class=
"showHtml"
v-if=
"content==''||content==null||content==undefined"
>
没有可显示的内容!
</div>
...
...
@@ -12,6 +12,7 @@
import
{
mapState
}
from
"vuex"
;
import
breadcrumb
from
"../comps/breadcrumb.vue"
;
import
pages
from
"../comps/pages2.vue"
;
import
{
Loading
}
from
'element-ui'
;
export
default
{
components
:
{
pages
,
...
...
@@ -34,16 +35,28 @@ export default {
created
()
{
this
.
policyInfoFn
();
},
mounted
()
{},
mounted
()
{
window
.
onbeforeunload
=
()
=>
{
localStorage
.
removeItem
(
'statute'
+
this
.
id
)
localStorage
.
removeItem
(
'isstaList'
+
this
.
id
)
}
},
methods
:
{
// 政策法规列表
async
policyInfoFn
()
{
this
.
loading
=
true
;
const
params
=
{
id
:
this
.
id
,
token
:
this
.
$route
.
query
.
token
||
''
};
const
policyInfoRes
=
await
this
.
$api
.
knowledge
.
policyInfo
(
params
);
let
policyInfoRes
=
{}
if
(
JSON
.
parse
(
localStorage
.
getItem
(
'isstaList'
+
this
.
id
))
&&
JSON
.
parse
(
localStorage
.
getItem
(
'isstaList'
+
this
.
id
))
==
1
){
policyInfoRes
=
localStorage
.
getItem
(
'statute'
+
this
.
id
)
?
JSON
.
parse
(
localStorage
.
getItem
(
'statute'
+
this
.
id
))
:
null
}
else
{
Loading
.
service
({
customClass
:
'el-loading-custom-class'
});
const
params
=
{
id
:
this
.
id
,
token
:
this
.
$route
.
query
.
token
||
''
};
policyInfoRes
=
await
this
.
$api
.
knowledge
.
policyInfo
(
params
);
Loading
.
service
().
close
();
}
const
{
returnCode
,
data
,
returnMsg
}
=
policyInfoRes
;
if
(
returnCode
===
"0"
)
{
if
(
data
.
directpath
&&
data
.
directpath
!==
""
&&
data
.
directpath
.
length
>
0
)
{
...
...
src/views/News/comps/list2.vue
View file @
9316fefa
...
...
@@ -3,7 +3,7 @@
<div
v-for=
"(tmp, i) in list"
:key=
"i"
class=
"list-li"
@
click=
"giveId(tmp.id,tmp.directpath)"
>
<div>
<span></span>
<span><a
:href=
"tmp.href"
v-html=
"tmp.title"
target=
"_blank"
></a></span>
<span><a
:href=
"tmp.href"
@
click
.
prevent=
"InfoFn(tmp.id, tmp.href, tmp.directpath)"
v-html=
"tmp.title"
target=
"_blank"
></a></span>
</div>
</div>
</div>
...
...
@@ -14,7 +14,33 @@ export default {
methods
:{
giveId
(
id
,
directpath
){
this
.
$emit
(
'getInfo'
,
id
,
directpath
)
}
},
async
InfoFn
(
id
,
href
,
directpath
)
{
if
(
id
===
undefined
&&
href
)
{
window
.
open
(
directpath
,
"_blank"
);
return
}
const
params
=
{
id
:
id
,
token
:
this
.
$route
.
query
.
token
||
''
};
let
listRes
=
{}
listRes
=
await
this
.
$api
.
news
.
newsTopicInfo
(
params
)
const
{
returnCode
,
data
,
returnMsg
}
=
listRes
;
if
(
returnCode
===
"0"
&&
data
!=
null
)
{
localStorage
.
setItem
(
"msg"
+
id
,
JSON
.
stringify
(
listRes
));
localStorage
.
setItem
(
"isList"
+
id
,
1
);
if
(
data
.
directpath
&&
data
.
directpath
!==
""
&&
data
.
directpath
.
length
>
0
)
{
window
.
open
(
data
.
directpath
,
"_blank"
);
localStorage
.
removeItem
(
'msg'
+
id
)
localStorage
.
removeItem
(
'isList'
+
id
)
}
else
{
window
.
open
(
href
,
'_blank'
)
}
}
else
{
window
.
open
(
href
,
'_blank'
)
}
},
}
}
</
script
>
...
...
src/views/News/msg.vue
View file @
9316fefa
...
...
@@ -353,7 +353,8 @@ export default {
// if(item.directpath&&item.directpath!==''&& item.directpath.length>0){
// item.href=item.directpath
// }else{
item
.
href
=
`/News/msg?id=
${
item
.
id
}
`
item
.
href
=
`/News/viewsub?id=
${
item
.
classid
}
`
item
.
id
=
item
.
classid
// }
});
...
...
src/views/News/viewsub.vue
View file @
9316fefa
...
...
@@ -167,7 +167,7 @@ export default {
this
.
$message
.
error
(
returnMsg
)
}
this
.
loading
=
false
Loading
.
service
().
close
();
//
Loading.service().close();
},
}
...
...
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