yordan1984

Member Since 2 Months Ago

Experience Points
600
Total
Experience

4,400 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed
0
Lessons
Completed
Best Reply Awards
0
Best Reply
Awards
  • start your engines Created with Sketch.

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • first-thousand Created with Sketch.

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • 1-year Created with Sketch.

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • 2-years Created with Sketch.

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • 3-years Created with Sketch.

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • 4-years Created with Sketch.

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • 5-years Created with Sketch.

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • school-in-session Created with Sketch.

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • welcome-newcomer Created with Sketch.

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • full-time-student Created with Sketch.

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • pay-it-forward Created with Sketch.

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • subscriber Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • evangelist Created with Sketch.

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • chatty-cathy Created with Sketch.

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • lara-veteran Created with Sketch.

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • 10k-strong Created with Sketch.

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • lara-master Created with Sketch.

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • laracasts-tutor Created with Sketch.

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • laracasts-sensei Created with Sketch.

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • top-50 Created with Sketch.

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

  • Community Pillar

    Earned once your experience points ranks in the top 10 of all Laracasts users.

Level 1
600 XP
Nov
19
2 weeks ago
Activity icon

Replied to MethodNotAllowedHttpException On A Route

Yes, you were rigth, I have'nt seen the PUT input, if I remove it, everithing works just perfecly, thanks a lot

Activity icon

Replied to MethodNotAllowedHttpException On A Route

It is used in a form with a post request...

Activity icon

Replied to MethodNotAllowedHttpException On A Route

I have removed som inputs from the form, because it is too big

< form role="form" class="form-horizontal form-groups-bordered person_form" method="post" action="{{ route('person.myDataUpdate', $person) }}" enctype="multipart/form-data">

    {{ csrf_field() }}

    @if ($errors->any())
        <div class="row">
            <div class="col-sm-offset-2 col-sm-8">
                <div class="alert alert-danger">
                    <ul>
                        @foreach ($errors->all() as $error)
                            <li>{{ $error }}</li>
                        @endforeach
                    </ul>
                </div>
            </div>
        </div>
    @endif

    <input type="hidden" name="_method" value="PUT"/>

    <div class="form-group{{ $errors->any() ? ' has-error' : '' }}">
        <div class="col-md-3" style="margin-top: -10px; padding-top: 10px">
            <div class="rcorners" style="height: 160px; text-align: center;">
                <a href="#" data-toggle="modal" data-target="#myModalViewCard" class="viewcard"><img id="card" src="{{url('pdf/persons/'.$person->elector_key.'/front.jpeg')}}" style="height: 100%; max-width: 210px"></a>
            </div>

            <h4 class="roboto" style="margin-top: 15px;">{{trans('admin.person_information')}}</h4>
            <div class="rcorners" style="height: 524px; overflow-y: auto">
                <table style="border: none; font-family: 'Open Sans Light'" id="data_recorded">
                    <tbody>
                    </tbody>
                </table>
            </div>
        </div>
      
        <div class="col-sm-offset-6 col-sm-3 text-center">
            <button type="submit" class="btn btn-default submit_form">{{ trans('admin.send') }}</button>
        </div>
    </div>

< /form>
Activity icon

Replied to MethodNotAllowedHttpException On A Route

I am calling it on a form, my form alrready have {{ csrf_field() }} incuded

Activity icon

Started a new Conversation MethodNotAllowedHttpException On A Route

Hi everyone, I am currently getting an error from my laravel web site:

Symfony \ Component \ HttpKernel \ Exception \ MethodNotAllowedHttpException No message

It happens when I added a post route, I dont know why this is the new route

Route::post('/admin/myDataUpdate/{id}', '[email protected]')->name('person.myDataUpdate');

Nov
18
2 weeks ago
Activity icon

Replied to Laravel Fails In First Authentication Intent

Actually thanks a lot, I think I found the problem, it was in the authenticated method in LoginController, there was some dirty code that made that strange behaviour.

Activity icon

Started a new Conversation Laravel Fails In First Authentication Intent

Hello every one, I have a problem, on my web site, when an user is created, its authentication fails on the first intent every time, when you try to login at the second intent, the system allows to get in, but at the first time, it usually fails, do someone knows why it can be happening? It was made with laravel 5.7

Nov
12
3 weeks ago
Activity icon

Started a new Conversation Laravel Routes Losted On Activate Https

Hi everyone, the routes of my laravel web site has losted when the https has been activated, this is the message:

