Merge branch 'feature/pay'

feature/pay
lyt 6 years ago
commit 56f28b6464

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -0,0 +1,59 @@
<form action="/webht.php/apps/pay/paymentService/gai_modal_save" method="post" id="form_modal_gai" name="form_modal_gai">
<?php if ( ! empty($gai_info)) { ?>
<p>已录入订单 <?php echo!empty($old_order) ? $old_order : ""; ?></p>
<table class="table table-hover table-bordered">
<thead>
<th>订单号</th>
<th>申请金额/币种</th>
<th>实收金额</th>
</thead>
<?php foreach ($gai_info as $key => $value) { ?>
<tr>
<td><?php echo $value->GAI_COLI_ID; ?></td>
<td><?php echo $value->GAI_SQJE; ?>&nbsp;<?php echo $value->GAI_SQJECurrency; ?></td>
<td><?php echo $value->GAI_SSJE; ?>&nbsp;CNY</td>
</tr>
<?php } ?>
</table>
<p>撤回以上订单收款记录, 并转移到订单: (手动录入的不会撤回) </p>
<?php } else { ?>
<dl class="dl-horizontal">
<dt>交易号</dt>
<dd><?php echo $note->OPN_transactionId ?> ( <?php echo strtoupper($note->OPN_noticeType) . " " . $note->OPN_transactionResult; ?> )</dd>
</dl>
<dl class="dl-horizontal">
<dt>付款金额</dt>
<dd><?php echo $note->OPN_currency . ' ' . $note->OPN_orderAmount ?></dd>
</dl>
<dl class="dl-horizontal">
<dt>付款时间</dt>
<dd><?php echo $note->OPN_completeTime; ?></dd>
</dl>
<?php } ?>
<div class="input-group">
<input type="text" class="form-control" id="pn_invoice" name="pn_invoice" value="<?php echo !empty($new_order) ? $new_order : $old_order; ?>" placeholder="输入订单号搜索匹配" >
<span class="input-group-addon search-btn" onclick="show_gai_modal('<?php echo $note->OPN_SN; ?>', $('#pn_invoice').val())"></span>
</div>
<label class="text-danger">订单号形如: 160414408_B , B商务订单JJ160321052_T,T传统订单请务必加上后缀</label>
<div>订单详细内容: </div>
<p>
<?php
if (!empty($order_info)) {
echo "COLI_SN => $order_info->COLI_SN<br/>";
echo "COLI_ID => $order_info->COLI_ID<br/>";
echo "OPI_Email => $order_info->OPI_Email<br/>";
echo "OPI_Name => $order_info->OPI_Name<br/>";
echo!empty($order_info->COLI_GroupCode) ? "COLI_GroupCode => $order_info->COLI_GroupCode<br/>" : false;
echo!empty($order_info->COLI_OrderDetailText) ? "COLI_OrderDetailText => $order_info->COLI_OrderDetailText\n" : false;
} else {
echo '找不到目标订单内容';
}
?>
</p>
<input type="hidden" name="pn_txn_id" id="pn_txn_id" value="<?php echo $note->OPN_transactionId; ?>" />
<input type="hidden" name="pn_id" id="pn_id" value="<?php echo $note->OPN_SN; ?>" />
</form>
<div class="dl-horizontal">
<p><a href="javascript:void(0);" onclick="$('#note_original_data').toggle()" >原始数据</a></p>
<p> <span style="display: none;" id="note_original_data"><?php echo str_replace('","', '"<br/>"', $note->OPN_rawContent); ?></span></p>
</div>

