Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
shop_mobile_uni
Project
Project
Details
Activity
Releases
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
郑秀明
shop_mobile_uni
Commits
3e32bb97
Commit
3e32bb97
authored
Sep 16, 2020
by
王建威
Browse files
Options
Browse Files
Download
Plain Diff
冲突
parents
33c56af2
d0f03a8d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
5 deletions
+26
-5
index.html
index.html
+6
-0
web.vue
pages/web/web.vue
+20
-5
No files found.
index.html
View file @
3e32bb97
...
@@ -83,5 +83,11 @@
...
@@ -83,5 +83,11 @@
})
})
</script>
</script>
<!-- built files will be auto injected -->
<!-- built files will be auto injected -->
<!-- <script src="https://cdn.bootcss.com/vConsole/3.3.4/vconsole.min.js"></script>
<script>
// 初始化
var vConsole = new VConsole();
console.log('Hello world');
</script> -->
</body>
</body>
</html>
</html>
pages/web/web.vue
View file @
3e32bb97
<
template
>
<
template
>
<view>
<view>
<TopBar
title=
"我的合同"
/>
<TopBar
title=
"我的合同"
/>
<web-view
:src=
"url"
></web-view>
<web-view
:src=
"url"
v-if=
"url"
></web-view>
<view
v-else
class=
"empty"
>
获取合同失败,请重试~
</view>
</view>
</view>
</
template
>
</
template
>
...
@@ -15,10 +18,14 @@
...
@@ -15,10 +18,14 @@
}
}
},
},
mounted
()
{
mounted
()
{
const
obj
=
window
.
location
.
href
.
split
(
'?'
)[
1
];
let
web_href
=
window
.
location
.
href
;
const
{
contract_url
}
=
parse
(
obj
);
let
Index
=
web_href
.
indexOf
(
'contract_url'
);
if
(
Index
>
-
1
){
web_href
=
web_href
.
slice
(
Index
);
}
const
contract_url
=
web_href
.
replace
(
/contract_url=/
,
''
);
if
(
contract_url
){
if
(
contract_url
){
this
.
url
=
contract_url
;
this
.
url
=
decodeURIComponent
(
contract_url
)
;
}
else
{
}
else
{
this
.
url
=
this
.
$store
.
state
.
webviewUrl
;
this
.
url
=
this
.
$store
.
state
.
webviewUrl
;
}
}
...
@@ -26,5 +33,13 @@
...
@@ -26,5 +33,13 @@
}
}
</
script
>
</
script
>
<
style
>
<
style
lang=
"scss"
>
.empty
{
height
:
100vh
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
font-size
:
30rpx
;
color
:
#808080
;
}
</
style
>
</
style
>
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