1 | <?php |
||
24 | class Standard |
||
25 | extends \Aimeos\Controller\Frontend\Base |
||
26 | implements Iface, \Aimeos\Controller\Frontend\Common\Iface |
||
27 | { |
||
28 | private $providers = []; |
||
|
|||
29 | |||
30 | |||
31 | /** |
||
32 | * Returns a list of attributes that are invalid |
||
33 | * |
||
34 | * @param string $serviceId Unique service ID |
||
35 | * @param string[] $attributes List of attribute codes as keys and strings entered by the customer as value |
||
36 | * @return string[] List of attributes codes as keys and error messages as values for invalid or missing values |
||
37 | */ |
||
38 | public function checkAttributes( $serviceId, array $attributes ) |
||
45 | |||
46 | |||
47 | /** |
||
48 | * Returns the service item for the given ID |
||
49 | * |
||
50 | * @param string $serviceId Unique service ID |
||
51 | * @param string[] $ref List of domain names whose items should be fetched too |
||
52 | * @return \Aimeos\MShop\Service\Provider\Iface Service provider object |
||
53 | */ |
||
54 | public function getProvider( $serviceId, $ref = ['media', 'price', 'text'] ) |
||
59 | |||
60 | |||
61 | /** |
||
62 | * Returns the service providers of the given type |
||
63 | * |
||
64 | * @param string|null $type Service type, e.g. "delivery" (shipping related), "payment" (payment related) or null for all |
||
65 | * @param string[] $ref List of domain names whose items should be fetched too |
||
66 | * @return \Aimeos\MShop\Service\Provider\Iface[] List of service IDs as keys and service provider objects as values |
||
67 | */ |
||
68 | public function getProviders( $type = null, $ref = ['media', 'price', 'text'] ) |
||
92 | |||
93 | |||
94 | /** |
||
95 | * Processes the service for the given order, e.g. payment and delivery services |
||
96 | * |
||
97 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order which should be processed |
||
98 | * @param string $serviceId Unique service item ID |
||
99 | * @param array $urls Associative list of keys and the corresponding URLs |
||
100 | * (keys are <type>.url-self, <type>.url-success, <type>.url-update where type can be "delivery" or "payment") |
||
101 | * @param array $params Request parameters and order service attributes |
||
102 | * @return \Aimeos\MShop\Common\Item\Helper\Form\Iface|null Form object with URL, parameters, etc. |
||
103 | * or null if no form data is required |
||
104 | */ |
||
105 | public function process( \Aimeos\MShop\Order\Item\Iface $orderItem, $serviceId, array $urls, array $params ) |
||
114 | |||
115 | |||
116 | /** |
||
117 | * Updates the order status sent by payment gateway notifications |
||
118 | * |
||
119 | * @param ServerRequestInterface $request Request object |
||
120 | * @param ResponseInterface $response Response object that will contain HTTP status and response body |
||
121 | * @param string $code Unique code of the service used for the current order |
||
122 | * @return \Psr\Http\Message\ResponseInterface Response object |
||
123 | */ |
||
124 | public function updatePush( ServerRequestInterface $request, ResponseInterface $response, $code ) |
||
131 | |||
132 | |||
133 | /** |
||
134 | * Updates the payment or delivery status for the given request |
||
135 | * |
||
136 | * @param ServerRequestInterface $request Request object with parameters and request body |
||
137 | * @param ResponseInterface $response Response object that will contain HTTP status and response body |
||
138 | * @param array $urls Associative list of keys and the corresponding URLs |
||
139 | * (keys are <type>.url-self, <type>.url-success, <type>.url-update where type can be "delivery" or "payment") |
||
140 | * @param string $code Unique code of the service used for the current order |
||
141 | * @param string $orderid Unique ID of the order whose payment status should be updated |
||
142 | * @return \Aimeos\MShop\Order\Item\Iface $orderItem Order item that has been updated |
||
143 | */ |
||
144 | public function updateSync( ServerRequestInterface $request, ResponseInterface $response, array $urls, $code, $orderid ) |
||
179 | } |
||
180 |
This check marks private properties in classes that are never used. Those properties can be removed.