@ -0,0 +1,303 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta content="width=device-width, initial-scale=1.0, user-scalable=no" name="viewport">
<meta content="yes" name="apple-mobile-web-app-capable">
<meta name="referrer" content="always">
<title>Payment List - China Highlights</title>
<script src="http://www.mycht.cn/min?f=/js/jquery.min.js,/js/bootstrap.min.js,/js/navigation.js,/js/jquery.form.min.js"></script>
<link href="/css/webht/bootstrap.min.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" href="/css/webht/flatpicker.min.css">
<style type="text/css" media="screen and (max-width:767px)"></style>
<style type="text/css">
.export_form_area{display: inline-block;padding: 6px;border: 1px solid #ccc;background-color: #ccc;/*position: absolute;top: 0;left: 17%;*/}
.trigger_export_btn{position: absolute;top: 0;left: 50%;}
.modal-dialog{width: 1024px;}
.navbar-header h1 {display: inline-block;margin-left: 30px;margin-right: 30px;}
.input-group-btn{border: 1px solid #ccc;padding: 5px;}
.search-btn{cursor: pointer; background: url(//data.chinahighlights.com/css/images/global/site-search-button.png) no-repeat center center;}
.input-check{width: 20px;height: 20px;}
label span{vertical-align: super;}
</style>
</head>
<body>
<!-- Button trigger modal -->
<!-- 先隐藏 -->
<button type="button" class="btn btn-primary trigger_export_btn hidden" data-toggle="modal" data-target="#exampleModal">
导出收款记录 &gt;
</button>
<!-- Modal -->
<div class="modal fade" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="exampleModalLabel">导出 Paypal 记录</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<form class="form-horizontal" role="form" method="post" id="search_list" action="/webht.php/apps/paypal/index/export_list/">
<div class="form-group row">
<label for="from_date" class="col-md-4">使用上次</label>
<div class="col-md-16">
<select class="form-control" id="date_history" name="date_history" onchange="set_start_date(this)">
<option value="">选择一个开始记录</option>
<?php
if ( ! empty($record_flags)) {
foreach ($record_flags as $kf => $vf) {
echo "<option value=\"$vf->TEL_SN@" . strstr($vf->TEL_transactionDate, " ", true) . "@" . $vf->TEL_transactionCurrency . "\">"
. " [" . strstr($vf->TEL_exportDate, " ", true) . "] "
. $vf->TEL_transactionCurrency . " " . $vf->TEL_transactionAmount . ' - '. $vf->TEL_exportAmount
. " / " . $vf->TEL_orderId . ' / '
. substr($vf->TEL_transactionDate,0,16)
. "</option>";
}
}
?>
</select>
</div>
</div>
<div class="form-group row">
<label for="from_date" class="col-md-4">Date From</label>
<div class="col-md-16">
<input type="text" class="form-control col-md-8" id="from_date" name="from_date" placeholder="开始日期" required>
</div>
</div>
<div class="form-group row">
<label for="to_date" class="col-md-4">To</label>
<div class="col-md-16">
<input type="text" class="form-control" id="to_date" name="to_date" placeholder="结束日期" required>
</div>
</div>
<div class="form-group row">
<label for="currency" class="col-md-4">Currency</label>
<div class="col-md-16">
<select class="form-control" id="currency" name="currency" required>
<option value="">所有币种</option>
<option value="CNY">CNY</option>
<option value="USD">USD</option>
<option value="EUR">EUR</option>
<option value="CAD">CAD</option>
<option value="AUD">AUD</option>
<option value="GBP">GBP</option>
<option value="NZD">NZD</option>
<option value="SGD">SGD</option>
<option value="CHF">CHF</option>
</select>
</div>
</div>
<div class="form-group row">
<label for="set_amount" class="col-md-4">总金额(元)</label>
<div class="col-md-16">
<input type="number" class="form-control" id="set_amount" name="set_amount" placeholder="总金额" onkeyup="set_target_amount(this)">
</div>
</div>
<div class="form-group">
<div class="col-sm-24 ">
<button type="submit" class="btn btn-primary center-block">导出</button>
</div>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
</div>
</div>
</div>
</div>
<div id="wrapper" class="chkVisible print-none">
<div class="navbar-header" style="float:none;border-bottom: 1px solid #ccc;">
<a class="navbar-brand text-muted" style="height: 52px;padding-top: 7px;padding-left: 30px;" href="https://www.mycht.cn/webht.php/index/index">
<img width="150" style="height:40px;" src="/css/nav/img/6000.png">
</a>
<h1>Payment List</h1>
<label>
<input type="checkbox" name="" value="15016" checked readonly class="input-check"><span>微信</span>
</label>
<ul class="nav navbar-nav navbar-right pull-right" style="margin:7.5px 0;">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"><?php $userdata=$this->session->userdata('admin_chtcdn'); echo $userdata['OPI_Name']; ?> <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li><a href="<?php echo site_url('login/logout'); ?>">退出</a></li>
</ul>
</li>
</ul>
</div>
</div>
<div class="" id="content">
<div class="container-fluid marginTop">
<div class="row">
<!-- left -->
<div class="col-md-4 col-xs-24 print-none">
<div class="row">
<form method="post" id="search_note_list" action="/webht.php/apps/pay/paymentservice/note_list/">
<div class="input-group">
<input type="text" name="keywords" value="<?php echo isset($keywords) ? $keywords : ''; ?>" class="form-control" placeholder="订单号" style="height: 33px;-webkit-box-shadow: inset 0 0px 0px rgba(0,0,0,0.075);box-shadow: inset 0 0px 0px rgba(0,0,0,0.075);border-bottom:1px solid #ddd;">
<span class="input-group-addon search-btn" onclick="$('#search_note_list').submit();"></span>
</div>
<div id="datepicker"></div>
</form>
</div>
<p class="btn-lg"></p>
<ul class="list-unstyled hidden-xs links">
<li><a class="text-primary" href="/webht.php/apps/pay/paymentservice/note_list">&gt;全部收款邮件</a></li>
<li class="btn-sm"></li>
<li><a class="text-primary" href="/webht.php/apps/pay/paymentservice/note_faillist" >&gt;错误通知列表</a></li>
<li class="btn-sm"></li>
<li><a class="text-primary" href="/webht.php/apps/pay/paymentservice/send_notify" target="_blank">&gt;手动处理通知</a></li>
<li class="btn-sm"></li>
<li><a class="text-primary" href="http://share.chtcdn.com/info.php/sendmail/send_mail" target="_blank">&gt;发送邮件</a></li>
<li class="btn-lg"></li>
</ul>
<div class="well well-sm hidden-xs" >
<h4>通知状态:</h4>
<p>1.send 表示通知正确发送给外联</p>
<p>2.unsend 表示通知在等待处理5~10分钟系统处理一遍</p>
<p>3.sendfail 状态的需要手工设置正确的订单号</p>
<p>4.Pending 还未到账,需要人工检查,确认支付或者取消,需要手工关闭此通知</p>
<p>5.Denied 银行拒付,需要手工关闭此通知</p>
</div>
</div>
<!-- left end -->
<div class=" pay_form_div col-sm-20 col-xs-24" style="min-height:1024px;border-left:1px solid #ddd;">
<table class="table table-bordered table-hover">
<thead>
<tr>
<th>#</th>
<th>主题</th>
<th>付款人</th>
<th>交易号</th>
<th>收单时间</th>
<th>通知时间</th>
<th>状态[通知/记录]</th>
</tr>
</thead>
<tbody>
<?php
foreach ($notelist as $key => $item) {
?>
<tr>
<td><?php echo $key+1; ?></td>
<td><?php echo $item->OPN_orderId . ' / ' . $item->OPN_orderAmount . $item->OPN_currency; ?></td>
<td>
<?php
echo $item->OPN_payerEmail;
?>
</td>
<td><?php echo $item->OPN_transactionId; ?></td>
<td><?php echo $item->OPN_acquiringTime; ?></td>
<td><?php echo $item->OPN_noticeTime; ?></td>
<td>
<?php
$send_text = '';$send_class='';
if ($item->OPN_accountStatus !== 'recorded') {
$send_class = 'btn-danger';
}
if ($item->OPN_noticeSendStatus !== 'send' ) {
$send_class = 'btn-danger';
}
if ($item->OPN_noticeSendStatus === 'closed') {
$send_class = '';
}
?>
<?php if ($item->OPN_noticeType !== 'pay') {
echo '<span class=text-danger >' . strtoupper($item->OPN_noticeType) . '</span><br>';
} ?>
<a href="javascript:void(0);" class="btn btn-sm <?php echo $send_class; ?>" onclick="show_gai_modal('<?php echo $item->OPN_SN; ?>')">
<?php echo $item->OPN_noticeSendStatus .' / ' . $item->OPN_accountStatus; ?>
</a>
</td>
</tr>
<?php } ?>
</tbody>
</table>
</div>
<!-- right end -->
</div>
</div>
</div>
<!-- 收款记录详情 -->
<div class="modal" id="modal_set_gai" tabindex="-1" role="dialog" aria-labelledby="gaiModalLabel">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span></button>
<h4 class="modal-title" id="gaiModalLabel">收款记录</h4>
</div>
<div class="modal-body" id="modal_set_gai_body">
...
</div>
<div class="modal-footer">
<button type="button" class="btn btn-warning pull-left" onclick="close_gai()" >忽略此条收款</button>
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
<button type="button" class="btn btn-warning" onclick="submit_gai_modal()">保存</button>
</div>
</div>
</div>
</div>
</body>
<script type="text/javascript" src="/js/flatpickr-4.4.4.min.js"></script>
<script type="text/javascript">
$(document).ready(function() {
$("#datepicker").flatpickr({
inline: true,
dateFormat: "Y-m-d",
defaultDate: "<?php echo $date; ?>",
onChange: function (selectedDates, dateStr, instance) {
window.location.href = '/webht.php/apps/pay/paymentservice/note_list?date=' + dateStr;
}
});
})
function show_gai_modal(pn_id, new_order) {
var url = '/webht.php/apps/pay/paymentservice/gai_modal/' + pn_id;
if (new_order) url += '/' + new_order;
$.ajax({
type: "get",
dataType: "json",
url: url,
success: function(data, textStatus) {
$('#modal_set_gai_body').html(data);
$('#modal_set_gai').modal('show');
},
error: function(msg) {
alert('\u53d1\u751f\u9519\u8bef\uff0c\u8bf7\u8054\u7cfbYoyo...');
}
});
}
function close_gai() {
var pn_id = $('#pn_id').val();
var pn_txn_id = $('#pn_txn_id').val();
if (confirm('是否忽略此记录: ' + pn_txn_id)) {
$.ajax({
type: "get",
dataType: "json",
url: '/webht.php/apps/pay/paymentservice/close_gai/' + pn_id,
success: function(data, textStatus) {
alert(data);
},
error: function(msg) {
alert('\u53d1\u751f\u9519\u8bef\uff0c\u8bf7\u8054\u7cfbYOYO...');
}
});
}
}
function submit_gai_modal() {
$('#form_modal_gai').ajaxSubmit({
success: function(data, textStatus) {
alert(data);
},
error: function(msg) {
alert('\u53d1\u751f\u9519\u8bef\uff0c\u8bf7\u8054\u7cfbYOYO...');
},
dataType: 'json',
timeout: 30000
});
return false;
}
</script>
</html>
Loading…
Cancel
Save