diff --git a/webht/third_party/pay/controllers/AlipayTradeService.php b/webht/third_party/pay/controllers/AlipayTradeService.php index e181633c..2ea85eb0 100644 --- a/webht/third_party/pay/controllers/AlipayTradeService.php +++ b/webht/third_party/pay/controllers/AlipayTradeService.php @@ -97,7 +97,7 @@ class AlipayTradeService extends CI_Controller * @date 2017-09-13 * @return [type] [description] */ - public function alipay_notice() + public function alipay_notice($site = 'cht') { error_reporting(0); $resp_arr = $this->input->post(); @@ -958,7 +958,7 @@ class AlipayTradeService extends CI_Controller /** * 验签方法 * @param $arr 验签支付宝返回的信息,使用支付宝公钥。 - * @return boolean + * @return obj */ function check($arr){ $ret = new ArrayObject(); @@ -1120,7 +1120,7 @@ class AlipayTradeService extends CI_Controller } $data["paytext"] = $this->payment_status(); $order_sn = empty($data['order_info']) ? 0 : $data['order_info']->COLI_SN; - $data['group_accout_info'] = + $data['group_accout_info'] = $this->Alipay_model->get_group_accout_info($order_sn, $data['note']->ALI_dealId); echo json_encode($this->load->view('alipay_note_setting', $data, true)); } diff --git a/webht/third_party/pay/models/Alipay_note_model.php b/webht/third_party/pay/models/Alipay_note_model.php index 040a16a7..6cbd3b2b 100644 --- a/webht/third_party/pay/models/Alipay_note_model.php +++ b/webht/third_party/pay/models/Alipay_note_model.php @@ -166,7 +166,23 @@ class Alipay_note_model extends CI_Model { return FALSE; } } else { - return $query->result(); + $result = $query->result(); + array_walk($result, 'Alipay_note_model::set_fundsource'); + return $result; + } + } + + private $code_fundsource = array( + "2021004129643221" => "Trippest", + "2017092108849921" => "", // "CHT", + ); + public function set_fundsource(&$ele) + { + $ele->fundsource = ""; + $raw = json_decode($ele->ALI_memo); + $app_id = isset($raw->app_id) ? $raw->app_id : '2017092108849921'; + if ($this->code_fundsource[$app_id]) { + $ele->fundsource = $this->code_fundsource[$app_id]; } } diff --git a/webht/third_party/pay/views/alipay_list.php b/webht/third_party/pay/views/alipay_list.php index 02584e14..d88d2279 100644 --- a/webht/third_party/pay/views/alipay_list.php +++ b/webht/third_party/pay/views/alipay_list.php @@ -63,6 +63,9 @@ .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;} .center-block{display: block;margin: 0 auto;} + .brand_text {color: #fff; padding: 2px 3px; border-radius: 4px;font-style: italic;} + .cht-color {background-color: #A31022;} + .trippest-color {background-color: #E83201;}