cac

cac

Member Since 1 Year Ago

Uberlandia

Experience Points
3,660
Total
Experience

1,340 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
18
Lessons
Completed
Best Reply Awards
0
Best Reply
Awards
  • start-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-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-token Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer-token Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • lara-evanghelist 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.

Level 1
3,660 XP
Nov
05
1 month ago
Activity icon

Replied to Login Route Cant Be Found (NotFoundHttpException)

@sinnbeck it is not even reaching the controller anymore because the route cant be found...

Activity icon

Replied to Login Route Cant Be Found (NotFoundHttpException)

POST localhost/api/v1/auth/login and I am sending a json with email and password. All other routes are working fine

Activity icon

Started a new Conversation Login Route Cant Be Found (NotFoundHttpException)

I am getting an exception regarding my login url: "exception": "Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException",

<?php

/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/
Route::group(['prefix' => 'v1'], function () {
    //OPEN ROUTES
    Route::group(['prefix' => 'auth'], function () {
        Route::resource('register', 'API\V1\Auth\RegisterController');
        Route::resource('login', 'API\V1\Auth\LoginController')->except(['destroy']);
    });
    //CLOSED ROUTES
    Route::middleware(['auth:api'])->group(function () {
        Route::group(['prefix' => 'auth'], function () {
            Route::delete('login', 'API\V1\Auth\[email protected]')->name('login.destroy');
        });
        Route::group(['prefix' => 'dropdown'], function () {
            Route::resource('relationship', 'API\V1\Dropdown\RelationshipController');
        });
        Route::group(['prefix' => 'self', 'middleware' => 'scope:self'], function () {
            //    Route::get('me', 'Api\V1\Self\[email protected]')->name('self.user.show');
        });
        Route::resource('address', 'API\V1\AddressController');
        Route::resource('city', 'API\V1\CityController');
        Route::resource('company', 'API\V1\CompanyController');
        Route::resource('contract', 'API\V1\ContractController');
        Route::resource('dependent', 'API\V1\DependentController');
        Route::resource('holder', 'API\V1\HolderController');
        Route::resource('item', 'API\V1\ItemController');
        Route::resource('sale', 'API\V1\SaleController');
        Route::resource('state', 'API\V1\StateController');
        Route::resource('payment-type', 'API\V1\PaymentTypeController');
        Route::resource('payment-method', 'API\V1\PaymentMethodController');
        Route::resource('payment', 'API\V1\PaymentController');
        Route::resource('people', 'API\V1\PeopleController');
        Route::resource('transaction-result', 'API\V1\TransactionResultController');
        Route::resource('referral', 'API\V1\ReferralController');
    });
});


But I can totally find it (login.store) when I run php artisan route:list

|        | DELETE    | api/v1/auth/login                                        | login.destroy                     | App\Http\Controllers\API\V1\Auth\[email protected]                  | api,auth:api |
|        | GET|HEAD  | api/v1/auth/login                                        | login.index                       | App\Http\Controllers\API\V1\Auth\[email protected]                    | api          |
|        | POST      | api/v1/auth/login                                        | login.store                       | App\Http\Controllers\API\V1\Auth\[email protected]                    | api          |
|        | GET|HEAD  | api/v1/auth/login/create                                 | login.create                      | App\Http\Controllers\API\V1\Auth\[email protected]                   | api          |
|        | GET|HEAD  | api/v1/auth/login/{login}                                | login.show                        | App\Http\Controllers\API\V1\Auth\[email protected]                     | api          |
|        | PUT|PATCH | api/v1/auth/login/{login}                                | login.update                      | App\Http\Controllers\API\V1\Auth\[email protected]                   | api          |
|        | GET|HEAD  | api/v1/auth/login/{login}/edit                           | login.edit                        | App\Http\Controllers\API\V1\Auth\[email protected]                     | api          |

It has been working for quite a while and all of a sudden I started getting that. Any suggestions?

Jul
31
4 months ago
Activity icon

Replied to Error Composer Install After Upgrade From 5.5 To 5.6

@mikenewbuild did you have the same env error? Honestly I tried but I was skeptical. I will try it again.

Jul
30
4 months ago
Activity icon

Replied to Error Composer Install After Upgrade From 5.5 To 5.6

@jlrdw I presume so. Here is my composer.json:

{
  "name": "laravel/laravel",
  "description": "The Laravel Framework.",
  "keywords": [
    "framework",
    "laravel"
  ],
  "license": "MIT",
  "type": "project",
  "require": {
    "laravel/framework": "5.6.*",
    "doctrine/dbal": "2.5.x-dev",
    "laravel/cashier": "~7.0",
    "maatwebsite/excel": "^3.1",
    "felixkiss/uniquewith-validator": "3.1.2",
    "tecnickcom/tcpdf": "dev-master",
    "rap2hpoutre/laravel-log-viewer": "^1.2.1",
    "jlapp/swaggervel": "2.0.x-dev",
    "laravelcollective/html": "5.6.*",
    "php": "^7.1.3",
    "laravel/tinker": "^1.0",
    "orangehill/iseed": "^2.6",
    "maknz/slack": "^1.7",
    "fideloper/proxy": "^4.0"
  },
  "autoload": {
    "classmap": [
      "database/seeds",
      "database/factories"
    ]
    "psr-0": {
      "myApp": "app/"
    },
    "psr-4": {
      "App\": "app/"
    }
  },
  "scripts": {
    "post-root-package-install": [
      "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
    ],
    "post-create-project-cmd": [
      "@php artisan key:generate"
    ],
    "post-autoload-dump": [
      "Illuminate\Foundation\ComposerScripts::postAutoloadDump",
      "@php artisan package:discover"
    ]
  },
  "config": {
    "preferred-install": "dist",
    "sort-packages": true,
    "optimize-autoloader": true
  },
  "require-dev": {
    "itsgoingd/clockwork": "~1.7",
    "fzaninotto/faker": "^1.4",
    "phpunit/phpunit": "^7.0",
    "laravel/browser-kit-testing": "^2.0",
    "filp/whoops": "^2.0",
    "mockery/mockery": "^1.0",
    "nunomaduro/collision": "^2.0"
  },
  "autoload-dev": {
    "psr-4": {
      "Tests\": "tests/"
    }
  },
  "extra": {
    "laravel": {
      "dont-discover": []
    }
  },
  "minimum-stability": "dev",
  "prefer-stable": true
}
Activity icon

Replied to Error Composer Install After Upgrade From 5.5 To 5.6

@snapey composer dump-autoload throws the same error.

My artisan isnt working anymore (nothing happens on the terminal) whenever I switch to the upgrading branch (this is actually something I forgot to mention earlier)

Activity icon

Started a new Conversation Error Composer Install After Upgrade From 5.5 To 5.6

After updating via shift service from 5.5 to 5.6 I started getting this error when I try to run composer install:

> @php artisan package:discover

Fatal error: Uncaught ReflectionException: Class env does not exist in /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php:767
Stack trace:
#0 /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php(767): ReflectionClass->__construct('env')
#1 /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php(646): Illuminate\Container\Container->build('env')
#2 /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php(601): Illuminate\Container\Container->resolve('env', Array)
#3 /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(734): Illuminate\Container\Container->make('env', Array)
#4 /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php(1210): Illuminate\Foundation\Application->make('env')
#5 /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(487): Illuminate\Contain in /Users/user/Sites/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 767
Script @php artisan package:discover handling the post-autoload-dump event returned with error code 255

I've tried a bunch of things and none is working. Any clues?

Jun
12
5 months ago
Activity icon

Started a new Conversation L5.2 Form Request With Comma Separated String Input

I need to validate a comma separated string. My rules are working as long as I work with array on the request but I've been required to use comma separated string. I heard about some method called prepareForValidation() but it seems to be not available on L5.2.

here are my validation rules:

 public function rules()
    {
        return [
            'array1.*' => 'required|numeric|exists:table1,id',
            'array2.*' => 'required|string|exists:table2,column',
        ];
    }

How can I convert my comma separated string before the validation occurs?

Jun
11
5 months ago
Activity icon

Replied to L5.2 [ReflectionException] Class 'ClassName' Does Not Exist

@TISUCHI - Man I must be blind because I didnt see what you did there. It all look the same to me...

Jun
10
5 months ago
Activity icon

Started a new Conversation L5.2 [ReflectionException] Class 'ClassName' Does Not Exist

Guys I’m getting the following error when I try to run `php artisan route:li Theoretically there is no mistakes on the naming convention.

[ReflectionException] Class 'ClassName' does not exist

I created a controller from the CLI and I am pretty sure it exists

Here's what I tried so far:

  1. composer dump-autoload
  2. composer install
  3. php artisan config:cache
  4. php artisan config:clear

Here's my autoload from composer:

"autoload": {
        "classmap": [
            "database",
            "app/Http/Controllers",
            "app/Models",
            "app/Console/Commands"
        ],
        "psr-0": {
            "scdda": "app/"
        },
        "psr-4": {
            "App\": "app/"
        }
    }

Here is the route:

Route::resource('newroute','MyNewController',['only'=>['index','delete']]);

and here's my newly created controller:

<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;

use App\Http\Requests;

class MyNewController extends Controller
{
    /**
     * Display a listing of the resource.
     *
     * @return \Illuminate\Http\Response
     */
    public function index()
    {
        //
    }

    /**
     * Show the form for creating a new resource.
     *
     * @return \Illuminate\Http\Response
     */
    public function create()
    {
        //
    }

    /**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
    public function store(Request $request)
    {
        //
    }

    /**
     * Display the specified resource.
     *
     * @param  int  $id
     * @return \Illuminate\Http\Response
     */
    public function show($id)
    {
        //
    }

    /**
     * Show the form for editing the specified resource.
     *
     * @param  int  $id
     * @return \Illuminate\Http\Response
     */
    public function edit($id)
    {
        //
    }

    /**
     * Update the specified resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @param  int  $id
     * @return \Illuminate\Http\Response
     */
    public function update(Request $request, $id)
    {
        //
    }

    /**
     * Remove the specified resource from storage.
     *
     * @param  int  $id
     * @return \Illuminate\Http\Response
     */
    public function destroy($id)
    {
        //
    }
}