Not Found

The requested URL was not found on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

can anyone help me?

Activity icon

Replied to Problem With .htacces File

I have tried everything you sugest me but nothing works, here is the web site, so you can see what is happening:

http://partidointegral.com.mx , I can not understand what is happening

Nov
11
3 weeks ago
Activity icon

Replied to Problem With .htacces File

When I try to cheange languaje, it just reload the web site in the same languaje, but when I try with the autentication it shows:

The page has expired due to inactivity.

Please refresh and try again.

Activity icon

Replied to Problem With .htacces File

But, for example, this route Route::get('lang/{lang}','[email protected]')->name('lang.swap'); as you can see it do not start with / and still it does't work, so, I dont think it is the problem...

Activity icon

Replied to Problem With .htacces File

yes, I think so, should I remove the / character??

Activity icon

Replied to Problem With .htacces File

Here is my web.php file contet:

Route::get('/', '[email protected]')->name('dashboard'); Route::get('/search', function(){ return redirect('dashboard'); });

Auth::routes();

Route::get('/about_us', '[email protected]_us')->name('about_us'); Route::get('/contact_us', '[email protected]_us')->name('contact_us'); Route::get('/mission', '[email protected]')->name('mission'); Route::get('/services', '[email protected]')->name('services'); Route::post('/sendmail', '[email protected]')->name('sendmail');

Route::get('/home', '[email protected]')->name('home');

Route::get('lang/{lang}','[email protected]')->name('lang.swap');

Route::post('/admin/person/filter', '[email protected]')->name('person.filter'); Route::post('/admin/address/filter', '[email protected]')->name('address.filter'); Route::post('/admin/social_network/filter', '[email protected]')->name('social_network.filter'); Route::post('/admin/group/filter', '[email protected]')->name('group.filter'); Route::post('/admin/box_type/filter', '[email protected]')->name('box_type.filter'); Route::post('/admin/political_function/filter', '[email protected]')->name('political_function.filter'); Route::post('/admin/system_function/filter', '[email protected]')->name('system_function.filter'); Route::post('/admin/validation/filter', '[email protected]')->name('validation.filter'); Route::post('/admin/municipality/filter', '[email protected]')->name('municipality.filter'); Route::post('/admin/fed_entity/filter', '[email protected]')->name('fed_entity.filter'); Route::post('/admin/history/filter', '[email protected]')->name('history.filter'); Route::post('/admin/role/filter', '[email protected]')->name('role.filter'); Route::post('/admin/phone_code/filter', '[email protected]')->name('phone_code.filter'); Route::post('/admin/area/filter', '[email protected]')->name('area.filter'); Route::post('/admin/loc_district/filter', '[email protected]')->name('loc_district.filter'); Route::post('/admin/fed_district/filter', '[email protected]')->name('fed_district.filter'); Route::post('/admin/communication/filter', '[email protected]')->name('communication.filter'); Route::post('/admin/section/filter', '[email protected]')->name('section.filter'); Route::post('/admin/block/filter', '[email protected]')->name('block.filter'); Route::post('/admin/colony/filter', '[email protected]')->name('colony.filter'); Route::post('/admin/ocupation/filter', '[email protected]')->name('ocupation.filter'); Route::post('/admin/street/filter', '[email protected]')->name('street.filter'); Route::post('/admin/postal_code/filter', '[email protected]')->name('postal_code.filter');

Route::post('/admin/person/filter', '[email protected]')->name('person.filter'); Route::post('/admin/address/filter', '[email protected]')->name('address.filter'); Route::post('/admin/social_network/filter', '[email protected]')->name('social_network.filter'); Route::post('/admin/group/filter', '[email protected]')->name('group.filter'); Route::post('/admin/box_type/filter', '[email protected]')->name('box_type.filter'); Route::post('/admin/political_function/filter', '[email protected]')->name('political_function.filter'); Route::post('/admin/system_function/filter', '[email protected]')->name('system_function.filter'); Route::post('/admin/validation/filter', '[email protected]')->name('validation.filter'); Route::post('/admin/municipality/filter', '[email protected]')->name('municipality.filter'); Route::post('/admin/fed_entity/filter', '[email protected]')->name('fed_entity.filter'); Route::post('/admin/history/filter', '[email protected]')->name('history.filter'); Route::post('/admin/role/filter', '[email protected]')->name('role.filter'); Route::post('/admin/phone_code/filter', '[email protected]')->name('phone_code.filter'); Route::post('/admin/area/filter', '[email protected]')->name('area.filter'); Route::post('/admin/loc_district/filter', '[email protected]')->name('loc_district.filter'); Route::post('/admin/communication/filter', '[email protected]')->name('communication.filter'); Route::post('/admin/zone/filter', '[email protected]')->name('zone.filter'); Route::post('/admin/user/filter', '[email protected]')->name('user.filter'); Route::post('/admin/section/filter', '[email protected]')->name('section.filter'); Route::post('/admin/block/filter', '[email protected]')->name('block.filter');

Route::get('/admin/person_validation/{temp_id}/verify','[email protected]')->name('person.verify'); Route::post('/admin/person_validation/{temp_id}/save_verify', '[email protected]')->name('person.saveVerify');

Route::group(['middleware' => 'auth','middleware' => 'role'],function(){

Route::get('/dashboard/manage_persons', '[email protected]')->name('dashboard.managePerson');

Route::get('/admin/home/', '[email protected]')->name('home');
Route::get('/user/profile', '[email protected]')->name('profile');
Route::post('/user/profile', '[email protected]_profile')->name('update_profile');

Route::resource('/admin/area', 'AreaController');
Route::resource('/admin/box_type', 'BoxTypeController');
Route::resource('/admin/group', 'GroupController');
Route::resource('/admin/political_function', 'PoliticalFunctionController');
Route::resource('/admin/system_function', 'SystemFunctionController');
Route::resource('/admin/role', 'RoleController');
Route::resource('/admin/social_network', 'SocialNetworkController');
Route::resource('/admin/validation', 'ValidationController');
Route::resource('/admin/municipality', 'MunicipalityController');
Route::resource('/admin/fed_entity', 'FedEntityController');
Route::resource('/admin/history', 'HistoryController');
Route::resource('/admin/person', 'PersonController');
Route::resource('/admin/address', 'AddressController');
Route::resource('/admin/phone_code', 'PhoneCodeController');
Route::resource('/admin/fed_district', 'FedDistrictController');
Route::resource('/admin/loc_district', 'LocDistrictController');
Route::resource('/admin/zone', 'ZoneController');
Route::resource('/admin/user', 'UserController');
Route::resource('/admin/section', 'SectionController');
Route::resource('/admin/block', 'BlockController');
Route::resource('/admin/colony', 'ColonyController');
Route::resource('/admin/ocupation', 'OcupationController');
Route::resource('/admin/street', 'StreetController');
Route::resource('/admin/postal_code', 'PostalCodeController');

Route::resource('/admin/setting', 'SettingController');

Route::post('/admin/group/import/data', '[email protected]')->name('group.importData');
Route::post('/admin/social_network/import/data', '[email protected]')->name('social_network.importData');
Route::post('/admin/role/import/data', '[email protected]')->name('role.importData');
Route::post('/admin/area/import/data', '[email protected]')->name('area.importData');
Route::post('/admin/loc_district/import/data', '[email protected]')->name('loc_district.importData');
Route::post('/admin/fed_district/import/data', '[email protected]')->name('fed_district.importData');
Route::post('/admin/person/import/data', '[email protected]')->name('person.importData');
Route::post('/admin/address/import/data', '[email protected]')->name('address.importData');
Route::post('/admin/fed_entity/import/data', '[email protected]')->name('fed_entity.importData');
Route::post('/admin/system_function/import/data', '[email protected]')->name('system_function.importData');
Route::post('/admin/political_function/import/data', '[email protected]')->name('political_function.importData');
Route::post('/admin/box_type/import/data', '[email protected]')->name('box_type.importData');
Route::post('/admin/validation/import/data', '[email protected]')->name('validation.importData');
Route::post('/admin/zone/import/data', '[email protected]')->name('zone.importData');
Route::post('/admin/municipality/import/data', '[email protected]')->name('municipality.importData');
Route::post('/admin/section/import/data', '[email protected]')->name('section.importData');
Route::post('/admin/block/import/data', '[email protected]')->name('block.importData');
Route::post('/admin/colony/import/data', '[email protected]')->name('colony.importData');
Route::post('/admin/ocupation/import/data', '[email protected]')->name('ocupation.importData');
Route::post('/admin/street/import/data', '[email protected]')->name('street.importData');
Route::post('/admin/postal_code/import/data', '[email protected]')->name('postal_code.importData');


//call address search
Route::post('/admin/address/post_add', '[email protected]_add')->name('address.post_add');

Route::get('/admin/role/{id}/assign_functions/', '[email protected]')->name('role.assignFunction');
Route::get('/admin/role/{id}/assign_groups/', '[email protected]')->name('role.assignGroup');
Route::get('/admin/municipality/{id}/responsible/', '[email protected]')->name('municipality.responsible');
Route::get('/admin/fed_entity/{id}/responsible/', '[email protected]')->name('fed_entity.responsible');

Route::post('/admin/role/save_role_system_function/{id}', '[email protected]')->name('role.saveFunctionRole');
Route::post('/admin/role/save_role_group/{id}', '[email protected]')->name('role.saveGroupRole');
Route::post('/admin/municipality/save_responsible/{id}', '[email protected]')->name('municipality.saveResponsible');
Route::post('/admin/fed_entity/save_responsible/{id}', '[email protected]')->name('fed_entity.saveResponsible');

Route::get('/admin/group/export/{format}', '[email protected]')->name('group.exportData');
Route::get('/admin/role/export/{format}', '[email protected]')->name('role.exportData');
Route::get('/admin/zone/export/{format}', '[email protected]')->name('zone.exportData');
Route::get('/admin/history/export/{format}', '[email protected]')->name('history.exportData');
Route::get('/admin/area/export/{format}', '[email protected]')->name('area.exportData');
Route::get('/admin/loc_district/export/{format}', '[email protected]')->name('loc_district.exportData');
Route::get('/admin/fed_district/export/{format}', '[email protected]')->name('fed_district.exportData');
Route::get('/admin/person/export/{format}', '[email protected]')->name('person.exportData');
Route::get('/admin/setting/export/{format}', '[email protected]')->name('setting.exportData');
Route::get('/admin/address/export/{format}', '[email protected]')->name('address.exportData');
Route::get('/admin/fed_entity/export/{format}', '[email protected]')->name('fed_entity.exportData');
Route::get('/admin/system_function/export/{format}', '[email protected]')->name('system_function.exportData');
Route::get('/admin/political_function/export/{format}', '[email protected]')->name('political_function.exportData');
Route::get('/admin/box_type/export/{format}', '[email protected]')->name('box_type.exportData');
Route::get('/admin/validation/export/{format}', '[email protected]')->name('validation.exportData');
Route::get('/admin/social_network/export/{format}', '[email protected]')->name('social_network.exportData');
Route::get('/admin/municipality/export/{format}', '[email protected]')->name('municipality.exportData');
Route::get('/admin/phone_code/export/{format}', '[email protected]')->name('phone_code.exportData');
Route::get('/admin/user/export/{format}', '[email protected]')->name('user.exportData');
Route::get('/admin/section/export/{format}', '[email protected]')->name('section.exportData');
Route::get('/admin/block/export/{format}', '[email protected]')->name('block.exportData');
Route::get('/admin/colony/export/{format}', '[email protected]')->name('colony.exportData');
Route::get('/admin/ocupation/export/{format}', '[email protected]')->name('ocupation.exportData');
Route::get('/admin/street/export/{format}', '[email protected]')->name('street.exportData');
Route::get('/admin/postal_code/export/{format}', '[email protected]')->name('postal_code.exportData');

//import data
Route::post('/admin/group/import/data', '[email protected]')->name('group.importData');
Route::post('/admin/social_network/import/data', '[email protected]')->name('social_network.importData');
Route::post('/admin/role/import/data', '[email protected]')->name('role.importData');
Route::post('/admin/area/import/data', '[email protected]')->name('area.importData');
Route::post('/admin/loc_district/import/data', '[email protected]')->name('loc_district.importData');
Route::post('/admin/person/import/data', '[email protected]')->name('person.importData');
Route::post('/admin/address/import/data', '[email protected]')->name('address.importData');
Route::post('/admin/fed_entity/import/data', '[email protected]')->name('fed_entity.importData');
Route::post('/admin/system_function/import/data', '[email protected]')->name('system_function.importData');
Route::post('/admin/political_function/import/data', '[email protected]')->name('political_function.importData');
Route::post('/admin/box_type/import/data', '[email protected]')->name('box_type.importData');
Route::post('/admin/validation/import/data', '[email protected]')->name('validation.importData');
Route::post('/admin/municipality/import/data', '[email protected]')->name('municipality.importData');
Route::post('/admin/user/import/data', '[email protected]')->name('user.importData');
Route::post('/admin/section/import/data', '[email protected]')->name('section.importData');
Route::post('/admin/block/import/data', '[email protected]')->name('block.importData');
Route::post('/admin/colony/import/data', '[email protected]')->name('colony.importData');
Route::post('/admin/street/import/data', '[email protected]')->name('street.importData');
Route::post('/admin/postal_code/import/data', '[email protected]')->name('postal_code.importData');

Route::post('/admin/person/responsibilities/save/{id}', '[email protected]')->name('person.saveResponsibilities');
Route::get('/admin/person/responsibilities/assign/{id}', '[email protected]')->name('person.assignResponsibilities');

});

