Files
refstack/refstack-ui/app/components/results/results.html
sslypushenko 8f8bf6dce3 Handle signout properly
RefStack UI should properly handle user signout.
How to check:
Open two RefStack in two browser tabs and signin in both. Then signout in first
tab. Then try to open 'Profile' or 'My Results' in second tab. If everything is
ok you will be redirected to RefStack home tab.

Change-Id: Ifc14ba953b269ce8940f82e61d7f3634682fe0da
2015-08-28 17:36:14 +03:00

85 lines
3.2 KiB
HTML

<h3>{{pageHeader}}</h3>
<p>The most recently uploaded community test results are listed here.</p>
<div class="result-filters">
<h4>Filters</h4>
<div class="row">
<div class="col-md-3">
<label for="cpid">Start Date</label>
<p class="input-group">
<input type="text" class="form-control"
datepicker-popup="{{format}}"
ng-model="startDate" is-open="startOpen"
datepicker-options="dateOptions"
close-text="Close" />
<span class="input-group-btn">
<button type="button" class="btn btn-default" ng-click="open($event, 'startOpen')">
<i class="glyphicon glyphicon-calendar"></i>
</button>
</span>
</p>
</div>
<div class="col-md-3">
<label for="cpid">End Date</label>
<p class="input-group">
<input type="text" class="form-control"
datepicker-popup="{{format}}"
ng-model="endDate" is-open="endOpen"
datepicker-options="dateOptions"
close-text="Close" />
<span class="input-group-btn">
<button type="button" class="btn btn-default" ng-click="open($event, 'endOpen')">
<i class="glyphicon glyphicon-calendar"></i>
</button>
</span>
</p>
</div>
<div class="col-md-3"style="margin-top:24px;">
<button type="submit" class="btn btn-primary" ng-click="update()">Filter</button>
<button type="submit" class="btn btn-primary btn-danger" ng-click="clearFilters()">Clear</button>
</div>
</div>
</div>
<div cg-busy="{promise:authRequest,message:'Loading'}"></div>
<div cg-busy="{promise:resultsRequest,message:'Loading'}"></div>
<div ng-show="data" class="results-table">
<table ng-show="data" class="table table-striped table-hover">
<thead>
<tr>
<th>Upload Date</th>
<th>Test Run ID</th>
<th ng-if="::isUserResults">Shared</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="result in data.results">
<td>{{result.created_at}}</td>
<td><a ui-sref="resultsDetail({testID: result.id})">{{result.id}}</a></td>
<td ng-if="::isUserResults"><span ng-show="result.meta.shared" class="glyphicon glyphicon-share"></span></td>
</tr>
</tbody>
</table>
<div class="pages">
<pagination
total-items="totalItems"
ng-model="currentPage"
items-per-page="itemsPerPage"
max-size="maxSize"
class="pagination-sm"
boundary-links="true"
rotate="false"
num-pages="numPages"
ng-change="update()">
</pagination>
</div>
</div>
<div ng-show="showError" class="alert alert-danger" role="alert">
<span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span>
<span class="sr-only">Error:</span>
{{error}}
</div>