samedi 28 octobre 2017

How to place a range in the model::list method for combo in laravel?

I would like you to help me, to solve my question, and I would like to know what is the way to range my combo of charges, which comes from the database in the description field, but It list all the records , and I just need to show some of them, so I need to know how to set a range for the mentioned combo, This is where my combo is that gives me all the charges that are registered in the database, to pass them to a View to a select tag:

//VIEW TO REGISTER USERS
  public function VistaRegistraUsuario()
{

  $id_franquicia_usuario = Session::get('id_franquicia');
  $charges = charges_users::lists('descripcion', 'id'); //COMBO OF CHARGES

  return view('auth.register', compact('charges', 'id_franquicia_usuario'));
}// END VIEW



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire