diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/includeproperties.prevalues.html b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/includeproperties.prevalues.html
index 345c58f423..830e4a41b0 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/includeproperties.prevalues.html
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/includeproperties.prevalues.html
@@ -18,6 +18,7 @@
|
Alias |
Header |
+ Template |
|
@@ -36,15 +37,20 @@
-
+
Required
-
+
{{val.alias}}
|
+
+
+
+
+ |
|
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/listview.controller.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/listview.controller.js
index 0437522845..7febda9508 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/listview.controller.js
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/listview.controller.js
@@ -1,4 +1,4 @@
-function listViewController($scope, $routeParams, $injector, $timeout, currentUserResource, notificationsService, iconHelper, editorState, localizationService, appState, $location, listViewHelper, navigationService, editorService, overlayService, languageResource, mediaHelper) {
+function listViewController($scope, $interpolate, $routeParams, $injector, $timeout, currentUserResource, notificationsService, iconHelper, editorState, localizationService, appState, $location, listViewHelper, navigationService, editorService, overlayService, languageResource, mediaHelper) {
//this is a quick check to see if we're in create mode, if so just exit - we cannot show children for content
// that isn't created yet, if we continue this will use the parent id in the route params which isn't what
@@ -168,6 +168,11 @@ function listViewController($scope, $routeParams, $injector, $timeout, currentUs
allowBulkDelete: $scope.model.config.bulkActionPermissions.allowBulkDelete,
cultureName: $routeParams.cculture ? $routeParams.cculture : $routeParams.mculture
};
+ _.each($scope.options.includeProperties, function (property) {
+ property.nameExp = !!property.nameTemplate
+ ? $interpolate(property.nameTemplate)
+ : undefined;
+ });
//watch for culture changes in the query strings and update accordingly
$scope.$watch(function () {
@@ -699,6 +704,13 @@ function listViewController($scope, $routeParams, $injector, $timeout, currentUs
value = value.substring(0, value.length - 3);
}
+ if (e.nameExp) {
+ var newValue = e.nameExp({ value });
+ if (newValue && (newValue = $.trim(newValue))) {
+ value = newValue;
+ }
+ }
+
// set what we've got on the result
result[alias] = value;
});
diff --git a/src/Umbraco.Web/PropertyEditors/ListViewConfiguration.cs b/src/Umbraco.Web/PropertyEditors/ListViewConfiguration.cs
index ae0b32fde1..ce41628ec1 100644
--- a/src/Umbraco.Web/PropertyEditors/ListViewConfiguration.cs
+++ b/src/Umbraco.Web/PropertyEditors/ListViewConfiguration.cs
@@ -77,6 +77,9 @@ namespace Umbraco.Web.PropertyEditors
[JsonProperty("header")]
public string Header { get; set; }
+ [JsonProperty("nameTemplate")]
+ public string Template { get; set; }
+
[JsonProperty("isSystem")]
public int IsSystem { get; set; } // TODO: bool
}