2
I have a table where I make a ng-repeat
, hitherto normal.
<tr data-ng-repeat="item in itemsconfiguration">
<td>{{::item.Description}}</td>
<td>{{::item.Order}}</td>
<td>{{::item.Type}}</td>
<td><span ng-if="item.Active"></span></td>
</tr>
Except that the Type field of my table which is an INT field, I would have to instead of displaying this integer value, display an item from my Enum table.
In my controller I’m already bringing the enuns...
AuditingItemType.query().$promise.then(function (itemtypes) {
$scope.itemtypes = itemtypes;
})
Json I get from Enum table
[{"$id":"1","Id":0,"Name":"TEXT"},{"$id":"2","Id":1,"Name":"QUANTITY"},{"$id":"3","Id":2,"Name":"MULTIPLE"}]
how can I display it on my table dynamically?
Jhonas, your Enum already has the Annotation Description?
– Vinícius
No... public Enum Auditingitemtype { TEXT, QUANTITY, MULTIPLE }
– Jhonas
You are using Webapi 2.0?
– Vinícius
I’m using yes.
– Jhonas