1
|
<?php
|
1
|
<?php
|
2
|
|
2
|
|
3
|
namespace WebPlugin\Pay;
|
3
|
namespace WebPlugin\Pay;
|
4
|
-
|
4
|
+use WebPlugin\Helpers;
|
5
|
abstract class PayAbstract implements PayInterface {
|
5
|
abstract class PayAbstract implements PayInterface {
|
6
|
|
6
|
|
7
|
/**
|
7
|
/**
|
|
@@ -14,14 +14,14 @@ abstract class PayAbstract implements PayInterface { |
|
@@ -14,14 +14,14 @@ abstract class PayAbstract implements PayInterface { |
14
|
*
|
14
|
*
|
15
|
* @var
|
15
|
* @var
|
16
|
*/
|
16
|
*/
|
17
|
- public $baseNoticeUrl = "http://www.yohobuy.com/pay/";
|
17
|
+ public $baseNoticeUrl = "//www.yohobuy.com/pay/";
|
18
|
|
18
|
|
19
|
/**
|
19
|
/**
|
20
|
* 测试的回调地址
|
20
|
* 测试的回调地址
|
21
|
* Enter description here ...
|
21
|
* Enter description here ...
|
22
|
* @var string
|
22
|
* @var string
|
23
|
*/
|
23
|
*/
|
24
|
- public $testBaseNoticeUrl = "http://www.yohobuy.com/pay/";
|
24
|
+ public $testBaseNoticeUrl = "//www.yohobuy.com/pay/";
|
25
|
|
25
|
|
26
|
/**
|
26
|
/**
|
27
|
* 获取支付的基地址
|
27
|
* 获取支付的基地址
|
|
@@ -30,7 +30,7 @@ abstract class PayAbstract implements PayInterface { |
|
@@ -30,7 +30,7 @@ abstract class PayAbstract implements PayInterface { |
30
|
* @return string
|
30
|
* @return string
|
31
|
*/
|
31
|
*/
|
32
|
public function getBaseNoticeUrl($isTest){
|
32
|
public function getBaseNoticeUrl($isTest){
|
33
|
- return $isTest ? $this->testBaseNoticeUrl : $this->baseNoticeUrl;
|
33
|
+ return Helpers::getHttpOrHttps() . ($isTest ? $this->testBaseNoticeUrl : $this->baseNoticeUrl);
|
34
|
}
|
34
|
}
|
35
|
|
35
|
|
36
|
/**
|
36
|
/**
|