protected function _checkWithoutCurrency( MShop_Order_Item_Base_Interface $order,
		MShop_Order_Item_Base_Product_Interface $value )
	{
		$config = $this->_getItem()->getConfig();

		if( isset( $config['single-number-max'] )
			&& !is_array( $config['single-number-max'] )
			&& $value->getQuantity() > (int) $config['single-number-max']
		) {
			$msg = sprintf( 'The maximum product quantity is %1$d', (int) $config['single-number-max'] );
			throw new MShop_Plugin_Provider_Exception( $msg );
		}


		if( isset( $config['total-number-max'] ) && !is_array( $config['total-number-max'] ) )
		{
			$total = $value->getQuantity();

			foreach( $order->getProducts() as $product ) {
				$total += $product->getQuantity();
			}

			if( $total > (int) $config['total-number-max'] )
			{
				$msg = sprintf( 'The maximum quantity of all products is %1$d', (int) $config['total-number-max'] );
				throw new MShop_Plugin_Provider_Exception( $msg );
			}
		}
	}
protected function _checkWithoutCurrency( MShop_Order_Item_Base_Interface $order,
		MShop_Order_Item_Base_Product_Interface $value )
	{
		$config = $this->_getItem()->getConfig();

		if( isset( $config['single-number-max'] )
			&& !is_array( $config['single-number-max'] )
			&& $value->getQuantity() > (int) $config['single-number-max']
		) {
			$msg = sprintf( 'The maximum product quantity is %1$d', (int) $config['single-number-max'] );
			throw new MShop_Plugin_Provider_Exception( $msg );
		}


		if( isset( $config['total-number-max'] ) && !is_array( $config['total-number-max'] ) )
		{
			$total = $value->getQuantity();

			foreach( $order->getProducts() as $product ) {
				$total += $product->getQuantity();
			}

			if( $total > (int) $config['total-number-max'] )
			{
				$msg = sprintf( 'The maximum quantity of all products is %1$d', (int) $config['total-number-max'] );
				throw new MShop_Plugin_Provider_Exception( $msg );
			}
		}
	}
protected function _checkWithoutCurrency ( MShop_Order_Item_Base_Interface $ order , MShop_Order_Item_Base_Product_Interface $ value ) { $ config = $ this -> _getItem ( ) -> getConfig ( ) ; if ( isset ( $ config [ 'single-number-max' ] ) && ! is_array ( $ config [ 'single-number-max' ] ) && $ value -> getQuantity ( ) > ( int ) $ config [ 'single-number-max' ] ) { $ msg = sprintf ( 'The maximum product quantity is %1$d' , ( int ) $ config [ 'single-number-max' ] ) ; throw new MShop_Plugin_Provider_Exception ( $ msg ) ; } if ( isset ( $ config [ 'total-number-max' ] ) && ! is_array ( $ config [ 'total-number-max' ] ) ) { $ total = $ value -> getQuantity ( ) ; foreach ( $ order -> getProducts ( ) as $ product ) { $ total += $ product -> getQuantity ( ) ; } if ( $ total > ( int ) $ config [ 'total-number-max' ] ) { $ msg = sprintf ( 'The maximum quantity of all products is %1$d' , ( int ) $ config [ 'total-number-max' ] ) ; throw new MShop_Plugin_Provider_Exception ( $ msg ) ; } } }
Checks for the product limits when the configuration doesn't contain limits per currency.

@param MShop_Order_Item_Base_Interface $order Basket object
@param MShop_Order_Item_Base_Product_Interface $value Order product item
@throws MShop_Plugin_Provider_Exception If one limit is exceeded
Checks for the product limits when the configuration doesn t contain limits per currency .