1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
/** |
4
|
|
|
* MIT License |
5
|
|
|
* Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file. |
6
|
|
|
*/ |
7
|
|
|
|
8
|
|
|
namespace SprykerEco\Yves\Computop\Plugin\Provider; |
9
|
|
|
|
10
|
|
|
use Silex\Application; |
11
|
|
|
use SprykerShop\Yves\ShopApplication\Plugin\Provider\AbstractYvesControllerProvider; |
12
|
|
|
|
13
|
|
|
/** |
14
|
|
|
* @deprecated Use `{@link \SprykerEco\Yves\Computop\Plugin\Router\ComputopRouteProviderPlugin}` instead. |
15
|
|
|
*/ |
16
|
|
|
class ComputopControllerProvider extends AbstractYvesControllerProvider |
|
|
|
|
17
|
|
|
{ |
18
|
|
|
public const CREDIT_CARD_SUCCESS = 'computop-credit-card-success'; |
19
|
|
|
public const PAY_NOW_SUCCESS = 'computop-paynow-success'; |
20
|
|
|
public const DIRECT_DEBIT_SUCCESS = 'computop-direct-debit-success'; |
21
|
|
|
public const EASY_CREDIT_SUCCESS = 'computop-easy-credit-success'; |
22
|
|
|
public const IDEAL_SUCCESS = 'computop-ideal-success'; |
23
|
|
|
public const PAYDIREKT_SUCCESS = 'computop-paydirekt-success'; |
24
|
|
|
public const PAY_PAL_SUCCESS = 'computop-pay-pal-success'; |
25
|
|
|
public const SOFORT_SUCCESS = 'computop-sofort-success'; |
26
|
|
|
|
27
|
|
|
public const FAILURE_PATH_NAME = 'computop-failure'; |
28
|
|
|
public const NOTIFY_PATH_NAME = 'computop-notify'; |
29
|
|
|
|
30
|
|
|
/** |
31
|
|
|
* @var string |
32
|
|
|
*/ |
33
|
|
|
protected $moduleName = 'Computop'; |
34
|
|
|
|
35
|
|
|
/** |
36
|
|
|
* @var string |
37
|
|
|
*/ |
38
|
|
|
protected $callbackControllerName = 'Callback'; |
39
|
|
|
|
40
|
|
|
/** |
41
|
|
|
* @param \Silex\Application $app |
42
|
|
|
* |
43
|
|
|
* @return void |
44
|
|
|
*/ |
45
|
|
|
protected function defineControllers(Application $app) |
46
|
|
|
{ |
47
|
|
|
$this->createController( |
48
|
|
|
'/computop/credit-card-success', |
49
|
|
|
self::CREDIT_CARD_SUCCESS, |
50
|
|
|
$this->moduleName, |
51
|
|
|
$this->callbackControllerName, |
52
|
|
|
'successCreditCard' |
53
|
|
|
); |
54
|
|
|
|
55
|
|
|
$this->createController( |
56
|
|
|
'/computop/paynow-success', |
57
|
|
|
self::PAY_NOW_SUCCESS, |
58
|
|
|
$this->moduleName, |
59
|
|
|
$this->callbackControllerName, |
60
|
|
|
'successPayNow' |
61
|
|
|
); |
62
|
|
|
|
63
|
|
|
$this->createController( |
64
|
|
|
'/computop/direct-debit-success', |
65
|
|
|
self::DIRECT_DEBIT_SUCCESS, |
66
|
|
|
$this->moduleName, |
67
|
|
|
$this->callbackControllerName, |
68
|
|
|
'successDirectDebit' |
69
|
|
|
); |
70
|
|
|
|
71
|
|
|
$this->createController( |
72
|
|
|
'/computop/easy-credit-success', |
73
|
|
|
self::EASY_CREDIT_SUCCESS, |
74
|
|
|
$this->moduleName, |
75
|
|
|
$this->callbackControllerName, |
76
|
|
|
'successEasyCredit' |
77
|
|
|
); |
78
|
|
|
|
79
|
|
|
$this->createController( |
80
|
|
|
'/computop/ideal-success', |
81
|
|
|
self::IDEAL_SUCCESS, |
82
|
|
|
$this->moduleName, |
83
|
|
|
$this->callbackControllerName, |
84
|
|
|
'successIdeal' |
85
|
|
|
); |
86
|
|
|
|
87
|
|
|
$this->createController( |
88
|
|
|
'/computop/paydirekt-success', |
89
|
|
|
self::PAYDIREKT_SUCCESS, |
90
|
|
|
$this->moduleName, |
91
|
|
|
$this->callbackControllerName, |
92
|
|
|
'successPaydirekt' |
93
|
|
|
); |
94
|
|
|
|
95
|
|
|
$this->createController( |
96
|
|
|
'/computop/pay-pal-success', |
97
|
|
|
self::PAY_PAL_SUCCESS, |
98
|
|
|
$this->moduleName, |
99
|
|
|
$this->callbackControllerName, |
100
|
|
|
'successPayPal' |
101
|
|
|
); |
102
|
|
|
|
103
|
|
|
$this->createController( |
104
|
|
|
'/computop/sofort-success', |
105
|
|
|
self::SOFORT_SUCCESS, |
106
|
|
|
$this->moduleName, |
107
|
|
|
$this->callbackControllerName, |
108
|
|
|
'successSofort' |
109
|
|
|
); |
110
|
|
|
|
111
|
|
|
$this->createController( |
112
|
|
|
'/computop/failure', |
113
|
|
|
self::FAILURE_PATH_NAME, |
114
|
|
|
$this->moduleName, |
115
|
|
|
$this->callbackControllerName, |
116
|
|
|
'failure' |
117
|
|
|
); |
118
|
|
|
|
119
|
|
|
$this->createController( |
120
|
|
|
'/computop/notify', |
121
|
|
|
self::NOTIFY_PATH_NAME, |
122
|
|
|
$this->moduleName, |
123
|
|
|
$this->callbackControllerName, |
124
|
|
|
'notify' |
125
|
|
|
); |
126
|
|
|
} |
127
|
|
|
} |
128
|
|
|
|