Jump to content


Soreno

Member Since 02 Oct 2019
Offline Last Active Feb 25 2020 11:37 AM
-----

Posts I've Made

In Topic: Problem with the setRelation dropdown.

04 February 2020 - 08:47 PM

Hello, dhouwen.

It depends on settings of your database field. If that field has NOT NULL constraint you will not have empty option in your GC.


In Topic: Unable to load the requested class: Grocery_CRUD

17 January 2020 - 07:04 PM

Hello, rkrajnik.
Try

$config = include(APPPATH . 'config/gcrud-enterprise.php');

 


In Topic: Don't find field in setRelation with where clause

17 January 2020 - 03:41 PM

Hello, nunenthal.

Try this

$crud->setRelation('dossier_id', 'dossier', 'nom_dossier', ['user_id' => $client_id]);

In Topic: unsetBootstrap() causes more function to no longer work

20 December 2019 - 04:36 PM

Hi, drinkingwine.
When you use unsetBootstrap() you need to add into the crud output php file both .css and .js files.


In Topic: Insert Account number on Add

20 November 2019 - 10:19 PM

Hello, drinkingwine.

Try to create private variable in you class than set your id value in it and use it in callbackAddForm function.

class YourController extends CI_Controller {

    private $accountId = 0;

    public function YourFunction($id)
    {
        ...
        $this->accountId = $id;
        
        $crud->callbackAddForm(function ($data) {
            $data['account'] = $this->accountId;
            return $data;
        });
        ...
    }

}