-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error when using the directive if the context path is not root #31
Comments
I think you can do as follows:
That ought to do the trick.. |
Hi @grtjn , setApi is not exposed because of the this.$get just limited the functions to search and expand. I'll try changing both functions instead. Thanks for the tip! :) |
Right, but it IS exposed. You can access it via the Provider that is automatically created for the service. You should be able to add this in your app.js (or similar):
|
@maeisabelle Above was tested locally both by me and @patrickmcelwee. That should work. I'd like to keep the ticket open though. Patrick and I both think it would be useful to expose that setApi on the service object itself too.. |
Thanks @grtjn and @patrickmcelwee :) Very useful! Thanks for the prompt response. |
I used the ml-visjs-graph directive in my application and it's working well when my app is in the root context path but when I tried to deploy my app in a path like http://localhost:8080/{contextpath}/, the call is pointing to http://localhost:8080/v1/resource instead of http://localhost:8080/{contextpath}/v1/resource. I think we need to set the VisjsGraphService api to v1/resource instead of /v1/resource. In the current version, is there a way to do that? I can see that the service has setApi but I think it's not exposed in the directive.
The text was updated successfully, but these errors were encountered: