Jump to content

Add classes from a module


Recommended Posts

Hi,

 

I am adding  a form like "customers->contacts " in prestashop, I copied the contoller file and class file and pasted in my module to achieve the same feature but when listing I got "Fatal error: Class 'Organization' not found in /opt/lampp/htdocs/baps/classes/controller/AdminController.php on line 1625

 

public function __construct()
    {
        $this->bootstrap = true;
        $this->table = 'organization';
        $this->className = 'Organization';        
        $this->addRowAction('edit');
        $this->addRowAction('delete');
        $this->bulk_actions = array(
            'delete' => array(
                'text' => $this->l('Delete selected'),
                'confirm' => $this->l('Delete selected items?'),
                'icon' => 'icon-trash'
            )
        );
 
        $this->fields_list = array(
            'id_contact' => array('title' => $this->l('ID'), 'align' => 'center', 'class' => 'fixed-width-xs'),
            'org_name' => array('title' => $this->l('Organization Name')),
            'org_level' => array('title' => $this->l('Organization Level')),
            'org_address1' => array('title' => $this->l('Organization Address1')),
            'org_address2' => array('title' => $this->l('Organization Address2')),
            'org_state' => array('title' => $this->l('Organization State')),
            'org_city' => array('title' => $this->l('Organization City')),
            'org_zipcode' => array('title' => $this->l('Organization Zipcode')),
            'admin_level' => array('title' => $this->l('Parent Level')),
        );
 
        parent::__construct();
    }
 
 
In the construct how to add class files from my module?
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...