subgrid & multiple tab on Laravel

Questionssubgrid & multiple tab on Laravel
Gianluca asked 5 years ago

Hi,

can someone give me basic tips for handling subgrid & multiple tab grid on laravel.

I don’t understand if I need more controllers and more blade view.

 

Thank in advance

7 Answers
Abu Ghufran Staff answered 5 years ago

You can make multiple tabs grid same way as you make single grid in laravel (controller/view).

You only need to prepare $out1 $out2 $out3 etc in controller by calling multiple $g->render() function and pass all of them to view. Then put tabs html in blade view and echo respective $out variables in tab DIV tags.

_________________________
Abu Ghufran - Dev Team
Grid 4 PHP Framework
 
gianluca answered 5 years ago

Thanks Abu,

and what about subgrid?

I’m trying join your laravel example with subgrid demos, without success

Abu answered 5 years ago

Emailed you demo code.

Samsun answered 5 years ago

Hey Mr Gianluca, May be you use multi tab with ajax, wher every tab with url link. every tab is one grid/method. I use this methode in Codeigniter use librrary http://www.dynamicdrive.com/dynamicindex17/ajaxtabscontent/index.htm. Regards, Samsun

Abu Ghufran Staff answered 5 years ago

Resolved via remote session.

_________________________
Abu Ghufran - Dev Team
Grid 4 PHP Framework
 
Raghu answered 4 years ago

I am facing the issue with Subgrid in laravel. It always says subgrid file not found. Even all path are correct. Can you please help us.

Abu Ghufran Staff answered 4 years ago

Continuing the guide: https://www.gridphp.com/laravel-datagrid/

To enable subgrid, process is simple:

Step1: Add subgrid method / config in controller. See attached file WelcomeController.php 47-47, 71-97

Step2: Add subgrid routes, routes/web.php
Route::get(‘/indexDetail’, ‘WelcomeController@indexDetail’);
Route::post(‘/indexDetail’, ‘WelcomeController@indexDetail’);

Step3: Add view for subgrid, detail.blade.php (used in WelcomeController.php line 96)

Files source code: https://gist.github.com/gridphp/8e4c337cf4e5c81771b60a16b28d541b

_________________________
Abu Ghufran - Dev Team
Grid 4 PHP Framework
 
Your Answer

19 + 1 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?