Mini Basket auto reload
Forum rules
Always add your TYPO3, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your TYPO3, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Re: Mini Basket auto reload
I set the page ID for JSON API manually in each plugin. However mini basket still needs a page reload to update. I also came across a similar Typoscript setting however with typenum = 191351524 and 191351525.
https://github.com/aimeos/aimeos-typo3/ ... /setup.txt
What do you mean with "default page tree". Do I have to insert this Typoscript setup in an extension template only for the JSON API page?
https://github.com/aimeos/aimeos-typo3/ ... /setup.txt
What do you mean with "default page tree". Do I have to insert this Typoscript setup in an extension template only for the JSON API page?
Last edited by georg03 on 13 Aug 2019, 14:05, edited 1 time in total.
Re: Mini Basket auto reload
We offer a page tree for import into TYPO3 that contains all necessary pages, plugins and settings:
https://aimeos.org/docs/TYPO3/Install_A ... s#Download
https://aimeos.org/docs/TYPO3/Install_A ... s#Download
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
Re: Mini Basket auto reload
Thank you! I checked the default page tree and added the typoscript for jsonapi page. Now when I add a product to basket I get the following error message in Developer Tools/Network/Response --> SyntaxError: JSON.parse: unexpected character at line 11 column 7 of the JSON data
Re: Mini Basket auto reload
Check the response which you get in the developer tools. Most probably, there is some string content above the json which is not allowed there.
Re: Mini Basket auto reload
I was able to eliminate all unexpected characters. For some reason however the json is called twice (see below) which generates the following error message: --> SyntaxError: JSON.parse: unexpected non-whitespace character after JSON data at line 7 column 1 of the JSON data
{
"errors": {
"title": "Use OPTIONS method for the resource list",
"detail": "This is the Aimeos JSON REST API\n\nUse the HTTP OPTIONS method to retrieve a list available resources from http:\/\/wbesiteurl.at\/index.php?id=32&ai%5Bcontroller%5D=Jsonapi&ai%5Baction%5D=options\nDocumentation about he Aimeos JSON REST API is available at https:\/\/aimeos.org\/docs\/Developers\/Client\/JSONAPI"
}
}
{
"errors": {
"title": "Use OPTIONS method for the resource list",
"detail": "This is the Aimeos JSON REST API\n\nUse the HTTP OPTIONS method to retrieve a list available resources from http:\/\/websiteurl.at\/index.php?id=32&ai%5Bcontroller%5D=Jsonapi&ai%5Baction%5D=options\nDocumentation about he Aimeos JSON REST API is available at https:\/\/aimeos.org\/docs\/Developers\/Client\/JSONAPI"
}
}
How can this be? There is just one JSON REST API plugin on page ID 32.
{
"errors": {
"title": "Use OPTIONS method for the resource list",
"detail": "This is the Aimeos JSON REST API\n\nUse the HTTP OPTIONS method to retrieve a list available resources from http:\/\/wbesiteurl.at\/index.php?id=32&ai%5Bcontroller%5D=Jsonapi&ai%5Baction%5D=options\nDocumentation about he Aimeos JSON REST API is available at https:\/\/aimeos.org\/docs\/Developers\/Client\/JSONAPI"
}
}
{
"errors": {
"title": "Use OPTIONS method for the resource list",
"detail": "This is the Aimeos JSON REST API\n\nUse the HTTP OPTIONS method to retrieve a list available resources from http:\/\/websiteurl.at\/index.php?id=32&ai%5Bcontroller%5D=Jsonapi&ai%5Baction%5D=options\nDocumentation about he Aimeos JSON REST API is available at https:\/\/aimeos.org\/docs\/Developers\/Client\/JSONAPI"
}
}
How can this be? There is just one JSON REST API plugin on page ID 32.
Re: Mini Basket auto reload
What's your TypoScript code for that page and the parent pages?
Is the plugin inherited from a parent page too?
Is the plugin inherited from a parent page too?
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
Re: Mini Basket auto reload
Finally I was able to solve the problem. This installation I took over from another developer uses the extensions fluidpages and flux for setup. Maybe there are some conflicts?
What I had to do is to change the ext Template Typoscript setup for the JSON REST API page from page = PAGE ... to e.g. jsonpage = PAGE ...
Thanks a lot for your help!
What I had to do is to change the ext Template Typoscript setup for the JSON REST API page from page = PAGE ... to e.g. jsonpage = PAGE ...
Thanks a lot for your help!