初始化
This commit is contained in:
97
app/external/view/skl/detail_paying.html
vendored
Normal file
97
app/external/view/skl/detail_paying.html
vendored
Normal file
@@ -0,0 +1,97 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>页面</title>
|
||||
<style>
|
||||
/* 页面整体居中 */
|
||||
body {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
height: 100vh;
|
||||
margin: 0;
|
||||
flex-direction: column;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* 按钮样式 */
|
||||
button {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 10px 20px;
|
||||
margin: 10px;
|
||||
font-size: 16px;
|
||||
cursor: pointer;
|
||||
border: none;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
/* 按钮图标样式 */
|
||||
img {
|
||||
margin-right: 8px;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
</style>
|
||||
<script>
|
||||
// 获取 URL 中的参数
|
||||
function getInvoiceNoFromUrl(name) {
|
||||
try {
|
||||
const fullUrl = window.location.href;
|
||||
const params = new URL(fullUrl).searchParams;
|
||||
const rawValue = params.get(name);
|
||||
if (!rawValue) return "";
|
||||
return rawValue.split("?")[0];
|
||||
} catch (err) {
|
||||
return "";
|
||||
}
|
||||
}
|
||||
// 页面加载后根据 URL 参数决定显示的按钮
|
||||
window.onload = function () {
|
||||
const orderNo = getInvoiceNoFromUrl('invoiceNo');
|
||||
|
||||
// 填充订单号
|
||||
if (orderNo) {
|
||||
document.getElementById('orderNoField').innerHTML = `订单号: ${orderNo}`;
|
||||
} else {
|
||||
document.getElementById('orderNoField').innerHTML = '订单号: 未找到';
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
// 关闭页面
|
||||
function closePage() {
|
||||
window.close();
|
||||
}
|
||||
|
||||
// 刷新页面
|
||||
function refreshPage() {
|
||||
window.location.reload();
|
||||
}
|
||||
|
||||
// 加载页面内容
|
||||
function loadContent() {
|
||||
alert('加载内容');
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<!-- <h1>按钮操作</h1> -->
|
||||
|
||||
<div id="loadButton" class="hidden">
|
||||
<img src="../img/icon03.png" alt="刷新" style="width: 200px;height: 200px;">
|
||||
<div style="font-size: 18px;margin-top: 30px;">获取支付状态中...</div>
|
||||
<div style="font-size: 18px;margin-top: 30px;"><strong id="orderNoField"></strong></div>
|
||||
<button style="background-color: #d78e0e;margin-top: 30px;" onclick="refreshPage()">刷新状态</button>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user