Sorry to ask this question again but no answer or workaround has been identified.
This is a follow-up of this question : Stackoverflow
I have a plunker which describes the issue (basically putting a tree structure in a dropdown list) :
Plunker example
As illustrated the first select does not select the value and gets back to an empty line - which is also a mystery.
I have not been able to find any similar cases and I am close to giving up so this is the last chance.
Key code areas are the filter and the initTreeSelect function :
$scope.initTreeSelect = function(tree){
$scope.filteredFields = $filter('flattenTree')(tree);
return $scope.filteredFields[0];
};
angular.module('myApp.filters', []).filter('flattenTree', function (OrgSvc) {
return function (array) {
var arrayToReturn = [];
arrayToReturn = OrgSvc.flattenTree(array);
return arrayToReturn;
};})
Your help would be very much appreciated! Thanks