I have a table which can be filtered by several columns. The filter is strict. When the data is initiated, it shows all values. However, after filtering by some column and getting back to empty option to show all values, it shows an empty table. How to apply a strict filter only to non-empty values?
<select
ng-model="search.column1">
<option value=''></option>
<option ng-repeat="e in vm.getExample value="{{e.column1}}">{{e.column1}}</option>
</select>
<select
ng-model="search.column2">
<option value=''></option>
<option ng-repeat="e in vm.getExample value="{{e.column2}}">{{e.column2}}</option>
</select>
<table>
<tr>
<th>Column1</th>
<th>Column2</th>
</tr>
<tr ng-repeat="e in vm.getExample | filter:search:true">
<td>{{ e.column1 }}</td>
<td>{{ e.column2 }}</td>
<tr>
</table>