-
+
-
-
-
+
-
+
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/contentpicker/contentpicker.controller.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/contentpicker/contentpicker.controller.js
index 7fafa20b0f..6667c3b539 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/contentpicker/contentpicker.controller.js
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/contentpicker/contentpicker.controller.js
@@ -86,7 +86,7 @@ function contentPickerController($scope, entityResource, editorState, iconHelper
showOpenButton: false,
showEditButton: false,
showPathOnHover: false,
- dataTypeId: null,
+ dataTypeKey: null,
maxNumber: 1,
minNumber: 0,
startNode: {
@@ -140,7 +140,7 @@ function contentPickerController($scope, entityResource, editorState, iconHelper
entityType: entityType,
filterCssClass: "not-allowed not-published",
startNodeId: null,
- dataTypeId: $scope.model.dataTypeId,
+ dataTypeKey: $scope.model.dataTypeKey,
currentNode: editorState ? editorState.current : null,
callback: function (data) {
if (angular.isArray(data)) {
@@ -162,7 +162,7 @@ function contentPickerController($scope, entityResource, editorState, iconHelper
// pre-value config on to the dialog options
angular.extend(dialogOptions, $scope.model.config);
- dialogOptions.dataTypeId = $scope.model.dataTypeId;
+ dialogOptions.dataTypeKey = $scope.model.dataTypeKey;
// if we can't pick more than one item, explicitly disable multiPicker in the dialog options
if ($scope.model.config.maxNumber && parseInt($scope.model.config.maxNumber) === 1) {
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/media.controller.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/media.controller.js
index 4e6c87d7a8..574aa87557 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/media.controller.js
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/media.controller.js
@@ -30,7 +30,7 @@ angular.module("umbraco")
showDetails: true,
disableFolderSelect: true,
onlyImages: true,
- dataTypeId: $scope.model.dataTypeId,
+ dataTypeKey: $scope.model.dataTypeKey,
submit: function(model) {
var selectedImage = model.selection[0];
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/rte.html b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/rte.html
index 63bc7570e1..7bfc6d125e 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/rte.html
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/grid/editors/rte.html
@@ -4,7 +4,7 @@
configuration="model.config.rte"
value="control.value"
unique-id="control.$uniqueId"
- datatype-id="{{model.dataTypeId}}"
+ datatype-key="{{model.dataTypeKey}}"
ignore-user-start-nodes="{{model.config.ignoreUserStartNodes}}">
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/mediapicker/mediapicker.controller.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/mediapicker/mediapicker.controller.js
index 41c1fa8c16..f7e88bef36 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/mediapicker/mediapicker.controller.js
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/mediapicker/mediapicker.controller.js
@@ -187,7 +187,7 @@ angular.module('umbraco').controller("Umbraco.PropertyEditors.MediaPickerControl
var mediaPicker = {
startNodeId: $scope.model.config.startNodeId,
startNodeIsVirtual: $scope.model.config.startNodeIsVirtual,
- dataTypeId: $scope.model.dataTypeId,
+ dataTypeKey: $scope.model.dataTypeKey,
multiPicker: multiPicker,
onlyImages: onlyImages,
disableFolderSelect: disableFolderSelect,
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/multiurlpicker/multiurlpicker.controller.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/multiurlpicker/multiurlpicker.controller.js
index abaee3fca0..69bcc6b41a 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/multiurlpicker/multiurlpicker.controller.js
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/multiurlpicker/multiurlpicker.controller.js
@@ -77,7 +77,7 @@ function multiUrlPickerController($scope, angularHelper, localizationService, en
var linkPicker = {
currentTarget: target,
- dataTypeId: $scope.model.dataTypeId,
+ dataTypeKey: $scope.model.dataTypeKey,
ignoreUserStartNodes : $scope.model.config.ignoreUserStartNodes,
submit: function (model) {
if (model.target.url || model.target.anchor) {
diff --git a/src/Umbraco.Web/Editors/EntityController.cs b/src/Umbraco.Web/Editors/EntityController.cs
index 6ee16ae1ee..b3edb308a2 100644
--- a/src/Umbraco.Web/Editors/EntityController.cs
+++ b/src/Umbraco.Web/Editors/EntityController.cs
@@ -104,10 +104,10 @@ namespace Umbraco.Web.Editors
///
/// A starting point for the search, generally a node id, but for members this is a member type alias
///
- /// If set used to look up whether user and group start node permissions will be ignored.
+ /// If set used to look up whether user and group start node permissions will be ignored.
///
[HttpGet]
- public IEnumerable Search(string query, UmbracoEntityTypes type, string searchFrom = null, Guid? dataTypeId = null)
+ public IEnumerable Search(string query, UmbracoEntityTypes type, string searchFrom = null, Guid? dataTypeKey = null)
{
// NOTE: Theoretically you shouldn't be able to see member data if you don't have access to members right? ... but there is a member picker, so can't really do that
@@ -116,7 +116,7 @@ namespace Umbraco.Web.Editors
//TODO: This uses the internal UmbracoTreeSearcher, this instead should delgate to the ISearchableTree implementation for the type
- var ignoreUserStartNodes = dataTypeId.HasValue && Services.DataTypeService.IsDataTypeIgnoringUserStartNodes(dataTypeId.Value);
+ var ignoreUserStartNodes = dataTypeKey.HasValue && Services.DataTypeService.IsDataTypeIgnoringUserStartNodes(dataTypeKey.Value);
return ExamineSearch(query, type, searchFrom, ignoreUserStartNodes);
}
@@ -424,7 +424,7 @@ namespace Umbraco.Web.Editors
}
#endregion
- public IEnumerable GetChildren(int id, UmbracoEntityTypes type, Guid? dataTypeId = null)
+ public IEnumerable GetChildren(int id, UmbracoEntityTypes type, Guid? dataTypeKey = null)
{
var objectType = ConvertToObjectType(type);
if (objectType.HasValue)
@@ -433,7 +433,7 @@ namespace Umbraco.Web.Editors
var startNodes = GetStartNodes(type);
- var ignoreUserStartNodes = IsDataTypeIgnoringUserStartNodes(dataTypeId);
+ var ignoreUserStartNodes = IsDataTypeIgnoringUserStartNodes(dataTypeKey);
// root is special: we reduce it to start nodes if the user's start node is not the default, then we need to return their start nodes
if (id == Constants.System.Root && startNodes.Length > 0 && startNodes.Contains(Constants.System.Root) == false && !ignoreUserStartNodes)
@@ -482,7 +482,7 @@ namespace Umbraco.Web.Editors
string orderBy = "SortOrder",
Direction orderDirection = Direction.Ascending,
string filter = "",
- Guid? dataTypeId = null)
+ Guid? dataTypeKey = null)
{
if (int.TryParse(id, out var intId))
{
@@ -507,7 +507,7 @@ namespace Umbraco.Web.Editors
//the EntityService can search paged members from the root
intId = -1;
- return GetPagedChildren(intId, type, pageNumber, pageSize, orderBy, orderDirection, filter, dataTypeId);
+ return GetPagedChildren(intId, type, pageNumber, pageSize, orderBy, orderDirection, filter, dataTypeKey);
}
//the EntityService cannot search members of a certain type, this is currently not supported and would require
@@ -543,7 +543,7 @@ namespace Umbraco.Web.Editors
string orderBy = "SortOrder",
Direction orderDirection = Direction.Ascending,
string filter = "",
- Guid? dataTypeId = null)
+ Guid? dataTypeKey = null)
{
if (pageNumber <= 0)
throw new HttpResponseException(HttpStatusCode.NotFound);
@@ -558,7 +558,7 @@ namespace Umbraco.Web.Editors
var startNodes = GetStartNodes(type);
- var ignoreUserStartNodes = IsDataTypeIgnoringUserStartNodes(dataTypeId);
+ var ignoreUserStartNodes = IsDataTypeIgnoringUserStartNodes(dataTypeKey);
// root is special: we reduce it to start nodes if the user's start node is not the default, then we need to return their start nodes
if (id == Constants.System.Root && startNodes.Length > 0 && startNodes.Contains(Constants.System.Root) == false && !ignoreUserStartNodes)
@@ -642,7 +642,7 @@ namespace Umbraco.Web.Editors
string orderBy = "SortOrder",
Direction orderDirection = Direction.Ascending,
string filter = "",
- Guid? dataTypeId = null)
+ Guid? dataTypeKey = null)
{
if (pageNumber <= 0)
throw new HttpResponseException(HttpStatusCode.NotFound);
@@ -661,7 +661,7 @@ namespace Umbraco.Web.Editors
int[] aids = GetStartNodes(type);
- var ignoreUserStartNodes = IsDataTypeIgnoringUserStartNodes(dataTypeId);
+ var ignoreUserStartNodes = IsDataTypeIgnoringUserStartNodes(dataTypeKey);
entities = aids == null || aids.Contains(Constants.System.Root) || ignoreUserStartNodes
? Services.EntityService.GetPagedDescendants(objectType.Value, pageNumber - 1, pageSize, out totalRecords,
SqlContext.Query().Where(x => x.Name.Contains(filter)),
@@ -704,7 +704,7 @@ namespace Umbraco.Web.Editors
}
}
- private bool IsDataTypeIgnoringUserStartNodes(Guid? dataTypeId) => dataTypeId.HasValue && Services.DataTypeService.IsDataTypeIgnoringUserStartNodes(dataTypeId.Value);
+ private bool IsDataTypeIgnoringUserStartNodes(Guid? dataTypeKey) => dataTypeKey.HasValue && Services.DataTypeService.IsDataTypeIgnoringUserStartNodes(dataTypeKey.Value);
public IEnumerable GetAncestors(int id, UmbracoEntityTypes type, [ModelBinder(typeof(HttpQueryStringModelBinder))]FormDataCollection queryStrings)
{
diff --git a/src/Umbraco.Web/Models/ContentEditing/ContentPropertyBasic.cs b/src/Umbraco.Web/Models/ContentEditing/ContentPropertyBasic.cs
index f0f5bba7c4..c5c22484ad 100644
--- a/src/Umbraco.Web/Models/ContentEditing/ContentPropertyBasic.cs
+++ b/src/Umbraco.Web/Models/ContentEditing/ContentPropertyBasic.cs
@@ -22,8 +22,7 @@ namespace Umbraco.Web.Models.ContentEditing
[Required]
public int Id { get; set; }
- //fixme: This name dataTypeId is inconsistent, but requires us to change it everywhere in angular
- [DataMember(Name = "dataTypeId", IsRequired = false)]
+ [DataMember(Name = "dataTypeKey", IsRequired = false)]
[ReadOnly(true)]
public Guid DataTypeKey { get; set; }
diff --git a/src/Umbraco.Web/Trees/ContentTreeControllerBase.cs b/src/Umbraco.Web/Trees/ContentTreeControllerBase.cs
index 4fa9db13e3..015c91cb81 100644
--- a/src/Umbraco.Web/Trees/ContentTreeControllerBase.cs
+++ b/src/Umbraco.Web/Trees/ContentTreeControllerBase.cs
@@ -338,7 +338,7 @@ namespace Umbraco.Web.Trees
//Here we need to figure out if the node is a container and if so check if the user has a custom start node, then check if that start node is a child
// of this container node. If that is true, the HasChildren must be true so that the tree node still renders even though this current node is a container/list view.
if (isContainer && UserStartNodes.Length > 0 && UserStartNodes.Contains(Constants.System.Root) == false)
- {
+ {
var startNodes = Services.EntityService.GetAll(UmbracoObjectType, UserStartNodes);
//if any of these start nodes' parent is current, then we need to render children normally so we need to switch some logic and tell
// the UI that this node does have children and that it isn't a container
@@ -396,7 +396,7 @@ namespace Umbraco.Web.Trees
}
var menu = new MenuItemCollection();
- // only add empty recycle bin if the current user is allowed to delete by default
+ // only add empty recycle bin if the current user is allowed to delete by default
if (deleteAllowed)
{
menu.Items.Add(new MenuItem("emptyRecycleBin", Services.TextService)
@@ -538,8 +538,8 @@ namespace Umbraco.Web.Trees
{
if (_ignoreUserStartNodes.HasValue) return _ignoreUserStartNodes.Value;
- var dataTypeId = queryStrings.GetValue(TreeQueryStringParameters.DataTypeId);
- _ignoreUserStartNodes = dataTypeId.HasValue ? Services.DataTypeService.IsDataTypeIgnoringUserStartNodes(dataTypeId.Value) : false;
+ var dataTypeKey = queryStrings.GetValue(TreeQueryStringParameters.DataTypeKey);
+ _ignoreUserStartNodes = dataTypeKey.HasValue && Services.DataTypeService.IsDataTypeIgnoringUserStartNodes(dataTypeKey.Value);
return _ignoreUserStartNodes.Value;
}
diff --git a/src/Umbraco.Web/Trees/TreeQueryStringParameters.cs b/src/Umbraco.Web/Trees/TreeQueryStringParameters.cs
index 9d012cb25c..02a198401b 100644
--- a/src/Umbraco.Web/Trees/TreeQueryStringParameters.cs
+++ b/src/Umbraco.Web/Trees/TreeQueryStringParameters.cs
@@ -8,7 +8,7 @@
public const string Use = "use";
public const string Application = "application";
public const string StartNodeId = "startNodeId";
- public const string DataTypeId = "dataTypeId";
+ public const string DataTypeKey = "dataTypeKey";
//public const string OnNodeClick = "OnNodeClick";
//public const string RenderParent = "RenderParent";
}