summaryrefslogtreecommitdiffstats
path: root/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/columns/column-list/column-list.component.html
blob: 4a8f26952a80096acd1d288fcac40ab1c149c032 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
<app-save-sql-changes-dialog-component [(visible)]="showSaveColDialog">

    <div class="card">
        <div class="card-body" style="height: 200px;">
            <div class="modalTitle">{{EditColstatus}}</div>
            <button (click)="close()" *ngIf="SQLclosable" aria-label="Close" class="dialog__close-btn">X</button>
            <br/>
            <label>{{EditColmessage}}</label>
        </div>
        <div class="card-footer" style="width: 500px;">
            <button (click)="close()" class="btn btn-alt btn-small">Close</button>
        </div>
    </div>
</app-save-sql-changes-dialog-component>


<app-columns-edit-component [(visible)]="showDialog">
    <div class="card">
        <div class="card-header">
            <div class="modalTitle">{{message}}</div>
            <button (click)="close()" *ngIf="closable" aria-label="Close" class="dialog__close-btn">X</button>
            <br/>
        </div>
        <div class="card-body" style="width: 1000px; height: 532px; ">
            <div style="height:500px; overflow: scroll; overflow-x: hidden;">
                <div class="tab-pane">
                    <app-edit-drill-down-link (completed)="onCompleted($event)" *ngIf="showEditDrillDownPage"
                                              [drillDownObj]="drillDownObj" [reportId]="reportId">

                    </app-edit-drill-down-link>
                    <app-column-advanced-display (completed)="finishAdvancedDisplay($event)"
                                                 *ngIf="showAdvancedDisplayPage"
                                                 [addNew]="addDisplay"
                                                 [columnList]="columnList"
                                                 [columnName]="finalEditRowGetObj.colId"
                                                 [inputSemaphoreName]="semaphoreName"
                                                 [semaphoreArr]="semaphoreList">

                    </app-column-advanced-display>
                    <div *ngIf="!showEditDrillDownPage && !showAdvancedDisplayPage">
                        <div class="field-group">
                            <label class="defaultFontSize1">Column ID:</label><label
                            class="boxMargin defaultFontSize">{{finalEditRowGetObj.colId}}</label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Column Name:</label><label
                            class="boxMargin defaultFontSize">{{finalEditRowGetObj.colName}}</label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Depends on formfield:</label><label><input
                            [(ngModel)]="dependsOnFormFields" class=" defaultFontSize" id="depeondsOnForField"
                            type="text"
                            value="{{finalEditRowGetObj.depeondsOnForField}}"/></label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1" for="dataType">Data Type:</label>
                            <select [(ngModel)]="dataType" class="browser-default custom-select"
                                    placeholder="Select Report Type" required="required"
                                    value="{{finalEditRowGetObj.dataType}}">
                                <option class="defaultFontSize1" selected>Select Data Type</option>
                                <option class="defaultFontSize1" value="Number">Number</option>
                                <option class="defaultFontSize1" value="Date">Date</option>
                                <option class="defaultFontSize1" value="Character">Character</option>
                                <option class="defaultFontSize1" value="Hyperlink">Hyperlink</option>
                            </select>
                        </div>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Group By Pos:</label><label><input [(ngModel)]="groupByPos"
                                                                                               class="defaultFontSize"
                                                                                               id="groupByPos"
                                                                                               type="text"
                                                                                               value="{{finalEditRowGetObj.groupByPos}}"/></label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Custom Text for Sub-Total:</label><label><input
                            [(ngModel)]="customTextForSubTotal" class="defaultFontSize" id="subTotalCustomText"
                            type="text"
                            value="{{finalEditRowGetObj.subTotalCustomText}}"/></label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Hide Repeated Values:</label>
                            <label class="defaultFontSize1" class="checkbox" for="hideFormFieldsAfterRun">
                                <input [(ngModel)]="hideRepeatedValues" class="ng-valid ng-dirty ng-valid-parse ng-touched"
                                       id="hideFormFieldsAfterRun"
                                       type="checkbox"
                                       value="{{finalEditRowGetObj.hideRepeatedKey}}"><i class="skin"></i><span></span>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Multi Group Column Level:</label>
                            <label><select [(ngModel)]="multiGroupColumnLevel" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Report Type" required="required"
                                           value="{{finalEditRowGetObj.multiGroupColumnLevel}}">
                                <option class="defaultFontSize1" selected>Select Level</option>
                                <option class="defaultFontSize1" value="1">1</option>
                                <option class="defaultFontSize1" value="2">2</option>
                                <option class="defaultFontSize1" value="3">3</option>
                                <option class="defaultFontSize1" value="4">4</option>
                            </select>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Multi group Column Range : Colspan:</label><label><input
                            [(ngModel)]="colspan" class="defaultFontSize" id="colspan" type="text"
                            value="{{finalEditRowGetObj.colspan}}"/></label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="displayName">Display Name:</label><label><input [(ngModel)]="displayName"
                                                                                          class="defaultFontSize" id="displayName"
                                                                                          type="text"
                                                                                          value="{{finalEditRowGetObj.displayName}}"/></label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Display Width (In Pxls):</label><label><input
                            [(ngModel)]="displayWidthInPixel" class="defaultFontSize" id="displayWidthInPixel"
                            type="text"
                            value="{{finalEditRowGetObj.displayWidthInPixel}}"/></label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">No Wrap ?:</label>
                            <label class="defaultFontSize" class="checkbox" for="noWrap">
                                <input [(ngModel)]="noWrap" class="ng-valid ng-dirty ng-valid-parse ng-touched" id="noWrap"
                                       type="checkbox" value="{{finalEditRowGetObj.noWrap}}"><i
                                class="skin"></i><span></span>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Indent Parameter to display value:</label>
                            <label><select [(ngModel)]="indentation" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Indent" required="required"
                                           value="{{finalEditRowGetObj.indentation}}">
                                <option class="defaultFontSize" selected>Select Indent</option>
                                <option class="defaultFontSize" value="1">1</option>
                                <option class="defaultFontSize" value="2">2</option>
                                <option class="defaultFontSize" value="3">3</option>
                            </select>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Display Alignment:</label>
                            <label><select [(ngModel)]="displayAlignment" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Report Type" required="required"
                                           value="{{finalEditRowGetObj.displayAlignment}}">
                                <option class="defaultFontSize" selected>Select Alignment</option>
                                <option value="Left">Left</option>
                                <option class="defaultFontSize" value="Center">Center</option>
                                <option class="defaultFontSize" value="Right">Right</option>
                            </select>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Display Header Alignment:</label>
                            <label><select [(ngModel)]="displayHeaderAlignment" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Report Type" required="required"
                                           value="{{finalEditRowGetObj.displayHeaderAlignment}}">
                                <option selected>Select Header Alignment</option>
                                <option value="Left">Left</option>
                                <option value="Center">Center</option>
                                <option value="Right">Right</option>
                            </select>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Sortable:</label>
                            <label class="defaultFontSize" class="checkbox" for="sortable">
                                <input [(ngModel)]="sortable" class="ng-valid ng-dirty ng-valid-parse ng-touched" id="sortable"
                                       type="checkbox" value="{{finalEditRowGetObj.sortable}}"><i
                                class="skin"></i><span></span>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Visible:</label>
                            <label class="defaultFontSize" class="checkbox" for="visible">
                                <input [(ngModel)]="visible" class="ng-valid ng-dirty ng-valid-parse ng-touched" id="visible"
                                       type="checkbox" value="true"><i class="skin"></i><span></span>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Drill-down Link:
                                <mat-icon (click)="drillDownLinkPage()" aria-hidden="false" aria-label="edit">edit
                                </mat-icon>
                            </label>
                            <label><select [(ngModel)]="drilldownURL" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Report Type" required="required"
                                           value="{{finalEditRowGetObj.drilldownURL}}">
                                <option class="defaultFontSize" selected value="">Select Drill Down Link</option>
                                <option *ngFor="let URLObj of URLListObjArray" class="defaultFontSize"
                                        value="{{URLObj.id}}">{{URLObj.id}}|{{URLObj.name}}</option>
                            </select>
                            </label>
                        </div>
                        <div>
                            <label class="defaultFontSize1">Advanced Display
                                <mat-icon (click)="editDisplay()" *ngIf="semaphoreName !== 'No Display'" aria-hidden="false"
                                          aria-label="edit">edit
                                </mat-icon>
                                <mat-icon (click)="addNewDisplay()" aria-hidden="false" aria-label="add">add</mat-icon>
                            </label>
                            <label><select [(ngModel)]="semaphoreName" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Report Type" required="required"
                                           value="{{semaphoreName}}">
                                <option class="defaultFontSize" selected>No Display</option>
                                <option *ngFor="let sem of semaphoreList.semaphore" class="defaultFontSize"
                                        value="{{sem.semaphoreName}}">{{sem.semaphoreName}}</option>
                            </select>
                            </label>
                        </div>
                        <br/>
                        <br/>
                        <div>
                            <label class="defaultFontSize1">Total for the column:</label>
                            <label><select [(ngModel)]="displayTotal" class="browser-default custom-select defaultFontSize"
                                           placeholder="Select Report Type" required="required"
                                           value="{{finalEditRowGetObj.displayTotal}}">
                                <option selected value="">Select Total</option>
                                <option *ngFor="let TotalListObj of TotalColListObjArray"
                                        value="{{TotalListObj.id}}">{{TotalListObj.name}}</option>
                            </select>
                            </label>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="card-footer" style="width: 1000px; padding-left: 770px;">
            <button (click)="save();" *ngIf="!showConfirmButton && !showAdvancedDisplayPage"
                    class="btn btn-alt btn-small">Save
            </button>&nbsp;
            <button (click)="complete();" *ngIf="showConfirmButton && !showAdvancedDisplayPage"
                    class="btn btn-alt btn-small">Confirm
            </button>&nbsp;&nbsp;
            <button (click)="close()" class="btn btn-alt btn-small">Cancel</button>
        </div>
    </div>