Activity icon

Replied to Problem With .htacces File

Can you talk to me more about it please? if you want to, I can publish my web.php file content

Activity icon

Replied to Problem With .htacces File

Actually no, I am calling http://domain/public, but in .env file the APP_URL var is pointing to http://domain/public, and it has always worked for me...

Activity icon

Replied to Routes Are Not Working On Linux

As the hostgator support said, they are using apache, but is really rare, I can´t find the apache folders, I suppouse they changed the default instalation folder..., how can I know if they are using nginx?

Activity icon

Replied to Problem With .htacces File

Actually is the default htaccess file the one I am using, and it has always worked for me...

Activity icon

Replied to Routes Are Not Working On Linux

Actually no, I am calling http://domain/public, but in .env file the APP_URL var is pointing to http://domain/public, and it has always worked for me...

Activity icon

Started a new Conversation Problem With .htacces File

Hello everyone, I have been trying a problem with my laravel web site, it was tested on a local server with ubuntu 20.02 and windows 10, an tis works perfectly fine, however, when I try to upload to a hosting site, the system does not recognize any route, I have been strugling but the only clue the hosting support give to me is the .htaccess file. These is my .htaccess file, I can not see what is wrong, can anyone help me please?

< IfModule mod_rewrite.c >

< IfModule mod_negotiation.c>
    Options -MultiViews -Indexes
