Skip to content
This repository was archived by the owner on May 14, 2025. It is now read-only.

Commit dd2eb84

Browse files
committed
Refactoring Apps Module, Manage versions
Resolves #602 Resolves #336
1 parent af54815 commit dd2eb84

File tree

68 files changed

+5356
-1235
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+5356
-1235
lines changed

ui/src/app/app.component.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,18 +41,18 @@
4141
</div>
4242
</div>
4343
</div>
44-
<div class='pane footer bg-dark-1'>
44+
<div class='pane footer' id="footer">
4545
<div class='container'>
4646
<div class='row'>
4747
<div class='col-sm-12'>
48-
<p id="copyright-notice" class='type-neutral-4 mtxl'>
48+
<p id="copyright-notice">
4949
© 2017&ndash;2018 <a target="_blank" href="https://pivotal.io/">Pivotal Software</a>, Inc.
5050
<br>
5151
All Rights Reserved.
5252
</p>
5353
</div>
5454
<div class='col-sm-4'>
55-
<h3 class='h4 type-neutral-11 em-alt mbs'>Project</h3>
55+
<h3 class='h4'>Project</h3>
5656
<ul class='list-unstyled'>
5757
<li>
5858
<a class='link-lowlight-alt' target="_blank" href='https://cloud.spring.io/spring-cloud-dataflow/'>Project Page</a>
@@ -63,7 +63,7 @@ <h3 class='h4 type-neutral-11 em-alt mbs'>Project</h3>
6363
</ul>
6464
</div>
6565
<div class='col-sm-4'>
66-
<h3 class='h4 type-neutral-11 em-alt mbs'>Documentation</h3>
66+
<h3 class='h4'>Documentation</h3>
6767
<ul class='list-unstyled'>
6868
<li *ngIf="dataflowVersionInfo$ | async as aboutInfo">
6969
<a class='link-lowlight-alt' target="_blank" href='https://docs.spring.io/spring-cloud-dataflow/docs/{{aboutInfo.versionInfo.core.version}}/reference/htmlsingle/'>Docs</a>
@@ -77,9 +77,9 @@ <h3 class='h4 type-neutral-11 em-alt mbs'>Documentation</h3>
7777
</ul>
7878
</div>
7979
<div class='col-sm-5 col-md-4'>
80-
<h3 class='h4 type-neutral-11 em-alt mbs'>Need Help?</h3>
80+
<h3 class='h4'>Need Help?</h3>
8181
<ul class='list-unstyled'>
82-
<li class='type-neutral-11'>
82+
<li>
8383
For questions + support:
8484
<a class='link-lowlight-alt' target="_blank" href='https://stackoverflow.com/questions/tagged/spring-cloud-dataflow'>Stackoverflow</a>
8585
</li>
Lines changed: 96 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,104 @@
1-
<h1>Application Details</h1>
1+
<div *ngIf="application" id="app-details">
22

3-
<table class="table table-striped table-hover table-fixed" *ngIf="detailedAppRegistration">
4-
<tbody>
5-
<tr>
6-
<th>
7-
Name
8-
</th>
9-
<td>
10-
{{detailedAppRegistration.name}}
11-
</td>
12-
</tr>
13-
<tr>
14-
<th>
15-
Type
16-
</th>
17-
<td>
18-
{{detailedAppRegistration.type}}
19-
</td>
20-
</tr>
21-
<tr>
22-
<th>
23-
Uri
24-
</th>
25-
<td>
26-
{{detailedAppRegistration.uri}}
27-
</td>
28-
</tr>
29-
</tbody>
30-
</table>
3+
<div class="heading">
4+
<h1>
5+
Application <strong>{{application.name}}</strong>
6+
<span style="position: relative">
7+
<span style="position: absolute;top:0;left:10px;white-space: nowrap;">
8+
<app-type [application]="application"></app-type>
9+
<app-version-label [forceSimple]="true" *ngIf="skipperEnabled && defaultVersion"
10+
[application]="application"></app-version-label>
11+
</span>
12+
</span>
13+
</h1>
14+
</div>
15+
16+
<hr/>
3117

32-
<div class="row" *ngIf="!detailedAppRegistration">
33-
<div class="col-md-12">
34-
No information available.
18+
<div id="no-default-version" *ngIf="skipperEnabled && application.versions.length > 0 && !defaultVersion">
19+
<div>
20+
<div class="alert alert-danger" style="display: inline-block;padding:1rem 2rem;">
21+
<strong>Application unavailable.</strong><br>
22+
You have to set a default version for this application.
23+
<div style="padding-top:1rem;">
24+
<a (click)="versions(application)" class="btn btn-danger">Manage versions</a>
25+
</div>
26+
</div>
27+
</div>
3528
</div>
36-
</div>
3729

