1

I installed an extension a while ago, which continues to throw back errors every time I try to configure it. When I go to backend, and then select "Shipping Methods" and then from the top left drop down "Default Website > Main Website" I get an exception thrown back at me, I've attempted to find the issue and after many hours of searching, I've failed to find anything close to a resolution.

This is the error -

Invalid config field backend model: 
dpd/adminhtml_system_config_backend_shipping_dpdclassic_tablerate

Trace:
#0 /html/magento/app/code/core/Mage/Adminhtml/Block/System/Config/Form.php(328): Mage::throwException('Invalid config ...')
#1 /html/magento/app/code/core/Mage/Adminhtml/Block/System/Config/Form.php(229): Mage_Adminhtml_Block_System_Config_Form->initFields(Object
(Varien_Data_Form_Element_Fieldset), Object(Mage_Core_Model_Config_Element), Object(Mage_Core_Model_Config_Element))
#2 /html/magento/app/code/core/Mage/Adminhtml/Block/System/Config/Form.php(164): Mage_Adminhtml_Block_System_Config_Form->_initGroup(Objec
(Varien_Data_Form), Object(Mage_Core_Model_Config_Element), Object(Mage_Core_Model_Config_Element))
#3 /html/magento/app/code/core/Mage/Adminhtml/Block/System/Config/Edit.php(92): Mage_Adminhtml_Block_System_Config_Form->initForm()
#4 /html/magento/app/code/core/Mage/Adminhtml/controllers/System/ConfigController.php(107): Mage_Adminhtml_Block_System_Config_Edit->initForm()
#5 /html/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(419): Mage_Adminhtml_System_ConfigController->editAction()
#6 /html/magento/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('edit')
#7 /html/magento/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object
Mage_Core_Controller_Request_Http))
#8 /html/magento/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#9 /html/magento/app/Mage.php(683): Mage_Core_Model_App->run(Array)
#10 /html/magento/index.php(90): Mage::run('', 'store')
#11 {main}

Perhaps someone could help me with this and find a fix? I've contacted the plugin creators but been given the whole "It's not our problem" run around.

closed as off-topic by Siarhey Uchukhlebau, Rakesh Jesadiya, Keyul Shah, Amit Bera, Murtuza Zabuawala May 15 '17 at 9:51

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions about third-party modules are generally off-topic because the scope of functionality and code are not available. For more information, see this meta post/answer." – Siarhey Uchukhlebau, Rakesh Jesadiya, Keyul Shah, Amit Bera, Murtuza Zabuawala
If this question can be reworded to fit the rules in the help center, please edit the question.

  • Please check if file exist: Dpd/Block/Adminhtml/System/Config/Backend/Shipping/Dpdclassic/Tablerate.php – sv3n May 12 '17 at 10:49
  • The folder structure only goes up to /system/config/ after that it branches off into /form/ and not /backend/ Is this is a broken installation? – Phil May 12 '17 at 10:53
  • sv3n, I have a direct download for the DPD plugin in question; and I've opened the .zip and found no such location. It seems to branch off from another location but it isn't specified where? – Phil May 12 '17 at 10:55
  • Any download link? – sv3n May 12 '17 at 10:58
0

Open file: app/code/community/DPD/Shipping/etc/system.xml

Change:

<import_classic translate="label">
    <label>Import table rates file</label>
    <frontend_type>import</frontend_type>
    <sort_order>9</sort_order>
    <backend_model>dpd/adminhtml_system_config_backend_shipping_dpdclassic_tablerate</backend_model>
    <depends>
        <ratetype>1</ratetype>
    </depends>
    <show_in_default>0</show_in_default>
    <show_in_website>1</show_in_website>
    <show_in_store>0</show_in_store>
    <comment>Upload your table rates configuration here. Refer to the manual for more information</comment>
</import_classic>

To the (remove unexisting backend model):

<import_classic translate="label">
    <label>Import table rates file</label>
    <frontend_type>import</frontend_type>
    <sort_order>9</sort_order>
    <depends>
        <ratetype>1</ratetype>
    </depends>
    <show_in_default>0</show_in_default>
    <show_in_website>1</show_in_website>
    <show_in_store>0</show_in_store>
    <comment>Upload your table rates configuration here. Refer to the manual for more information</comment>
</import_classic>

Or create file DPD/Shipping/Model/Adminhtml/System/Config/Backend/Shipping/Dpdclassic/Tablerate.php with content from the old module version:

<?php
/**
 * Created by PHPro
 *
 * @package      DPD
 * @subpackage   Shipping
 * @category     Checkout
 * @author       PHPro (info@phpro.be)
 */
/**
 * Class DPD_Shipping_Model_Adminhtml_System_Config_Backend_Shipping_Dpdclassic_Tablerate
 */
class DPD_Shipping_Model_Adminhtml_System_Config_Backend_Shipping_Dpdclassic_Tablerate extends Mage_Core_Model_Config_Data
{
    /**
     * Call the uploadAndImport function from the classic tablerate recourcemodel.
     */
    public function _afterSave()
    {
        Mage::getResourceModel('dpd/dpdclassic_tablerate')->uploadAndImport($this);
    }
}
  • I just followed your first section and it worked perfectly! Thank you so much for your help. Very appreciated. I will continue to work with this and I'll be sure to refer to this in the future. I will definitely need it! Much appreciated! :-) – Phil May 15 '17 at 6:25

Not the answer you're looking for? Browse other questions tagged or ask your own question.