Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart_gov_platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
smart_gov_platform
Commits
386a65bf
Commit
386a65bf
authored
Dec 18, 2023
by
“yiyousong”
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
perf: 修改站点跳转admin账号右键获取跳转信息
parent
f84a6112
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
74 additions
and
20 deletions
+74
-20
portal-manager-ui/admin/src/views/siteArrange/siteArrange.vue
...al-manager-ui/admin/src/views/siteArrange/siteArrange.vue
+74
-20
No files found.
portal-manager-ui/admin/src/views/siteArrange/siteArrange.vue
View file @
386a65bf
...
...
@@ -19,7 +19,6 @@
class=
"img-title mb-[42px]"
src=
"@/assets/images/siteArrange/title.png"
/>
-->
<h1
class=
"slogan_title"
>
{{
sloganTitle
}}
</h1>
<div
class=
"slogan"
>
建设高效便民、智慧泛在的智慧政务大厅
</div>
</div>
<!-- 站点 -->
...
...
@@ -46,7 +45,11 @@
v-for=
"(v, i) in collectList"
:key=
"'' + v.id + i"
>
<div
class=
"item-logo cursor-pointer"
@
click=
"openWindow(v)"
>
<div
class=
"item-logo cursor-pointer"
@
click=
"openWindow($event, v, 'click')"
@
contextmenu=
"openWindow($event, v)"
>
<img
class=
"w-full h-full object-contain"
:src=
"api + v.modelIcon"
...
...
@@ -92,7 +95,11 @@
v-for=
"item in v.list"
:key=
"item.id"
>
<div
class=
"item-logo cursor-pointer"
@
click=
"openWindow(item)"
>
<div
class=
"item-logo cursor-pointer"
@
click=
"openWindow(($event, item, 'click'))"
@
contextmenu=
"openWindow($event, item)"
>
<img
class=
"w-full h-full object-contain"
:src=
"api + item.modelIcon"
...
...
@@ -118,7 +125,6 @@ import { mapState } from "vuex";
export
default
{
data
()
{
return
{
sloganTitle
:
''
,
api
:
process
.
env
.
VUE_APP_API_IMG_URL
,
siteId
:
Storage
.
get
(
2
,
"
siteId
"
),
arr
:
[],
...
...
@@ -137,7 +143,6 @@ export default {
},
created
()
{
this
.
sloganTitle
=
localStorage
.
getItem
(
'
sloganTitle
'
)
this
.
getCollect
();
this
.
appsListInterface
();
},
...
...
@@ -160,7 +165,7 @@ export default {
this
.
siteModelList
=
data
;
}
},
openWindow
(
row
)
{
async
openWindow
(
event
,
row
,
type
)
{
let
siteid
=
Storage
.
get
(
2
,
"
siteId
"
)
||
0
;
let
siteName
=
Storage
.
get
(
2
,
"
siteName
"
)
||
""
;
let
userInfo
=
JSON
.
stringify
({
...
...
@@ -170,12 +175,47 @@ export default {
let
{
modelUrl
,
modelName
,
modelIcon
}
=
row
;
let
path
=
this
.
$route
.
path
;
modelName
=
encodeURI
(
modelName
);
window
.
open
(
`
${
modelUrl
}
?token=
${
this
.
token
}
&siteid=
${
siteid
}
&siteName=
${
encodeURI
(
let
params
=
`?token=
${
this
.
token
}
&siteid=
${
siteid
}
&siteName=
${
encodeURI
(
siteName
)}
&userInfo=
${
userInfo
}
&sysName=
${
modelName
}
&sysLogo=
${
modelIcon
}
&path=
${
path
}
`
,
"
_blank
"
);
)}
&userInfo=
${
userInfo
}
&sysName=
${
modelName
}
&sysLogo=
${
modelIcon
}
&path=
${
path
}
`
;
if
(
type
===
"
click
"
)
{
window
.
open
(
`
${
modelUrl
}${
params
}
`
,
"
_blank
"
);
return
;
}
if
(
this
.
userData
.
admin
||
this
.
userData
.
id
==
1
)
{
event
.
preventDefault
();
let
redirectUrl
=
""
;
let
hash
=
""
;
let
redirect
=
await
this
.
getFinalRedirect
(
modelUrl
);
if
(
!
modelUrl
.
includes
(
"
http
"
))
{
let
index
=
modelUrl
.
indexOf
(
"
/
"
);
hash
=
modelUrl
.
slice
(
index
+
1
);
}
if
(
redirect
)
{
redirectUrl
=
redirect
+
hash
;
}
else
{
redirectUrl
=
modelUrl
;
}
this
.
$notification
.
open
({
message
:
"
跳转链接
"
,
key
:
1
,
duration
:
null
,
description
:
(
<
div
>
<
div
class
=
"
notif-name
"
>
完整链接:
<
/div
>
<
div
>
{
redirectUrl
+
params
}
<
/div
>
<
div
class
=
"
notif-name
"
>
链接参数:
<
/div
>
<
div
>
{
params
}
<
/div
>
<
/div
>
),
style
:
{
"
word-break
"
:
"
break-all
"
,
},
icon
:
<
a
-
icon
type
=
"
smile
"
style
=
"
color: #108ee9
"
/>
,
});
}
},
handleJoin
()
{
...
...
@@ -233,15 +273,36 @@ export default {
}
return
false
;
},
// 获取重定向地址
getFinalRedirect
(
url
)
{
return
fetch
(
url
,
{
method
:
"
GET
"
,
redirect
:
"
follow
"
})
.
then
((
response
)
=>
{
if
(
!
response
.
ok
)
{
throw
new
Error
(
"
Network response was not ok
"
);
}
return
response
.
url
;
})
.
catch
((
error
)
=>
{
console
.
error
(
"
Error:
"
,
error
);
return
null
;
});
},
},
};
</
script
>
<
style
>
.notif-name
{
font-size
:
14px
;
font-weight
:
600
;
}
</
style
>
<
style
lang=
"less"
scoped
>
.station {
background: url("@/assets/images/siteArrange/bg_3.jpg") no-repeat;
background-size: 100% 100%;
overflow: hidden;
.del-box {
width: 100%;
height: 150px;
...
...
@@ -260,13 +321,6 @@ export default {
top: 0px;
}
.title {
.slogan_title {
font-size: 65px;
font-family: Source Han Sans CN;
font-weight: 600;
color: #ffffff;
margin-bottom: 30px;
}
.slogan {
font-size: 39px;
font-family: Source Han Sans CN;
...
...
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