laravel authentication and jenssegers-mongodb not working
<p>Hello i am using laravel, mongoDB and AdminLTE template in my project. for mongoDB i am using <code>jenssegers/laravel-mongodb</code>. But now i am facing error when i creating login authentication in laravel controller this my code in AuthController.php</p>

<pre><code>   public function postLogin(Request $request)
   {
    $authUser = User::where('email', '=', $request-&gt;email)-&gt;first();
    if (isset($authUser)) {
        if (Auth::attempt(['email' =&gt; $request-&gt;email, 'password' =&gt; $request-&gt;password])) {
            echo "success";exit;
        } else {
            echo "fail";exit;
        }
    } else {
        echo "fail";exit;
    }
</code></pre>

<p>In User.php code</p>

<pre><code>    &lt;?php

namespace App;

use Jenssegers\Mongodb\Eloquent\Model as Eloquent;
use DB;

use Illuminate\Contracts\Auth\Authenticatable;
use Illuminate\Auth\Authenticable as AuthenticableTrait;



class User extends Eloquent implements Authenticatable 
{
    protected $connection = 'mongodb';
    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $fillable = [
        'name', 'email', 'password',
    ];

    /**
     * The attributes that should be hidden for arrays.
     *
     * @var array
     */
    protected $hidden = [
        'password', 'remember_token',
    ];
}
</code></pre>

<p>in User.php if i using only Eloquent like <code>class User extends Eloquent</code> so getting this error</p>

<pre><code>Argument 1 passed to Illuminate\Auth\EloquentUserProvider::validateCredentials() must be an instance of Illuminate\Contracts\Auth\Authenticatable, instance of App\User given, called in /var/www/html/cams_alphaV1/vendor/laravel/framework/src/Illuminate/Auth/SessionGuard.php on line 378 and defined
</code></pre>

<p>if i using <code>class User extends Eloquent implements Authenticatable</code> so getting this error </p>

<pre><code>Class App\User contains 6 abstract methods and must therefore be declared abstract or implement the remaining methods (Illuminate\Contracts\Auth\Authenticatable::getAuthIdentifierName, Illuminate\Contracts\Auth\Authenticatable::getAuthIdentifier, Illuminate\Contracts\Auth\Authenticatable::getAuthPassword, ...)
</code></pre>

<p>please help me i am totally stuck.</p>