尝试访问配置面板时出现Magento system.xml和404错误 [英] Magento system.xml and 404 error when trying to access the configuration panel

查看:247
本文介绍了尝试访问配置面板时出现Magento system.xml和404错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想为我的自定义模块实现一些配置设置。我已设法在左侧导航栏中添加标签和部分。但是当我想打开一个部分,我得到一个404错误页,没有任何进一步的信息。

I'm trying to implement some configuration settings for my custom module. I've managed to add a tab and a section in the left navigation bar. But when I want to open a section I get a 404 error page without any further information.

到目前为止,我已经尝试了任何东西使其工作..阅读博客,示例等,但我找不到错误。也许有人可以向我解释我做错了什么。

So far, I've tried anything to get it working.. reading blogs, examples etc. but I can't find the error. Maybe someone of you can explain me what I'm doing wrong.

我的adminhtml.xml:

my adminhtml.xml:

<?xml version="1.0" ?>
<config>
    <resources>
        <admin>
            <children>
                <system>
                    <children>
                        <config>
                            <children>
                                <tempest_section translate="title" module="Tempest">
                                    <title>Tempest</title>
                                </tempest_section>
                            </children>
                        </config>
                    </children>
                </system>
            </children>
        </admin>
    </resources>
</config>

我的config.xml:

my config.xml:

<?xml version="1.0"?>

<config>
    <modules>
        <Polyvision_Tempest>
            <version>0.1.0</version>
        </Polyvision_Tempest>
    </modules>


    <global>
        <helpers>
            <Tempest>
                <class>Polyvision_Tempest_Helper</class>
            </Tempest>  
        </helpers>
    </global>        

    <admin>
        <routers>
            <adminhtml>
                <args>
                    <modules>
                        <tempest before="Mage_Adminhtml">Polyvision_Tempest_Adminhtml</tempest>
                    </modules>
                </args>
            </adminhtml>
        </routers>
    </admin>


    <adminhtml>
        <menu>
            <menu1 translate="title" module="Tempest">
                <title>polyvision</title>
                <sort_order>60</sort_order>
                <children>
                    <menuitem1 module="Tempest">
                        <title>Tempest - Export</title>
                        <action>adminhtml/tempest_main</action>
                    </menuitem1>
                </children>                
            </menu1>
        </menu>
    </adminhtml>    

    <default>
        <tempest>
            <settings>
                <export_directory>/tmp/</export_directory>
            </settings>
        </tempest>
    </default>
</config>

my system.xml:

my system.xml:

<?xml version="1.0" ?>
<config>
    <tabs>
        <polyvision module="Tempest" translate="label">
            <label>polyvision</label>
            <sort_order>100</sort_order>
        </polyvision>
    </tabs>
    <sections>
        <tempest_section module="Tempest" translate="label">
            <label>Tempest-Einstellungen</label>
            <sort_order>200</sort_order>
            <show_in_default>1</show_in_default>
            <show_in_website>1</show_in_website>
            <show_in_store>1</show_in_store>
            <tab>polyvision</tab>
            <groups>
                <settings translate="label">
                    <label>Settings</label>
                    <comment></comment>
                    <sort_order>10</sort_order>
                    <show_in_default>1</show_in_default>
                    <show_in_website>1</show_in_website>
                    <show_in_store>1</show_in_store>
                    <fields>
                        <export_directory translate="label tooltip comment">
                            <label>My Custom Field</label>
                            <comment>Some comment about my field</comment>
                            <tooltip>Field ToolTip</tooltip>
                            <show_in_default>1</show_in_default>
                            <show_in_website>1</show_in_website>
                            <show_in_store>1</show_in_store>
                        <frontend_input>text</frontend_input>
                        <source_model>adminhtml/system_config_text</source_model>
                    </export_directory>
                </fields>
            </settings>
        </groups>
    </tempest_section>
</sections>

没有麻烦。只有管​​理员设置无效:/

Well, my module itself works without hassles. Only the admin settings are not working :/

回答:Alex

推荐答案

p>如果是管理控制台Chrome中的404,那么您的问题是缺少ACL角色。请阅读本文,了解如何设置。 (自我链接)

If it's the 404 in the Admin Console chrome, then your problem is a missing ACL role. Read this article on how to set one up. (self link)

此外,设置您的ACL角色后,您需要清除您的Magento会话。 Magento缓存会话中的特定角色,新会话不会自动添加到具有超级用户角色的用户缓存中。

Also, after setting up your ACL role, you'll need to clear out your Magento sessions. Magento caches specific roles in the session, and new sessions won't be automatically added to the cache of users with the super user role.

这篇关于尝试访问配置面板时出现Magento system.xml和404错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