Project

General

Profile

1
<div id="tm-main" class=" uk-section  uk-margin-small-top tm-middle"   >
2
  <div uk-grid uk-grid>
3
    <div class="tm-main uk-width-1-1@s uk-width-1-1@m  uk-width-1-1@l uk-row-first ">
4

    
5
      <div   [class]="'uk-background-norepeat uk-background-cover uk-section uk-flex uk-flex-middle '+searchFormClass" >
6
        <div   class="uk-width-1-1">
7
          <div   class="uk-width-1-1">
8
            <search-form [isDisabled]="disableForms" [(keyword)]="searchUtils.keyword" (keywordChange)="keywordChanged($event)"  [placeholderText]="formPlaceholderText"></search-form>
9
          </div>
10
          <div   class="uk-width-1-1  uk-light">
11
            <div *ngIf="isFiltered()" class = "uk-container uk-text-center ">
12
              <span *ngIf = "searchUtils.keyword.length > 0">Keywords: <span>{{searchUtils.keyword}}<a (click) = "clearKeywords() " [class]="(disableForms)?'uk-icon-button uk-disabled':'uk-icon-button'"><span class=" clickable " aria-hidden="true"><span class="uk-icon">
13
                <svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="close" ratio="1"><path fill="none" stroke="#000" stroke-width="1.06" d="M16,16 L4,4"></path><path fill="none" stroke="#000" stroke-width="1.06" d="M16,4 L4,16"></path></svg>
14
                </span></span></a></span>
15
              </span>
16
              <span *ngFor="let filter of filters " >
17
                <span *ngIf = "filter.countSelectedValues > 0"> {{filter.title}}:
18
                  <span *ngFor="let value of getSelectedValues(filter); let i = index;  let end = last; " >{{value.name}}<a (click) = "removeFilter(value, filter) " [class]="(disableForms)?'uk-icon-button uk-disabled':'uk-icon-button'"><span class=" clickable" aria-hidden="true"><span class="uk-icon">
19
                    <svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="close" ratio="1"><path fill="none" stroke="#000" stroke-width="1.06" d="M16,16 L4,4"></path><path fill="none" stroke="#000" stroke-width="1.06" d="M16,4 L4,16"></path></svg>
20
                    </span></span></a>
21
                    <span *ngIf="!end">, </span>
22
                  </span>
23
                </span>
24
              </span>
25

    
26
              <a (click)="clearFilters()" [class]="(disableForms)?'uk-disabled uk-link-muted':''">
27
                Clear All
28
              </a>
29
            </div>
30
          </div>
31
        </div>
32
      </div>
33
      <div  class="uk-container">
34
        <helper position="top"></helper>
35
        <errorMessages [status]="[searchUtils.status]" [type]="'results'"></errorMessages>
36

    
37
        <div  class="uk-width-2-3@m  uk-width-2-3@l  uk-width-1-1@s">
38

    
39
          <div *ngIf="searchUtils.totalResults > 0" class="uk-offcanvas-content uk-hidden@m">
40
            <a href="#offcanvas-usage" uk-toggle><svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" ratio="1"><rect x="6" y="4" width="12" height="1"></rect><rect x="6" y="9" width="12" height="1"></rect><rect x="6" y="14" width="12" height="1"></rect><rect x="2" y="4" width="2" height="1"></rect><rect x="2" y="9" width="2" height="1"></rect><rect x="2" y="14" width="2" height="1"></rect></svg></a>
41

    
42
            <div id="offcanvas-usage" uk-offcanvas>
43
              <div class="uk-offcanvas-bar">
44
                <button class="uk-offcanvas-close" type="button" uk-close></button>
45
                <div class="uk-text-large">Filter By:</div>
46
                <search-filter  *ngFor="let filter of filters " [addShowMore]=false [isDisabled]="disableForms" [filter]="filter"  [showResultCount]=showResultCount (change)="filterChanged($event)" (toggleModal)="toggleModal($event)"></search-filter>
47
              </div>
48
            </div>
49

    
50
          </div>
51
        </div>
52

    
53
        <div  class="uk-grid uk-width-1-1">
54
          <div *ngIf="searchUtils.totalResults > 0" class="helper-left-right search-filters uk-width-1-6@m  uk-visible@m">
55
            <helper position="left"></helper>
56
            <search-filter  *ngFor="let filter of filters " [isDisabled]="disableForms" [filter]="filter"  [showResultCount]=showResultCount (change)="filterChanged($event)" (toggleModal)="toggleModal($event)"></search-filter>
57
          </div>
58

    
59
          <div class="uk-width-expand@m uk-width-1-1@s uk-first-column" >
60
            <div class="uk-align-center uk-margin-remove-bottom">
61
              <div class="searchPaging uk-panel uk-margin-top uk-grid uk-margin-bottom">
62
                <span class="uk-h6 uk-width-1-1@s uk-width-1-2@m">