< /IfModule>

RewriteEngine On

# Handle Authorization Header
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

# Redirect Trailing Slashes If Not A Folder...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} (.+)/$
RewriteRule ^ %1 [L,R=301]

# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]

< /IfModule>

Activity icon

Replied to Routes Are Not Working On Linux

Finally it looks like the problem is the .htaccess file in public folder, here is my .htaccess file, can anyone helpme with it?

< IfModule mod_rewrite.c >

< IfModule mod_negotiation.c>
    Options -MultiViews -Indexes
< /IfModule>

RewriteEngine On

# Handle Authorization Header
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

# Redirect Trailing Slashes If Not A Folder...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} (.+)/$
RewriteRule ^ %1 [L,R=301]

# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]

< /IfModule>

Activity icon

Replied to Routes Are Not Working On Linux

Hi, as I am seeing, it should be something that is'nt working on the server, I put another web site that is actually working on another server, and is not working in this server, the routes are losted too, what can be messing with routes in server??

Nov
10
3 weeks ago
Activity icon

Replied to Routes Are Not Working On Linux

I don´t think so, it is on a vps service on hostgator, it is working on a centos 7 os

Activity icon

Replied to Routes Are Not Working On Linux

I alrready made it, but nothing again...

Activity icon

Replied to Routes Are Not Working On Linux

Actually there you can see all routes when route:list is used. When you talk about the site root are you talking about the APP_URL var in .env file?? In a fact if you run php artisan serve all routes are runing just fine, I dont Know what can be happening....

Activity icon

Started a new Conversation Routes Are Not Working On Linux

Hello every one, I have a problem, my laravel 5.7 site does not work on linux server, it is perfectly working on xamplite over windows, but all routes are losted when it is published on linux, It shows me this error:

The page has expired due to inactivity.

Please refresh and try again.

And it sends 404 Not Found error

can any one help me with that??

Sep
25
2 months ago
Activity icon

Replied to Error With Routs

Hi, thanks anyway, I actually found the mistake, I have been sending an id is not existing in database...

Activity icon

Replied to Error With Routs

yes, this is the URL that is been calling http://localhost:8081/politica_integral/public/admin/person/30/edit, actually as I tested the delete URL isn't working too, but index and create are working

Activity icon

Replied to Error With Routs

yes, all other resource controllers are working

