@@ -287,7 +287,7 @@ |
||
287 | 287 | { |
288 | 288 | $total = 0; |
289 | 289 | $map = []; |
290 | - $direction = '+'; |
|
290 | + $direction = '+'; |
|
291 | 291 | |
292 | 292 | $ref = $view->param( 'include', [] ); |
293 | 293 | $size = $view->param( 'page/limit', 48 ); |
@@ -101,8 +101,7 @@ |
||
101 | 101 | $decorators = $config->get( 'client/jsonapi/' . $dpath . 'decorators/local', [] ); |
102 | 102 | $client = self::addDecorators( $client, $decorators, $classprefix, $context, $view, $templatePaths, $path ); |
103 | 103 | } |
104 | - } |
|
105 | - else |
|
104 | + } else |
|
106 | 105 | { |
107 | 106 | $classprefix = '\\Aimeos\\Client\\JsonApi\\Common\\Decorator\\'; |
108 | 107 | $client = self::addDecorators( $client, $decorators, $classprefix, $context, $view, $templatePaths, $path ); |
@@ -31,7 +31,7 @@ |
||
31 | 31 | $first = ( $offset > 0 ? 0 : null ); |
32 | 32 | $prev = ( $offset - $limit >= 0 ? $offset - $limit : null ); |
33 | 33 | $next = ( $offset + $limit < $total ? $offset + $limit : null ); |
34 | -$last = ( ((int) ($total / $limit)) * $limit > $offset ? ((int) ($total / $limit)) * $limit : null ); |
|
34 | +$last = ( ( (int) ( $total / $limit ) ) * $limit > $offset ? ( (int) ( $total / $limit ) ) * $limit : null ); |
|
35 | 35 | |
36 | 36 | |
37 | 37 | $fields = $this->param( 'fields', [] ); |
@@ -32,7 +32,7 @@ |
||
32 | 32 | $first = ( $offset > 0 ? 0 : null ); |
33 | 33 | $prev = ( $offset - $limit >= 0 ? $offset - $limit : null ); |
34 | 34 | $next = ( $offset + $limit < $total ? $offset + $limit : null ); |
35 | -$last = ( ((int) ($total / $limit)) * $limit > $offset ? ((int) ($total / $limit)) * $limit : null ); |
|
35 | +$last = ( ( (int) ( $total / $limit ) ) * $limit > $offset ? ( (int) ( $total / $limit ) ) * $limit : null ); |
|
36 | 36 | |
37 | 37 | |
38 | 38 | $fields = $this->param( 'fields', [] ); |
@@ -97,7 +97,7 @@ discard block |
||
97 | 97 | $first = ( $offset > 0 ? 0 : null ); |
98 | 98 | $prev = ( $offset - $limit >= 0 ? $offset - $limit : null ); |
99 | 99 | $next = ( $offset + $limit < $total ? $offset + $limit : null ); |
100 | -$last = ( ((int) ($total / $limit)) * $limit > $offset ? ((int) ($total / $limit)) * $limit : null ); |
|
100 | +$last = ( ( (int) ( $total / $limit ) ) * $limit > $offset ? ( (int) ( $total / $limit ) ) * $limit : null ); |
|
101 | 101 | |
102 | 102 | |
103 | 103 | $map = $this->get( 'itemMap', [] ); |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | $type = $item->getResourceType(); |
116 | 116 | |
117 | 117 | $params = array( 'resource' => $type, 'id' => $id ); |
118 | - $basketParams = [ 'resource' => 'basket', 'id' => 'default', 'related' => 'product' ]; |
|
118 | + $basketParams = ['resource' => 'basket', 'id' => 'default', 'related' => 'product']; |
|
119 | 119 | |
120 | 120 | if( isset( $fields[$type] ) ) { |
121 | 121 | $attributes = array_intersect_key( $attributes, $fields[$type] ); |