I have the following scene:
$consulta = Dealer::find(1);
No Model
# Serviços
public function dealer_servicos(){
return $this->hasMany('App\DealerService', 'id_concessionaria');
}
Then if I do:
@foreach($consulta->dealer...
Good morning, other than Laravel 4 , the 5.1 version creates the Models directly in the App folder, I wanted to know if it will influence something if I create folders to better organize those Models .
Hey guys, all right?
I would really appreciate your help as I have been stuck with this problem for a couple of days and can not solve it myself.
I have a multi-line table with a checkbox on each line and a button that, when clicked, takes...
I created a CRUD with Modal is working everything right but I created form request data view, queries with BD all inside Routes, I do not think very cool would like to pass these features to the Controller to do but is not working is appearing t...
Personal I have the code below in Laravel that saves a single image and works correctly. But I would like to save multiple images that come from an input that looks like name: "name []" multiple. I think I would need a for but I could not get it...
In% with both 4 and 5, we have class Laravel , which allows specific validations.
By default there are several, such as Validator , required , email , and others.
But I would also like to be able to validate a phon...
Actually, this way, is it really wrong? I'm not really understanding the typing:
class FinanceiroController extends Controller
{
/**
* @var ChamadosFinanceirosRepository
*/
private $chamadosFinanceirosRepository;
/**...
My question is about the following:
public function getIndex()
{
$users = \User::all();
return \View::make('admin.users.index')
->with('title', 'Usuários')
->with('users', $users);
}
In this case I called the all()...
I created a function in the controller that returns me the users where the user_anjo condition is equal to 1.
You are currently returning all of this user's data in json.
How can I do to return only the user's emails?
I tried something...