From 7959c035aa9b7549283138f8354acbf0abe5c1b0 Mon Sep 17 00:00:00 2001 From: lyt Date: Fri, 8 Sep 2017 16:53:34 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=8C=E6=AD=A5=E7=BD=91=E5=89=8D=E6=94=AF?= =?UTF-8?q?=E4=BB=98=E9=A1=B5=E9=9D=A2=E7=9A=84=E4=BB=A3=E7=A0=81;?= =?UTF-8?q?=E6=89=B9=E9=87=8F=E5=A4=84=E7=90=86=E9=80=9A=E7=9F=A5=E8=BE=93?= =?UTF-8?q?=E5=87=BA=E8=AE=B0=E5=BD=95=E6=80=BB=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- webht/third_party/pay/config/iPayLinks.php | 14 ++------- .../pay/controllers/iPayLinksService.php | 22 +++++-------- .../third_party/pay/views/iPayLinks_index.php | 31 ++++++++++--------- .../third_party/pay/views/iPayLinks_list.php | 16 +++++----- webht/third_party/pay/views/note_setting.php | 2 +- 5 files changed, 36 insertions(+), 49 deletions(-) diff --git a/webht/third_party/pay/config/iPayLinks.php b/webht/third_party/pay/config/iPayLinks.php index 8e74d39f..594624ef 100644 --- a/webht/third_party/pay/config/iPayLinks.php +++ b/webht/third_party/pay/config/iPayLinks.php @@ -1,13 +1,11 @@ notify_url = $this->config->item('noticeUrl'); $this->pay_info_arr['version'] = $this->query_info_arr['version'] = $this->config->item('version'); - $this->pay_info_arr['partnerId'] = $this->query_info_arr['partnerId'] = $this->config->item('partnerId'); + $this->pay_info_arr['partnerId'] = $this->query_info_arr['partnerId'] = "10000004000"; + // $this->pay_info_arr['partnerId'] = $this->query_info_arr['partnerId'] = $this->config->item('partnerId'); $this->pay_info_arr['charset'] = $this->query_info_arr['charset'] = $this->config->item('charset'); $this->pay_info_arr['signType'] = $this->query_info_arr['signType'] = $this->config->item('signType'); @@ -114,19 +114,11 @@ class IPayLinksService extends CI_Controller $data['month_html'] .= ""; } $this->get_order_info(); - $param_arr = $this->order_info_arr['goodsDesc']; + $data['description'] = $param_arr = str_replace("\n", "
", $this->order_info_arr['goodsDesc']) ; bcscale(2); $data['amount'] = strval(bcdiv($this->order_info_arr['orderAmount'], 100)); $data['currencyCode'] = $this->pay_info_arr['currencyCode']; $data['orderId'] = $this->order_info_arr['orderId']; - if (strpos($param_arr, 'Tracking Code:') !== false) { - $tmp = explode("Tracking Code:", $this->order_info_arr['goodsDesc']); - $data["track_code"] = trim(explode("Travel Advisor:", $tmp[1])[0]); - $tmp = explode("Travel Advisor:", $tmp[1]); - $tmp = explode("Content:", $tmp[1]); - $data["advisor"] = trim($tmp[0]); - $data["content"] = trim($tmp[1]); - } $this->load->view("iPayLinks_index",$data); } @@ -299,6 +291,7 @@ class IPayLinksService extends CI_Controller public function batch_send_note($pn_txn_id = false) { $data = array(); + $int = 0; //优先处理指定的交易号,用于修正交易号直接发送通知 if ( ! empty($pn_txn_id)) { @@ -432,11 +425,9 @@ class IPayLinksService extends CI_Controller //给外联发送通知邮件 $fromName = 'iPayLinks'; $fromEmail = ''; - // test $toName = !empty($opi_firstname) ? $opi_firstname : ''; $toEmail = !empty($opi_email) ? $opi_email : ''; $subject = $orderid_info->orderid . '_' . $orderid_info->ordertype . ' / ' . $item->IPL_payAmount . $item->IPL_currencyCode . ' / ' . $fromName; - // todo $body = $this->load->view('receipt_mail', $item, true); $M_RelatedInfo = $item->IPL_sn; $M_AddTime = $item->IPL_completeTime; @@ -445,7 +436,9 @@ class IPayLinksService extends CI_Controller //添加邮件发送记录 end $this->Note_model->update_send($item->IPL_dealId, 'send'); + $int++; } + echo "done. recorde count:".$int; return; } @@ -592,7 +585,8 @@ class IPayLinksService extends CI_Controller { ksort($request); unset($request['signMsg']); - $request['pkey'] = $this->config->item('pkey'); + $request['pkey'] = "30819f300d06092a864886f70d010101050003818d00308189028181008c903972be5509375edec0d6793d8d3eb533334d146069b5dfcdafd24e5c7d0a05d1774488ea257d504a18c9098d798c0f523f3ad722e3e9c32ae7fecd7e734b340b9c8ff805aa32d0a49cb6df9eca3bb6954d966f6148533a8d667aabb55b2762dcd06308c94d24d257dfdb2ad86b46702774c51e7627e5b707d52224ef794b0203010001"; + // $request['pkey'] = $this->config->item('pkey'); $param_str = ""; foreach ($request as $sysParamKey => $sysParamValue) { if ($sysParamKey == "details") { diff --git a/webht/third_party/pay/views/iPayLinks_index.php b/webht/third_party/pay/views/iPayLinks_index.php index 2d29c812..ecffd2cb 100644 --- a/webht/third_party/pay/views/iPayLinks_index.php +++ b/webht/third_party/pay/views/iPayLinks_index.php @@ -79,23 +79,24 @@
diff --git a/webht/third_party/pay/views/iPayLinks_list.php b/webht/third_party/pay/views/iPayLinks_list.php index 519505f4..c1c9bace 100644 --- a/webht/third_party/pay/views/iPayLinks_list.php +++ b/webht/third_party/pay/views/iPayLinks_list.php @@ -58,7 +58,7 @@
-
+
@@ -68,11 +68,11 @@