diff --git a/src/Umbraco.Web.UI.Client/src/common/services/contenteditinghelper.service.js b/src/Umbraco.Web.UI.Client/src/common/services/contenteditinghelper.service.js index 16d6cc20c9..7b80694e3b 100644 --- a/src/Umbraco.Web.UI.Client/src/common/services/contenteditinghelper.service.js +++ b/src/Umbraco.Web.UI.Client/src/common/services/contenteditinghelper.service.js @@ -682,7 +682,7 @@ function contentEditingHelper(fileManager, $q, $location, $routeParams, notifica // /belle/#/content/edit/9876 (where 9876 is the new id) //clear the query strings - navigationService.clearSearch(); + navigationService.clearSearch(["cculture"]); //change to new path $location.path("/" + $routeParams.section + "/" + $routeParams.tree + "/" + $routeParams.method + "/" + id); diff --git a/src/Umbraco.Web.UI.Client/src/common/services/navigation.service.js b/src/Umbraco.Web.UI.Client/src/common/services/navigation.service.js index 13940b5124..3ad2864fa8 100644 --- a/src/Umbraco.Web.UI.Client/src/common/services/navigation.service.js +++ b/src/Umbraco.Web.UI.Client/src/common/services/navigation.service.js @@ -30,6 +30,7 @@ function navigationService($rootScope, $route, $routeParams, $log, $location, $q //A list of query strings defined that when changed will not cause a reload of the route var nonRoutingQueryStrings = ["mculture", "cculture"]; + var retainedQueryStrings = ['mculture']; //used to track the current dialog object var currentDialog = null; @@ -192,8 +193,8 @@ function navigationService($rootScope, $route, $routeParams, $log, $location, $q * @description * utility to clear the querystring/search params while maintaining a known list of parameters that should be maintained throughout the app */ - clearSearch: function () { - var toRetain = ["mculture"]; + clearSearch: function (toRetain) { + var toRetain = _.union(retainedQueryStrings, toRetain); var currentSearch = $location.search(); $location.search(''); _.each(toRetain, function (k) {