This topic contains 0 replies, has 1 voice, and was last updated by nicotontige 9 years, 2 months ago.
- Topic
Hi,
We detect a strange behaviour by adding a prefix in all routes.
What’s we want to do :
Add prefix for all routes of our application.What’s we technically do:
– add our prefix in firewalls in security.yml
– change assets_base_urls parameter in config.ymlWhat’s happend :
For ajax calls, the url called was http://server/beta-v/beta-v2/datagrid/…
instead of http://server/beta-v2/datagrid/…Where our investigation lead :
in file : vendor/oro/platform/src/Oro/Bundle/NavigationBundle/Resources/views/Js/requirejs.config.js.twig at line 812345678910init: function(routing) {{% if not app.debug %}{# processed correctly only in case when routing comes via controller #}{% set data = {'base_url': asset('')[:-0], 'scheme': app.request.scheme, 'host': app.request.host } %}var data = {{ data|json_encode|raw }};data.routes = routing.getRoutes();fos.Router.setData(data);{% endif %}return routing;}The problem seems come from this parameter “[:-1]”.
We don’t found what this parameter is for, but it seems that it delete the last character..
So by replacing the 1 by 0, it seems to fix our problem.Maybe you can help us to understand this behaviour, and maybe tell us how fix this properly.
thanks!
The forum ‘OroPlatform – Installation/Technical Issues or Problems’ is closed to new topics and replies.