-
Notifications
You must be signed in to change notification settings - Fork 284
/
filters.html
80 lines (70 loc) · 3.14 KB
/
filters.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
<span page-title ng-model="contentView">{{ 'Filters for Content View:' | translate }} {{ contentView.name }}</span>
<div data-extend-template="layouts/details-nutupane.html">
<div data-block="messages"></div>
<div data-block="header">
<h3 translate>Filters</h3>
</div>
<div data-block="actions">
<button class="btn btn-default"
ng-hide="denied('edit_content_views', contentView)"
ui-sref="content-views.details.filters.new">
<i class="fa fa-plus"></i>
<span translate>New Filter</span>
</button>
<button class="btn btn-default"
ng-hide="denied('edit_content_views', contentView)"
ng-disabled="detailsTable.numSelected === 0"
ng-click="removeFilters()">
<i class="fa fa-trash-o"></i>
<span translate>Remove Filters</span>
</button>
</div>
<div data-block="table">
<p bst-alert="info" ng-show="detailsTable.rows.length === 0 && !detailsTable.working">
<span translate>
You currently don't have any Filters included in this Content View, you can add a new Filter by using the button on the right.
</span>
</p>
<table class="table table-striped table-bordered" ng-show="detailsTable.rows.length > 0"
ng-class="{'table-mask': detailsTable.working}">
<thead>
<tr bst-table-head row-select>
<th bst-table-column><span translate>Name</span></th>
<th bst-table-column><span translate>Description</span></th>
<th bst-table-column><span translate>Updated</span></th>
<th bst-table-column><span translate>Content Type</span></th>
<th bst-table-column><span translate>Type</span></th>
</tr>
</thead>
<tbody>
<tr bst-table-row ng-repeat="filter in detailsTable.rows" row-select="filter">
<td bst-table-cell>
<a ng-if="filter.type === 'erratum' && !filter.rules[0].types"
ui-sref="content-views.details.filters.details.erratum.list({filterId: filter.id})">
{{ filter.name }}
</a>
<a ng-if="filter.type === 'erratum' && filter.rules[0].types"
ui-sref="content-views.details.filters.details.erratum.dateType({filterId: filter.id})">
{{ filter.name }}
</a>
<a ng-if="filter.type === 'rpm'"
ui-sref="content-views.details.filters.details.rpm.details({filterId: filter.id})">
{{ filter.name }}
</a>
<a ng-if="filter.type === 'package_group'"
ui-sref="content-views.details.filters.details.package_group.list({filterId: filter.id})">
{{ filter.name }}
</a>
</td>
<td bst-table-cell>{{ filter.description }}</td>
<td bst-table-cell>{{ filter.updated_at | date:"short" }}</td>
<td bst-table-cell>
{{ filter.type | filterContentType }}
<span ng-if="filter.type === 'erratum' && filter.rules[0].types">{{ '- Date and Type' | translate }}</span>
</td>
<td bst-table-cell>{{ filter.inclusion | filterType }}</td>
</tr>
</tbody>
</table>
</div>
</div>