UI-Router evolves the concept of an AngularJS Route into a more general concept of a State for managing complex application UI states. Most notably, it allows nested state/view hierarchies and multiple named views.

learn more… | top users | synonyms (2)

1
vote
1answer
19 views

$stateParams empty ui router

I have a state as such: .state('home.deletemsg', { views: { "contentworker@": { url: '/delete/:entityname/:id/:redirectstate', templateUrl: "Scripts/proteanapp/templates/delete.html", ...
0
votes
0answers
4 views

Configuring Angular UI Router Extras Sticky views within Angular 1.5 Component

I'm trying to implement sticky states on two "panes" within a view. However that view itself is an angular 1.5 component, which is run as a result of a higher level route match. A simplified example ...
0
votes
0answers
7 views

$stateChangeStart params get overriden?

I am trying to get the returnURL to work after a successful login. But I am having little problem to solve it. I am using $rootScope and listens for "stateChangeStart"-event, and it almost works. ...
2
votes
0answers
10 views

ui-router 1.0.0 beta and nested resolves: How to rewrite

I'm currently trying to move from ui-router 1.0.0-alpha.5 to 1.0.0.beta.3, and I don't know how to rewrite the resolve part of my states. I'm pretty sure it's relative to "9) BC-BREAK: remove support ...
0
votes
0answers
15 views

Angular 1 app resets to root after declaring abstract true in parent view

When navigating to /part-1/4-int/1 the app defaults to / after declaring /part-1/4-int as abstract: true Aim: To have the <ui-view> in the parent (slides call) to be displaying children (a ...
1
vote
1answer
18 views

AngularJS: Cannot reach variable in the controller after ui-router resolving

I have following code in config. I use ui-router template: "<employee-info-component user='$resolve.user'></employee-info-component>", resolve: { user: function () { ...
2
votes
1answer
28 views

AngularJS: Resolving promise in ui-router config

There is code of mine $stateProvider: $stateProvider .state("home", { url: "/", template: "<employee-info-component user='$resolve.user'></employee-info-component>", ...
0
votes
0answers
14 views

How to maintain the user session without data loss and without refreshing the page in Angular js

I have implemented an application: Technology used: -- Angular, Mvc, WebApi. How I have calculated the session in the application means? When user login into the app, Set the logout time , Before 3 ...
0
votes
0answers
20 views

Why my Angular state is not being loaded?

At the start of my app, I have : $urlRouterProvider.otherwise('/loading'); which brings control to my loadCtrl. Here I have: Service.getRoleDetails(config.USER_DETAILS_URL).then(useRoleDetails, ...
0
votes
0answers
4 views

How to force a parameter's value to be ommited in the url ui-router for anguar 2?

// Example Below /* The url to my update job is as below http://localhost:9000/#/jobcreator/creator/updatejob/3c83ea7e-906c-437a-93ef-72f39888be9ca I dont need the job id param to appear in ...
0
votes
0answers
19 views

$state url mismatch with angular ui-router

I have the below two routes : .state({ name: 'main', url: '/main/:clientId', templateUrl: '/main.html', controller: 'mainCtrl', }); .state({ name: 'mainDashboard', url: '/{...
0
votes
1answer
14 views

How to use bootstrap JS-plugins like accordion with angular single page application (using .otherwise method)

Here is a simple SPA with angular-ui-router Plunker However, i used bootstrap accordion in the accordion state but as u guess the accordion behavior doesn`t work unless i comment the otherwise ...
0
votes
1answer
28 views

What's wrong with my code to go to a child state in UI Router

Let's say I've configured an state as follows: { name: "results", parent: "modules/globalSearch/main", url: "" // other settings } * Note that I'm not using URLs. "modules/globalSearch/main" ...
0
votes
0answers
8 views

Access parent state's scope (nested views)

Given a multi-step form, each step has its own route. There's a progress bar indicating what the current step is. I set up the routes like this: stateRoot (abstract) containing the progress bar ...
0
votes
1answer
16 views

Protect routes and redirect user based on some conditions with Angular ui-router

The scenario is: For some routes in my app, I want to force user to complete their profile first. There are a few ways to achieve that: Redirect inside the user resolve (where we load the user data)...
1
vote
1answer
16 views

UI Router 1.0 state change events not working

I'm migrating my Angular 1.5 application to Angular UI Router 1.0-beta3 to use the component router. I'm listening for state change events on $rootScope but none of the events are fired. Example: ...
0
votes
0answers
8 views

How can I prevent persistent URL anchor link hash values with UI-Router?

I'm using Angular2 and UI-Router 2 in no-hash mode for a simple app with some anchor links in the menu. For example: https://example.com/blah/blech https://example.com/blah/blech#specifications https:...
1
vote
2answers
19 views

Is it possible to load a routerOutlet from a function in angular2

I want to load a routerOutles in angular2 without a button, but can't figure out how to do it. This is how to do it with a button: <button (click) = "load()" ><a routerLink="/next" ...
0
votes
2answers
23 views

Protecting views, authentication or canActivate for Angular 2 with ui-router

I thought I could try using ui-router with Angular 2. Currently, I already have some default angular2-router configuration, which mostly comes down to something like: export const homeRoute: Route = ...
0
votes
0answers
29 views

How to redirect from NgOnInit?

I want to redirect, under certain conditions, when the page is loaded or before. For example, Cookies have to have something, then do a redirect. this.router.navigate(["details"]); in AppComponent....
0
votes
1answer
14 views

sx-sref not being compiled to href

I have the following directive that I'm using to generate links (among other things). I've simplified it somewhat here: oActivityModule.directive('activityDetails', function () { ...
0
votes
2answers
20 views

ui-router to resolve same object but with different data

I have the following example which resolves an existing product code by returning the results from my DB (ProductsFactory.getProduct) and then enters my editProduct state: .state('editProduct', { ...
0
votes
1answer
19 views

How can I maintain previous state param on 404?

I am new to working with Angular and I need some help with router-ui package. Several of my states are made up of a dynamic value like so: .state('state-name', { url: `${dynamicValue}/state-name`, ...
0
votes
1answer
15 views

Set default nested state in ui-router

I have two level nested state on ui-router and I can't set a default nested state for some view. I need to load the state cars.detail.supply.list when the state cars.detail is active without changing ...
0
votes
1answer
27 views

nested ui-router $location binding

I have some problem with binding when i use ui-router. I am trying to make the app modular and keep it clean and simple. I have the following app.js // main routing - index.html var app = angular....
1
vote
1answer
78 views

Angular 2 wrapper project

I have to develop an angular 2 application which is the wrapper of other angular 2 applications. Lets say the main Module of project is called MainModule Other 3rd party modules which are deployed in ...
0
votes
0answers
8 views

ui-router and angular-translate working together

I read different SO posts and blog posts about that question but none of them answered my questions. Here's what I have: Angular-translate is activated to find the preferred language, store it in ...
0
votes
1answer
27 views

Change nested views through ng-click in ui.router

I am trying to insert views inside view. But it is working only at the defined state but when I trying to change the view with the help of ngClick the state lost the path. It is like View 1 --...
0
votes
1answer
26 views

AngularJS When and Otherwise with UI Rout

I'm new angular student. I have a problem with my routes of UI Route. here is my code: $urlRouterProvider .when('/GRN', '/GRN/Produtos') .when('/Executivo', "Executivo/Produtos") ....
1
vote
1answer
29 views

UI-router: deal with nested controllers

I have following config: .state("addUser", { url: "/addUser", templateUrl: "users/add-user.html", controller: "AddUserParent", controllerAs: "$ctrl", abstract: ...
0
votes
2answers
23 views

UI-router nested view not being injected

I have a root index.html file which has a ui-view tag, to which a main template file home.html is injected. home.html has a ui-view tag which needs to change depending on the current route. I ...
0
votes
1answer
23 views

what does the '.' in state name in Angularjs state provider mean?

what is the significance of '.' in state('xxx.yyy') in Angularjs 1.x? Q1) Are the 2 states emAllTickets.closed and emAllTickets/closed are different? what is the significance of . and / here? Q2) ...
0
votes
2answers
28 views

Angular ui.router provide state

I have an angular/rails app with 2 pages that needs to serve 2 templates: The states are currently displayed with <ui-view></ui-view> on 2 different pages: http://localhost:3000/...
0
votes
1answer
25 views

Identify path of value from console results

I have an angular project that calls an API. I'm trying to figure out how to reference a value from the returned results and am trying to figure it out by looking at the console.log results. Here is ...
1
vote
2answers
22 views

Showing undefined when passing data using params in ui-router

In my controller, $scope.register = function(index) { $state.go('account.accountRegister', {obj: {accountType: $stateParams.accountType, accountName: $scope.data[index].accountName}}) ...
0
votes
1answer
16 views

Hoow to use params without showing in url?

controllerA from state A $state.go('account.accountRegister', {accountType: $stateParams.accountType, acName: acName}) State defined in app.js .state('account.accountRegister', { url: '/:...
0
votes
0answers
15 views

Cannot display images and use php scripts within AngularJS UIRouter based WordPress site

I am importing AngularJS based SPA using ui-router into WordPress but have hard time getting the images to display and insert php code into the partial pages. Everything is fine at header and footer ...
0
votes
2answers
54 views

Passing parameters to Angular UI router template

My angular ui router is changing states/views as: $stateProvider .state({ name: 'home', url: '/', template: '<home-view></home-view>', ...
2
votes
2answers
32 views

ng-show with $state.includes has blink/flickering - angular; ui-router

As described here How to ng-hide and ng-show views using angular ui router, I have the following markup: <div class='container'> <div ng-show='$state.includes('state1')></div> &...
0
votes
0answers
34 views

ocLazyLoad and Angular UI Router

I'm using oclazyload to load an Angular controller dynamically, when I enter a specific nested state. That nested state: .state('login.home', { url: "home", views: { "nav-right": { ...
0
votes
1answer
25 views

Angular UI Router Controller Provider $HTTP

I was hoping after a user logs in I could load a controller for the logged in view in Angular UI Router as simply as this: "content@":{ templateProvider: function($http, $stateParams) { ...
0
votes
1answer
21 views

scope access when promise resolved in Angular UI-Router

I have a small question regarding scopes and promises. I declared wiz_ids outside a promise call and I would like to access it again when the promise is resolved. I tried to use bind() but without ...
-1
votes
0answers
18 views

Parse URL to state in ui-router 1.x for angular 1.x

I need to parse $location.path or $window.pathname to state. Has anyone done this?
0
votes
0answers
12 views

ui -router update the current state for abstract parent state

I am using ui-router for maintaining the state in my application. The application has one abstract parent state and few child states. Parent state has got some resolves(working fine), now since I have ...
0
votes
0answers
15 views

How to prevent change state when Ionic “onHold” gesture is fired

I have a list of items with href that goes to an specific page of every item, and also has a onHold gesture that displays an action sheet with some options (delete and ...). I wrote this angular ...
-1
votes
1answer
53 views

Uncaught Error: [$injector:modulerr]

I am getting an Uncaught Error: [$injector:modulerr] jquery.js:3855 It seems i have included almost all the dependencies but still i am getting an error app.js angular.module('app', ['ui....
0
votes
0answers
35 views

How to load a view in angular directly through a URL

I want to access a view in my Angular app. It does work when I go there through a button however when I want to access that view via a link (e.g. by clicking on one) or when I am refreshing the page, ...
0
votes
1answer
29 views

UI-Router (resolve) cant pass data into controller

when i run code like this my controller stops working and it happens with all kinds of data passed with resolve, from api or any other way.. i just cant pass anything to my controller > $...
0
votes
0answers
14 views

ng-infinite-scroll with ng-show and sticky states

I am new to angular. In my single page web app, I have two tabs with ng-infinite-scroll in each of them. The two tabs are traversed between using a nav-bar, <div ng-show="$state.includes('...
0
votes
2answers
24 views

AngularJS: Editing a “pick-one” field in a separate view

I am developing an AngularJS 1 (+ Ionic + ui-router) single page app. Among other things, the app lets 'CRUD' employees and companies. I am struggling with the "edit employee" page. This page shows ...