Questions tagged as 'laravel-5'

2
answers

Problems viewing the Data Laravel 5.1 [closed]

I'm a beginner in Laravel and I'm trying to get data from a DB with multiple Postgresql schemas with Laravel 5.1 and it's bringing me an error What configuration should I make for the model to correctly access the table of that schema? Dir...
asked by 04.01.2016 / 20:41
1
answer

Defining a middleware for a controller, except a function in Laravel 5

I'm starting to work now with Laravel and realized that defining the routes directly to the controls where I can set the HTTP request type is more feasible for my application. Today I have something like this: routes.php Route::controller...
asked by 07.08.2016 / 00:42
1
answer

Check which of the 'guards' is loggedin

I have a large application 5.2, with multiauthentication, the guards configured in config/auth.php are: ... 'admin' => [ 'driver' => 'session', 'provider' => 'admin', ], 'user' => [ 'driver' => 'session',...
asked by 17.08.2016 / 15:50
1
answer

Failed to register a package created in Laravel 5.1

I'm developing a package for Laravel 5.1 and I've already identified a problem that I could not find the solution for. Displays the following error: FatalErrorException in ProviderRepository.php line 146: Class 'MyNamespace\MyApp\MyAppServi...
asked by 23.06.2015 / 19:53
1
answer

Undefined offset 0 - Laravel

I have a list of users, each user has their 'role' (role / function inside the system, such as 'user' and 'admin') and this role has to be shown in the users list screen, which I I did it using the code block below. @foreach ($users as $key =&...
asked by 20.09.2018 / 20:40
1
answer

Redirect failure Laravel

Expensive, Can you help me with this laravel redirect? I created a method where it re-evaluates the data and redirects, on the other hand at the time of redirect I get the error Route [climate.consensus.visual.ID] not defined, only that I def...
asked by 11.09.2018 / 19:35
1
answer

Laravel - Validate field unique in update

I have an enrollment field in the table that needs to be unique NA MIGRATION Schema::create('professors', function (Blueprint $table) { $table->increments('id'); $table->boolean('inativo')->default(0); $tabl...
asked by 10.05.2018 / 16:17
2
answers

Consultations in Laravel

I'm trying to run a query in Laravel , the terminal works perfectly, but when I enter in Laravel , it returns me empty, eg: Query: SELECT MAX(positions.id), devices.name, positions.deviceid, positions.ser...
asked by 07.03.2018 / 19:13
1
answer

Return API Laravel json

I have a following problem, I made a API and it returns me a array : "id": 1, "email": "[email protected]", "senha": "lucas123", "created_at": "2018-02-15 16:48:12", "updated_at": "2018-02-15 16:48:12"' I would like to only retur...
asked by 06.03.2018 / 14:57
1
answer

How to make specific queries in sql using Laravel?

I need to make an appointment at the bank to see the birthday of the current month. Such a query, see:    SELECT * FROM membros WHERE day(dataNasc) = day(CURRENT_DATE) and month(dataNasc) = month(CURRENT_DATE); How could I make thi...
asked by 04.09.2017 / 04:37