Tagged Questions
1
vote
0answers
44 views
AngularJS: Two Parallel Views, One URL
I'm building a dashboard/control panel app that is basically made up of two tabs (bootstrap) at the root level, called "dispatch" and "admin". Each tab has a good bit of its own multi-tiered ...
1
vote
0answers
20 views
Angular-UI ui-router supporting infinitely nested states
I have a situation in my Angular app where I'd like to consider an infinitely nested state/route. For example, let's say that I have a person and I want to see the lineage of the family. I might ...
1
vote
1answer
32 views
angular ui router directive dynamically ui-sref
HTML
<li class="dropdown signals" signals="signals" data-nb-signals="" style="visibility: hidden;">
<a data-toggle="dropdown" href="#">
<i class="glyphicon ...
2
votes
1answer
30 views
Changing the default behavior of $state.go() in ui.router to reload by default
I have an Angular app built using the ui.router package for its URL routing. I would like to change it so that if the user attempts to navigate to the page they're already on, the router reloads that ...
0
votes
1answer
16 views
Conditional ui-view
I have a ui-view defined in my root template <div ui-view=""></div>. Is that possible to automatically hide that view if it's content is empty?
I was searching for similar thread for some ...
1
vote
1answer
20 views
Nested views without nested states
Following this tutorial: https://github.com/angular-ui/ui-router/wiki/Multiple-Named-Views, i'm able to create an application with multiple views defined in a root template. I need to modify that ...
0
votes
1answer
13 views
Angular ui-router url issue
I have a search form, something like (jade):
div.search
form.form-inline(role="form", method="get", ng-controller="searchFormController")
div.row
div.col-xs-2
h3 Search
...
1
vote
0answers
24 views
AngularJS Ui Router regex matching wildcard in url
I wonder if this is possible - I need to match the following URLs with one pattern:
/one/app/home
/one/two/app/home
/one/two/three/app/home
...
I understand that AngularJS routing doesn't support ...
0
votes
0answers
7 views
Is it possible to have cross-references states?
Is it possible to reference a state from a child of a different state?
For example:
I have an abstract state admin which I use for prefixing the url with /admin.
It has a child state: admin.list from ...
0
votes
0answers
12 views
Distinction between Angular controllers in filesystem vs controllers in Angular-ui-router
I am trying to keep all different providers (services, factories, services, providers) in their own file for a growing application. So the file system should look similar to this:
www
↳ bower
↳ img
...
0
votes
1answer
8 views
How can I prevent the window from scrolling when changing states with AngularJS UI-Router?
With ui-router whenever the user navigates between states the browser window always scrolls to a seemingly random location. It seems to be worse when there are multiple ui-views in play. How can I ...
0
votes
0answers
14 views
Prevent user from executing actions in parent state when parent and child state are in the same view
I'm developing an application with some complex forms. For example I have a grid that displays personnel to the user in my personnel state, the grid has editing/deleting/creating functionalities which ...
0
votes
1answer
51 views
Change a url parameter in the current state from ui-sref in angular-ui-router
Using ui-router I would like to set a URL parameter no matter what state I'm in. A use-case for this is to switch between bookmarkable interface modes (e.g. "boring" or "funny").
I know it can be ...
0
votes
0answers
10 views
ui-router - handling bad URL's when dynamic templateUrl
I don't know how to redirect to another state when html file is not found...
.config ($stateProvider) ->
$stateProvider
.state 'main.page',
url: '/page/:staticName'
...
0
votes
0answers
24 views
angular ui router resolve view not loading
I have a state configuration which can be abstracted to the following:
$stateProvider.state('myState', {
templateUrl: 'myPath.html',
resolve:{
'myData': function($q, ...
1
vote
1answer
27 views
Synchronizing nested views in Angular ui-router
My "root" state includes two views that exist for the entirety of the application:
//index.html
<body ui-view>
<under-pane ui-view = "underpane"></div>
...
1
vote
1answer
37 views
Matching url path with regex in $urlRouterProvider.when()
Based on the angular ui-router wiki (https://github.com/angular-ui/ui-router/wiki/URL-Routing#urlrouterprovider) it should be possible to use regex for matching the incoming path. How could I express ...
0
votes
1answer
18 views
angular-ui-router: add css class if state matched
simple wiki
I'd like to show an edit button in the navbar is state == 'page'
v0.2.10
.state('page',{
url: "/wiki/{ns:[0-9a-zA-Z\-/_]+}/{wp:[0-9a-zA-Z\-/_]+}",
templateUrl: ...
0
votes
1answer
32 views
Deep linking to AngularJS app doesn't work consistently… what's up?
I have an AngularJS app that uses ui.route. This is hosted within ASP.NET MVC, which is intended to only serve a single View that points to this app and ideally links into it as needed. My state ...
0
votes
1answer
27 views
$state.go('state.name') not correctly changing states
I am attempting to move between states (using ui.router) programmatically without the user having to click on anything. The documentation at ...
0
votes
1answer
16 views
$stateParams returning undefined
I have these routes defined:
.state('sport',
url: '/sport'
templateUrl: '/templates/sport'
controller: 'SportCtrl'
)
.state('sport.selected'
url: '/:sport'
...
0
votes
1answer
36 views
ngRouter/uiRouter preserve controllers when changing view
Is there anyway to preserve route controllers in Angular when using routing?
Everytime I change the view, the old controller is destroyed and a new one created, but I was wondering if there was a way ...
0
votes
0answers
12 views
Update view dynamically based on stateParams without controller reload (Angular ui-router)
First time I navigate to this route I want to initialize a chart.
.state('county', {
url: "/county/:id",
templateUrl: "templates/county.html",
controller: "CountyController"
})
...
1
vote
1answer
68 views
+50
Angular UI Router animation on parent view
I have a nested state like:
.state('contacts', {
url: '/contacts',
views: {
'': {
templateURL: 'views/contacts.html',
contacts: 'ContactsCtrl'
}
}
...
0
votes
0answers
29 views
Angular UI router structure for this type of application
I am building an reporting application that uses stacked tabs for navigation. These tabs are in a parent/child hierarchy as shown below.
When the user selects the parent tab (ex feature 2) they ...
1
vote
1answer
29 views
Directives isolated scope not working properly together with nested views? (AngularJS / UI Router)
I'm using ui-router in a AngularJS project where I have a nested view that contains a custom directive.
This directive renders an input field (lets say a filter-field) and its value should be in sync ...
2
votes
1answer
42 views
Angular UI Router - functions inside template not working
I am learning to use Angular UI Router to control the different parts of the application.
Take a look at this plunkr (http://plnkr.co/edit/KH7lgNOG7iCAEDS2D3C1?p=preview)
Things not working:
When ...
0
votes
0answers
22 views
Angularjs ['ui-routing'] using different layout in parent as well as children
Lets say;
state: /profile (parent) i want to show 3 columns next to each other leftpane content rightpane
state /profile/{id} i want to show 2 columns leftpane and content.
i have worked this code ...
1
vote
1answer
54 views
HTML5 pushState Clash w/Angular UI-Router URL Routing
I have an Angular.js webapp that employs ui-router (https://github.com/angular-ui/ui-router) w/parallel named views like such:
.state(
'app.experience', {
url: ...
0
votes
1answer
20 views
Angular, UI-Router: How do I get access to both a Ctrl and stateParam values within a template?
Based on these set-ups (Angular UI-Router testing scope inheritance, Angular ui-router - how to access parameters in nested, named view, passed from the parent template?), I did the following (the ...
0
votes
1answer
75 views
Angular ng-repeat view not updating after custom filter
I have an ng-repeat that filters out items based on a category chosen by the user. When the page renders the category is all and none of the items are filtered. There are three categories and the ...
0
votes
1answer
41 views
Infinite Loop on ui-router's $stateChangeStart
Ramping up on angular, and ui-router
And struggling with redirecting to a different state if a precondition is not met:
I tried using an interceptor: (How do I preform a redirect in an angular ...
0
votes
1answer
36 views
How do I preform a redirect in an angular interceptor
Hi guys I am pretty new to angular, and I had a question on the best way to handle a redirect within an interceptor.
I have certain pages in my app that I should only be able to access if I have an ...
1
vote
1answer
57 views
angular ui-router: get state name in resolve
I would like to access the state's name and other attributes the app is navigating to using angular ui-router when working on the resolve.
The reason: I want load some user data (including their ...
1
vote
0answers
19 views
angular ui routes state duplication due to multiple urls
I am using angularjs with angular ui routes and I have a problem with multiple urls for route.
I have a state called "bookDetails". Book have unique id and unique name and therefore can be accessed ...
0
votes
0answers
40 views
Handling error in ui-routers resolve function? (aka $stateChangeError) Passing data to error state?
inside my Angular application I handle routes/states via ui-router. If everything works - it is great. But what is a good way to handle errors occurring inside resolve functions?
My current solution:
...
1
vote
0answers
33 views
angularUI select dropdown displays data only after entering a character
I am using AngularJS v1.2.15 and angular-ui / ui-select. My select HTML is:
<div class="form-group col-md-3">
<div class="input-group select2-bootstrap-append">
<ui-select ...
0
votes
0answers
26 views
Weird navigation bug, with side menu, routing views won’t update
I am fairly new to ionic (using the 1.0.0 beta1) and Angular, and I am working on my first project, where I experience weird bugs, I cannot understand.
My app is based on the "Ionic Book" task app, ...
0
votes
1answer
39 views
Confused about ui-router nesting
I'm trying to find a way for one of my views to have multiple states. Let's say I have this template:
<body>
<div ui-view="overlay">
<div ui-view="content">
</body>
...
0
votes
1answer
19 views
How do I test for default route with angularjs + ui.router?
In the gist https://gist.github.com/CarmineM74/10021667
You can see 2 files:
app.coffee
contains states configuration
states.coffee
The goal for this test is to check for correct fallback behaviour ...
0
votes
0answers
22 views
AngularUI routing managing user permissions
I have am porting an application with a series of tabs and sub tabs. Current we only generate the tabs and sub tabs that the user can accessed based on their User Type. Can do the same with ...
0
votes
0answers
19 views
How to avoid $resource:badcfg when using ui-router views
I want to implement a user info page (for admin) which has a list of all users and displays a tabview with specific user info in each tab when I click on a user. The content of each tab is to be ...
0
votes
0answers
23 views
Access AngularJS module config from directives
I'd like to be able to define ui-router states from markup, using directives. The directive's children would be the template for the state, for example:
<state name="foo" url="bar">
...
0
votes
1answer
49 views
AngularJS nested views
Hi there I don't know how to show for example navbar and real content from route.
My stateProvider looks like this:
.state('panel', {
abstract: true,
views: {
// the ...
0
votes
3answers
65 views
Injecting $scope into an angular service function()
I have a Service:
angular.module('cfd')
.service('StudentService', [ '$http',
function ($http) {
// get some data via the $http
var path = 'data/people/students.json';
var students ...
0
votes
1answer
23 views
How to achieve nested states(using named views) without using abstract in parent
I am really new to angular I am trying to build a navigation page. The defined structure is:
There is a button on the main page which navigates to the main-page1.html
main-page1.html contains menu-bar ...
2
votes
1answer
63 views
Angular ui.router infinite loop on $state or $location change
I am at the end of my wits, nerves, everything, for the past 4 hours I am TRYING to debug and reading all over the internet what the problem might be with this.
So, I am working on mocking up a ...
0
votes
0answers
44 views
Angular Route No Errors but Not Woking
It's just simple but I don't know what's wrong. I have the following example, making a simple web template with angular ui-router and angular 1.2.16.
<script type='text/javascript' ...
0
votes
1answer
39 views
AngularJS tabset does not show the correct state when the page is reloaded
I'm using angular-ui-router in an AngularJS SPA along with the bootstrap tabset directive.
Here is my example http://plnkr.co/V0Cs6BfnggXshawMv4LX and the steps to reproduce the problem.
Launch ...
0
votes
1answer
24 views
AngularJS Resource - URL template not formatting passed parameters properly
I am new to angularjs and ui-router and having trouble getting the resource service to format the GET URL in the way I would like, using the parameter I am passing to it.
Here is my Controller code:
...