Updated recycle-bin dashboard controller to handle both content and media items.

This commit is contained in:
leekelleher
2014-06-08 16:46:04 +01:00
parent 2ff1c973e0
commit caa59f2c80

View File

@@ -9,8 +9,17 @@
*/
function RecycleBinController($scope, $routeParams) {
$routeParams.id = "-20"; // media = "-21"
$scope.model = { config: { entityType: "content" } };
if ($routeParams.section) {
if ($routeParams.section === "content") {
$routeParams.id = "-20";
}
else if ($routeParams.section === "media") {
$routeParams.id = "-21";
}
$scope.model = { config: { entityType: $routeParams.section } };
}
}
angular.module('umbraco').controller("Umbraco.Dashboard.RecycleBinController", RecycleBinController);