1 | <?php |
||
20 | class Select |
||
21 | extends \Aimeos\Controller\Frontend\Basket\Decorator\Base |
||
2 ignored issues
–
show
|
|||
22 | implements \Aimeos\Controller\Frontend\Basket\Iface, \Aimeos\Controller\Frontend\Common\Decorator\Iface |
||
1 ignored issue
–
show
|
|||
23 | { |
||
24 | /** |
||
25 | * Adds a selection product to the basket of the user stored in the session. |
||
26 | * |
||
27 | * @param string $prodid ID of the base product to add |
||
28 | * @param integer $quantity Amount of products that should by added |
||
29 | * @param array $options Possible options are: 'stock'=>true|false and 'variant'=>true|false |
||
30 | * The 'stock'=>false option allows adding products without being in stock. |
||
31 | * The 'variant'=>false option allows adding the selection product to the basket |
||
32 | * instead of the specific sub-product if the variant-building attribute IDs |
||
33 | * doesn't match a specific sub-product or if the attribute IDs are missing. |
||
34 | * @param array $variantAttributeIds List of variant-building attribute IDs that identify a specific product |
||
35 | * in a selection products |
||
36 | * @param array $configAttributeIds List of attribute IDs that doesn't identify a specific product in a |
||
37 | * selection of products but are stored together with the product (e.g. for configurable products) |
||
38 | * @param array $hiddenAttributeIds List of attribute IDs that should be stored along with the product in the order |
||
39 | * @param array $customAttributeValues Associative list of attribute IDs and arbitrary values that should be stored |
||
40 | * along with the product in the order |
||
41 | * @param string $stocktype Unique code of the stock type to deliver the products from |
||
42 | * @throws \Aimeos\Controller\Frontend\Basket\Exception If the product isn't available |
||
43 | */ |
||
44 | public function addProduct( $prodid, $quantity = 1, array $options = array(), array $variantAttributeIds = array(), |
||
84 | |||
85 | |||
86 | /** |
||
87 | * Returns the variant attributes and updates the price list if necessary. |
||
88 | * |
||
89 | * @param \Aimeos\MShop\Order\Item\Base\Product\Iface $orderBaseProductItem Order product item |
||
90 | * @param \Aimeos\MShop\Product\Item\Iface &$productItem Product item which is replaced if necessary |
||
91 | * @param array &$prices List of product prices that will be updated if necessary |
||
92 | * @param array $variantAttributeIds List of product variant attribute IDs |
||
93 | * @param array $options Associative list of options |
||
94 | * @return \Aimeos\MShop\Order\Item\Base\Product\Attribute\Iface[] List of order product attributes |
||
95 | * @throws \Aimeos\Controller\Frontend\Basket\Exception If no product variant is found |
||
96 | */ |
||
97 | protected function getVariantDetails( \Aimeos\MShop\Order\Item\Base\Product\Iface $orderBaseProductItem, |
||
145 | } |
||
146 |