1

I've installed the laravel tracker package by antonioribeiro from here

I also installed the stats panel. When I first went to the panel, it said 'authentication required'. So I searched around and found this issue, so I changed that line.

Now when I go to the /stats page on my website, I get the error 'User model misses admin property'.

But my model has that. I have put in the admin property just as instructed on the install page

public function getIsAdminAttribute() {
    return true;
}

It appears that tracker is working. I can echo out $tracker = Tracker::currentSession() and everything works there.

I've changed the user models in the tracker config file and enabled the stats panel.

I can't figure out what I'm missing.

1 Answer 1

0

@Nertskull You have to change the line 491 of the file vendor\pragmarx\tracker\src\Vendor\Laravel\ServiceProvider to add the web middleware :

$router->group(['prefix' => $prefix, 'middleware' => 'web'], function($router)
1
  • I actually already have done that. It was the 2nd link in my post about the issue I found and fixed. But having changed that, I still get that the admin attribute isn't set, even though it is.
    – Nertskull
    Commented Apr 26, 2016 at 18:02

Not the answer you're looking for? Browse other questions tagged or ask your own question.