示例#1
0
 public static function getLocalidadToList($id)
 {
     return Localidades::where('id', $id)->lists('localidad', 'id');
 }
 /**
  * Método de actualizar Localidades por Ajax
  * @return mixed
  */
 public function cambiarLocalidades()
 {
     if (\Request::ajax()) {
         $provincia_id = \Request::input('provincia_id');
         $localidades = Localidades::where('provincia_id', $provincia_id)->where('activo', true)->orderBy('localidad', 'ASC')->select('localidad', 'id')->get();
         return $localidades;
     }
     return null;
 }