I have a custom property editor - does anyone know how I can get the value of another property from within the angular controller by the property alias.
For example I have the start of my function:
angular.module("umbraco")
.controller("My.Controller",
function ($scope, editorState) {
I tried editorState.current.getPropertyValue(myAlias) but did not work. Any help would be greatly appreciated.
I created simple helper function for handling it. It is using underscore to filter and retrieve proper value for desired property by alias.
$scope.getPropertyValueByAlias = function (myAlias) {
return _.findWhere(_.filter(editorState.current.tabs, function(tab) {
return _.some(tab.properties, { alias: myAlias });
})[0].properties, {
alias: myAlias // It could be any else property you want
}).value;
};
Hope that it will be helpful for anyone else. Helped for me :)
Get Property By Alias In Property Editor
Hello,
I have a custom property editor - does anyone know how I can get the value of another property from within the angular controller by the property alias.
For example I have the start of my function:
I tried editorState.current.getPropertyValue(myAlias) but did not work. Any help would be greatly appreciated.
Regards L
Sorry to ask but does anybody have any idea on this one?
I am in desperate need of finding a solution.
Thanks and Regards, L
Hello,
I created simple helper function for handling it. It is using underscore to filter and retrieve proper value for desired property by alias.
Hope that it will be helpful for anyone else. Helped for me :)
is working on a reply...