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.
0
votes
0answers
7 views
Angular-Ui-Router state changes but template URL doesn't load for nested states
I am working on an a requirejs + angularjs project with ui-router . I tried to implement nested views but only the state changes but the template URL doesn't load.
My route-config.js
....
0
votes
1answer
10 views
Angular-ui-router: Making asynchronous call across state transition
I'm trying to make an asynchronous API call triggered by the onEnter to a new .state
onEnter: function(StatFactory){
StatFactory.getStats(function(res){
console....
0
votes
0answers
8 views
Multiple themes (view + controller) for a single angular UIRouter route
I have 2 different "versions" of the same screen. Each has its own view and controller right now and both run properly (separately) when set using the UI-Router config file.
There is a setting being ...
2
votes
1answer
27 views
Why does /#!/ appear on address bar?
Hi I've been studying angular 1.5 and using this course
https://thinkster.io/angularjs-es6-tutorial
I've cloned the repo to help me get started and while following the video tutorial, I noticed that ...
0
votes
1answer
17 views
AngularJS ui-router state not detected after server side redirect
When there is a serverside redirect (301 permanent) ui-router does not detect the initial state. Html5mode is enabled.
ASP.NET MVC 5 is used for the backend and the first page load is serverside ...
0
votes
0answers
25 views
Accessing ui-router resolve objects in controller
I have a function returning some data from an API inside ui-router resolve, and would like to access that object in my controller.
UI-Router:
.state('base.home', {
url:'/',
templateUrl: '...
1
vote
2answers
33 views
Angular ui-router resolve - using $state.go
Im just learning ui-router resolve and would like to simply redirect my state if the user is not logged-in.
It seems I cannot simply use $state.go inside the callback function.
Here is my code:
....
0
votes
1answer
16 views
ui-router / ui-sref, inherited parameters?
I have a couple of parameters that are fundamental and often present in my application.
Simplified exemple of url in the router definition:
url:'/settings/:id'
url:'/profile/:id'
url:'/account/:id'
...
1
vote
1answer
21 views
Getting routing to work with hashes in AngularJS
There is a partially working example of my issue at http://nwlink.com/~geoffrey/routing/default.html
var routingInterface = angular.module("routingInterface", ['ui.router'])
.config(function($...
0
votes
2answers
30 views
UI router empty parameters in URL
I am converting my application from using simple Angular router service to UI-Router. I have a route which has some parameters coming from search field. In the router service provided with Angular, if ...
0
votes
2answers
23 views
Preserving $rootScope while browsing between states
I developed a single page application with index.html file and 2 views view1.html and view2.html and configured 2 states for the above views but when I'm browsing between the states I'm losing the ...
0
votes
2answers
23 views
How to have states for hierarchial data using ui-router in angular js?
I need to have a url structure in place for hierarchical categories using angularjs ui-router.
Example;
Category tree is like below:
Root
-Application 1
--Category level 1
---Category level 2
----...
0
votes
1answer
31 views
How to read $stateParms value in Angular2?
Using Ui-Router
In Angular1 The stateparam value is coming using $state.params
How to do the same thing in ANgular2
I tried like this this._uiRouter.globals.params.id
it's working, But its not a ...
0
votes
1answer
20 views
Pass resolve parameter to angular1 component in UI Router
I am trying to pass my resolve parameters to angular one component using ui router. My UIRouter configuration is as below :-
.state(memberConstants.memberMVLicense, {
url: "/mvlicense",
...
0
votes
2answers
18 views
how to pass parameters from one state to other using angular2 ui router form ts code?
I am new to Angular2 . I tried quickstart application.same application now I want to do with angular2 ui router,I am struckking here
I have some list Items. When I click one Item it shows details of ...
0
votes
0answers
16 views
Angularjs routing with Spring MVC
var app = angular.module("BlankApp", ['ngMaterial','ngRoute']);
app.config(function($routeProvider)
{
$routeProvider
.when("/", {
templateUrl : "views/home1.jsp",
})
....
0
votes
1answer
31 views
AngularJS ui-router application has /#!/ in the URL
I have an application with ui.router working normally, but another application the url has an "!" after "#"
Ex: http://localhost:8090/dev/#!/home
Why it happens?
The normal should be: http://...
0
votes
2answers
25 views
How to activate default state in ui-router?
I'm using ui-router 0.2.18
Main referral admin URL for my website looks like this http://example.com/partners/dashboard I want it to be changed to http://example.com/partners/dashboard#referral-link (...
0
votes
1answer
38 views
reload the angularjs after update , date not updated
i am working in angularjs 1.i am trying to make CRUD in angularjs and laravel.i have successfully make the CRUD and CRUD is working fine , in my application their is child and parent routing present ...
0
votes
1answer
37 views
Duplicates in a repeater are not allowed?Use 'track by' expression to specify unique keys.?
I have created notification service globally for the application, while sending the db call, capturing the error code in interceptors and show alert.
how to avoid the duplicated Error mesage in ...
0
votes
1answer
15 views
AngularJS. Templates are not included in ui-views, when transitioning between child states of different abstract parents
Templates are not included in ui-views, when transitioning between child states of different abstract parents.
Here is the plunker and link to the editor. Navigate form login (auth.login) state to ...
1
vote
4answers
31 views
why the factory is not able to access inside the controller
I have created notification factory and pass inside controller,Inside controller when assign the factory to the scope getting error.
alertsManager
MyApp.factory('alertsManager', function() {
...
0
votes
0answers
10 views
Notification alert service not working in controller getting typeError: Cannot read property 'alerts' of undefined
I have capturing the application response error ,while capturing the error, i am getting the error.
In Interceptor ,according to the response code , have assign the rootscope broadcast and show the ...
0
votes
0answers
39 views
“/” issue in angular route
I use ionic framework. I have an url address like below:
<a ng-repeat="item in list" href="#/detail/{{item.Subject}}/{{item.Id}}" class="item item-avatar">
xxxx
</a>
Above code, item....
0
votes
1answer
18 views
Angular ui-router resolve is calling function that returns object properly, but still ends up getting undefined. Why?
I have a custom function that properly returns a cache object of user details. Additionally, the function checks to see if the cache is empty beforehand and makes an API call to retrieve the ...
1
vote
1answer
24 views
Access a child state from a child state
I want to access a child state from a child state but I get : angular.js:14195 Error: Could not resolve '#/projects/detailProject' from state 'projects.list
these are the states :
function ...
0
votes
1answer
27 views
Filtering for Parameters
When using the $urlMatcherFactory provider to create new parameter types, is there a way to filter types while encoding/decoding or validating them? I need some "date" parameters, and it seems easiest ...
1
vote
0answers
13 views
Relative path not working with express subdomain and ui router
I am getting serious problem while using "express-subdomain-handler" with angular ui router. I have created different apps for different subdomain.
Normally site runs well for primary domain: http://...
0
votes
3answers
16 views
can't load template to route using ui-router from sidebar
I am a newbee to angular. in my web app i have a side bar loaded in a ui-view from template in the index page and there is another ui-view where i want to load template clicking links from the side ...
0
votes
1answer
27 views
Inject data from ngResource into controller with ui-router's resolve
In the angular ui-router documentation it is stated, that a controller will be instantiated only after all the promises have been resolved, including fetching data from a remote server.
I have a $...
0
votes
0answers
10 views
using angular ui-router for login page without including main project template
I used ui-router in my project. "index.html" has my root view that my project template apply in this view.
now I want to load login page in my routing. but I didn't want to show login page with the ...
-1
votes
1answer
16 views
How to pass multiple parameters but show only one using uiRouter?
Problem : I want to pass parameter in my url e.g /{{title}}/{{id}} the title is title of the content and the id is mongooDB ID which is resolved(by GETting from server) before landing to the next ...
0
votes
0answers
16 views
download Excel with filtering in Angular JS
I would like to implement exactly excel-like filtering such as
If there are 2 columns, one of name and other would be of age.
Now when no filter is applied, filters are showing all data.
When we ...
1
vote
2answers
37 views
Page title, description using angular-ui-router
I have tried / used all the possible references on stackoverflow and other tutorials but could not get page title, description to work.
My state code looks like this
$urlRouterProvider.otherwise(...
0
votes
0answers
45 views
AngularJS UI-Router Not Rendering Component Template
I'm trying to route an extremely simple example component in AngularJS 1.5.8. Spent about two days trying different things but am down to this extremely simple example.
I've tried using ui-view name=...
5
votes
1answer
94 views
Implement different layouts for a (part of a) web page
I want to implement a coding playground. At the moment, I use flex-box to define the position of different panels. Here is a JSBin, and its html part:
<div class="flex-box">
<div class="...
0
votes
0answers
19 views
How to integrate angular ui router with angular ng-metadata?
Could someone please let me know on how to integrate angular ui router with angular ng-metadata
I am trying to do something like this https://plnkr.co/edit/4NMjPkt8GfR51ATg1iFV?p=preview
import '...
3
votes
2answers
49 views
What does #! mean in ui.router?
I am using the Angular ui.router to navigate through my application.
Usually, the url should look like this:
http://localhost:8001/#/start
But in my case, it looks like this:
http://localhost:8001/#...
0
votes
1answer
37 views
angular ui router optimizing resolve to only one requst
I want to combine multiple requests to one, so it won't do n requests but one.
Problem is that I don't know how to do a resolve to an object of names, which are variables that are injected in ctrl.
...
0
votes
0answers
34 views
View doesn't show Controller's data
I have 4 files, View, a Module, a controller and a factory :
Module : project.module.js
(function () {
'use strict';
angular.module('BlurAdmin.pages.projects', [])
.config(routeConfig);
/** @...
1
vote
4answers
62 views
AngularJS : Pass data from one view to another with in same controller
Summary :
I have a form in view(first) of my angular application and on success response from the ajax call on submit it redirects the user to the view(second). There is only one controller for the ...
0
votes
0answers
29 views
Populate route params with resolved data in angular ui-route
Give the following code:
$stateProvider
.state('app.users', {
abstract: true,
url: '/users',
templateUrl: 'views/users.html',
resolve: {
userId: Users =...
-1
votes
1answer
31 views
access resolve in component controller in angularjs 1.5
I am trying to bind to an angularjs 1.5 component a resolve value without success, In the state definition, I have replaced the common value of template properties with a value of the name of my new ...
2
votes
3answers
36 views
Adding id in urls in angular js
I am creating an app on angular in which I need every user has its separate page.
localhost/{username}
below are my routing param,
app.config(function($routeProvider) {
$routeProvider
.when('/',...
0
votes
0answers
30 views
ui-router html5Mode doesn't like hrefs to static html files
When using ui-router without html5Mode (using hangbang URL syntax), anchor tags that do a full page refresh to other pages (or static html content) using hrefs are working properly. As soon as I ...
0
votes
2answers
28 views
Resolve multiple promises in route's resolve before initializing controller
I have 2 http calls needed to be reslove before initializing my controller, currenly using Angular UI router and I have resolve map under $stateProvider.state('stateName', {stateObject}) my ...
1
vote
0answers
23 views
how to set a master state for all urls on angular with ui-route?
How I can use one state for all urls?
For example:
.state('home', {
url:'/',
template:'home.html',
controller:'homeCtrl'
})
.state('user', {
url:'/user',
template:'user.html',
...
1
vote
0answers
33 views
Angular Hash versus Hashbang
Why does Angular sometimes use a hash in the URL and other times use a hashbang? I've started writing two Angular apps from scratch. Neither are using HTML5 mode. Both have the same default route. ...
10
votes
0answers
103 views
Change-detection not working properly in ng2 component after navigation via angular1 ui-router
In an application that uses ng-upgrade to use some new ng2 (V2.2.4) components inside a big ng1 (V1.5.9) app (using ui-router) I am currently seeing a very strange change-detection issue. As far as I ...
0
votes
0answers
30 views
why angular $q service response gets null with mvc json response
I have created an small login page with angular js with mvc .
When submit the login ,it goes into the below function.
function LoginController($scope, $rootScope, LoginService,$location, $...