Revision 60202
Added by Argiro Kokogiannaki over 3 years ago
portals.component.html | ||
---|---|---|
1 |
<div id="page_content" click-outside-or-esc targetId="page_content"> |
|
2 |
<!-- [escClose]="false"--> |
|
3 |
<!-- (clickOutside)="toggleOpen($event)">--> |
|
4 |
<div class="uk-padding-small md-bg-white" uk-grid> |
|
5 |
|
|
6 |
<div class="uk-width-expand@m uk-width-1-1 uk-flex uk-flex-middle uk-flex-right"> |
|
7 |
<div class="uk-inline uk-width-medium"> |
|
1 |
<div page-content> |
|
2 |
<admin-tabs tab = "portal" header></admin-tabs> |
|
3 |
<div inner class="admin-pages"> |
|
4 |
<div *ngIf="!errorMessage && !showLoading" class="filters" uk-sticky="offset:150"> |
|
5 |
<div class="show-options uk-float-right"> |
|
6 |
<button class="uk-button uk-button-primary " type="button">Bulk Actions</button> |
|
7 |
<div uk-dropdown="mode: click"> |
|
8 |
<ul class="uk-nav uk-margin-left" |
|
9 |
[attr.uk-tooltip]="getSelectedCommunities().length == 0 ? 'pos:left; cls: uk-active' : 'cls: uk-invisible'" |
|
10 |
title="Select at least one portal"> |
|
11 |
<li><a [class]="getSelectedCommunities().length == 0 ? 'uk-disabled' : ''" |
|
12 |
(click)="confirmDeleteSelectedCommunities()"><i></i> Delete </a></li> |
|
13 |
</ul> |
|
14 |
</div> |
|
15 |
</div> |
|
16 |
<div class="uk-inline uk-width-medium uk-float-right uk-margin-right" > |
|
8 | 17 |
<span class="uk-position-center-right"><i class="material-icons">search</i></span> |
9 |
<div dashboard-input label="Locate indicator" [formInput]="formControl" label="Locate portal"></div> |
|
18 |
<div dashboard-input [formInput]="filterForm.controls.keyword" |
|
19 |
placeholder="Search"></div> |
|
10 | 20 |
</div> |
11 |
|
|
21 |
<ul class="uk-subnav uk-subnav-pill subCategoriesTabs ignore admin " > |
|
22 |
<li [class.uk-active]="filterForm.get('type').value === 'all'" class="uk-margin-small-bottom"><a |
|
23 |
(click)="filterForm.get('type').setValue('all')"><span |
|
24 |
class="title">All portals</span></a></li> |
|
25 |
<li *ngFor="let type of portalUtils.portalTypes; let i=index" |
|
26 |
[class.uk-active]="filterForm.get('type').value === type.value" class="uk-margin-small-bottom"><a |
|
27 |
(click)="filterForm.get('type').setValue(type.value)"><span |
|
28 |
class="title">{{type.label}}</span></a></li> |
|
29 |
</ul> |
|
12 | 30 |
</div> |
13 |
</div> |
|
14 |
<div id="page_content_inner"> |
|
15 | 31 |
|
16 |
<div class="menubar "> |
|
17 |
<h4 class="uk-text-bold">Portals</h4> |
|
32 |
<div class="uk-margin-top"> |
|
33 |
<a *ngIf="!showLoading && !errorMessage" (click)="newCommunity()" |
|
34 |
class="uk-flex uk-flex-right uk-flex-middle uk-margin-small-bottom"> |
|
35 |
<div class="uk-button-default large uk-icon-button uk-margin-small-right" uk-icon="plus"> |
|
36 |
</div> |
|
37 |
Add portal |
|
38 |
</a> |
|
18 | 39 |
<div *ngIf="updateErrorMessage" class="uk-alert-danger" uk-alert> |
19 | 40 |
<a class="uk-alert-close" uk-close></a> |
20 | 41 |
{{updateErrorMessage}} |
21 | 42 |
</div> |
22 |
</div> |
|
43 |
<div *ngIf="errorMessage" class="uk-alert uk-alert-danger uk-margin-large-top" |
|
44 |
role="alert">{{errorMessage}}</div> |
|
45 |
<div [style.display]="showLoading ? 'inline' : 'none'" |
|
46 |
class="uk-animation-fade uk-margin-large-top uk-width-1-1" role="alert"><img |
|
47 |
class="uk-align-center loading-gif"></div> |
|
23 | 48 |
|
24 |
<div class="content-wrapper" id="contentWrapper"> |
|
25 | 49 |
|
26 |
<div class="contentPanel"> |
|
27 |
<div *ngIf="errorMessage" class="uk-alert uk-alert-danger uk-margin-large-top" |
|
28 |
role="alert">{{errorMessage}}</div> |
|
29 |
<div [style.display]="showLoading ? 'inline' : 'none'" |
|
30 |
class="uk-animation-fade uk-margin-large-top uk-width-1-1" role="alert"><img |
|
31 |
class="uk-align-center loading-gif"></div> |
|
32 | 50 |
|
33 |
<div *ngIf="!errorMessage && !showLoading" class="page-controls"> |
|
34 |
<div class=" filters "> |
|
35 |
<div class="show-options uk-float-right"> |
|
36 |
<button class="uk-button" type="button">Bulk Actions</button> |
|
37 |
<div uk-dropdown="mode: click"> |
|
38 |
<ul class="uk-nav uk-margin-left" |
|
39 |
[attr.uk-tooltip]="getSelectedCommunities().length == 0 ? 'pos:left; cls: uk-active' : 'cls: uk-invisible'" |
|
40 |
title="Select at least one portal"> |
|
41 |
<li><a [class]="getSelectedCommunities().length == 0 ? 'uk-disabled' : ''" |
|
42 |
(click)="confirmDeleteSelectedCommunities()"><i></i> Delete </a></li> |
|
43 |
</ul> |
|
44 |
</div> |
|
45 |
</div> |
|
46 |
</div> |
|
47 |
</div> |
|
51 |
<div class=" uk-margin-medium-bottom" *ngIf="!errorMessage && !showLoading"> |
|
48 | 52 |
|
49 |
<div class="md-card uk-margin-medium-bottom" *ngIf="!errorMessage && !showLoading"> |
|
50 |
<div class="md-card-content"> |
|
51 |
<div class="uk-overflow-container"> |
|
52 |
<table class="uk-table uk-table-striped uk-table-hover"> |
|
53 |
<div class=""> |
|
54 |
<div class="uk-overflow-container"> |
|
55 |
<table class="uk-table uk-table-striped uk-table-hover"> |
|
56 |
<thead class="form-header"> |
|
57 |
<tr> |
|
58 |
<th><input id="allCommunityCheckbox" type="checkbox" (change)="toggleCheckBoxes($event)"></th> |
|
59 |
<th>Name</th> |
|
60 |
<th>Type</th> |
|
61 |
<th>Actions</th> |
|
62 |
</tr> |
|
63 |
</thead> |
|
64 |
<tbody> |
|
65 |
<tr *ngFor="let check of checkboxes; let i=index"> |
|
66 |
<td><input id="{{check.community._id}}" class="checkBox" type="checkbox" |
|
67 |
name="communitiescb[]" value="{{check.community._id}}" [(ngModel)]="check.checked"> |
|
68 |
</td> |
|
69 |
<td> |
|
70 |
<div class="name" href="#">{{check.community.name}}</div> |
|
71 |
</td> |
|
72 |
<td> |
|
73 |
<div class="type" href="#">{{check.community.type}}</div> |
|
74 |
</td> |
|
75 |
<td> |
|
76 |
<div class="actions" href="#"> |
|
77 |
<i class="clickable" uk-icon="pencil" (click)="editCommunity(i)"></i> |
|
78 |
<i class="clickable uk-text-danger" uk-icon="trash" |
|
79 |
(click)="confirmDeleteCommunity(check.community._id)"></i> |
|
80 |
</div> |
|
81 |
</td> |
|
53 | 82 |
|
54 |
<thead> |
|
55 |
<tr> |
|
56 |
<th><input id="allCommunityCheckbox" type="checkbox" (change)="toggleCheckBoxes($event)"></th> |
|
57 |
<th>Name</th> |
|
58 |
<th>Type</th> |
|
59 |
<th>Actions</th> |
|
60 |
</tr> |
|
61 |
</thead> |
|
62 |
<tbody> |
|
63 |
<tr *ngFor="let check of checkboxes; let i=index"> |
|
64 |
<td><input id="{{check.community._id}}" class="checkBox" type="checkbox" |
|
65 |
name="communitiescb[]" value="{{check.community._id}}" [(ngModel)]="check.checked"> |
|
66 |
</td> |
|
67 |
<td> |
|
68 |
<div class="name" href="#">{{check.community.name}}</div> |
|
69 |
</td> |
|
70 |
<td> |
|
71 |
<div class="type" href="#">{{check.community.type}}</div> |
|
72 |
</td> |
|
73 |
<td> |
|
74 |
<div class="actions" href="#"> |
|
75 |
<i class="clickable" uk-icon="pencil" (click)="editCommunity(i)"></i> |
|
76 |
<i class="clickable uk-text-danger" uk-icon="trash" |
|
77 |
(click)="confirmDeleteCommunity(check.community._id)"></i> |
|
78 |
</div> |
|
79 |
</td> |
|
83 |
</tr> |
|
80 | 84 |
|
81 |
</tr>
|
|
82 |
|
|
83 |
</tbody>
|
|
84 |
</table>
|
|
85 |
<div class="uk-width-1-1 uk-flex uk-flex-center ">
|
|
86 |
<div class="uk-width-small uk-button-default uk-button" (click)="newCommunity()">
|
|
87 |
<i class="" uk-icon="plus"></i>
|
|
88 |
</div>
|
|
85 |
</tbody>
|
|
86 |
</table> |
|
87 |
<div *ngIf="checkboxes.length==0" class="col-md-12">
|
|
88 |
<div class="uk-alert-warning" uk-alert>No portals found</div>
|
|
89 |
</div>
|
|
90 |
<!--<div class="uk-width-1-1 uk-flex uk-flex-center ">
|
|
91 |
<div class="uk-width-small uk-button-default uk-button" (click)="newCommunity()">
|
|
92 |
<i class="" uk-icon="plus"></i>
|
|
89 | 93 |
</div> |
90 |
|
|
91 |
|
|
92 |
<div *ngIf="checkboxes.length==0" class="col-md-12"> |
|
93 |
<div class="uk-alert-warning" uk-alert>No portals found</div> |
|
94 |
</div> |
|
95 |
</div> |
|
94 |
</div>--> |
|
96 | 95 |
</div> |
97 | 96 |
</div> |
98 |
|
|
99 |
|
|
100 | 97 |
</div> |
101 | 98 |
</div> |
99 |
</div> |
|
100 |
</div> |
|
102 | 101 |
|
103 |
|
|
104 |
</div> |
|
105 | 102 |
<modal-alert #AlertModalSaveCommunity (alertOutput)="communitySaveConfirmed($event)" |
106 | 103 |
[okDisabled]="portalFG && (portalFG.invalid || !portalFG.dirty)"> |
107 | 104 |
|
... | ... | |
129 | 126 |
</form> |
130 | 127 |
|
131 | 128 |
</modal-alert> |
132 |
|
|
133 |
|
|
134 | 129 |
<modal-alert #AlertModalDeleteCommunities (alertOutput)="confirmedDeleteCommunities($event)"></modal-alert> |
135 |
</div> |
Also available in: Unified diff
[Library | Trunk]
Dashboard - Admin tool pages:
- add tabs components
- add rout module (without guards)
- put tabs and page-content in pages, classes, entities pages
Stakeholder:
initial try to add filters for country and organization fields (doesn't work properly)