</app-columns-edit-component>

<span *ngIf="showSpinner" class="ecomp-spinner"></span>

<div class="app-data-table">

    <table aria-label="Elements" class="full-width-table app-data-table" mat-table matSort>
        <!-- Id Column -->
        <ng-container matColumnDef="id">
            <th *matHeaderCellDef class="defaultFontSize" mat-header-cell mat-sort-header>ID</th>
            <td *matCellDef="let row" mat-cell>{{row.id}}</td>
        </ng-container>

        <!-- No Column -->
        <ng-container matColumnDef="no">
            <th *matHeaderCellDef class="defaultFontSize" mat-header-cell mat-sort-header>NO</th>
            <td *matCellDef="let row" mat-cell>{{row.no}}</td>
        </ng-container>

        <!-- Name Column -->
        <ng-container matColumnDef="name">
            <th *matHeaderCellDef class="defaultFontSize" mat-header-cell mat-sort-header>NAME</th>
            <td *matCellDef="let row" mat-cell>{{row.name}}</td>
        </ng-container>

        <!-- Name Column -->
        <ng-container matColumnDef="edit">
            <th *matHeaderCellDef class="defaultFontSize" mat-header-cell mat-sort-header>EDIT</th>
            <td *matCellDef="let row" mat-cell>
                <mat-icon (click)="editRecord(row.id)" aria-hidden="false" aria-label="edit">edit</mat-icon>
            </td>

        </ng-container>

        <tr *matHeaderRowDef="displayedColumns" mat-header-row></tr>
        <tr *matRowDef="let row; columns: displayedColumns;" mat-row></tr>
    </table>

    <mat-paginator #paginator
                   [length]="dataSource?.data.length"
                   [pageIndex]="0"
                   [pageSizeOptions]="[25, 50, 100, 250]"
                   [pageSize]="25">
    </mat-paginator>
</div>