config.xml 5.2 KB
<?xml version="1.0" encoding="UTF-8"?>
<config>
	<!-- versionierung des moduls - 
		wichtig vor alle dem auch im Zusammenhang mit dem Datenbankinstallationsskript
	-->
	<modules>
		<Anc_Playlist>
			<version>0.0.1</version>
		</Anc_Playlist>
	</modules>
	<!-- was im frontend passiert -->
	<frontend>
		<!-- einbindung der layoutkonfiguration (s.u.) -->
		<layout>
			<updates>
				<Anc_Playlist>
					<file>anc/playlist.xml</file>
				</Anc_Playlist>
			</updates>
		</layout>
		<!-- damit die controller funktionen über eine url erreichbar sind (s.u.) -->
		<routers>
			<!--Umleitung bzw aktivierung der controllers-->
			<anc_playlist>
				<use>standard</use>
				<args>
					<!-- alle urls die mit "http://magento/ancplaylist" werden ins modul Anc_Playlist umgeleitet -->
					<module>Anc_Playlist</module>
					<frontName>ancplaylist</frontName>
				</args>				
			</anc_playlist>
		</routers>
		<events>
			<anclib_quoteitem_cloneproductitem>
				<observers>
                    <anc_playlist_makeNewNcplaylistItemAfterClone>
                        <type>singleton</type>
                        <class>anc_playlist/observer</class>
                        <method>makeNewNcplaylistItemAfterClone</method>
                    </anc_playlist_makeNewNcplaylistItemAfterClone>										
				</observers>
			</anclib_quoteitem_cloneproductitem>			
			<sales_order_save_commit_after>
				<observers>
					<anc_playlist_save_playlist_order_link>
						<type>singleton</type>
						<class>anc_playlist/observer</class>
						<method>savePlaylistOrderLink</method>
					</anc_playlist_save_playlist_order_link>
				</observers>
			</sales_order_save_commit_after>				
		</events>
	</frontend>	
	
	<global>
		<helpers>
			<anc_playlist>
				<class>Anc_Playlist_Helper</class>
			</anc_playlist>
		</helpers>		
		
		<!-- dem system bekannt machen das block klassen existieren -->
		<blocks>
			<anc_playlist>
				<class>Anc_Playlist_Block</class>
			</anc_playlist>
			<!-- Wichtig damit die Blocks zum editieren richtig geladen werden-->
			<anc_playlist_adminhtml>
                <class>Anc_Playlist_Block_Adminhtml</class>
            </anc_playlist_adminhtml>
			<adminhtml>
				<!-- @anc_playlist_eingabetyp -->
				<rewrite>
					<catalog_product_edit_tab_options_option>Anc_Playlist_Block_Adminhtml_Catalog_Product_Edit_Tab_Options_Option</catalog_product_edit_tab_options_option>
				</rewrite>
			</adminhtml>			
		</blocks>
		<catalog>
			<product>
				<options>
					<custom>
						<groups>
							<!-- @anc_playlist_eingabetyp -->
							<ancplaylist translate="label" module="anc_playlist">
								<label>NcPlaylist</label>
								<render>anc_playlist/adminhtml_catalog_product_edit_tab_options_type_ancplaylist</render>
								<types>
									<ancplaylist_type translate="label" module="anc_playlist">
										<label>Playlist</label>
									</ancplaylist_type>									
								</types>
							</ancplaylist>							
						</groups>				 
					</custom>
				</options>
			</product>
		</catalog>
		
		<!-- die konfiguration der datenbank schnittstelle -->
		<models>
			<anc_playlist>
				<class>Anc_Playlist_Model</class>
				<!-- folgendes ist ein verweis auf den nachfolgenden tag <anc_playlist_resource> -->
				<resourceModel>anc_playlist_resource</resourceModel>
			</anc_playlist>
			<anc_playlist_resource>
				<class>Anc_Playlist_Model_Resource_Mysql4</class>
				<!-- entitie's mit s hier können mehrere Tabellen(namen) untergebracht werden -->
					<entities>
						<ncplaylist>
							<table>anc_playlist_ncplaylist</table>
						</ncplaylist>
					</entities>
			</anc_playlist_resource>			
			<catalog>
				<!-- @anc_playlist_eingabetyp -->
				<rewrite>
					<product_option>Anc_Playlist_Model_Catalog_Product_Option</product_option>
				</rewrite>
			</catalog>			
		</models>
		<resources>
			<!-- hier verbirgt sich das installationsskript um die datenbanktabellen zu erstellen -->
				<anc_playlist_setup>
					<setup><module>Anc_Playlist</module><class>Mage_Sales_Model_Mysql4_Setup</class></setup>
					<connection><use>core_setup</use></connection>				
				</anc_playlist_setup>
			<!-- datenbank verbindungen -->
				<anc_playlist_write><connection><use>core_write</use></connection></anc_playlist_write>
				<anc_playlist_read><connection><use>core_read</use></connection></anc_playlist_read>			
		</resources>
	</global>
	<admin>
        <routers>
            <anc_playlist>
                <use>admin</use>
                <args>
					<modules>
                        <certification_may before="Mage_Adminhtml">Anc_Playlist_Adminhtml</certification_may>
                    </modules>
                    <module>Anc_Playlist</module>
                    <frontName>playlist</frontName>
                </args>
            </anc_playlist>
        </routers>
    </admin>	
	<adminhtml>
<!--		<layout>
			<updates>
				<album>
					<file>anc/album.xml</file>
				</album>
			</updates>
		</layout>		-->
		<menu>
			<Anc_Anc module="anc_playlist">
				<title>ANC</title>
				<sort_order>72</sort_order>
				<children>
					<item1site module="anc_playlist">
						<title>Playlist</title>
						<sort_order>3</sort_order>
						<action>playlist/adminhtml_ncplaylist/list</action>
					</item1site>	
				</children>
				               	
			</Anc_Anc>
		</menu>
	</adminhtml>	
</config>