Jump to content
thirty bees forum
  • 0

Bootstrap is missing? in an HelpersOptions form it does seem to...


Question

Posted

I have this code in a displayForm() for a new module. ``` $defaultlang = (int)Configuration::get('PSLANGDEFAULT'); $fieldsoptions = array( 'Paramêtres' => array( 'title' => $this->l('Paramétrage'), 'fields' => array( 'ACOLYTEVDFCKOI' => array( 'title' => $this->l('BLOC: Viandes de la ferme c\'est quoi?'), 'type' => 'textareaLang', 'identifier' => 'idckoi', 'cols' => 60, 'rows' => 5, ), ), 'submit' => array( 'title' => $this->l('Save'), 'class' => 'button' ), ), );

    $this->helper = new HelperOptions($this);
    // Module, token and currentIndex
    $this->helper->id = $this->id;
    $this->helper->module = $this;
    $this->helper->name_controller = $this->name;
    $this->helper->token = Tools::getAdminTokenLite('AdminModules');
    $this->helper->currentIndex = AdminController::$currentIndex.'&configure='.$this->name;
    // Language
    $this->helper->default_form_language = $default_lang;
    $this->helper->allow_employee_form_lang = $default_lang;

    // Title and toolbar
    $this->helper->title = $this->displayName;
    $this->helper->show_toolbar = true;
    $this->helper->toolbar_scroll = true;
    $this->helper->submit_action = 'submit'.$this->name;
    $this->helper->toolbar_btn = array(
        'save' => array(
            'desc' => $this->l('Save'),
            'href' => AdminController::$currentIndex.'&configure='.$this->name.'&save'.$this->name.
                '&token='.Tools::getAdminTokenLite('AdminModules'),
        ),
        'back' => array(
            'href' => AdminController::$currentIndex.'&token='.Tools::getAdminTokenLite('AdminModules'),
            'desc' => $this->l('Back to list')
        )
    );

    // Load current value
    $this->helper->fields_value['ACOLYTE_VDFCKOI'] = Configuration::get('ACOLYTE_VDFCKOI');
    $this->helper->tpl_vars = array(
        'languages'    => $this->context->controller->getLanguages(),
        'id_language'  => $this->context->language->id,
    );
    return $this->helper->generateOptions($fields_options);

```

But somehow the form in the configure page in the back office looks very odd: http://c2.acolyte.ws/Screenshot-at-09-09-53.png

What am I doing wrong?

2 answers to this question

Recommended Posts

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...