Activity icon

Replied to Error With Routs

Actually I removed all routes except the one I am working with and stil gives an error, the strange is that it includes index, create, edit and delete, and all other routes are fine, just this one is getting this error...

Activity icon

Replied to Error With Routs

Sorry, my mistake is PersonController, it is included as Route::resource('/admin/person', 'PersonController');

Activity icon

Started a new Conversation Error With Routs

Hi, laravel is giving to me an error of Sorry, the page you are looking for could not be found. and this page was working, I have no idea of what is wrong, here is my web.php file. The problem is happening when I am calling the edit route of ControlerPerson controller, do anyone see the mistake??

Route::get('/', '[email protected]')->name('dashboard'); Route::get('/search', function(){ return redirect('dashboard'); });

//rutas de autenticación
Auth::routes();

Route::get('/about_us', '[email protected]_us')->name('about_us');
Route::get('/contact_us', '[email protected]_us')->name('contact_us');
Route::get('/mission', '[email protected]')->name('mission');
Route::get('/services', '[email protected]')->name('services');
Route::post('/sendmail', '[email protected]')->name('sendmail');

Route::get('/home', '[email protected]')->name('home');

//call filters
Route::post('/admin/person/filter', '[email protected]')->name('person.filter');
Route::post('/admin/address/filter', '[email protected]')->name('address.filter');
Route::post('/admin/social_network/filter', '[email protected]')->name('social_network.filter');
Route::post('/admin/group/filter', '[email protected]')->name('group.filter');
Route::post('/admin/box_type/filter', '[email protected]')->name('box_type.filter');
Route::post('/admin/political_function/filter', '[email protected]')->name('political_function.filter');
Route::post('/admin/system_function/filter', '[email protected]')->name('system_function.filter');
Route::post('/admin/validation/filter', '[email protected]')->name('validation.filter');
Route::post('/admin/municipality/filter', '[email protected]')->name('municipality.filter');
Route::post('/admin/fed_entity/filter', '[email protected]')->name('fed_entity.filter');
Route::post('/admin/history/filter', '[email protected]')->name('history.filter');
Route::post('/admin/role/filter', '[email protected]')->name('role.filter');
Route::post('/admin/phone_code/filter', '[email protected]')->name('phone_code.filter');
Route::post('/admin/area/filter', '[email protected]')->name('area.filter');
Route::post('/admin/loc_district/filter', '[email protected]')->name('loc_district.filter');
Route::post('/admin/communication/filter', '[email protected]')->name('communication.filter');

//switch entre los lenguajes
Route::get('lang/{lang}','[email protected]')->name('lang.swap');

//verify person
Route::get('/admin/person_validation/{temp_id}/verify','[email protected]')->name('person.verify');


