⚠ In case you've missed it we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This forum is read-only and soon will be archived. ⚠


aserfozo

Member Since 02 Jan 2021
Offline Last Active Jan 04 2021 04:52 PM
-----

Topics I've Started

setActionButton not working -> GroceryCrud Enterprise v2.8.7

02 January 2021 - 03:14 AM

Hello

 

I have been working in a new project and using GC Enterprise. The issue that has arisen is that the setActionButton function does not render a button. I am using the given example from the online documentation as is but there is not Avatar button showing after a browser cache clear  and page refresh. The table works flawlessly otherwise. 

 

The code used is directly copied from the example as: $crud->setActionButton('Avatar', 'fa fa-user', function ($row) { return '/view_avatar/' . $row->url; }, true);

 

The only thing I get on the page in the table rows is the edit, more -> view, delete buttons. 

 

complete code is as follows in Codeigniter class

 

$crud = $this->engineModel->getGCE('app');
$crud->setActionButton('Avatar', 'fa fa-user', function ($row) { return '/demo_view_avatar/' . $row->employeeNumber;}, true);
$crud->setApiUrlPath('getInventory');
 
$output = $crud->render();

$this->loadGcView($outputt);

 

using bootstrap v4 theme

 

 

Can anyone help with this please?

Thank You

Andras