@@ -11,17 +11,17 @@ |
||
11 | 11 | * Set error reporting to maximum |
12 | 12 | */ |
13 | 13 | error_reporting( -1 ); |
14 | -ini_set( 'display_errors', '1' ); |
|
14 | +ini_set('display_errors', '1'); |
|
15 | 15 | |
16 | -date_default_timezone_set( 'UTC' ); |
|
16 | +date_default_timezone_set('UTC'); |
|
17 | 17 | |
18 | 18 | /* |
19 | 19 | * Set locale settings to reasonable defaults |
20 | 20 | */ |
21 | -setlocale( LC_ALL, 'en_US.UTF-8' ); |
|
22 | -setlocale( LC_NUMERIC, 'POSIX' ); |
|
23 | -setlocale( LC_CTYPE, 'en_US.UTF-8' ); |
|
24 | -setlocale( LC_TIME, 'POSIX' ); |
|
21 | +setlocale(LC_ALL, 'en_US.UTF-8'); |
|
22 | +setlocale(LC_NUMERIC, 'POSIX'); |
|
23 | +setlocale(LC_CTYPE, 'en_US.UTF-8'); |
|
24 | +setlocale(LC_TIME, 'POSIX'); |
|
25 | 25 | |
26 | 26 | |
27 | 27 | require_once 'TestHelperJqadm.php'; |
@@ -28,14 +28,14 @@ discard block |
||
28 | 28 | { |
29 | 29 | $result = $this->getClient()->delete(); |
30 | 30 | |
31 | - $ids = (array) $this->getView()->param( 'id' ); |
|
32 | - $tags = array( 'product' ); |
|
31 | + $ids = (array) $this->getView()->param('id'); |
|
32 | + $tags = array('product'); |
|
33 | 33 | |
34 | - foreach( $ids as $id ) { |
|
34 | + foreach ($ids as $id) { |
|
35 | 35 | $tags[] = 'product-' . $id; |
36 | 36 | } |
37 | 37 | |
38 | - $this->getContext()->getCache()->deleteByTags( $tags ); |
|
38 | + $this->getContext()->getCache()->deleteByTags($tags); |
|
39 | 39 | |
40 | 40 | return $result; |
41 | 41 | } |
@@ -51,10 +51,10 @@ discard block |
||
51 | 51 | $result = $this->getClient()->save(); |
52 | 52 | $item = $this->getView()->item; |
53 | 53 | |
54 | - if( $item->getId() !== null ) |
|
54 | + if ($item->getId() !== null) |
|
55 | 55 | { |
56 | 56 | $idtag = 'product-' . $item->getId(); |
57 | - $this->getContext()->getCache()->deleteByTags( array( 'product', $idtag ) ); |
|
57 | + $this->getContext()->getCache()->deleteByTags(array('product', $idtag)); |
|
58 | 58 | } |
59 | 59 | |
60 | 60 | return $result; |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | * @param string|null $name Name of the sub-client (Default if null) |
27 | 27 | * @return \Aimeos\Admin\JQAdm\Iface Sub-client object |
28 | 28 | */ |
29 | - public function getSubClient( $type, $name = null ); |
|
29 | + public function getSubClient($type, $name = null); |
|
30 | 30 | |
31 | 31 | /** |
32 | 32 | * Returns the view object that will generate the admin output. |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | * @param \Aimeos\MW\View\Iface $view The view object which generates the admin output |
42 | 42 | * @return \Aimeos\Admin\JQAdm\Iface Reference to this object for fluent calls |
43 | 43 | */ |
44 | - public function setView( \Aimeos\MW\View\Iface $view ); |
|
44 | + public function setView(\Aimeos\MW\View\Iface $view); |
|
45 | 45 | |
46 | 46 | /** |
47 | 47 | * Copies a resource |
@@ -27,13 +27,13 @@ |
||
27 | 27 | public function save() |
28 | 28 | { |
29 | 29 | $result = $this->getClient()->save(); |
30 | - $ids = array( 'catalog' ); |
|
30 | + $ids = array('catalog'); |
|
31 | 31 | |
32 | - foreach( $this->getView()->param( 'category/catalog.id', [] ) as $id ) { |
|
32 | + foreach ($this->getView()->param('category/catalog.id', []) as $id) { |
|
33 | 33 | $ids[] = 'catalog-' . $id; |
34 | 34 | } |
35 | 35 | |
36 | - $this->getContext()->getCache()->deleteByTags( $ids ); |
|
36 | + $this->getContext()->getCache()->deleteByTags($ids); |
|
37 | 37 | |
38 | 38 | return $result; |
39 | 39 | } |
@@ -10,17 +10,17 @@ |
||
10 | 10 | * Set error reporting to maximum |
11 | 11 | */ |
12 | 12 | error_reporting( -1 ); |
13 | -ini_set( 'display_errors', '1' ); |
|
13 | +ini_set('display_errors', '1'); |
|
14 | 14 | |
15 | -date_default_timezone_set( 'UTC' ); |
|
15 | +date_default_timezone_set('UTC'); |
|
16 | 16 | |
17 | 17 | /* |
18 | 18 | * Set locale settings to reasonable defaults |
19 | 19 | */ |
20 | -setlocale( LC_ALL, 'en_US.UTF-8' ); |
|
21 | -setlocale( LC_NUMERIC, 'POSIX' ); |
|
22 | -setlocale( LC_CTYPE, 'en_US.UTF-8' ); |
|
23 | -setlocale( LC_TIME, 'POSIX' ); |
|
20 | +setlocale(LC_ALL, 'en_US.UTF-8'); |
|
21 | +setlocale(LC_NUMERIC, 'POSIX'); |
|
22 | +setlocale(LC_CTYPE, 'en_US.UTF-8'); |
|
23 | +setlocale(LC_TIME, 'POSIX'); |
|
24 | 24 | |
25 | 25 | |
26 | 26 | require_once 'TestHelperCustom.php'; |
@@ -25,5 +25,5 @@ |
||
25 | 25 | * |
26 | 26 | * @param \Aimeos\MShop\Context\Item\Iface $context Context object |
27 | 27 | */ |
28 | - public function __construct( \Aimeos\MShop\Context\Item\Iface $context ); |
|
28 | + public function __construct(\Aimeos\MShop\Context\Item\Iface $context); |
|
29 | 29 | } |
@@ -30,10 +30,10 @@ discard block |
||
30 | 30 | * @param \Aimeos\Admin\JQAdm\Iface $client Admin object |
31 | 31 | * @param \Aimeos\MShop\Context\Item\Iface $context Context object with required objects |
32 | 32 | */ |
33 | - public function __construct( \Aimeos\Admin\JQAdm\Iface $client, |
|
34 | - \Aimeos\MShop\Context\Item\Iface $context ) |
|
33 | + public function __construct(\Aimeos\Admin\JQAdm\Iface $client, |
|
34 | + \Aimeos\MShop\Context\Item\Iface $context) |
|
35 | 35 | { |
36 | - parent::__construct( $context ); |
|
36 | + parent::__construct($context); |
|
37 | 37 | |
38 | 38 | $this->client = $client; |
39 | 39 | } |
@@ -47,9 +47,9 @@ discard block |
||
47 | 47 | * @return mixed Returns the value of the called method |
48 | 48 | * @throws \Aimeos\Admin\JQAdm\Exception If method call failed |
49 | 49 | */ |
50 | - public function __call( $name, array $param ) |
|
50 | + public function __call($name, array $param) |
|
51 | 51 | { |
52 | - return @call_user_func_array( array( $this->client, $name ), $param ); |
|
52 | + return @call_user_func_array(array($this->client, $name), $param); |
|
53 | 53 | } |
54 | 54 | |
55 | 55 | |
@@ -148,9 +148,9 @@ discard block |
||
148 | 148 | * @param string|null $name Name of the sub-client (Default if null) |
149 | 149 | * @return \Aimeos\Admin\JQAdm\Iface Sub-client object |
150 | 150 | */ |
151 | - public function getSubClient( $type, $name = null ) |
|
151 | + public function getSubClient($type, $name = null) |
|
152 | 152 | { |
153 | - return $this->client->getSubClient( $type, $name ); |
|
153 | + return $this->client->getSubClient($type, $name); |
|
154 | 154 | } |
155 | 155 | |
156 | 156 | |
@@ -171,11 +171,11 @@ discard block |
||
171 | 171 | * @param \Aimeos\MW\View\Iface $view The view object which generates the admin output |
172 | 172 | * @return \Aimeos\Admin\JQAdm\Iface Reference to this object for fluent calls |
173 | 173 | */ |
174 | - public function setView( \Aimeos\MW\View\Iface $view ) |
|
174 | + public function setView(\Aimeos\MW\View\Iface $view) |
|
175 | 175 | { |
176 | - parent::setView( $view ); |
|
176 | + parent::setView($view); |
|
177 | 177 | |
178 | - $this->client->setView( $view ); |
|
178 | + $this->client->setView($view); |
|
179 | 179 | return $this; |
180 | 180 | } |
181 | 181 | |
@@ -197,11 +197,11 @@ discard block |
||
197 | 197 | * @param \Aimeos\Bootstrap $aimeos The Aimeos bootstrap object |
198 | 198 | * @return \Aimeos\Admin\JQAdm\Iface Reference to this object for fluent calls |
199 | 199 | */ |
200 | - public function setAimeos( \Aimeos\Bootstrap $aimeos ) |
|
200 | + public function setAimeos(\Aimeos\Bootstrap $aimeos) |
|
201 | 201 | { |
202 | - parent::setAimeos( $aimeos ); |
|
202 | + parent::setAimeos($aimeos); |
|
203 | 203 | |
204 | - $this->client->setAimeos( $aimeos ); |
|
204 | + $this->client->setAimeos($aimeos); |
|
205 | 205 | return $this; |
206 | 206 | } |
207 | 207 |
@@ -26,5 +26,5 @@ |
||
26 | 26 | * @param \Aimeos\Admin\JQAdm\Iface $client Admin object |
27 | 27 | * @param \Aimeos\MShop\Context\Item\Iface $context Context object with required objects |
28 | 28 | */ |
29 | - public function __construct( \Aimeos\Admin\JQAdm\Iface $client, \Aimeos\MShop\Context\Item\Iface $context ); |
|
29 | + public function __construct(\Aimeos\Admin\JQAdm\Iface $client, \Aimeos\MShop\Context\Item\Iface $context); |
|
30 | 30 | } |
31 | 31 | \ No newline at end of file |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | * @param string $siteid ID of a site item |
40 | 40 | * @return string|null Label of the site item or null if not found |
41 | 41 | */ |
42 | - public function match( $siteid ); |
|
42 | + public function match($siteid); |
|
43 | 43 | |
44 | 44 | /** |
45 | 45 | * Returns "readonly" if the item is inherited from another site |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | * @param string $siteid ID of a site item |
48 | 48 | * @return string|null "readonly" if item is from a parent site, null if not |
49 | 49 | */ |
50 | - public function readonly( $siteid ); |
|
50 | + public function readonly($siteid); |
|
51 | 51 | |
52 | 52 | /** |
53 | 53 | * Returns the site ID of the current site |