Fixes content blueprint creation
This commit is contained in:
@@ -242,9 +242,13 @@
|
||||
}
|
||||
|
||||
if (!$scope.content.isChildOfListView) {
|
||||
navigationService.syncTree({ tree: $scope.treeAlias, path: path.split(","), forceReload: initialLoad !== true }).then(function (syncArgs) {
|
||||
$scope.page.menu.currentNode = syncArgs.node;
|
||||
});
|
||||
navigationService.syncTree({ tree: $scope.treeAlias, path: path.split(","), forceReload: initialLoad !== true })
|
||||
.then(function (syncArgs) {
|
||||
$scope.page.menu.currentNode = syncArgs.node;
|
||||
}, function () {
|
||||
//handle the rejection
|
||||
console.log("A problem occurred syncing the tree! A path is probably incorrect.")
|
||||
});
|
||||
}
|
||||
else if (initialLoad === true) {
|
||||
|
||||
|
||||
@@ -47,9 +47,13 @@ function ContentBlueprintEditController($scope, $routeParams, contentResource) {
|
||||
|
||||
//Bind to $routeUpdate which will execute anytime a location changes but the route is not triggered.
|
||||
//This is so we can listen to changes on the cculture parameter since that will not cause a route change
|
||||
// and then we can pass in the updated culture to the editor
|
||||
//and then we can pass in the updated culture to the editor.
|
||||
//This will also execute when we are redirecting from creating an item to a newly created item since that
|
||||
//will not cause a route change and so we can update the isNew and contentId flags accordingly.
|
||||
$scope.$on('$routeUpdate', function (event, next) {
|
||||
$scope.culture = next.params.cculture ? next.params.cculture : $routeParams.mculture;
|
||||
$scope.isNew = $routeParams.id === "-1";
|
||||
$scope.contentId = $routeParams.id;
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user