So im my view (made with using Blade templates) I have link with href that calls Controller directly, that looks like:
<a id="@{{user.id}}" href="{{action('Controller@method')}}>update</a>
and it works fine, but now I need to pass some additional data, which is taken from vue.js array, which also should be put in curved braces, like:
<a id="@{{user.id}}" href="{{action('Controller@method', ['user_id' => @{{user.id}}])}}>update</a>
and here I start getting messages about unexpected { symbol. I've tried removing @ symbol, and putting this variable outside href quotes, but it didn't work. Is there any possibility to solve this?
UPD: I also tried putting this link in vue method, like
$.getJSON('{{action("Controller@method", ["user_id" => '+vm.user.id+'])}}')
but in this case literally "vm.user.id", not variable gets passed in link
UPD2:
I'm now trying to pass data not in link, like $.getJSON('{{action("Controller@method")}}', {user_id: vm.user.id})
and I'm getting links like update?user_id=123, but I need format like update/123