public function copyFrom( MShop_Product_Item_Interface $product )
	{
		$this->setName( $product->getName() );
		$this->setType( $product->getType() );
		$this->setSupplierCode( $product->getSupplierCode() );
		$this->setProductCode( $product->getCode() );
		$this->setProductId( $product->getId() );

		$items = $product->getRefItems( 'media', 'default', 'default' );
		if( ( $item = reset( $items ) ) !== false ) {
			$this->setMediaUrl( $item->getUrl() );
		}

		$this->setModified();
	}
public function copyFrom( MShop_Product_Item_Interface $product )
	{
		$this->setName( $product->getName() );
		$this->setType( $product->getType() );
		$this->setSupplierCode( $product->getSupplierCode() );
		$this->setProductCode( $product->getCode() );
		$this->setProductId( $product->getId() );

		$items = $product->getRefItems( 'media', 'default', 'default' );
		if( ( $item = reset( $items ) ) !== false ) {
			$this->setMediaUrl( $item->getUrl() );
		}

		$this->setModified();
	}
public function copyFrom ( MShop_Product_Item_Interface $ product ) { $ this -> setName ( $ product -> getName ( ) ) ; $ this -> setType ( $ product -> getType ( ) ) ; $ this -> setSupplierCode ( $ product -> getSupplierCode ( ) ) ; $ this -> setProductCode ( $ product -> getCode ( ) ) ; $ this -> setProductId ( $ product -> getId ( ) ) ; $ items = $ product -> getRefItems ( 'media' , 'default' , 'default' ) ; if ( ( $ item = reset ( $ items ) ) !== false ) { $ this -> setMediaUrl ( $ item -> getUrl ( ) ) ; } $ this -> setModified ( ) ; }
Copys all data from a given product item.

@param MShop_Product_Item_Interface $product Product item to copy from
Copys all data from a given product item .