admin: Improve file readability

This commit is contained in:
nemunaire 2024-03-17 16:03:40 +01:00
commit d323bf9ee9
3 changed files with 26 additions and 3 deletions

View file

@ -14,13 +14,17 @@
<th ng-repeat="field in fields">
{{ field }}
</th>
<th>checksum</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="file in files | filter: query" ng-class="{'bg-danger': file.err !== undefined && file.err !== true}" ng-click="show(file)">
<td>
<button type="button" class="btn btn-sm btn-light" ng-click="$event.stopPropagation();checksum(file)"><span class="glyphicon glyphicon-flash" aria-hidden="true"></span></button>
<button type="button" class="btn btn-sm btn-light" ng-click="$event.stopPropagation();gunzipFile(file)" ng-disabled="file.gunzipWIP">
<button type="button" class="btn btn-sm btn-light" ng-click="$event.stopPropagation();checksum(file)" ng-disabled="file.checkWIP">
<span class="glyphicon glyphicon-flash" aria-hidden="true" ng-if="!file.checkWIP"></span>
<div class="spinner-border spinner-border-sm" role="status" ng-if="file.checkWIP"></div>
</button>
<button type="button" class="btn btn-sm btn-light" ng-click="$event.stopPropagation();gunzipFile(file)" ng-disabled="file.gunzipWIP" ng-if="file.checksum_shown">
<span class="glyphicon glyphicon-compressed" aria-hidden="true" ng-if="!file.gunzipWIP"></span>
<div class="spinner-border spinner-border-sm" role="status" ng-if="file.gunzipWIP"></div>
</button>
@ -29,6 +33,10 @@
{{ file[field] }}
<span ng-if="field == 'id' && file.err !== undefined && file.err !== true" title="{{ file.err }}" class="glyphicon glyphicon-exclamation-sign"></span>
</td>
<td>
{{ file.checksum | bto16 }}
<div ng-if="file.checksum_shown">{{ file.checksum_shown | bto16 }}</div>
</td>
</tr>
</tbody>
</table>