Merge pull request #4545 from samherrmann/add-parent-property-to-angular-ui-router-state-object

Add parent property to angular-ui-router stateConfig object
This commit is contained in:
Masahiro Wakame
2015-06-08 00:29:13 +09:00
2 changed files with 17 additions and 1 deletions
+10 -1
View File
@@ -64,7 +64,16 @@ myApp.config((
controller: function ($scope: MyAppScope) {
$scope.things = ["A", "Set", "Of", "Things"];
}
}).state('index', {
})
.state('list', {
parent: 'state3',
url: "/list",
templateUrl: "partials/state3.list.html",
controller: function ($scope: MyAppScope) {
$scope.things = ["A", "Set", "Of", "Things"];
}
})
.state('index', {
url: "",
views: {
"viewA": { template: "index.viewA" },
+7
View File
@@ -30,6 +30,13 @@ declare module angular.ui {
* Function (injectable), returns the actual controller function or string.
*/
controllerProvider?: Function;
/**
* Specifies the parent state of this state
*/
parent?: string | IState
resolve?: {};
/**
* A url with optional parameters. When a state is navigated or transitioned to, the $stateParams service will be populated with any parameters that were passed.