This repository has been archived by the owner on Nov 22, 2019. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes to selected table card of the data service wizard
- selected table cards are now in a scrollable div - selected table card can now be expanded to allow column selection - just using dummy column data currently until design is approved
- Loading branch information
1 parent
f8fda6c
commit 43639e7
Showing
9 changed files
with
309 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/** | ||
* @license | ||
* Copyright 2017 JBoss Inc | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
export class Column { | ||
|
||
public selected = true; | ||
public name: string; | ||
public type: string; | ||
public size: number; | ||
|
||
public constructor( name: string, | ||
selected: boolean, | ||
type: string, | ||
size: number ) { | ||
this.name = name; | ||
this.type = type; | ||
this.selected = selected; | ||
this.size = size; | ||
} | ||
|
||
} |
68 changes: 57 additions & 11 deletions
68
ngapp/src/app/dataservices/selected-table/selected-table.component.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,70 @@ | ||
.selected-table-card { | ||
.selected-table-card .card-pf { | ||
background-color: #def3ff; | ||
border:2px dotted darkblue; | ||
margin-top: 5px; | ||
margin-left: 0; | ||
min-height: 60px; | ||
max-height: 80px; | ||
padding-top: 5px; | ||
padding-right: 5px; | ||
margin: 0 0px 10px; | ||
min-height: 40px; | ||
} | ||
|
||
.selected-table-name { | ||
margin-left: 20px; | ||
.selected-table-name:before { | ||
display: inline-block; | ||
margin-bottom: 0px; | ||
margin-right: 10px; | ||
margin-top: 0px; | ||
font-family: "FontAwesome"; | ||
content: "\f0ce"; | ||
} | ||
|
||
.selected-table-name .card-pf-title { | ||
margin-bottom: 0px; | ||
margin-left: 5px; | ||
margin-top: 0px; | ||
font-size: 14px; | ||
font-weight: bold; | ||
} | ||
|
||
.selected-table-connection { | ||
.selected-table-connection:before { | ||
display: inline-block; | ||
margin-bottom: 0px; | ||
margin-left: 20px; | ||
margin-right: 10px; | ||
margin-top: 0px; | ||
font-family: "FontAwesome"; | ||
content: "\f1e6"; | ||
color: #666666; | ||
} | ||
|
||
.selected-table-connection .card-pf-subtitle { | ||
color: #666666; | ||
margin-bottom: 0px; | ||
margin-left: 5px; | ||
margin-top: 0px; | ||
font-size: 14px; | ||
} | ||
|
||
.selected-table-close-icon { | ||
cursor: pointer; | ||
color: darkred; | ||
} | ||
|
||
.selected-table-body .card-pf-body { | ||
background-color: white; | ||
margin-top: 10px !important; | ||
} | ||
|
||
.selected-table-column-selection { | ||
margin-left: 5px; | ||
padding-top: 5px; | ||
font-weight: bold; | ||
} | ||
|
||
.seleted-table-card .pfng-card .card-pf-heading { | ||
background-color: #def3ff; | ||
margin-bottom: -10px !important; | ||
} | ||
|
||
|
||
.selected-table-card .pfng-card .card-pf-footer { | ||
margin: 0 !important; | ||
padding: 10px 0px 5px 20px; | ||
min-height: 20px; | ||
} | ||
|
90 changes: 84 additions & 6 deletions
90
ngapp/src/app/dataservices/selected-table/selected-table.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,84 @@ | ||
<div class="col-sm-12 selected-table-card"> | ||
<span class="fa fa-plug"></span><span class="selected-table-connection">{{ table.getConnection().getId() }}</span> | ||
<span class="fa fa-close pull-right selected-table-close-icon" (click)="onRemove()"></span> | ||
<br> | ||
<span class="selected-table-name">{{ table.getName() }}</span> | ||
</div> | ||
<pfng-card class="selected-table-card" | ||
[config]="config" | ||
[headerTemplate]="tableHeaderTemplate" | ||
(onActionSelect)="handleActionSelect($event)"> | ||
<ng-template #tableHeaderTemplate> | ||
<h3 class="selected-table-name"> | ||
<span class="fa fa-close pull-right selected-table-close-icon" (click)="onRemove()"></span> | ||
{{ table.getName() }} | ||
</h3> | ||
<h5 class="selected-table-connection">{{ table.getConnection().getId() }}</h5> | ||
</ng-template> | ||
<div class="selected-table-body"> | ||
<div *ngIf="showColumns"> | ||
<h5 class="selected-table-column-selection">Select columns to include in the view:</h5> | ||
<ngx-datatable style="max-height: 200px;" | ||
[rows]="columnDefinitions" | ||
[footerHeight]="50" | ||
[scrollbarV]="true" | ||
[scrollbarH]="true" | ||
[columnMode]="'force'" | ||
[reorderable]="false" | ||
[selectionType]="'checkbox'" | ||
[sorts]="[{prop: 'name', dir: 'asc'}]" | ||
[cssClasses]="customClasses"> | ||
<ngx-datatable-column name="" | ||
[prop]="'selected'" | ||
[width]="40" | ||
[sortable]="false" | ||
[canAutoResize]="true" | ||
[draggable]="false" | ||
[resizeable]="false"> | ||
<ngx-datatable-footer> | ||
<ng-template ngx-datatable-footer-template> | ||
<div style="padding: 5px 10px">{{selectedColumnCount}} of {{columnCount}} selected</div> | ||
</ng-template> | ||
</ngx-datatable-footer> | ||
<ng-template ngx-datatable-cell-template let-row="row" let-isSelected="row.selected" let-onCheckboxChangeFn="selectedColumnChanged"> | ||
<input type="checkbox" [checked]="row.selected" (change)="selectedColumnChanged( row )"/> | ||
</ng-template> | ||
</ngx-datatable-column> | ||
<ngx-datatable-column name="Name" | ||
[prop]="'name'" | ||
[sortable]="true" | ||
[checkboxable]="false" | ||
[canAutoResize]="true" | ||
[draggable]="false" | ||
[resizeable]="true"> | ||
</ngx-datatable-column> | ||
<ngx-datatable-column name="Type" | ||
[prop]="'type'" | ||
[sortable]="true" | ||
[checkboxable]="false" | ||
[canAutoResize]="true" | ||
[draggable]="false" | ||
[resizeable]="true"> | ||
</ngx-datatable-column> | ||
<ngx-datatable-column name="Size" | ||
[prop]="'size'" | ||
[sortable]="true" | ||
[checkboxable]="false" | ||
[canAutoResize]="true" | ||
[draggable]="false" | ||
[resizeable]="true"> | ||
</ngx-datatable-column> | ||
</ngx-datatable> | ||
</div> | ||
</div> | ||
</pfng-card> | ||
|
||
<!-- | ||
<pfng-info-status-card | ||
[config]="selectedTableConfig"> | ||
</pfng-info-status-card> | ||
--> | ||
|
||
<!-- | ||
<div class="col-sm-12 selected-table-card"> | ||
<span class="fa fa-plug"></span><span class="selected-table-connection">{{ table.getConnection().getId() }}</span> | ||
<span class="fa fa-close pull-right selected-table-close-icon" (click)="onRemove()"></span> | ||
<br> | ||
<span class="selected-table-name">{{ table.getName() }}</span> | ||
</div> | ||
--> |
Oops, something went wrong.