@@ -19,7 +19,7 @@ |
||
19 | 19 | public function getDefaultParameters() |
20 | 20 | { |
21 | 21 | return [ |
22 | - 'TradeType' => '2', //1:Android SDK (手遊適用) 2:WEB |
|
22 | + 'TradeType' => '2', //1:Android SDK (手遊適用) 2:WEB |
|
23 | 23 | ]; |
24 | 24 | } |
25 | 25 |
@@ -39,8 +39,8 @@ |
||
39 | 39 | 'FacServiceId' => $this->getAppId(), |
40 | 40 | 'FacTradeSeq' => $this->getTransactionId(), |
41 | 41 | 'TradeType' => $this->getParameter('tradeType'), |
42 | - 'ServerId' => $this->serverId, // 服务器ID |
|
43 | - 'CustomerId' => $this->customerId, // 用户ID |
|
42 | + 'ServerId' => $this->serverId, // 服务器ID |
|
43 | + 'CustomerId' => $this->customerId, // 用户ID |
|
44 | 44 | 'PaymentType' => $this->paymentType, |
45 | 45 | 'ItemCode' => $this->itemCode, |
46 | 46 | 'ProductName' => $this->getDescription(), |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | { |
10 | 10 | |
11 | 11 | private $ip = [ |
12 | - '220.130.127.125', // MyCard正式服务器IP |
|
12 | + '220.130.127.125', // MyCard正式服务器IP |
|
13 | 13 | '218.32.37.148' // MyCard测试服务器IP |
14 | 14 | ]; |
15 | 15 | |
@@ -46,16 +46,16 @@ discard block |
||
46 | 46 | */ |
47 | 47 | private function getReturnParams() |
48 | 48 | { |
49 | - $ReturnCode = $this->httpRequest->get('ReturnCode'); // 1 为成功, 其他则为失败. 注意: ReturnCode 为1并不代表交易成功,正确交易结果请参考PayResult |
|
49 | + $ReturnCode = $this->httpRequest->get('ReturnCode'); // 1 为成功, 其他则为失败. 注意: ReturnCode 为1并不代表交易成功,正确交易结果请参考PayResult |
|
50 | 50 | $ReturnMsg = $this->httpRequest->get('ReturnMsg'); |
51 | - $PayResult = $this->httpRequest->get('PayResult'); // 交易结果代码 交易成功为 3; 交易失败为 0 |
|
52 | - $FacTradeSeq = $this->httpRequest->get('FacTradeSeq'); // 厂商交易序号 |
|
53 | - $PaymentType = $this->httpRequest->get('PaymentType'); // 付费方式 |
|
51 | + $PayResult = $this->httpRequest->get('PayResult'); // 交易结果代码 交易成功为 3; 交易失败为 0 |
|
52 | + $FacTradeSeq = $this->httpRequest->get('FacTradeSeq'); // 厂商交易序号 |
|
53 | + $PaymentType = $this->httpRequest->get('PaymentType'); // 付费方式 |
|
54 | 54 | $Amount = $this->httpRequest->get('Amount'); |
55 | 55 | $Currency = $this->httpRequest->get('Currency'); |
56 | - $MyCardType = $this->httpRequest->get('MyCardType'); // 通路代码 PaymentType = INGAME 时才有值 |
|
57 | - $PromoCode = $this->httpRequest->get('PromoCode'); // 活动代码 |
|
58 | - $Hash = $this->httpRequest->get('Hash'); // 验证码 |
|
56 | + $MyCardType = $this->httpRequest->get('MyCardType'); // 通路代码 PaymentType = INGAME 时才有值 |
|
57 | + $PromoCode = $this->httpRequest->get('PromoCode'); // 活动代码 |
|
58 | + $Hash = $this->httpRequest->get('Hash'); // 验证码 |
|
59 | 59 | // 1.PaymentType=INGAME时,传MyCard卡片号码; 2.PaymentType=COSTPOINT时,传会员扣点交易序号,格式为MMS开头+数; 3.其余PaymentType为Billing小额付款交易,传Billing交易序号 |
60 | 60 | $MyCardTradeNo = $this->httpRequest->get('MyCardTradeNo'); |
61 | 61 |
@@ -19,8 +19,7 @@ |
||
19 | 19 | if ($this->httpRequest->get('DATA')) { |
20 | 20 | $this->getNotifyParams(); |
21 | 21 | $type = 'notify'; |
22 | - } |
|
23 | - else { |
|
22 | + } else { |
|
24 | 23 | $this->getReturnParams(); |
25 | 24 | $type = 'return'; |
26 | 25 | } |