我的客户经营一个多店,其产品非常不同,布局不同,领域不同。 我为其中一个仓库的检查过程做了延伸,现在看不出只向Magento提供与这一特定仓库合作的途径。
我期望这一点在xml的/app/etc/modules/sampleextension.xml中提及,但并没有在互联网上找到这方面的任何信息。
是否有办法具体安排展期讲习班?
Thanks Thomas
我的客户经营一个多店,其产品非常不同,布局不同,领域不同。 我为其中一个仓库的检查过程做了延伸,现在看不出只向Magento提供与这一特定仓库合作的途径。
我期望这一点在xml的/app/etc/modules/sampleextension.xml中提及,但并没有在互联网上找到这方面的任何信息。
是否有办法具体安排展期讲习班?
Thanks Thomas
There are two solutions. 1) Programmatically: You can make any configuration field, store specific. And from that you can check, in code if you need to activate your module or not. With the file /app/code//yourcompany/yourmodule/etc/system.xml, thanks to the tags show_in_default, show_in_store, show_in_website, you can set a configuration field store view, website or by default.
因此,你必须建立一个“积极”的组合领域。 这意味着,付款方法配置领域的“活动”途径是付款/付款名称/活动。
而且,从这条道路上看,如果你把支付班级延长。 Mage_Payment_Model_Method_ 摘要是,Magento将检查能否获得付款模块。
2. 检查等级和方法 Mage_Payment_Model_Method_Abstract:isAvailable at the file app/code/core/Mage/Payment/Model/Method/Abstract.php
如果你将背信弃你的支付方法,你将不得不按照你的愿望,将“1”现场“活跃”用于储存观点或网站,或默认。
这里,“组合文件系统”的一个实例是,贵方付款模块。
<config>
<sections>
<payment translate="label" module="payment">
<label>Payment Methods</label>
<tab>sales</tab>
<frontend_type>text</frontend_type>
<sort_order>400</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
<groups>
<yourpaymentname translate="label">
<label>Your new Payment method</label>
<frontend_type>text</frontend_type>
<sort_order>1</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
<fields>
<active translate="label">
<label>Enabled</label>
<frontend_type>select</frontend_type>
<source_model>adminhtml/system_config_source_yesno</source_model>
<sort_order>1</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>0</show_in_store>
</active>
<yourpaymentname>
</groups>
....
</sales>
<sections>
2) The second solution can be done through the backend, the easiest way maybe, in the tab Advanced of the configuration page, at the bottom left of the configuration page. You will have a list of all enabled or disabled modules in your shop. You select which store view you want to display or not, in the store switcher, at the top left of the page then you choose which module to enable or not thanks to the drop down menu in front of each module name.
Hope it helps Regards
you could/should have a "active" field, in your system.xml, which d be a dropdown "yes/no", and then you can (des)active it for every website/store/store view.
Of course in some strategic points of your code you will check if it s active for this view :)
When using the Magento collection method addFieldToFilter is it possible to allow filtering by NULL values? I want to select all the products in a collection that have a custom attribute even if no ...
I am new to Magento and using their API. I need to be able to get the product url from the API call. I see that I can access the url_key and url_path, but unfortunately that s not necessarily what ...
My problem is I want to change my category page layout similar as homepage I tried a lot but didn t get the answer.
I want to install a Magento extension in WAMP, but not from the Magento connect system. How can I do this? I have the module (extension) code and I already installed the sample data in the Magento ...
Is it possible to redirect the browser to nth step in the onepage checkout? If so, how would one go about doing it? I m working on a payment module and have a sort of "cancel" action that i would ...
I was wondering if it possible to link a category to My Account . Basically I would like to make My Account more prominent, by creating a category - My Account which appears in the main menu ...
I have a ‘featured’ attribute, which has a Yes/No select-list as the admin input. I presume that the values for Yes and No are 1 and 0, as they are for every other Yes/No list. However, if I try and ...
I tried importing product images into Magento using an absolute path, but it did not work. The image was not uploaded. For example, I tried importing "http://somewebsite.com/someimage.jpg". The image ...