38-
<h2 *ngIf="detailedAppRegistration">Application Properties</h2>
30+
<div *ngIf="detailedAppRegistration">
31+
<div *ngIf="skipperEnabled && application.versions.length > 1" style="padding: 1rem 0;">
32+
<div id="version-dropdown" class="dropdown" dropdown>
33+
<button dropdownToggle type="button" class="btn btn-dropdown btn-primary">
34+
Version: {{ versionSelect }}
35+
<span *ngIf="versionSelect == defaultVersion?.version">
36+
<span placement="bottom" tooltip="Default version"
37+
class="ico-current-version glyphicon glyphicon-star"></span>
38+
</span>
39+
<span class="caret"></span>
40+
</button>
41+
<ul *dropdownMenu class="dropdown-menu">
42+
<li *ngFor="let version of application.versions" [class.active]="versionSelect == version.version">
43+
<a style="cursor: pointer" (click)="selectVersion(version.version)">
44+
{{ version.version }}
45+
<span *ngIf="version.defaultVersion">
46+
<span placement="bottom" tooltip="Default version"
47+
class="ico-current-version glyphicon glyphicon-star"></span>
48+
</span>
49+
</a>
50+
</li>
51+
</ul>
52+
</div>
53+
</div>
54+
<div style="padding: 0.5rem 0 1.5rem;">
55+
<div><strong>Uri</strong>: <code>{{ detailedAppRegistration.uri }}</code></div>
56+
<div *ngIf="skipperEnabled && application.versions.length == 1">
57+
<strong>Version</strong>: {{ detailedAppRegistration.version }}
58+
</div>
59+
</div>
60+
<div *ngIf="detailedAppRegistration?.options && detailedAppRegistration?.options.length > 0">
61+
<table id="table-properties" class="table table-hover" *ngIf="detailedAppRegistration?.options">
62+
<thead>
63+
<tr>
64+
<th>
65+
<app-sort id="sort-name" [indeterminate]="true" (change)="applySort($event)" [value]="'name'" [sort]="sort">
66+
Property
67+
</app-sort>
68+
</th>
69+
<th>Description</th>
70+
</tr>
71+
</thead>
72+
<tbody>
73+
<tr *ngFor="let property of detailedAppRegistration.options | orderby:sort.sort:sort.order">
74+
<td>
75+
<strong>{{property.name}}</strong>
76+
<div *ngIf="property.isDeprecated">
77+
<span class="label label-warning">Deprecation level: {{property.deprecation.level}}</span>
78+
</div>
79+
</td>
80+
<td>
81+
<p>{{property.description ? property.description : '(No Description Available)'}}</p>
82+
<p class="type-block"><code>{{property.type}}</code> <span
83+
*ngIf="property.defaultValue">(Default value: <code>{{property.defaultValue}}</code>)</span></p>
84+
</td>
85+
</tr>
86+
</tbody>
87+
</table>
88+
</div>
89+
<div *ngIf="!(detailedAppRegistration?.options && detailedAppRegistration?.options.length > 0)">
90+
<div class="alert alert-warning" style="display: inline-block;margin-top: 5px;">
91+
No properties available.
92+
</div>
93+
</div>
94+
</div>
3995

40-
<table class="table table-striped table-hover table-fixed" *ngIf="detailedAppRegistration?.options">
41-
<tbody>
42-
<tr *ngFor="let property of detailedAppRegistration.options">
43-
<th>
44-
{{property.name}} <span *ngIf="property.isDeprecated" class="label label-warning">Deprecation level: {{property.deprecation.level}}</span>
45-
</th>
46-
<td>
47-
<p>{{property.description ? property.description : '(No Description Available)'}}</p>
48-
<p class="type-block"><code>{{property.type}}</code> <span *ngIf="property.defaultValue">(Default value: <code>{{property.defaultValue}}</code>)</span></p>
49-
</td>
50-
</tr>
51-
</tbody>
52-
</table>
96+
<hr/>
5397

54-
<div class="row" *ngIf="detailedAppRegistration && detailedAppRegistration.options && detailedAppRegistration?.options.length === 0">No properties available.</div>
98+
<div class="footer-actions">
99+
<button id="back-button" type="button" class="btn btn-default" (click)="cancel()">
100+
Cancel
101+
</button>
102+
</div>
55103

56-
<div class="row">
57-
<div class="col-md-12 text-right"><button id="back-button"
58-
type="button" class="btn btn-default" (click)="goBack()"><span class="glyphicon glyphicon-arrow-left" aria-hidden="true"></span>Back</button></div>
59104
</div>

0 commit comments

Comments
 (0)