Page 1 of 1

UrlGenerator.php line 603:

Posted: 24 Feb 2016, 16:41
by rabol
Hi

I just saw this package today and wanted to try it out

To the best of my knowledge i did follow the instructions
But I get a exception when I try to access the site

My setup is like this:
Windows 10
WAMP

Composer is installed and working

What I did:

1) laravel new aimeos (laravel version 5.2.20)
2) created the database (aimeos)
3) created a local domain aimeos.dev
4) changed .ENV
5) modified composer.json
6) composer update
7) added Aimeos\Shop\ShopServiceProvider::class, to config/app.php
8) Executed the 4 artisan commands
9) created /resources/views/app.blade.php - pasted the code from https://github.com/aimeos/aimeos-larave ... el-package into the file
10) php artisan cache:clear
11) open browser and go to http://aimeos.dev/list

and I get the following error:
ErrorException in UrlGenerator.php line 603:
Action App\Http\Controllers\Auth\AuthController@postLogin not defined. (View: C:\webdev\aimeos\resources\views\app.blade.php) (View: C:\webdev\aimeos\resources\views\app.blade.php) (View: C:\webdev\aimeos\resources\views\app.blade.php)

I get the same result if I use PHP’s internal server
What did I forget ?

If I go to http://aimeos.dev/ I get the ‘clean’ Laravel 5 welcome page - so the site is working

Thanks in advance

Kind regards
Steen

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 16:49
by rabol
Hmm... i did this

php artisan make:auth
then I created a user and now it works

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 17:08
by aimeos
Thanks for the hint! We've added a note about setting up authentication first in the docs.

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 18:04
by rabol
Next issue:

When I go to the admin part, switch to expert mode it never finish loading

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 18:12
by aimeos
Can you please open the web console in your browser and have a look at the requests and why they fail? The error log of your web server might also be a good source of information.

BTW: Which version of the Aimeos Laravel package do you use?

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 18:14
by rabol

Code: Select all

VM119:1 Uncaught SyntaxError: Unexpected token <Ext.util.JSON.doDecode @ ext-all.js:21(anonymous function) @ ext-all.js:21Ext.ux.direct.JsonRpcProvider.Ext.extend.onData @ file?site=default:1422Ext.extend.handleResponse @ ext-all.js:21f @ ext-base.js:21m @ ext-base.js:21(anonymous function) @ ext-base.js:21
I assume that i use the latest version

Json: "aimeos/aimeos-laravel": "~2016.01",

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 18:24
by aimeos
rabol wrote:

Code: Select all

VM119:1 Uncaught SyntaxError: Unexpected token <Ext.util.JSON.doDecode @ ext-all.js:21(anonymous function) @ ext-all.js:21Ext.ux.direct.JsonRpcProvider.Ext.extend.onData @ file?site=default:1422Ext.extend.handleResponse @ ext-all.js:21f @ ext-base.js:21m @ ext-base.js:21(anonymous function) @ ext-base.js:21
Hmm, what's the response for the HTTP request causing this error?
rabol wrote:I assume that i use the latest version
Json: "aimeos/aimeos-laravel": "~2016.01",
Yes, that's the current beta version.

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 18:32
by rabol
I'm not sure that I understand your question :)

i 'simply' goto /admin, and then switch to 'Expert mode'

Re: UrlGenerator.php line 603:

Posted: 24 Feb 2016, 19:47
by aimeos
rabol wrote:I'm not sure that I understand your question :)
In Chrome press Ctrl+Shift+J to open the web console. Go to the network tab and click on "XHR". Reload the page and go to the Preview (or Response) tab to see what the server returns. This should be similar to the attached screen shot.

Re: UrlGenerator.php line 603:

Posted: 25 Feb 2016, 04:45
by rabol
Sorry it took me a while to figure it out :)

changing always_populate_raw_post_data to -1 in my php.ini solved the problem

Maybe this should be added to the 'installation hints' :)