Is there a way to create a dropdown list that displays items from a string Array and sets the ng-model as the index of the selected item?
I understand if my description is not clear, so here is what I am trying to achieve.
HTML
<select ng-model="chosenPropertyIndex"
ng-options="arrayProperties.PropertyNames[idx] for idx in [0,1,2,3,4,5]"
></select>
Controller
$scope.chosenPropertyIndex = 0;
$scope.arrayProperties = [
"Property A",
"Property B",
"Property C",
"Property D",
"Property E",
"Property F"
];
If you have any suggestions on how to implement this, please let me know.