You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
dongfeng-pay/jhboss/views/self_notify.html

131 lines
4.8 KiB
Go

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title></title>
<link rel="stylesheet" type="text/css" href="../static/css/basic.css">
<link rel="stylesheet" type="text/css" href="../static/lib/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="../static/lib/bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css">
<script src="../static/js/filter.js"></script>
<script src="../static/js/jquery.min.js"></script>
<script src="../static/lib/bootstrap/js/bootstrap.min.js"></script>
<script src="../static/lib/bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
<script src="../static/lib/bootstrap-datetimepicker/js/locales/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="../static/js/basic.js"></script>
<style>
.search label {
font-weight: normal;
padding-right: 20px;
}
.order-record .search div {
height: 20px;
}
#search-order-supplier-name, #select-merchant-name,#search-notify-pay-type {
height: 30px;
line-height: 30px;
}
</style>
</head>
<body>
<div class="self_notify">
<div class="search form-inline">
<label for="">
<span></span>
<input type="text" name="" id="search-notify-start-time" class="start-time" value="">
</label>
<label for="">
<span></span>
<input type="text" name="" id="search-notify-end-time" class="end-time" value="">
</label>
<label for="">
<span></span>
<select name="" id="select-merchant-name">
</select>
</label>
<label for="">
<span></span>
<select name="" id="search-order-supplier-name">
</select>
</label>
<label for="">
<span></span>
<select name="" id="notify-type">
<option value=""></option>
<option value="order"></option>
<option value="payfor"></option>
</select>
</label>
<label for="">
<input type="button" class="btn btn-primary" value="开始" onclick="startNotify()">
</label>
</div>
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title"></h3>
</div>
<div class="panel-body" style="color: red;">
</div>
</div>
<script>
function getSearchValues() {
let startTime = $("#search-notify-start-time").val();
let endTime = $("#search-notify-end-time").val();
let merchantUid = $("#select-merchant-name").val();
let notifyType = $("#notify-type").val();
return {
"startTime": startTime,
"endTime":endTime,
"merchantUid":merchantUid,
"notifyType":notifyType
};
}
function sendNotify(bankOrderId) {
$.ajax({
url:"/self/send/notify",
data: {
"bankOrderId":bankOrderId
},
success: function () {
}
});
}
function startNotify() {
if (!confirm("是否开始执行批量回调操作")){
return;
}
let dataJSON = getSearchValues();
$.ajax({
url: "/get/notify/bankOrderId/list",
data: dataJSON,
success: function (res) {
if (res.Code == 404){
window.parent.location = "/login.html";
} else if (res.Code == 200) {
$(".panel-body").html("回调处理中......");
for (let i = 0; i < res.NotifyIdList.length; i++) {
sendNotify(res.NotifyIdList[i]);
$(".panel-body").html("回调完毕");
}
}
},
error: function () {
alert("系统异常,请稍后再试");
}
});
}
$(function () {
let day = new Date(new Date().getTime() - 86400000);
let s = dateFtt("yyyy-MM-dd hh:mm:ss", day);
$("#search-notify-start-time").val(s);
setSupplier();
setMerchant();
/*let dataJSON = getOrderSearchValues();
AjaxOrderList(dataJSON);*/
});
</script>
</body>
</html>