Я создаю специальный модуль с именем «постоянные заказы» внутри пространства имен Stallioni.
Мое приложение / etc / modules / Stallioni_Standingorders.xml:
<?xml version="1.0"?>
<config>
<modules>
<Stallioni_Standingorders>
<active>true</active>
<codePool>local</codePool>
<depends>
<Mage_Core />
<Mage_Checkout/>
<Mage_Customer />
<Mage_Sales />
<Mage_Adminhtml/>
</depends>
</Stallioni_Standingorders>
</modules>
</config>
Мое приложение / код / local / Stallioni / Standingorders / etc / config.xml:
<?xml version="1.0"?>
<config>
<modules>
<Stallioni_Standingorders>
<version>0.1.0</version>
</Stallioni_Standingorders>
</modules>
<frontend>
<routers>
<standingorders>
<use>standard</use>
<args>
<module>Stallioni_Standingorders</module>
<frontName>standingorders</frontName>
</args>
</standingorders>
</routers>
<layout>
<updates>
<standingorders>
<file>standingorders.xml</file>
</standingorders>
</updates>
</layout>
</frontend>
<global>
<models>
<standingorders>
<class>Stallioni_Standingorders_Model</class>
<resourceModel>standingorders_mysql4</resourceModel>
</standingorders>
<standingorders_mysql4>
<class>Stallioni_Standingorders_Model_Mysql4</class>
<entities>
<standingorders>
<table>standingorders</table>
</standingorders>
</entities>
</standingorders_mysql4>
</models>
<resources>
<standingorders_setup>
<setup>
<module>Stallioni_Standingorders</module>
</setup>
<connection>
<use>core_setup</use>
</connection>
</standingorders_setup>
<standingorders_write>
<connection>
<use>core_write</use>
</connection>
</standingorders_write>
<standingorders_read>
<connection>
<use>core_read</use>
</connection>
</standingorders_read>
</resources>
<blocks>
<standingorders>
<class>Stallioni_Standingorders_Block</class>
</standingorders>
</blocks>
<helpers>
<standingorders>
<class>Stallioni_Standingorders_Helper</class>
</standingorders>
</helpers>
</global>
</config>
В default / default / template / Standorders / checkout / cart / item / default.phtml я переопределил base / default / template / checkout / cart / item / default.phtml
Мой файл layout / Standingorders.xml:
<?xml version="1.0" encoding="utf-8"?>
<layout version="0.1.0">
<standingorders_index_index>
<reference name="content">
<block type="standingorders/standingorders" name="standingorders" />
</reference>
</standingorders_index_index>
<checkout_cart_index>
<reference name="head">
<action method="addItem"><type>js_css</type><name>calendar/calendar-win2k-1.css</name><params></params></action>
<action method="addItem"><type>js</type><name>calendar/calendar.js</name></action>
<action method="addItem"><type>js</type><name>calendar/calendar-setup.js</name></action>
<block type="core/html_calendar" name="head.calendar" as="calendar" template="page/js/calendar.phtml"></block>
</reference>
<reference name="checkout.cart">
<action method="addItemRender"><type>simple</type><block>checkout/cart_item_renderer</block>
<template>standingorders/checkout/cart/item/default.phtml</template>
</action>
</reference>
</checkout_cart_index>
<standingorders_ajax_index>
<block type="standingorders/standingorders" name="root" output="toHtml" template="standingorders/checkout/cart/item/call.php" />
</standingorders_ajax_index>
<checkout_onepage_review>
<reference>
<action method="addItemRender"><type>default</type><block>checkout/cart_item_renderer</block>
<template>standingorders/checkout/onepage/review/item.phtml</template>
</action>
</reference>
</checkout_onepage_review>
</layout>
Моя проблема в том, что когда я отключаю Stallioni_Standingorders в Configuration -> Advanced tab, модуль не отключается. Он показывает настройку, которую я сделал в default.phtml. Я очистил кеш, но проблема все еще возникает .. Любая помощь!
1 ответ
Наконец-то я получил ответ. Я переопределил блок в своем модуле. Я переопределил постоянные заказы / блок / постоянные заказы / тележку / предмет / средство визуализации.
Похожие вопросы
Новые вопросы
xml
XML (Extensible Markup Language) - это формат структурированного документа, определяющий правила кодирования текста. При использовании этого тега включайте дополнительные теги, такие как язык программирования, наборы инструментов, используемые технологии XML и другие теги, описывающие среду, в которой опубликована проблема. Гибкость XML обеспечивает широкий спектр применений для передачи человеческих и машинных данных, в том числе конкретных инструментов и библиотек.