already paste
TorchSK said:
Paste the User model as well please
I have tried, the result remains the same
TorchSK said:
Try renaming the class 'user' to 'User'
Add this to the User model
public function getAuthIdentifier() {
return $this->getKey();
}
public function getAuthPassword() {
return $this->password;
}
public function getReminderEmail() {
return $this->email;
}
same error
model
<?php
use Illuminate\Auth\UserTrait;
use Illuminate\Auth\UserInterface;
use Illuminate\Auth\Reminders\RemindableTrait;
use Illuminate\Auth\Reminders\RemindableInterface;
class User extends Eloquent implements UserInterface, RemindableInterface {
use UserTrait, RemindableTrait;
/**
* The database table used by the model.
*
* @var string
*/
protected $table = 'user';
/**
* The attributes excluded from the model's JSON form.
*
* @var array
*/
protected $hidden = array('password', 'remember_token');
public function getAuthIdentifier() {
return $this->getKey();
}
public function getAuthPassword() {
return $this->password;
}
public function getReminderUsername() {
return $this->username;
}
}
Run composer dump-autoload to see if there are any errors.
Don't you have some other class named 'User'?
already run the composer dump-autoload but nothing happened. for a class named 'User' only exists in the model only
Double check the class naming for migrations, helpers, seeds, etc...
Otherwise I am out of ideas :/ sorry
Edit
open Vendor/Composer/autoload_classmap.php and find the "User" class.
What is the path to it?
I just don't have any idea on this I think i'm lost here :/ i upload packages on Git https://github.com/scarings/loginLaler
vendor
'User' => $baseDir . '/app/database/migrations/2014_07_26_101506_user.php',
'UserController' => $baseDir . '/app/controllers/UserController.php',
And that is your problem. User class is set to the migration path.
Rename the migration class, run composer dump-autoload and everything should be fine
The line should be
'User' => $baseDir . '/app/models/User.php',
I know the topic is solved but, maybe a tip for your next migration files do like,
For example for creating a users table "create_users_table".
eriktisme said:
I know the topic is solved but, maybe a tip for your next migration files do like,
For example for creating a users table "create_users_table".
why ??
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community