Use the one parameter in other pages with Laravel?

0

I am making an application in laravel 5.4 that the administrator modifies various information of a particular client.

Example: Click on Modules in the client list

Theuserisdirectingtoanotherpage,whichisenvironmentthatwilllist,modify,etc.Allinformationforeachmoduleofthisclient.

But my problem is that I'm having to spend ID of the client on all pages, by URL .

Example:

  

admin / modules / 1 / financial / data the '1' is the customer ID.

Or

  

admin / modules / 1 / provider / data is the customer ID .

I would try to use laravel Service Container , but I could not figure out how to do this in my application.

    
asked by anonymous 06.09.2017 / 16:35

1 answer

0

Hi, I'm trying to use this as an example.

session(['cliente'=>'valor do id']);

and at the end of the last module when it is saved you can use

$id = session()->pull('cliente');

pull () method will take client from session and move to $ id

    
06.09.2017 / 18:09