I have a view where I have the following code:
T
If you are using ui-router
there is an attribute called ui-sref
that can be used as follows:
I recommend using that and styling the link as a button (can easily be done if you're using a CSS library like Twitter Bootstrap). Then you don't need to mess around with any JavaScript when writing your links.
If you need to pass a parameter into the state, you can do the following:
where $scope.item is an object with an ID property you want to be passed as a URL parameter.