//middleware para asegurar autenticacion
Route::group(['middleware' => 'auth','middleware' => 'role'],function(){

	Route::get('/admin/home/', '[email protected]')->name('home');
	Route::get('/user/profile', '[email protected]')->name('profile');
	Route::post('/user/profile', '[email protected]_profile')->name('update_profile');

	Route::resource('/admin/area', 'AreaController');
	Route::resource('/admin/box_type', 'BoxTypeController');
	Route::resource('/admin/group', 'GroupController');
	Route::resource('/admin/political_function', 'PoliticalFunctionController');
	Route::resource('/admin/system_function', 'SystemFunctionController');
	Route::resource('/admin/role', 'RoleController');
	Route::resource('/admin/social_network', 'SocialNetworkController');
	Route::resource('/admin/validation', 'ValidationController');
	Route::resource('/admin/municipality', 'MunicipalityController');
	Route::resource('/admin/fed_entity', 'FedEntityController');
	Route::resource('/admin/history', 'HistoryController');
	Route::resource('/admin/person', 'PersonController');
	Route::resource('/admin/address', 'AddressController');
	Route::resource('/admin/phone_code', 'PhoneCodeController');
	Route::resource('/admin/loc_district', 'LocDistrictController');
	Route::resource('/admin/setting', 'SettingController');

	//import data
	Route::post('/admin/group/import/data', '[email protected]')->name('group.importData');
	Route::post('/admin/social_network/import/data', '[email protected]')->name('social_network.importData');
	Route::post('/admin/role/import/data', '[email protected]')->name('role.importData');
	Route::post('/admin/area/import/data', '[email protected]')->name('area.importData');
	Route::post('/admin/loc_district/import/data', '[email protected]')->name('loc_district.importData');
	Route::post('/admin/person/import/data', '[email protected]')->name('person.importData');
	Route::post('/admin/address/import/data', '[email protected]')->name('address.importData');
	Route::post('/admin/fed_entity/import/data', '[email protected]')->name('fed_entity.importData');
	Route::post('/admin/system_function/import/data', '[email protected]')->name('system_function.importData');
	Route::post('/admin/political_function/import/data', '[email protected]')->name('political_function.importData');
	Route::post('/admin/box_type/import/data', '[email protected]')->name('box_type.importData');
	Route::post('/admin/validation/import/data', '[email protected]')->name('validation.importData');
	Route::post('/admin/municipality/import/data', '[email protected]')->name('municipality.importData');

	//call address search
	Route::post('/admin/address/post_add', '[email protected]_add')->name('address.post_add');

	Route::get('/admin/role/{id}/assign_functions/', '[email protected]')->name('role.assignFunction');
	Route::get('/admin/role/{id}/assign_groups/', '[email protected]')->name('role.assignGroup');
	Route::get('/admin/municipality/{id}/responsible/', '[email protected]')->name('municipality.responsible');
	Route::get('/admin/fed_entity/{id}/responsible/', '[email protected]')->name('fed_entity.responsible');

	Route::post('/admin/role/save_role_system_function/{id}', '[email protected]')->name('role.saveFunctionRole');
	Route::post('/admin/role/save_role_group/{id}', '[email protected]')->name('role.saveGroupRole');
	Route::post('/admin/municipality/save_responsible/{id}', '[email protected]')->name('municipality.saveResponsible');
	Route::post('/admin/fed_entity/save_responsible/{id}', '[email protected]')->name('fed_entity.saveResponsible');

	//excel, csv
	Route::get('/admin/group/export/{format}', '[email protected]')->name('group.exportData');
	Route::get('/admin/role/export/{format}', '[email protected]')->name('role.exportData');
	Route::get('/admin/history/export/{format}', '[email protected]')->name('history.exportData');
	Route::get('/admin/area/export/{format}', '[email protected]')->name('area.exportData');
	Route::get('/admin/loc_district/export/{format}', '[email protected]')->name('loc_district.exportData');
	Route::get('/admin/person/export/{format}', '[email protected]')->name('person.exportData');
	Route::get('/admin/setting/export/{format}', '[email protected]')->name('setting.exportData');
	Route::get('/admin/address/export/{format}', '[email protected]')->name('address.exportData');
	Route::get('/admin/fed_entity/export/{format}', '[email protected]')->name('fed_entity.exportData');
	Route::get('/admin/system_function/export/{format}', '[email protected]')->name('system_function.exportData');
	Route::get('/admin/political_function/export/{format}', '[email protected]')->name('political_function.exportData');
	Route::get('/admin/box_type/export/{format}', '[email protected]')->name('box_type.exportData');
	Route::get('/admin/validation/export/{format}', '[email protected]')->name('validation.exportData');
	Route::get('/admin/social_network/export/{format}', '[email protected]')->name('social_network.exportData');
	Route::get('/admin/municipality/export/{format}', '[email protected]')->name('municipality.exportData');

	//call asign political functions
	Route::get('/admin/person/responsibilities/assign/{id}', '[email protected]')->name('person.assignResponsibilities');

});
Sep
14
2 months ago
Activity icon

Started a new Conversation Laravel + Maatwebsite Error

Hello everyone, I am trying to use /maatwebsite library to export excel for the first time, but when I try to export data, the system gives this error:

SQLSTATE[22P02]: Invalid text representation: 7 ERROR: la sintaxis de entrada no es válida para integer: «exportExcel» (SQL: select * from "groups" where "id" = exportExcel limit 1)

Here is my code:

html: a href="{{ route('group.exportExcel') }}"> <i class="fa fa-file-excel-o" </i </a (tags has been removed for post reazons)

web.php: Route::get('/admin/group/exportExcel', '[email protected]')->name('group.exportExcel');

GroupController: public function exportExcel(Request $request){ return Excel::download(new GroupExport(),'group.xls'); }

App/Exports/GroupExport.php:

use App\Group; use Illuminate\Support\Collection; use Maatwebsite\Excel\Concerns\FromCollection;

class GroupExport implements FromCollection { /** * @return Collection */ public function collection() { return Group::all(); } }

Can anyone help me please?