63
                  {{searchUtils.totalResults}} content providers, page {{searchUtils.page}} of {{(totalPages())}}
64
                </span>
65
                <span class="float-children-right-at-medium margin-small-top-at-small uk-width-1-1@s uk-width-1-2@m">
66
                  <paging-no-load [currentPage]="searchUtils.page" [totalResults]="searchUtils.totalResults" [size]="rowsOnPage" (pageChange)="goTo($event.value, false)"></paging-no-load>
67
                </span>
68
              </div>
69
            </div>
70

    
71
            <div *ngIf="searchViewLink" class="uk-width-1-1@s uk-hidden@m">
72
              <p>
73
                <span class="uk-margin-small-right uk-icon"><svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" ratio="1"><rect x="2" y="2" width="3" height="3"></rect><rect x="8" y="2" width="3" height="3"></rect><rect x="14" y="2" width="3" height="3"></rect><rect x="2" y="8" width="3" height="3"></rect><rect x="8" y="8" width="3" height="3"></rect><rect x="14" y="8" width="3" height="3"></rect><rect x="2" y="14" width="3" height="3"></rect><rect x="8" y="14" width="3" height="3"></rect><rect x="14" y="14" width="3" height="3"></rect></svg></span>
74

    
75
                <a routerLinkActive="router-link-active" [class]="(disableForms)?'uk-disabled uk-link-muted':''" [routerLink]=searchViewLink >
76
                  <span class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="table" ratio="1"><rect x="1" y="3" width="18" height="1"></rect><rect x="1" y="7" width="18" height="1"></rect><rect x="1" y="11" width="18" height="1"></rect><rect x="1" y="15" width="18" height="1"></rect></svg></span>
77
                </a>
78
              </p>
79
            </div>
80

    
81
            <div class="uk-overflow-container custom-dataTable-content">
82
              <table  class="uk-table uk-table-striped divider-table"  #mf="mfDataTable" [mfRowsOnPage]="rowsOnPage"
83
                      [mfData]="results | contentProvidersDatatable : [searchUtils, filters, triggerPipe]">
84

    
85
                <thead *ngIf="searchUtils.totalResults > 0">
86
                  <tr>
87
                    <!-- Name	Type	Country	Institution	Compatibility -->
88
                    <th class="uk-text-left"><mfDefaultSorter by="title.name">Name</mfDefaultSorter>
89
                      <svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
90
                        <polygon fill="#767779" points="4 1 1 6 7 6"></polygon>
91
                        <polygon fill="#767779" points="4 13 1 8 7 8"></polygon>
92
                      </svg>
93
                    </th>
94
                    <th class="uk-text-center"><mfDefaultSorter by="type">Type</mfDefaultSorter>
95
                      <svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
96
                        <polygon fill="#767779" points="4 1 1 6 7 6"></polygon>
97
                        <polygon fill="#767779" points="4 13 1 8 7 8"></polygon>
98
                      </svg>
99
                    </th>
100
                    <th class="uk-text-center"><mfDefaultSorter by="countries">Country</mfDefaultSorter>
101
                      <svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
102
                        <polygon fill="#767779" points="4 1 1 6 7 6"></polygon>
103
                        <polygon fill="#767779" points="4 13 1 8 7 8"></polygon>
104
                      </svg>
105
                    </th>
106
                    <th class="uk-text-center"><mfDefaultSorter [by]="sortByOrganization">Institution</mfDefaultSorter>
107
                      <svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
108
                        <polygon fill="#767779" points="4 1 1 6 7 6"></polygon>
109
                        <polygon fill="#767779" points="4 13 1 8 7 8"></polygon>
110
                      </svg>
111
                    </th>
112
                    <th class="uk-text-center"><mfDefaultSorter by="compatibility">Compatibility</mfDefaultSorter>
113
                      <svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
114
                        <polygon fill="#767779" points="4 1 1 6 7 6"></polygon>
115
                        <polygon fill="#767779" points="4 13 1 8 7 8"></polygon>
116
                      </svg>
117
                    </th>
118
                  </tr>
119
                </thead>
120
                <tbody *ngIf="searchUtils.totalResults > 0">
121
                  <tr class="uk-table-middle" *ngFor="let dataprovider of mf.data">
122
                    <td  class="uk-width-1-5 uk-text-left">
123
                      <a [queryParams]="{datasourceId: dataprovider.id}" routerLinkActive="router-link-active" routerLink="/search/dataprovider">
124
                        <span *ngIf="dataprovider.title.name"
125
                              [innerHTML]="dataprovider.title.name">
126
                        </span>
127
                        <span *ngIf="!dataprovider.title.name">
128
                          [no title available]
129
                        </span>
130
                      </a>
131
                    </td>
132
                    <td class="uk-width-1-5 uk-text-center">
133
                      <span *ngIf="dataprovider.type">{{dataprovider.type}}</span>
