Edit in JSFiddle

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.0/angular.min.js"></script>
<div ng-app="app">
    <p>{{0 | status}}</p>
    <p>{{1 | status}}</p>
    <p>{{2 | status}}</p>
</div>
angular.module('app', [])
  .filter('status', function() {
    return function(input, scope) {
        switch(input) {
            case 0: return "Error";
            case 1: return "Warning";
            case 2: return "Success";
        }
    }
  });