add new editor to content recycle bin

This commit is contained in:
Mads Rasmussen
2015-09-01 16:20:43 +02:00
parent 65623ea5d0
commit 0ed6b0bdd3
2 changed files with 31 additions and 15 deletions

View File

@@ -8,10 +8,14 @@
*
*/
function ContentRecycleBinController($scope, $routeParams, dataTypeResource, navigationService) {
function ContentRecycleBinController($scope, $routeParams, dataTypeResource, navigationService, localizationService) {
//ensures the list view doesn't actually load until we query for the list view config
// for the section
$scope.page = {};
$scope.page.name = "Recycle Bin";
$scope.page.nameLocked = true;
$scope.listViewPath = null;
$routeParams.id = "-20";
@@ -26,6 +30,18 @@ function ContentRecycleBinController($scope, $routeParams, dataTypeResource, nav
// sync tree node
navigationService.syncTree({ tree: "content", path: ["-1", $routeParams.id], forceReload: false });
localizePageName();
function localizePageName() {
var pageName = "general_recycleBin";
localizationService.localize(pageName).then(function(value) {
$scope.page.name = value;
});
}
}
angular.module('umbraco').controller("Umbraco.Editors.Content.RecycleBinController", ContentRecycleBinController);

View File

@@ -1,14 +1,14 @@
<umb-panel ng-controller="Umbraco.Editors.Content.RecycleBinController">
<umb-header>
<div class="umb-headline-editor-wrapper span12">
<h1><localize key="general_recycleBin">Recycle Bin</localize></h1>
</div>
</umb-header>
<umb-tab-view>
<umb-tab id="tabRecycleBin" rel="RecycleBin">
<umb-pane>
<div ng-include="listViewPath"></div>
</umb-pane>
</umb-tab>
</umb-tab-view>
</umb-panel>
<umb-editor-view ng-controller="Umbraco.Editors.Content.RecycleBinController">
<umb-editor-header
name="page.name"
name-locked="page.nameLocked">
</umb-editor-header>
<umb-editor-container>
<div ng-include="listViewPath"></div>
</umb-editor-container>
</umb-editor-view>