134
                      <span *ngIf="!dataprovider.type">-</span>
135
                    </td>
136
                    <td class="uk-width-1-5 uk-text-center">
137
                      <span *ngFor="let country of dataprovider['countries'].slice(0,5) let i = index">{{country}}{{(i < ( dataprovider['countries'].slice(0,5).length-1))?", ":""}}{{(i ==  dataprovider['countries'].slice(0,5).length-1 &&  dataprovider['countries'].length > 5)?"...":""}}</span>
138
                      <span *ngIf="dataprovider.countries.length == 0">-</span>
139
                    </td>
140
                    <td class="uk-width-1-5 uk-text-center">
141
                      <span *ngFor="let org of dataprovider['organizations'].slice(0,5) let i = index">
142
                        <a *ngIf="org.id" [queryParams]="{organizationId: org.id}" routerLinkActive="router-link-active" routerLink="/search/organization">{{org.name}}</a><span *ngIf="!org.id">{{org.name}}</span>{{(i < ( dataprovider['organizations'].slice(0,5).length-1))?", ":""}}{{(i ==  dataprovider['organizations'].slice(0,5).length-1 &&  dataprovider['organizations'].length > 5)?"...":""}}
143
                      </span>
144
                      <span *ngIf="dataprovider.organizations.length == 0">-</span>
145
                    </td>
146
                    <td  class="uk-width-1-5 uk-text-center">
147
                      <span *ngIf="dataprovider.compatibility">{{dataprovider.compatibility}}</span>
148
                      <span *ngIf="!dataprovider.compatibility">-</span>
149
                    </td>
150
                  </tr>
151
                </tbody>
152
                <!-- <thead *ngIf="searchUtils.totalResults > 0">
153
                  <tr><td colspan="5" class="uk-padding-remove-horizontal">
154
                    <span class="uk-h6">
155
                      {{searchUtils.totalResults}} content providers, page {{searchUtils.page}} of {{(totalPages())}}
156
                    </span>
157
                    <paging-no-load class="uk-float-right" [currentPage]="searchUtils.page" [totalResults]="searchUtils.totalResults" [size]="rowsOnPage" (pageChange)="goTo($event.value, false)"></paging-no-load>
158
                  </td></tr>
159
                </thead> -->
160
              </table>
161
            </div>
162

    
163
            <div class="uk-align-center uk-margin-remove-bottom">
164
              <div class="searchPaging uk-panel uk-margin-top uk-grid uk-margin-bottom">
165
                <span class="uk-h6 uk-width-1-1@s uk-width-1-2@m">
166
                  {{searchUtils.totalResults}} content providers, page {{searchUtils.page}} of {{(totalPages())}}
167
                </span>
168
                <span class="float-children-right-at-medium margin-small-top-at-small uk-width-1-1@s uk-width-1-2@m">
169
                  <paging-no-load [currentPage]="searchUtils.page" [totalResults]="searchUtils.totalResults" [size]="rowsOnPage" (pageChange)="goTo($event.value, false)"></paging-no-load>
170
                </span>
171
              </div>
172
            </div>
173

    
174
            <helper class="uk-hidden@m" position="left" styleName="uk-width-1-1@s"></helper>
175
            <helper class="uk-hidden@m" position="right" styleName="uk-width-1-1@s"></helper>
176
          </div>
177

    
178
          <div *ngIf="searchViewLink" class="helper-left-right uk-width-1-6@m uk-visible@m">
179
            <p>
180
              <span class="uk-margin-small-right uk-icon"><svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" ratio="1"><rect x="2" y="2" width="3" height="3"></rect><rect x="8" y="2" width="3" height="3"></rect><rect x="14" y="2" width="3" height="3"></rect><rect x="2" y="8" width="3" height="3"></rect><rect x="8" y="8" width="3" height="3"></rect><rect x="14" y="8" width="3" height="3"></rect><rect x="2" y="14" width="3" height="3"></rect><rect x="8" y="14" width="3" height="3"></rect><rect x="14" y="14" width="3" height="3"></rect></svg></span>
181

    
182
              <a routerLinkActive="router-link-active" [class]="(disableForms)?'uk-disabled uk-link-muted':''" [routerLink]=searchViewLink >
183
                <span class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="table" ratio="1"><rect x="1" y="3" width="18" height="1"></rect><rect x="1" y="7" width="18" height="1"></rect><rect x="1" y="11" width="18" height="1"></rect><rect x="1" y="15" width="18" height="1"></rect></svg></span>
184
              </a>
185
            </p>
186

    
187
            <helper position="right"></helper>
188
          </div>
189
        </div>
190

    
191
        <helper position="bottom"></helper>
192
      </div>
193
      <modal-search-filter [filter]="currentFilter" [showResultCount]=showResultCount (modalChange)="filterChanged($event)"></modal-search-filter>
194
    </div>
195
  </div>
196
</div>
(25-25/36)