I'm using Angular 1.4.8 and angular ui-router 0.2.18
My config:
$stateProvider
.state('searchScreen', {
url:'/offers/:mode?id',
templateUrl: 'offerssearch',
controller: 'SearchController as search'
})
What I want to do is to bind a function changing url with button, here is my function:
search.createLink = function () {
$state.go('searchScreen', {url:'/offers/link?id=234'});
}
and I want my URL look like this after function call:
http://localhost:8080/#/offers/link?id=234
But /offers/link?id=234 is not appear in my URL http://localhost:8080/#/offers/