@@ -27,7 +27,7 @@ discard block |
||
| 27 | 27 | * @param string $name Name of the manager |
| 28 | 28 | * @return \Aimeos\MShop\Common\Manager\Iface Manager object |
| 29 | 29 | */ |
| 30 | - public function createManager( $name ); |
|
| 30 | + public function createManager($name); |
|
| 31 | 31 | |
| 32 | 32 | |
| 33 | 33 | /** |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | * @return array Associative list of items implementing \Aimeos\MShop\Catalog\Item\Iface with their IDs as keys |
| 48 | 48 | * @since 2015.08 |
| 49 | 49 | */ |
| 50 | - public function getCatalogPath( $id, array $domains = array( 'text', 'media' ) ); |
|
| 50 | + public function getCatalogPath($id, array $domains = array('text', 'media')); |
|
| 51 | 51 | |
| 52 | 52 | |
| 53 | 53 | /** |
@@ -61,8 +61,8 @@ discard block |
||
| 61 | 61 | * @return \Aimeos\MShop\Catalog\Item\Iface Catalog node, maybe with children depending on the level constant |
| 62 | 62 | * @since 2015.08 |
| 63 | 63 | */ |
| 64 | - public function getCatalogTree( $id = null, array $domains = array( 'text', 'media' ), |
|
| 65 | - $level = \Aimeos\MW\Tree\Manager\Base::LEVEL_TREE, \Aimeos\MW\Criteria\Iface $search = null ); |
|
| 64 | + public function getCatalogTree($id = null, array $domains = array('text', 'media'), |
|
| 65 | + $level = \Aimeos\MW\Tree\Manager\Base::LEVEL_TREE, \Aimeos\MW\Criteria\Iface $search = null); |
|
| 66 | 66 | |
| 67 | 67 | |
| 68 | 68 | /** |
@@ -73,7 +73,7 @@ discard block |
||
| 73 | 73 | * @return array Associative list of key values as key and the product count for this key as value |
| 74 | 74 | * @since 2015.08 |
| 75 | 75 | */ |
| 76 | - public function aggregateIndex( \Aimeos\MW\Criteria\Iface $filter, $key ); |
|
| 76 | + public function aggregateIndex(\Aimeos\MW\Criteria\Iface $filter, $key); |
|
| 77 | 77 | |
| 78 | 78 | |
| 79 | 79 | /** |
@@ -84,7 +84,7 @@ discard block |
||
| 84 | 84 | * @return \Aimeos\MW\Criteria\Iface Criteria object containing the conditions for searching |
| 85 | 85 | * @since 2015.08 |
| 86 | 86 | */ |
| 87 | - public function addIndexFilterCategory( \Aimeos\MW\Criteria\Iface $search, $catid ); |
|
| 87 | + public function addIndexFilterCategory(\Aimeos\MW\Criteria\Iface $search, $catid); |
|
| 88 | 88 | |
| 89 | 89 | |
| 90 | 90 | /** |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | * @return \Aimeos\MW\Criteria\Iface Criteria object containing the conditions for searching |
| 97 | 97 | * @since 2015.08 |
| 98 | 98 | */ |
| 99 | - public function addIndexFilterText( \Aimeos\MW\Criteria\Iface $search, $input, $listtype = 'default' ); |
|
| 99 | + public function addIndexFilterText(\Aimeos\MW\Criteria\Iface $search, $input, $listtype = 'default'); |
|
| 100 | 100 | |
| 101 | 101 | |
| 102 | 102 | /** |
@@ -110,7 +110,7 @@ discard block |
||
| 110 | 110 | * @return \Aimeos\MW\Criteria\Iface Criteria object containing the conditions for searching |
| 111 | 111 | * @since 2015.08 |
| 112 | 112 | */ |
| 113 | - public function createIndexFilter( $sort = null, $direction = '+', $start = 0, $size = 100, $listtype = 'default' ); |
|
| 113 | + public function createIndexFilter($sort = null, $direction = '+', $start = 0, $size = 100, $listtype = 'default'); |
|
| 114 | 114 | |
| 115 | 115 | |
| 116 | 116 | /** |
@@ -125,7 +125,7 @@ discard block |
||
| 125 | 125 | * @return \Aimeos\MW\Criteria\Iface Criteria object containing the conditions for searching |
| 126 | 126 | * @since 2015.08 |
| 127 | 127 | */ |
| 128 | - public function createIndexFilterCategory( $catid, $sort = 'position', $direction = 'asc', $start = 0, $size = 100, $listtype = 'default' ); |
|
| 128 | + public function createIndexFilterCategory($catid, $sort = 'position', $direction = 'asc', $start = 0, $size = 100, $listtype = 'default'); |
|
| 129 | 129 | |
| 130 | 130 | |
| 131 | 131 | /** |
@@ -140,7 +140,7 @@ discard block |
||
| 140 | 140 | * @return \Aimeos\MW\Criteria\Iface Criteria object containing the conditions for searching |
| 141 | 141 | * @since 2015.08 |
| 142 | 142 | */ |
| 143 | - public function createIndexFilterText( $input, $sort = 'relevance', $direction = 'asc', $start = 0, $size = 100, $listtype = 'default' ); |
|
| 143 | + public function createIndexFilterText($input, $sort = 'relevance', $direction = 'asc', $start = 0, $size = 100, $listtype = 'default'); |
|
| 144 | 144 | |
| 145 | 145 | |
| 146 | 146 | /** |
@@ -152,7 +152,7 @@ discard block |
||
| 152 | 152 | * @return array Ordered list of product items implementing \Aimeos\MShop\Product\Item\Iface |
| 153 | 153 | * @since 2015.08 |
| 154 | 154 | */ |
| 155 | - public function getIndexItems( \Aimeos\MW\Criteria\Iface $filter, array $domains = array( 'media', 'price', 'text' ), &$total = null ); |
|
| 155 | + public function getIndexItems(\Aimeos\MW\Criteria\Iface $filter, array $domains = array('media', 'price', 'text'), &$total = null); |
|
| 156 | 156 | |
| 157 | 157 | |
| 158 | 158 | /** |
@@ -163,7 +163,7 @@ discard block |
||
| 163 | 163 | * @return array List of product items implementing \Aimeos\MShop\Product\Item\Iface |
| 164 | 164 | * @since 2015.08 |
| 165 | 165 | */ |
| 166 | - public function getProductItems( array $ids, array $domains = array( 'media', 'price', 'text' ) ); |
|
| 166 | + public function getProductItems(array $ids, array $domains = array('media', 'price', 'text')); |
|
| 167 | 167 | |
| 168 | 168 | |
| 169 | 169 | /** |
@@ -178,7 +178,7 @@ discard block |
||
| 178 | 178 | * @param string $type Type of the text like "name", "short", "long", etc. |
| 179 | 179 | * @return \Aimeos\MW\Criteria\Iface Criteria object containing the conditions for searching |
| 180 | 180 | */ |
| 181 | - public function createTextFilter( $input, $sort = null, $direction = 'desc', $start = 0, $size = 25, $listtype = 'default', $type = 'name' ); |
|
| 181 | + public function createTextFilter($input, $sort = null, $direction = 'desc', $start = 0, $size = 25, $listtype = 'default', $type = 'name'); |
|
| 182 | 182 | |
| 183 | 183 | |
| 184 | 184 | /** |
@@ -187,5 +187,5 @@ discard block |
||
| 187 | 187 | * @param \Aimeos\MW\Criteria\Iface $filter Critera object which contains the filter conditions |
| 188 | 188 | * @return array Associative list of the product ID as key and the product text as value |
| 189 | 189 | */ |
| 190 | - public function getTextList( \Aimeos\MW\Criteria\Iface $filter ); |
|
| 190 | + public function getTextList(\Aimeos\MW\Criteria\Iface $filter); |
|
| 191 | 191 | } |
@@ -29,7 +29,7 @@ discard block |
||
| 29 | 29 | * @param string|null $name Name of the controller implementaton (default: "Standard") |
| 30 | 30 | * @return \Aimeos\Controller\Frontend\Common\Iface Controller object |
| 31 | 31 | */ |
| 32 | - public static function createController( \Aimeos\MShop\Context\Item\Iface $context, $name = null ) |
|
| 32 | + public static function createController(\Aimeos\MShop\Context\Item\Iface $context, $name = null) |
|
| 33 | 33 | { |
| 34 | 34 | /** controller/frontend/catalog/name |
| 35 | 35 | * Class name of the used catalog frontend controller implementation |
@@ -64,20 +64,20 @@ discard block |
||
| 64 | 64 | * @since 2014.03 |
| 65 | 65 | * @category Developer |
| 66 | 66 | */ |
| 67 | - if( $name === null ) { |
|
| 68 | - $name = $context->getConfig()->get( 'controller/frontend/catalog/name', 'Standard' ); |
|
| 67 | + if ($name === null) { |
|
| 68 | + $name = $context->getConfig()->get('controller/frontend/catalog/name', 'Standard'); |
|
| 69 | 69 | } |
| 70 | 70 | |
| 71 | - if( ctype_alnum( $name ) === false ) |
|
| 71 | + if (ctype_alnum($name) === false) |
|
| 72 | 72 | { |
| 73 | - $classname = is_string( $name ) ? '\\Aimeos\\Controller\\Frontend\\Catalog\\' . $name : '<not a string>'; |
|
| 74 | - throw new \Aimeos\Controller\Frontend\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) ); |
|
| 73 | + $classname = is_string($name) ? '\\Aimeos\\Controller\\Frontend\\Catalog\\' . $name : '<not a string>'; |
|
| 74 | + throw new \Aimeos\Controller\Frontend\Exception(sprintf('Invalid characters in class name "%1$s"', $classname)); |
|
| 75 | 75 | } |
| 76 | 76 | |
| 77 | 77 | $iface = '\\Aimeos\\Controller\\Frontend\\Catalog\\Iface'; |
| 78 | 78 | $classname = '\\Aimeos\\Controller\\Frontend\\Catalog\\' . $name; |
| 79 | 79 | |
| 80 | - $manager = self::createControllerBase( $context, $classname, $iface ); |
|
| 80 | + $manager = self::createControllerBase($context, $classname, $iface); |
|
| 81 | 81 | |
| 82 | 82 | /** controller/frontend/catalog/decorators/excludes |
| 83 | 83 | * Excludes decorators added by the "common" option from the catalog frontend controllers |
@@ -153,7 +153,7 @@ discard block |
||
| 153 | 153 | * @see controller/frontend/catalog/decorators/excludes |
| 154 | 154 | * @see controller/frontend/catalog/decorators/global |
| 155 | 155 | */ |
| 156 | - return self::addControllerDecorators( $context, $manager, 'catalog' ); |
|
| 156 | + return self::addControllerDecorators($context, $manager, 'catalog'); |
|
| 157 | 157 | } |
| 158 | 158 | |
| 159 | 159 | } |
@@ -32,22 +32,22 @@ discard block |
||
| 32 | 32 | * @param \Aimeos\MShop\Order\Item\Base\Iface $basket Basket object to be stored |
| 33 | 33 | * @return \Aimeos\MShop\Order\Item\Iface Order item that belongs to the stored basket |
| 34 | 34 | */ |
| 35 | - public function store( \Aimeos\MShop\Order\Item\Base\Iface $basket ) |
|
| 35 | + public function store(\Aimeos\MShop\Order\Item\Base\Iface $basket) |
|
| 36 | 36 | { |
| 37 | 37 | $context = $this->getContext(); |
| 38 | 38 | |
| 39 | - $orderManager = \Aimeos\MShop\Factory::createManager( $context, 'order' ); |
|
| 40 | - $orderBaseManager = \Aimeos\MShop\Factory::createManager( $context, 'order/base' ); |
|
| 39 | + $orderManager = \Aimeos\MShop\Factory::createManager($context, 'order'); |
|
| 40 | + $orderBaseManager = \Aimeos\MShop\Factory::createManager($context, 'order/base'); |
|
| 41 | 41 | |
| 42 | 42 | |
| 43 | 43 | $orderBaseManager->begin(); |
| 44 | - $orderBaseManager->store( $basket ); |
|
| 44 | + $orderBaseManager->store($basket); |
|
| 45 | 45 | $orderBaseManager->commit(); |
| 46 | 46 | |
| 47 | 47 | $orderItem = $orderManager->createItem(); |
| 48 | - $orderItem->setBaseId( $basket->getId() ); |
|
| 49 | - $orderItem->setType( \Aimeos\MShop\Order\Item\Base::TYPE_WEB ); |
|
| 50 | - $orderManager->saveItem( $orderItem ); |
|
| 48 | + $orderItem->setBaseId($basket->getId()); |
|
| 49 | + $orderItem->setType(\Aimeos\MShop\Order\Item\Base::TYPE_WEB); |
|
| 50 | + $orderManager->saveItem($orderItem); |
|
| 51 | 51 | |
| 52 | 52 | |
| 53 | 53 | return $orderItem; |
@@ -72,9 +72,9 @@ discard block |
||
| 72 | 72 | * |
| 73 | 73 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object |
| 74 | 74 | */ |
| 75 | - public function block( \Aimeos\MShop\Order\Item\Iface $orderItem ) |
|
| 75 | + public function block(\Aimeos\MShop\Order\Item\Iface $orderItem) |
|
| 76 | 76 | { |
| 77 | - \Aimeos\Controller\Common\Order\Factory::createController( $this->getContext() )->block( $orderItem ); |
|
| 77 | + \Aimeos\Controller\Common\Order\Factory::createController($this->getContext())->block($orderItem); |
|
| 78 | 78 | } |
| 79 | 79 | |
| 80 | 80 | |
@@ -96,9 +96,9 @@ discard block |
||
| 96 | 96 | * |
| 97 | 97 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object |
| 98 | 98 | */ |
| 99 | - public function unblock( \Aimeos\MShop\Order\Item\Iface $orderItem ) |
|
| 99 | + public function unblock(\Aimeos\MShop\Order\Item\Iface $orderItem) |
|
| 100 | 100 | { |
| 101 | - \Aimeos\Controller\Common\Order\Factory::createController( $this->getContext() )->unblock( $orderItem ); |
|
| 101 | + \Aimeos\Controller\Common\Order\Factory::createController($this->getContext())->unblock($orderItem); |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | |
@@ -116,8 +116,8 @@ discard block |
||
| 116 | 116 | * |
| 117 | 117 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object |
| 118 | 118 | */ |
| 119 | - public function update( \Aimeos\MShop\Order\Item\Iface $orderItem ) |
|
| 119 | + public function update(\Aimeos\MShop\Order\Item\Iface $orderItem) |
|
| 120 | 120 | { |
| 121 | - \Aimeos\Controller\Common\Order\Factory::createController( $this->getContext() )->update( $orderItem ); |
|
| 121 | + \Aimeos\Controller\Common\Order\Factory::createController($this->getContext())->update($orderItem); |
|
| 122 | 122 | } |
| 123 | 123 | } |
@@ -31,7 +31,7 @@ discard block |
||
| 31 | 31 | * @param \Aimeos\MShop\Order\Item\Base\Iface $basket Basket object to be stored |
| 32 | 32 | * @return \Aimeos\MShop\Order\Item\Iface Order item that belongs to the stored basket |
| 33 | 33 | */ |
| 34 | - public function store( \Aimeos\MShop\Order\Item\Base\Iface $basket ); |
|
| 34 | + public function store(\Aimeos\MShop\Order\Item\Base\Iface $basket); |
|
| 35 | 35 | |
| 36 | 36 | |
| 37 | 37 | /** |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object |
| 54 | 54 | * @return void |
| 55 | 55 | */ |
| 56 | - public function block( \Aimeos\MShop\Order\Item\Iface $orderItem ); |
|
| 56 | + public function block(\Aimeos\MShop\Order\Item\Iface $orderItem); |
|
| 57 | 57 | |
| 58 | 58 | |
| 59 | 59 | /** |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object |
| 76 | 76 | * @return void |
| 77 | 77 | */ |
| 78 | - public function unblock( \Aimeos\MShop\Order\Item\Iface $orderItem ); |
|
| 78 | + public function unblock(\Aimeos\MShop\Order\Item\Iface $orderItem); |
|
| 79 | 79 | |
| 80 | 80 | |
| 81 | 81 | /** |
@@ -93,5 +93,5 @@ discard block |
||
| 93 | 93 | * @param \Aimeos\MShop\Order\Item\Iface $orderItem Order item object |
| 94 | 94 | * @return void |
| 95 | 95 | */ |
| 96 | - public function update( \Aimeos\MShop\Order\Item\Iface $orderItem ); |
|
| 96 | + public function update(\Aimeos\MShop\Order\Item\Iface $orderItem); |
|
| 97 | 97 | } |
@@ -29,7 +29,7 @@ discard block |
||
| 29 | 29 | * @param string|null $name Name of the controller implementaton (default: "Standard") |
| 30 | 30 | * @return \Aimeos\Controller\Frontend\Common\Iface Controller object |
| 31 | 31 | */ |
| 32 | - public static function createController( \Aimeos\MShop\Context\Item\Iface $context, $name = null ) |
|
| 32 | + public static function createController(\Aimeos\MShop\Context\Item\Iface $context, $name = null) |
|
| 33 | 33 | { |
| 34 | 34 | /** controller/frontend/order/name |
| 35 | 35 | * Class name of the used order frontend controller implementation |
@@ -64,19 +64,19 @@ discard block |
||
| 64 | 64 | * @since 2014.03 |
| 65 | 65 | * @category Developer |
| 66 | 66 | */ |
| 67 | - if( $name === null ) { |
|
| 68 | - $name = $context->getConfig()->get( 'controller/frontend/order/name', 'Standard' ); |
|
| 67 | + if ($name === null) { |
|
| 68 | + $name = $context->getConfig()->get('controller/frontend/order/name', 'Standard'); |
|
| 69 | 69 | } |
| 70 | 70 | |
| 71 | - if( ctype_alnum( $name ) === false ) { |
|
| 72 | - $classname = is_string( $name ) ? '\\Aimeos\\Controller\\Frontend\\Order\\' . $name : '<not a string>'; |
|
| 73 | - throw new \Aimeos\Controller\Frontend\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) ); |
|
| 71 | + if (ctype_alnum($name) === false) { |
|
| 72 | + $classname = is_string($name) ? '\\Aimeos\\Controller\\Frontend\\Order\\' . $name : '<not a string>'; |
|
| 73 | + throw new \Aimeos\Controller\Frontend\Exception(sprintf('Invalid characters in class name "%1$s"', $classname)); |
|
| 74 | 74 | } |
| 75 | 75 | |
| 76 | 76 | $iface = '\\Aimeos\\Controller\\Frontend\\Order\\Iface'; |
| 77 | 77 | $classname = '\\Aimeos\\Controller\\Frontend\\Order\\' . $name; |
| 78 | 78 | |
| 79 | - $manager = self::createControllerBase( $context, $classname, $iface ); |
|
| 79 | + $manager = self::createControllerBase($context, $classname, $iface); |
|
| 80 | 80 | |
| 81 | 81 | /** controller/frontend/order/decorators/excludes |
| 82 | 82 | * Excludes decorators added by the "common" option from the order frontend controllers |
@@ -152,6 +152,6 @@ discard block |
||
| 152 | 152 | * @see controller/frontend/order/decorators/excludes |
| 153 | 153 | * @see controller/frontend/order/decorators/global |
| 154 | 154 | */ |
| 155 | - return self::addControllerDecorators( $context, $manager, 'order' ); |
|
| 155 | + return self::addControllerDecorators($context, $manager, 'order'); |
|
| 156 | 156 | } |
| 157 | 157 | } |