Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
U
uniapp_friends
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
h5
uniapp_friends
Commits
3db4339a
Commit
3db4339a
authored
Feb 10, 2025
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
b1889043
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
43 additions
and
24 deletions
+43
-24
pages.json
friends/pages.json
+2
-23
cashBag.vue
friends/pagesD/cashBag/cashBag.vue
+1
-1
h5alipay.vue
friends/pagesD/h5alipay/h5alipay.vue
+40
-0
No files found.
friends/pages.json
View file @
3db4339a
...
@@ -39,28 +39,7 @@
...
@@ -39,28 +39,7 @@
"navigationBarTextStyle"
:
"white"
"navigationBarTextStyle"
:
"white"
}
}
}
}
,{
],
"path"
:
"uni_modules/uni-pay/pages/success/success"
,
"style"
:
{
"backgroundColor"
:
"#F8F8F8"
,
"navigationBarTitleText"
:
"支付成功"
}
}
,{
"path"
:
"uni_modules/uni-pay/pages/ad-interactive-webview/ad-interactive-webview"
,
"style"
:
{
"backgroundColor"
:
"#F8F8F8"
,
"navigationBarTitleText"
:
"ad"
}
}
,{
"path"
:
"uni_modules/uni-pay/pages/pay-desk/pay-desk"
,
"style"
:
{
"backgroundColor"
:
"#F8F8F8"
,
"navigationBarTitleText"
:
"收银台"
}
}
],
//
分包配置
//
分包配置
"subPackages"
:
[{
"subPackages"
:
[{
"root"
:
"pagesA"
,
"root"
:
"pagesA"
,
...
@@ -232,7 +211,7 @@
...
@@ -232,7 +211,7 @@
"navigationBarTextStyle"
:
"black"
"navigationBarTextStyle"
:
"black"
}
}
},
{
},
{
"path"
:
"
alipay/
alipay"
,
"path"
:
"
h5alipay/h5
alipay"
,
"style"
:
{
"style"
:
{
"navigationStyle"
:
"default"
,
"navigationStyle"
:
"default"
,
"navigationBarTitleText"
:
"支付宝支付"
,
"navigationBarTitleText"
:
"支付宝支付"
,
...
...
friends/pagesD/cashBag/cashBag.vue
View file @
3db4339a
...
@@ -156,7 +156,7 @@
...
@@ -156,7 +156,7 @@
pid
:
vipBean
.
pid
pid
:
vipBean
.
pid
}).
then
(
data
=>
{
}).
then
(
data
=>
{
// openUrl(data.params.params)
// openUrl(data.params.params)
navigateTo
(
`/pagesD/
alipay/
alipay?url=`
+
data
.
params
.
params
)
navigateTo
(
`/pagesD/
h5alipay/h5
alipay?url=`
+
data
.
params
.
params
)
})
})
.
catch
((
err
)
=>
{
.
catch
((
err
)
=>
{
message
.
notify
(
err
)
message
.
notify
(
err
)
...
...
friends/pagesD/h5alipay/h5alipay.vue
0 → 100644
View file @
3db4339a
<
template
>
<view
class=
"container"
>
<!-- 使用 web-view 组件加载包含表单的 HTML 内容 -->
<web-view
:src=
"formUrl"
@
message=
"handleWebViewMessage"
></web-view>
</view>
</
template
>
<
script
>
export
default
{
data
()
{
return
{
formUrl
:
''
};
},
onLoad
(
options
)
{
// 将 HTML 内容转换为 base64 编码的 URL
const
base64Html
=
btoa
(
unescape
(
encodeURIComponent
(
options
.
url
)));
this
.
formUrl
=
`data:text/html;base64,
${
base64Html
}
`
;
},
methods
:
{
handleWebViewMessage
(
e
)
{
// 处理 web-view 传递过来的消息,可根据实际需求添加逻辑
console
.
log
(
'Received message from web-view:'
,
e
.
detail
.
data
);
}
}
};
</
script
>
<
style
scoped
>
.container
{
width
:
100%
;
height
:
100%
;
}
web-view
{
width
:
100%
;
height
:
100%
;
}
</
style
>
\ No newline at end of file
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