2017-10-31 18:59:27 +01:00
|
|
|
|
2017-11-03 18:57:06 +01:00
|
|
|
|
2017-11-01 16:07:51 +01:00
|
|
|
<table class="table table-striped" [mfData]="tableData | datasetTableFilter : filterQuery | datasetstatusFilter: statusFilter" #mf="mfDataTable" [mfRowsOnPage]="rowsOnPage"
|
2017-11-01 13:01:14 +01:00
|
|
|
[(mfSortBy)]="sortBy" [(mfSortOrder)]="sortOrder">
|
2017-11-03 18:57:06 +01:00
|
|
|
|
2017-10-31 18:59:27 +01:00
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th colspan="1">
|
2017-11-01 13:01:14 +01:00
|
|
|
<input class="form-control" [(ngModel)]="filterQuery" placeholder='Search in Labels' />
|
|
|
|
</th>
|
|
|
|
<th colspan="1">
|
|
|
|
<!-- <input class="form-control" [(ngModel)]="versionFilter" placeholder='Filter' /> -->
|
2017-11-06 14:11:03 +01:00
|
|
|
<select class="form-control" [id]="statusid" [(ngModel)]="statusFilter" [name]="statusDropDown" #datasetfield >
|
2017-11-01 13:01:14 +01:00
|
|
|
<option *ngFor="let opt of statusDropDown.options" [value]="opt.key">{{opt.value}}</option>
|
2017-11-06 14:11:03 +01:00
|
|
|
</select>
|
2017-10-31 18:59:27 +01:00
|
|
|
</th>
|
|
|
|
<th>
|
2017-11-07 13:04:58 +01:00
|
|
|
<button class="btn btn-default" (click)="getDatasets('false')">
|
2017-10-31 18:59:27 +01:00
|
|
|
<span class="glyphicon glyphicon-refresh"></span>
|
|
|
|
</button>
|
|
|
|
</th>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<th [ngClass]="{true:'visible', false:'invisible'}[showIDs]">
|
|
|
|
<mfDefaultSorter by="id">ID</mfDefaultSorter>
|
|
|
|
</th>
|
|
|
|
<th>
|
|
|
|
<mfDefaultSorter by="label">Label</mfDefaultSorter>
|
2017-11-01 16:42:01 +01:00
|
|
|
</th>
|
2017-10-31 18:59:27 +01:00
|
|
|
<th>
|
|
|
|
<mfDefaultSorter by="uri">Uri</mfDefaultSorter>
|
|
|
|
</th>
|
|
|
|
<th>
|
|
|
|
<mfDefaultSorter by="profile">Profile</mfDefaultSorter>
|
|
|
|
</th>
|
|
|
|
<th>
|
|
|
|
<mfDefaultSorter by="description">Description</mfDefaultSorter>
|
|
|
|
</th>
|
2017-11-01 16:42:01 +01:00
|
|
|
<th>
|
2017-11-03 18:57:06 +01:00
|
|
|
<mfDefaultSorter by="created">Created at</mfDefaultSorter>
|
|
|
|
</th>
|
|
|
|
<th>
|
|
|
|
<mfDefaultSorter by="status">Status</mfDefaultSorter>
|
|
|
|
</th>
|
2017-10-31 18:59:27 +01:00
|
|
|
<th>
|
2017-11-03 18:57:06 +01:00
|
|
|
Actions
|
2017-10-31 18:59:27 +01:00
|
|
|
</th>
|
2017-11-01 13:01:14 +01:00
|
|
|
|
2017-10-31 18:59:27 +01:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
<tr class="grayout-empty-table" *ngIf="!mf.data[0]">
|
2017-11-03 18:57:06 +01:00
|
|
|
<td colspan="7">No elements</td>
|
2017-10-31 18:59:27 +01:00
|
|
|
</tr>
|
2017-11-01 13:01:14 +01:00
|
|
|
|
2017-11-01 10:18:51 +01:00
|
|
|
<tr *ngFor="let dataset of mf.data" class="hover">
|
|
|
|
<td [ngClass]="{true:'visible', false:'invisible'}[showIDs]">{{dataset.id}}</td>
|
|
|
|
<td>{{dataset?.label}}</td>
|
|
|
|
<td>{{dataset?.uri}}</td>
|
|
|
|
<td>{{dataset?.profile?.label}}</td>
|
|
|
|
<td>{{dataset?.description}}</td>
|
2017-11-03 18:57:06 +01:00
|
|
|
<td>{{dataset?.created | date:'yyyy-MM-dd HH:mm:ss Z'}}</td>
|
|
|
|
<td>{{dataset?.status | statusToString }}</td>
|
2017-11-01 10:18:51 +01:00
|
|
|
<td><a class="editGridColumn" (click)="editRow(dataset, $event)"><i class="fa fa-pencil fa-fw" data-toggle="tooltip" title="edit Properties" id="editDataset"></i>
|
2017-11-06 14:11:03 +01:00
|
|
|
<i class="fa fa-eraser fa-fw" data-toggle="tooltip" (click)="deleteRow(dataset, $event)" title="delete Dataset"></i>
|
2017-11-01 10:18:51 +01:00
|
|
|
<i class="fa fa-list-alt fa-fw" data-toggle="tooltip" title="describe dataset" id="describeDataset"></i></a></td>
|
2017-11-01 13:01:14 +01:00
|
|
|
|
2017-10-31 18:59:27 +01:00
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
<tfoot>
|
|
|
|
<tr>
|
|
|
|
<td colspan="5">
|
2017-11-01 13:01:14 +01:00
|
|
|
<button type="button" class="btn btn-info btncustom" (click)="newDataset(item)">New Dataset</button>
|
2017-10-31 18:59:27 +01:00
|
|
|
<mfBootstrapPaginator [rowsOnPageSet]="[5,20,40]"></mfBootstrapPaginator>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tfoot>
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
2017-10-27 16:08:10 +02:00
|
|
|
|
|
|
|
<div class="modal fade" id="newDatasetModal" tabindex="-1" role="dialog" aria-labelledby="newDatasetModalLabel" aria-hidden="true">
|
|
|
|
<div class="modal-dialog" role="document">
|
|
|
|
<div class="modal-content">
|
|
|
|
<div class="modal-header">
|
2017-11-06 14:11:03 +01:00
|
|
|
<h5 class="modal-title" >Dataset</h5>
|
2017-10-27 16:08:10 +02:00
|
|
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
|
|
|
<span aria-hidden="true">×</span>
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
<div class="modal-body">
|
2017-11-06 14:11:03 +01:00
|
|
|
<form #newProjectForm="ngForm" (ngSubmit)="SaveDataset()">
|
2017-11-01 13:01:14 +01:00
|
|
|
<div class="form-group">
|
|
|
|
<label for="recipient-name" class="col-form-label">Dataset Profile:</label>
|
2017-11-07 10:19:31 +01:00
|
|
|
<select class="form-control" id="datasetProfileDropDownKey" [(ngModel)]="dataset.profile" name="datasetProfileDropDown"
|
2017-11-01 13:01:14 +01:00
|
|
|
#datasetfield>
|
2017-10-27 16:08:10 +02:00
|
|
|
<option *ngFor="let opt of datasetProfileDropDown.options" [value]="opt.key">{{opt.value}}</option>
|
|
|
|
</select>
|
2017-11-01 13:01:14 +01:00
|
|
|
</div>
|
2017-10-27 16:08:10 +02:00
|
|
|
<div class="form-group">
|
|
|
|
<label for="label-name" class="form-control-label">Label:</label>
|
2017-11-01 13:01:14 +01:00
|
|
|
<input type="text" class="form-control" id="label-name" [(ngModel)]="dataset.label" name="label">
|
2017-10-27 16:08:10 +02:00
|
|
|
</div>
|
|
|
|
<div class="form-group">
|
2017-10-30 15:56:50 +01:00
|
|
|
<label for="abbreviation-text" class="form-control-label">DMP:</label>
|
2017-11-01 13:01:14 +01:00
|
|
|
<input class="form-control" id="abbreviation-text" [(ngModel)]="dataset.dmp" name="dmp" disabled>
|
2017-10-27 16:08:10 +02:00
|
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
|
|
<label for="uri-text" class="form-control-label">Uri:</label>
|
2017-11-01 13:01:14 +01:00
|
|
|
<input class="form-control" id="uri-text" [(ngModel)]="dataset.uri" name="uri">
|
2017-10-27 16:08:10 +02:00
|
|
|
</div>
|
2017-11-07 10:19:31 +01:00
|
|
|
<div class="form-group">
|
|
|
|
<label for="status-name" class="col-form-label">Status:</label>
|
|
|
|
<select class="form-control" id="statusid" [(ngModel)]="dataset.status" name="statusDropDown" #datasetfield>
|
|
|
|
<option *ngFor="let opt of statusDropDown.options" [value]="opt.key">{{opt.value}}</option>
|
|
|
|
</select>
|
|
|
|
</div>
|
2017-11-07 10:21:21 +01:00
|
|
|
<div class="form-group">
|
|
|
|
<label for="abbreviation-text" class="form-control-label">Description:</label>
|
|
|
|
<textarea rows="3" class="form-control" id="abbreviation-text" [(ngModel)]="dataset.description" name="description"></textarea>
|
|
|
|
</div>
|
2017-11-01 13:01:14 +01:00
|
|
|
<!-- <div class="form-group">
|
2017-10-30 15:56:50 +01:00
|
|
|
<label for="start-date" class="form-control-label">Properties:</label>
|
|
|
|
<input class="form-control" id="startDate-date" [(ngModel)]= "dataset.properties" name = "properties">
|
2017-11-01 10:18:51 +01:00
|
|
|
</div> -->
|
2017-11-01 13:01:14 +01:00
|
|
|
<!-- <div class="form-group">
|
2017-10-27 16:08:10 +02:00
|
|
|
<label for="end-date" class="form-control-label">End Date:</label>
|
|
|
|
<input class="form-control" id="endDate-date" [(ngModel)]= "dataset.endDate" name = "endDate">
|
|
|
|
</div> -->
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
<div class="modal-footer">
|
|
|
|
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
2017-11-01 10:18:51 +01:00
|
|
|
<button type="submit" class="btn btn-primary" (click)="SaveDataset();">Save</button>
|
|
|
|
<button type="submit" class="btn btn-primary" (click)="SaveDescribeDataset();">Save and describe</button>
|
2017-10-27 16:08:10 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2017-10-18 18:30:39 +02:00
|
|
|
</div>
|