protected function _getTypeId( $name, $domain, $type )
	{
		$key = str_replace( '/', '.', $name );
		$manager = MShop_Factory::createManager( $this->_getContext(), $name );

		$search = $manager->createSearch();
		$expr = array(
			$search->compare( '==', $key . '.domain', $domain ),
			$search->compare( '==', $key . '.code', $type ),
		);
		$search->setConditions( $search->combine( '&&', $expr ) );

		$result = $manager->searchItems( $search );

		if( ( $item = reset( $result ) ) === false ) {
			throw new Exception( sprintf( 'No type item found for "%1$s/%2$s" using "%3$s"', $domain, $type, $name ) );
		}

		return $item->getId();
	}
protected function _getTypeId( $name, $domain, $type )
	{
		$key = str_replace( '/', '.', $name );
		$manager = MShop_Factory::createManager( $this->_getContext(), $name );

		$search = $manager->createSearch();
		$expr = array(
			$search->compare( '==', $key . '.domain', $domain ),
			$search->compare( '==', $key . '.code', $type ),
		);
		$search->setConditions( $search->combine( '&&', $expr ) );

		$result = $manager->searchItems( $search );

		if( ( $item = reset( $result ) ) === false ) {
			throw new Exception( sprintf( 'No type item found for "%1$s/%2$s" using "%3$s"', $domain, $type, $name ) );
		}

		return $item->getId();
	}
protected function _getTypeId ( $ name , $ domain , $ type ) { $ key = str_replace ( '/' , '.' , $ name ) ; $ manager = MShop_Factory :: createManager ( $ this -> _getContext ( ) , $ name ) ; $ search = $ manager -> createSearch ( ) ; $ expr = array ( $ search -> compare ( '==' , $ key . '.domain' , $ domain ) , $ search -> compare ( '==' , $ key . '.code' , $ type ) , ) ; $ search -> setConditions ( $ search -> combine ( '&&' , $ expr ) ) ; $ result = $ manager -> searchItems ( $ search ) ; if ( ( $ item = reset ( $ result ) ) === false ) { throw new Exception ( sprintf ( 'No type item found for "%1$s/%2$s" using "%3$s"' , $ domain , $ type , $ name ) ) ; } return $ item -> getId ( ) ; }
Returns the type ID for the given type and domain found by the manager

@param string $name Manager name like 'catalog/list/type'
@param string $domain Domain of the type item we are looking for, e.g. 'text'
@param string $type Type code of the item we are looking for, e.g. 'default'
Returns the type ID for the given type and domain found by the manager