ipaylinks 查询异步通知记录, 增加使用IPL表的key字段

原因: ipaylinks 2018-07-23升级系统后通知得到的交易号不准确
feature/trippest
lyt 7 years ago
parent 895c429410
commit 31b064474d

@ -900,11 +900,11 @@ class IPayLinksService extends CI_Controller
} }
//获取note详情以便后续修改各项数据 //获取note详情以便后续修改各项数据
public function note_modal($pn_txn_id = false, $pn_invoice = false ,$notice_time = false) { public function note_modal($pn_txn_id = false, $pn_invoice = false, $pn_id = null) {
$data = array(); $data = array();
$data['IPL_orderId'] = $pn_invoice; $data['IPL_orderId'] = $pn_invoice;
if (!empty($pn_txn_id)) { if (!empty($pn_txn_id)) {
$data['note'] = $this->Note_model->note($pn_txn_id); $data['note'] = $this->Note_model->note($pn_txn_id, $pn_id);
if (!empty($data['note'])) { if (!empty($data['note'])) {
if (!empty($pn_invoice)) { if (!empty($pn_invoice)) {
$orderid_info = $this->analysis_orderid($pn_invoice); $orderid_info = $this->analysis_orderid($pn_invoice);

@ -48,10 +48,11 @@ class Note_model extends CI_Model {
return $this->get_list(); return $this->get_list();
} }
public function note($txn_id){ public function note($txn_id, $pn_id=null){
$this->init(); $this->init();
$this->topnum=1; $this->topnum=1;
$this->dealId=" AND IPL_dealId=".$this->INFO->escape($txn_id); $this->dealId=" AND IPL_dealId=".$this->INFO->escape($txn_id);
$this->dealId .= ($pn_id===null) ? " " : " AND IPL_sn=" . $pn_id;
return $this->get_list(); return $this->get_list();
} }

@ -166,7 +166,7 @@
$class_css = 'btn-danger'; $class_css = 'btn-danger';
$show_send = $item->IPL_sent; $show_send = $item->IPL_sent;
} }
?><a href="javascript:void(0);" title="<?php echo $item->IPL_resultMsg; ?>" onclick="show_order_modal('<?php echo $item->IPL_dealId; ?>', '<?php echo $item->IPL_orderId; ?>','<?php echo $item->IPL_noticeTime; ?>','<?php echo $item->IPL_orderId; ?>')" class="btn btn-sm <?php echo $class_css; ?>"><?php echo $show_send; ?></a> ?><a href="javascript:void(0);" title="<?php echo $item->IPL_resultMsg; ?>" onclick="show_order_modal('<?php echo $item->IPL_dealId; ?>', '<?php echo $item->IPL_orderId; ?>','<?php echo $item->IPL_noticeTime; ?>','<?php echo $item->IPL_orderId; ?>', '<?php echo $item->IPL_sn; ?>')" class="btn btn-sm <?php echo $class_css; ?>"><?php echo $show_send; ?></a>
</li> </li>
</ul> </ul>
@ -253,12 +253,12 @@
return date; return date;
} }
}); });
function show_order_modal(pn_txn_id, pn_invoice,noticeTime,old_order) { function show_order_modal(pn_txn_id, pn_invoice,noticeTime,old_order, pn_id) {
if (pn_txn_id) { if (pn_txn_id) {
$.ajax({ $.ajax({
type: "get", type: "get",
dataType: "json", dataType: "json",
url: '/webht.php/apps/pay/ipaylinksservice/note_modal/' + pn_txn_id + '/' + pn_invoice, url: '/webht.php/apps/pay/ipaylinksservice/note_modal/' + pn_txn_id + '/' + pn_invoice + '/' + pn_id,
success: function(data, textStatus) { success: function(data, textStatus) {
$('#modal_set_orderid_body').html(data); $('#modal_set_orderid_body').html(data);
$('#modal_set_orderid').modal('show'); $('#modal_set_orderid').modal('show');

Loading…
Cancel
Save