Merge branch 'dev-v7' of https://github.com/umbraco/Umbraco-CMS into dev-v7
This commit is contained in:
@@ -1,52 +1,57 @@
|
||||
(function() {
|
||||
'use strict';
|
||||
'use strict';
|
||||
|
||||
function EditorHeaderDirective(iconHelper) {
|
||||
function EditorHeaderDirective(iconHelper) {
|
||||
|
||||
function link(scope, el, attr, ctrl) {
|
||||
function link(scope, el, attr, ctrl) {
|
||||
|
||||
scope.openIconPicker = function() {
|
||||
scope.dialogModel = {
|
||||
view: "iconpicker",
|
||||
show: true,
|
||||
submit: function(model) {
|
||||
if (model.color) {
|
||||
scope.icon = model.icon + " " + model.color;
|
||||
} else {
|
||||
scope.icon = model.icon;
|
||||
scope.openIconPicker = function() {
|
||||
scope.dialogModel = {
|
||||
view: "iconpicker",
|
||||
show: true,
|
||||
submit: function(model) {
|
||||
if (model.color) {
|
||||
scope.icon = model.icon + " " + model.color;
|
||||
} else {
|
||||
scope.icon = model.icon;
|
||||
}
|
||||
|
||||
// set form to dirty
|
||||
ctrl.$setDirty();
|
||||
|
||||
scope.dialogModel.show = false;
|
||||
scope.dialogModel = null;
|
||||
}
|
||||
scope.dialogModel.show = false;
|
||||
scope.dialogModel = null;
|
||||
}
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
var directive = {
|
||||
transclude: true,
|
||||
restrict: 'E',
|
||||
replace: true,
|
||||
templateUrl: 'views/components/editor/umb-editor-header.html',
|
||||
scope: {
|
||||
tabs: "=",
|
||||
actions: "=",
|
||||
name: "=",
|
||||
nameLocked: "=",
|
||||
menu: "=",
|
||||
icon: "=",
|
||||
hideIcon: "@",
|
||||
alias: "=",
|
||||
hideAlias: "@",
|
||||
description: "=",
|
||||
hideDescription: "@",
|
||||
navigation: "="
|
||||
},
|
||||
link: link
|
||||
};
|
||||
var directive = {
|
||||
require: '^form',
|
||||
transclude: true,
|
||||
restrict: 'E',
|
||||
replace: true,
|
||||
templateUrl: 'views/components/editor/umb-editor-header.html',
|
||||
scope: {
|
||||
tabs: "=",
|
||||
actions: "=",
|
||||
name: "=",
|
||||
nameLocked: "=",
|
||||
menu: "=",
|
||||
icon: "=",
|
||||
hideIcon: "@",
|
||||
alias: "=",
|
||||
hideAlias: "@",
|
||||
description: "=",
|
||||
hideDescription: "@",
|
||||
navigation: "="
|
||||
},
|
||||
link: link
|
||||
};
|
||||
|
||||
return directive;
|
||||
}
|
||||
return directive;
|
||||
}
|
||||
|
||||
angular.module('umbraco.directives').directive('umbEditorHeader', EditorHeaderDirective);
|
||||
angular.module('umbraco.directives').directive('umbEditorHeader', EditorHeaderDirective);
|
||||
|
||||
})();
|
||||
|
||||
@@ -1,10 +1,13 @@
|
||||
(function() {
|
||||
'use strict';
|
||||
|
||||
function GroupsBuilderDirective(contentTypeHelper, contentTypeResource, mediaTypeResource, dataTypeHelper, dataTypeResource, $filter, iconHelper, $q, $timeout) {
|
||||
function GroupsBuilderDirective(contentTypeHelper, contentTypeResource, mediaTypeResource, dataTypeHelper, dataTypeResource, $filter, iconHelper, $q, $timeout, notificationsService, localizationService) {
|
||||
|
||||
function link(scope, el, attr, ctrl) {
|
||||
|
||||
var validationTranslated = "";
|
||||
var tabNoSortOrderTranslated = "";
|
||||
|
||||
scope.sortingMode = false;
|
||||
scope.toolbar = [];
|
||||
scope.sortableOptionsGroup = {};
|
||||
@@ -25,6 +28,14 @@
|
||||
// add init tab
|
||||
addInitGroup(scope.model.groups);
|
||||
|
||||
// localize texts
|
||||
localizationService.localize("validation_validation").then(function(value) {
|
||||
validationTranslated = value;
|
||||
});
|
||||
|
||||
localizationService.localize("contentTypeEditor_tabHasNoSortOrder").then(function(value) {
|
||||
tabNoSortOrderTranslated = value;
|
||||
});
|
||||
}
|
||||
|
||||
function setSortingOptions() {
|
||||
@@ -202,13 +213,30 @@
|
||||
|
||||
scope.toggleSortingMode = function(tool) {
|
||||
|
||||
scope.sortingMode = !scope.sortingMode;
|
||||
if (scope.sortingMode === true) {
|
||||
|
||||
if(scope.sortingMode === true) {
|
||||
scope.sortingButtonKey = "general_reorderDone";
|
||||
} else {
|
||||
scope.sortingButtonKey = "general_reorder";
|
||||
}
|
||||
var sortOrderMissing = false;
|
||||
|
||||
for (var i = 0; i < scope.model.groups.length; i++) {
|
||||
var group = scope.model.groups[i];
|
||||
if (group.tabState !== "init" && group.sortOrder === undefined) {
|
||||
sortOrderMissing = true;
|
||||
group.showSortOrderMissing = true;
|
||||
notificationsService.error(validationTranslated + ": " + group.name + " " + tabNoSortOrderTranslated);
|
||||
}
|
||||
}
|
||||
|
||||
if (!sortOrderMissing) {
|
||||
scope.sortingMode = false;
|
||||
scope.sortingButtonKey = "general_reorder";
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
scope.sortingMode = true;
|
||||
scope.sortingButtonKey = "general_reorderDone";
|
||||
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
@@ -394,8 +422,12 @@
|
||||
}
|
||||
};
|
||||
|
||||
scope.changeSortOrderValue = function() {
|
||||
scope.model.groups = $filter('orderBy')(scope.model.groups, 'sortOrder');
|
||||
scope.changeSortOrderValue = function(group) {
|
||||
|
||||
if (group.sortOrder !== undefined) {
|
||||
group.showSortOrderMissing = false;
|
||||
}
|
||||
scope.model.groups = $filter('orderBy')(scope.model.groups, 'sortOrder');
|
||||
};
|
||||
|
||||
function addInitGroup(groups) {
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
}
|
||||
|
||||
.umb-group-builder__group.-inherited {
|
||||
background: #FDFDFD;
|
||||
border-color: #F2F2F2;
|
||||
animation: fadeIn 0.5s;
|
||||
}
|
||||
@@ -90,7 +89,6 @@
|
||||
font-weight: bold;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
.umb-group-builder__group-title-icon {
|
||||
@@ -109,7 +107,6 @@
|
||||
|
||||
.umb-group-builder__group-title.-inherited {
|
||||
border-color: #F2F2F2;
|
||||
background: #FDFDFD;
|
||||
}
|
||||
|
||||
input.umb-group-builder__group-title-input {
|
||||
@@ -134,6 +131,15 @@ input.umb-group-builder__group-title-input {
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
top: 2px;
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
.umb-group-builder__group-sort-order {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-left: 10px;
|
||||
position: relative;
|
||||
top: 2px;
|
||||
}
|
||||
|
||||
input.umb-group-builder__group-sort-value {
|
||||
@@ -141,10 +147,7 @@ input.umb-group-builder__group-sort-value {
|
||||
padding: 0px 0 0px 5px;
|
||||
width: 40px;
|
||||
margin-bottom: 0;
|
||||
margin-right: 10px;
|
||||
border-color: #d9d9d9;
|
||||
position: relative;
|
||||
top: 2px;
|
||||
}
|
||||
|
||||
/* ---------- PROPERTIES ---------- */
|
||||
@@ -182,7 +185,6 @@ input.umb-group-builder__group-sort-value {
|
||||
|
||||
.umb-group-builder__property.-inherited {
|
||||
border: transparent;
|
||||
background: #FDFDFD;
|
||||
animation: fadeIn 0.5s;
|
||||
}
|
||||
|
||||
@@ -232,7 +234,9 @@ input.umb-group-builder__group-sort-value {
|
||||
.umb-group-builder__property-meta-alias {
|
||||
font-size: 10px;
|
||||
color: @gray;
|
||||
word-wrap: break-word;
|
||||
word-break: break-word;
|
||||
line-height: 1.5;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.umb-group-builder__property-meta-label textarea {
|
||||
@@ -256,6 +260,7 @@ input.umb-group-builder__group-sort-value {
|
||||
|
||||
.umb-group-builder__property-meta-description textarea {
|
||||
font-size: 12px;
|
||||
line-height: 1.5;
|
||||
color: @grayDark;
|
||||
margin-bottom: 0;
|
||||
padding: 0;
|
||||
|
||||
@@ -200,10 +200,6 @@ ul.color-picker li a {
|
||||
border: 1px solid #f8f8f8;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails li:hover a {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails li img {
|
||||
max-width:100%;
|
||||
max-height:100%;
|
||||
@@ -228,6 +224,43 @@ ul.color-picker li a {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails .umb-sortable-thumbnails__actions {
|
||||
position: absolute;
|
||||
bottom: 10px;
|
||||
right: 10px;
|
||||
text-decoration: none;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
opacity: 0;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails li:hover .umb-sortable-thumbnails__actions {
|
||||
opacity: 1;
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails .umb-sortable-thumbnails__action {
|
||||
font-size: 16px;
|
||||
background: white;
|
||||
height: 25px;
|
||||
width: 25px;
|
||||
border-radius: 15px;
|
||||
color: @grayDarker;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails .umb-sortable-thumbnails__action.-red {
|
||||
color: red;
|
||||
}
|
||||
|
||||
.umb-sortable-thumbnails .umb-sortable-thumbnails__action:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Cropper
|
||||
|
||||
@@ -84,7 +84,13 @@
|
||||
</div>
|
||||
</ng-form>
|
||||
|
||||
<input type="number" class="umb-group-builder__group-sort-value" ng-if="sortingMode" ng-model="tab.sortOrder" ng-disabled="tab.inherited" on-blur="changeSortOrderValue()" />
|
||||
<ng-form name="groupSortOrderForm">
|
||||
<div class="umb-group-builder__group-sort-order" ng-if="sortingMode">
|
||||
<input name="groupSortOrder" type="number" class="umb-group-builder__group-sort-value" ng-model="tab.sortOrder" ng-disabled="tab.inherited" on-blur="changeSortOrderValue(tab)" required />
|
||||
<div class="umb-validation-label -arrow-left" ng-if="groupSortOrderForm.groupSortOrder.$error.required && tab.showSortOrderMissing"><localize key="required"></localize></div>
|
||||
<div class="umb-validation-label -arrow-left" ng-if="!tab.showSortOrderMissing" val-msg-for="groupSortOrder" val-toggle-msg="required"><localize key="required"></localize></div>
|
||||
</div>
|
||||
</ng-form>
|
||||
|
||||
<div class="umb-group-builder__group-inherited-label" ng-if="tab.inherited">
|
||||
<i class="icon icon-merge"></i>
|
||||
|
||||
@@ -2,61 +2,60 @@
|
||||
|
||||
<umb-load-indicator ng-if="vm.page.loading"></umb-load-indicator>
|
||||
|
||||
<form novalidate name="contentTypeForm"
|
||||
ng-submit="vm.save()"
|
||||
val-form-manager>
|
||||
<form novalidate name="contentTypeForm" val-form-manager>
|
||||
|
||||
<umb-editor-view ng-if="!vm.page.loading">
|
||||
|
||||
<umb-editor-header
|
||||
name="vm.contentType.name"
|
||||
alias="vm.contentType.alias"
|
||||
description="vm.contentType.description"
|
||||
navigation="vm.page.navigation"
|
||||
icon="vm.contentType.icon">
|
||||
name="vm.contentType.name"
|
||||
alias="vm.contentType.alias"
|
||||
description="vm.contentType.description"
|
||||
navigation="vm.page.navigation"
|
||||
icon="vm.contentType.icon">
|
||||
</umb-editor-header>
|
||||
|
||||
<umb-editor-container>
|
||||
|
||||
<umb-editor-sub-views ng-if="!vm.page.loading" sub-views="vm.page.navigation" model="vm.contentType"></umb-editor-sub-views>
|
||||
<umb-editor-sub-views
|
||||
ng-if="!vm.page.loading"
|
||||
sub-views="vm.page.navigation"
|
||||
model="vm.contentType">
|
||||
</umb-editor-sub-views>
|
||||
|
||||
</umb-editor-container>
|
||||
|
||||
<umb-editor-footer>
|
||||
|
||||
<umb-editor-footer-content-left>
|
||||
<umb-editor-footer-content-left>
|
||||
|
||||
<umb-keyboard-shortcuts-overview
|
||||
model="vm.page.keyboardShortcutsOverview">
|
||||
</umb-keyboard-shortcuts-overview>
|
||||
<umb-keyboard-shortcuts-overview
|
||||
model="vm.page.keyboardShortcutsOverview">
|
||||
</umb-keyboard-shortcuts-overview>
|
||||
|
||||
</umb-editor-footer-content-left>
|
||||
</umb-editor-footer-content-left>
|
||||
|
||||
<umb-editor-footer-content-right>
|
||||
<umb-editor-footer-content-right>
|
||||
|
||||
<umb-button
|
||||
ng-if="!vm.page.modelsBuilder"
|
||||
type="submit"
|
||||
state="vm.page.saveButtonState"
|
||||
button-style="success"
|
||||
shortcut="ctrl+s"
|
||||
label="Save"
|
||||
label-key="buttons_save">
|
||||
</umb-button>
|
||||
|
||||
<umb-button
|
||||
ng-if="!vm.page.modelsBuilder"
|
||||
type="button" action="vm.save()"
|
||||
state="vm.page.saveButtonState"
|
||||
button-style="success"
|
||||
shortcut="ctrl+s"
|
||||
label="Save"
|
||||
label-key="buttons_save">
|
||||
</umb-button>
|
||||
|
||||
<umb-button-group
|
||||
ng-if="vm.page.modelsBuilder"
|
||||
default-button="vm.page.defaultButton"
|
||||
sub-buttons="vm.page.subButtons"
|
||||
state="vm.page.saveButtonState"
|
||||
direction="up"
|
||||
float="right">
|
||||
</umb-button-group>
|
||||
|
||||
|
||||
</umb-editor-footer-content-right>
|
||||
<umb-button-group
|
||||
ng-if="vm.page.modelsBuilder"
|
||||
default-button="vm.page.defaultButton"
|
||||
sub-buttons="vm.page.subButtons"
|
||||
state="vm.page.saveButtonState"
|
||||
direction="up"
|
||||
float="right">
|
||||
</umb-button-group>
|
||||
|
||||
</umb-editor-footer-content-right>
|
||||
|
||||
</umb-editor-footer>
|
||||
|
||||
|
||||
@@ -1,70 +1,71 @@
|
||||
<div ng-controller="Umbraco.Editors.MediaTypes.EditController as vm">
|
||||
|
||||
<umb-load-indicator ng-if="vm.page.loading"></umb-load-indicator>
|
||||
<umb-load-indicator ng-if="vm.page.loading"></umb-load-indicator>
|
||||
|
||||
<form novalidate name="contentTypeForm"
|
||||
ng-submit="vm.save()"
|
||||
val-form-manager>
|
||||
<form novalidate name="contentTypeForm" val-form-manager>
|
||||
|
||||
<umb-editor-view ng-if="!vm.page.loading">
|
||||
|
||||
<umb-editor-header
|
||||
name="vm.contentType.name"
|
||||
alias="vm.contentType.alias"
|
||||
description="vm.contentType.description"
|
||||
navigation="vm.page.navigation"
|
||||
icon="vm.contentType.icon">
|
||||
name="vm.contentType.name"
|
||||
alias="vm.contentType.alias"
|
||||
description="vm.contentType.description"
|
||||
navigation="vm.page.navigation"
|
||||
icon="vm.contentType.icon">
|
||||
</umb-editor-header>
|
||||
|
||||
<umb-editor-container class="editors-document-type-container">
|
||||
|
||||
<div class="editors-document-type-canvas">
|
||||
|
||||
<umb-editor-sub-views ng-if="!vm.page.loading" sub-views="vm.page.navigation" model="vm.contentType"></umb-editor-sub-views>
|
||||
<umb-editor-sub-views
|
||||
ng-if="!vm.page.loading"
|
||||
sub-views="vm.page.navigation"
|
||||
model="vm.contentType">
|
||||
</umb-editor-sub-views>
|
||||
|
||||
</div>
|
||||
|
||||
</umb-editor-container>
|
||||
|
||||
|
||||
<umb-editor-footer>
|
||||
|
||||
<umb-editor-footer-content-left>
|
||||
<umb-editor-footer-content-left>
|
||||
|
||||
<umb-keyboard-shortcuts-overview
|
||||
model="vm.page.keyboardShortcutsOverview">
|
||||
</umb-keyboard-shortcuts-overview>
|
||||
<umb-keyboard-shortcuts-overview
|
||||
model="vm.page.keyboardShortcutsOverview">
|
||||
</umb-keyboard-shortcuts-overview>
|
||||
|
||||
</umb-editor-footer-content-left>
|
||||
</umb-editor-footer-content-left>
|
||||
|
||||
<umb-editor-footer-content-right>
|
||||
<umb-editor-footer-content-right>
|
||||
|
||||
<umb-button ng-if="!vm.page.modelsBuilder"
|
||||
type="submit"
|
||||
state="vm.page.saveButtonState"
|
||||
button-style="success"
|
||||
shortcut="ctrl+s"
|
||||
label="Save"
|
||||
label-key="buttons_save">
|
||||
</umb-button>
|
||||
<umb-button
|
||||
ng-if="!vm.page.modelsBuilder"
|
||||
type="button"
|
||||
action="vm.save()"
|
||||
state="vm.page.saveButtonState"
|
||||
button-style="success"
|
||||
shortcut="ctrl+s"
|
||||
label="Save"
|
||||
label-key="buttons_save">
|
||||
</umb-button>
|
||||
|
||||
<umb-button-group
|
||||
ng-if="vm.page.modelsBuilder"
|
||||
default-button="vm.page.defaultButton"
|
||||
sub-buttons="vm.page.subButtons"
|
||||
state="vm.page.saveButtonState"
|
||||
direction="up"
|
||||
float="right">
|
||||
</umb-button-group>
|
||||
|
||||
<umb-button-group ng-if="vm.page.modelsBuilder"
|
||||
default-button="vm.page.defaultButton"
|
||||
sub-buttons="vm.page.subButtons"
|
||||
state="vm.page.saveButtonState"
|
||||
direction="up"
|
||||
float="right">
|
||||
</umb-button-group>
|
||||
|
||||
</umb-editor-footer-content-right>
|
||||
|
||||
</umb-editor-footer-content-right>
|
||||
|
||||
</umb-editor-footer>
|
||||
|
||||
</umb-editor-view>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -1,67 +1,69 @@
|
||||
<div ng-controller="Umbraco.Editors.MemberTypes.EditController as vm">
|
||||
|
||||
<umb-load-indicator ng-if="vm.page.loading"></umb-load-indicator>
|
||||
<umb-load-indicator ng-if="vm.page.loading"></umb-load-indicator>
|
||||
|
||||
<form novalidate name="contentTypeForm" val-form-manager>
|
||||
|
||||
<form novalidate name="contentTypeForm"
|
||||
ng-submit="vm.save()"
|
||||
val-form-manager>
|
||||
|
||||
<umb-editor-view ng-if="!vm.page.loading">
|
||||
|
||||
<umb-editor-header
|
||||
name="vm.contentType.name"
|
||||
alias="vm.contentType.alias"
|
||||
description="vm.contentType.description"
|
||||
navigation="vm.page.navigation"
|
||||
icon="vm.contentType.icon">
|
||||
name="vm.contentType.name"
|
||||
alias="vm.contentType.alias"
|
||||
description="vm.contentType.description"
|
||||
navigation="vm.page.navigation"
|
||||
icon="vm.contentType.icon">
|
||||
</umb-editor-header>
|
||||
|
||||
<umb-editor-container class="editors-document-type-container">
|
||||
|
||||
<div class="editors-document-type-canvas">
|
||||
<umb-editor-sub-views ng-if="!vm.page.loading" sub-views="vm.page.navigation" model="vm.contentType"></umb-editor-sub-views>
|
||||
<umb-editor-sub-views
|
||||
ng-if="!vm.page.loading"
|
||||
sub-views="vm.page.navigation"
|
||||
model="vm.contentType">
|
||||
</umb-editor-sub-views>
|
||||
</div>
|
||||
|
||||
</umb-editor-container>
|
||||
|
||||
|
||||
<umb-editor-footer>
|
||||
|
||||
<umb-editor-footer-content-left>
|
||||
<umb-editor-footer-content-left>
|
||||
|
||||
<umb-keyboard-shortcuts-overview
|
||||
model="vm.page.keyboardShortcutsOverview">
|
||||
</umb-keyboard-shortcuts-overview>
|
||||
<umb-keyboard-shortcuts-overview
|
||||
model="vm.page.keyboardShortcutsOverview">
|
||||
</umb-keyboard-shortcuts-overview>
|
||||
|
||||
</umb-editor-footer-content-left>
|
||||
</umb-editor-footer-content-left>
|
||||
|
||||
<umb-editor-footer-content-right>
|
||||
<umb-editor-footer-content-right>
|
||||
|
||||
<umb-button ng-if="!vm.page.modelsBuilder"
|
||||
type="submit"
|
||||
state="vm.page.saveButtonState"
|
||||
button-style="success"
|
||||
shortcut="ctrl+s"
|
||||
label="Save"
|
||||
label-key="buttons_save">
|
||||
</umb-button>
|
||||
<umb-button
|
||||
ng-if="!vm.page.modelsBuilder"
|
||||
type="button"
|
||||
action="vm.save()"
|
||||
state="vm.page.saveButtonState"
|
||||
button-style="success"
|
||||
shortcut="ctrl+s"
|
||||
label="Save"
|
||||
label-key="buttons_save">
|
||||
</umb-button>
|
||||
|
||||
<umb-button-group
|
||||
ng-if="vm.page.modelsBuilder"
|
||||
default-button="vm.page.defaultButton"
|
||||
sub-buttons="vm.page.subButtons"
|
||||
state="vm.page.saveButtonState"
|
||||
direction="up"
|
||||
float="right">
|
||||
</umb-button-group>
|
||||
|
||||
<umb-button-group ng-if="vm.page.modelsBuilder"
|
||||
default-button="vm.page.defaultButton"
|
||||
sub-buttons="vm.page.subButtons"
|
||||
state="vm.page.saveButtonState"
|
||||
direction="up"
|
||||
float="right">
|
||||
</umb-button-group>
|
||||
|
||||
</umb-editor-footer-content-right>
|
||||
</umb-editor-footer-content-right>
|
||||
|
||||
</umb-editor-footer>
|
||||
|
||||
</umb-editor-view>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
//this controller simply tells the dialogs service to open a mediaPicker window
|
||||
//with a specified callback, this callback will receive an object with a selection on it
|
||||
angular.module('umbraco').controller("Umbraco.PropertyEditors.MediaPickerController",
|
||||
function ($rootScope, $scope, dialogService, entityResource, mediaResource, mediaHelper, $timeout, userService) {
|
||||
function ($rootScope, $scope, dialogService, entityResource, mediaResource, mediaHelper, $timeout, userService, $location) {
|
||||
|
||||
//check the pre-values for multi-picker
|
||||
var multiPicker = $scope.model.config.multiPicker && $scope.model.config.multiPicker !== '0' ? true : false;
|
||||
@@ -56,6 +56,10 @@ angular.module('umbraco').controller("Umbraco.PropertyEditors.MediaPickerControl
|
||||
$scope.sync();
|
||||
};
|
||||
|
||||
$scope.goToItem = function(item) {
|
||||
$location.path('media/media/edit/' + item.id);
|
||||
};
|
||||
|
||||
$scope.add = function() {
|
||||
|
||||
$scope.mediaPickerOverlay = {
|
||||
|
||||
@@ -2,14 +2,23 @@
|
||||
|
||||
<ul ui-sortable="sortableOptions" ng-model="images" class="umb-sortable-thumbnails">
|
||||
<li style="width: 120px; height: 100px; overflow: hidden;" ng-repeat="image in images">
|
||||
<img ng-src="{{image.thumbnail}}" alt="" ng-show="image.thumbnail">
|
||||
|
||||
<span class="icon-holder" ng-hide="image.thumbnail">
|
||||
<i class="icon {{image.icon}} large" ></i>
|
||||
<small>{{image.name}}</small>
|
||||
</span>
|
||||
<img ng-src="{{image.thumbnail}}" alt="" ng-show="image.thumbnail">
|
||||
|
||||
<span class="icon-holder" ng-hide="image.thumbnail">
|
||||
<i class="icon {{image.icon}} large" ></i>
|
||||
<small>{{image.name}}</small>
|
||||
</span>
|
||||
|
||||
<div class="umb-sortable-thumbnails__actions">
|
||||
<a class="umb-sortable-thumbnails__action" href="" ng-click="goToItem(image)">
|
||||
<i class="icon icon-edit"></i>
|
||||
</a>
|
||||
<a class="umb-sortable-thumbnails__action -red" href="" ng-click="remove($index)">
|
||||
<i class="icon icon-delete"></i>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<a href class="picked-image" ng-click="remove($index)"><i class="icon icon-delete"></i></a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
@@ -1037,37 +1037,38 @@ To manage your website, simply open the Umbraco back office and start adding con
|
||||
<key alias="compositionsDescription">Inherit tabs and properties from an existing document type. New tabs will be added to the current document type or merged if a tab with an identical name exists.</key>
|
||||
<key alias="compositionInUse">This content type is used in a composition, and therefore cannot be composed itself.</key>
|
||||
<key alias="noAvailableCompositions">There are no content types available to use as a composition.</key>
|
||||
|
||||
|
||||
<key alias="availableEditors">Available editors</key>
|
||||
<key alias="reuse">Reuse</key>
|
||||
<key alias="editorSettings">Editor settings</key>
|
||||
|
||||
|
||||
<key alias="configuration">Configuration</key>
|
||||
|
||||
|
||||
<key alias="yesDelete">Yes, delete</key>
|
||||
|
||||
|
||||
<key alias="movedUnderneath">was moved underneath</key>
|
||||
<key alias="folderToMove">Select the folder to move</key>
|
||||
<key alias="structureBelow">to in the tree structure below</key>
|
||||
|
||||
|
||||
<key alias="allDocumentTypes">All Document types</key>
|
||||
<key alias="allDocuments">All Documents</key>
|
||||
<key alias="allMediaItems">All media items</key>
|
||||
|
||||
|
||||
<key alias="usingThisDocument">using this document type will be deleted permanently, please confirm you want to delete these as well.</key>
|
||||
<key alias="usingThisMedia">using this media type will be deleted permanently, please confirm you want to delete these as well.</key>
|
||||
<key alias="usingThisMember">using this member type will be deleted permanently, please confirm you want to delete these as well</key>
|
||||
|
||||
|
||||
<key alias="andAllDocuments">and all documents using this type</key>
|
||||
<key alias="andAllMediaItems">and all media items using this type</key>
|
||||
<key alias="andAllMembers">and all members using this type</key>
|
||||
|
||||
|
||||
<key alias="thisEditorUpdateSettings">using this editor will get updated with the new settings</key>
|
||||
|
||||
<key alias="memberCanEdit">Member can edit</key>
|
||||
<key alias="showOnMemberProfile">Show on member profile</key>
|
||||
<key alias="tabHasNoSortOrder">tab has no sort order</key>
|
||||
</area>
|
||||
|
||||
|
||||
<area alias="templateEditor">
|
||||
<key alias="alternativeField">Alternative field</key>
|
||||
<key alias="alternativeText">Alternative Text</key>
|
||||
|
||||
Reference in New Issue
Block a user