Questions tagged as 'laravel'

1
answer

How to transform an Eloquent Collection into a simple array?

I'm doing a query to the bank and a Collection is being returned ... How do I instead of having to call $role->role to get the column value, achieve the same behavior by calling only $role ? > Current code: $roles = Role::all...
asked by 06.12.2018 / 19:30
1
answer

Customization of Fields Login Laravel

It's been a while since I've been headlining this Laravel Authentication System and I need to learn how to properly override functions to be able to use custom fields by default. Laravel uses email and password . I want to use pa...
asked by 03.12.2018 / 21:48
1
answer

Update of a single information in Laravel

I'm starting to work with Laravel and wanted to know if you can help me. I need to update a single value in the database, using 'name' in the where clause instead of id. This is for a situation of a real system that I need to migrate to Larav...
asked by 20.11.2018 / 22:02
1
answer

Laravel: How to retrieve the last record inserted in the mysql database by its foreign key?

I'm working on a database that has only as a reference your foreign key, and I need to locate the last record based on your foreign key.     
asked by 09.11.2018 / 19:53
1
answer

Error in Laravel after inserting the save () method

Good afternoon I'm trying at all costs to make an insert in the bank, using Laravel and Controller, however, it does not work at all, I've tried everything that is shape, doing migrate, changing screen name, anyway, in any way and nothing. In my...
asked by 18.08.2014 / 23:10
1
answer

Form unconfigures DIV

Div is not side by side after I insert the {!! Form:: inside the div row, the div divs are broken, one underneath the other instead of side by side. Is it possible to solve this? or is it normal for Form to make this mess?    Bootstrap...
asked by 26.07.2018 / 16:26
1
answer

Pass parameter to route resource | Laravel

I'm developing a project control application. Each project has its tasks, that is, when I create a task, it needs to be linked to the project. I'm using the Laravel feature of Route resource. When I pass the project id to the route, it does not...
asked by 27.11.2018 / 01:40
1
answer

How to delete a record from a table in the undeleted view of the database

I'm developing a system at didactic level and in my view I have a table that displays the data of an employee registered by the user. In the view you have the edit and delete buttons, but deleting it is also deleting the the record in the databa...
asked by 05.09.2018 / 21:25
2
answers

response () in XML with Laravel

I have studied about the development of APIs with Laravel, a quick question, is it possible to return an XML instead of a json? instead of doing: return response()->json($json); Do something like: return response()->xml($xml);...
asked by 24.07.2018 / 16:07
1
answer

A single application of laravel with many database

I have an application with the Laravel framework that I have created many subdomains to access. Today I make a separate environment for each one, but the files in each of them will be the same. My question is, is it possible to make a single...
asked by 20.08.2018 / 21:31