c061149390f8f5ac06851c852a9526a51a58a6b1
[portal/sdk.git] /
1 <!--
2   ============LICENSE_START==========================================
3   ONAP Portal SDK
4   ===================================================================
5   Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
6   ===================================================================
7  
8   Unless otherwise specified, all software contained herein is licensed
9   under the Apache License, Version 2.0 (the "License");
10   you may not use this software except in compliance with the License.
11   You may obtain a copy of the License at
12  
13               http://www.apache.org/licenses/LICENSE-2.0
14  
15   Unless required by applicable law or agreed to in writing, software
16   distributed under the License is distributed on an "AS IS" BASIS,
17   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18   See the License for the specific language governing permissions and
19   limitations under the License.
20  
21   Unless otherwise specified, all documentation contained herein is licensed
22   under the Creative Commons License, Attribution 4.0 Intl. (the "License");
23   you may not use this documentation except in compliance with the License.
24   You may obtain a copy of the License at
25  
26               https://creativecommons.org/licenses/by/4.0/
27  
28   Unless required by applicable law or agreed to in writing, documentation
29   distributed under the License is distributed on an "AS IS" BASIS,
30   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
31   See the License for the specific language governing permissions and
32   limitations under the License.
33  
34   ============LICENSE_END============================================
35    
36   -->
37 <div class="container">
38         <div id="page-content">
39                 <h1 class="heading-page" id="profileSearch">Self Profile Detail</h1>
40                 <h3 class="heading-small" *ngIf="isAppCentralized=='true'" style="color:red;">Please use Portal for access
41                         management</h3>
42                 <h3 class="heading-small" *ngIf="isAppCentralized=='false'">Please edit the profile details below:</h3>
43                 <br>
44                 <div class="input-group-first">
45                         <div class="form-row">
46                                 <label for="textinputID-2a">*Last Name</label><br>
47                                 <input [(ngModel)]="profile.lastName" type="text" name="lastName" class="form-control" id="lastName"
48                                         style="width: 100%;" [disabled]="isAppCentralized =='true'">
49                                 <div *ngIf="!profile.lastName||profile.lastName.length==0">
50                                         Last name is Required
51                                 </div>
52                         </div>
53                         <div class="form-row">
54                                 <label for="textinputID-3a">*First Name</label>
55                                 <input [(ngModel)]="profile.firstName" type="text" name="firstName" class="form-control" id="firstName"
56                                         style="width: 100%;">
57                                 <div *ngIf="!profile.lastName||profile.lastName.length==0">
58                                         First name is Required
59                                 </div>
60                         </div>
61                         <div class="form-row">
62                                 <label for="textinputID-3a">Organization User ID</label>&nbsp;
63
64                                 <input [(ngModel)]="profile.orgUserId" type="text" name="orgUserId" class="form-control" id="orgUserId"
65                                         style="width: 100%;" disabled="true">
66                         </div>
67                         <div class="form-row">
68                                 <label for="textinputID-3a">Organization Manager ID</label>
69                                 &nbsp;
70
71                                 <input [(ngModel)]="profile.orgManagerUserId" type="text" name="orgManagerUserId" class="form-control"
72                                         id="orgManagerUserId" style="
73                                                 width: 59%;" disabled="true">
74                         </div>
75                 </div>
76                 <br>
77                 <div class="input-group">
78
79                         <div class="form-row">
80                                 <label for="textinputID-2a">Login Id
81                                 </label>
82                                 <input [(ngModel)]="profile.loginId" type="text" name="loginId" class="form-control" id="loginId" style="
83                                                 width: 100%;">
84
85
86                         </div>
87
88                         <div class="form-row">
89                                 <label for="textinputID-3a">Password</label>
90                                 <input [(ngModel)]="profile.loginPwd" type="text" name="loginPwd" class="form-control" id="loginPwd" style="
91                                                 width: 100%;">
92
93
94                         </div>
95
96                         <div class="form-row">
97                                 <label for="textinputID-3a">*Phone
98                                 </label>
99                                 <input [(ngModel)]="profile.phone" type="text" name="phone" class="form-control" id="phone" style="
100                                                 width: 100%;">
101                         </div>
102
103
104                         <div class="form-row">
105                                 <label for="textinputID-3a">Fax</label>
106                                 <input [(ngModel)]="profile.fax" type="text" name="fax" class="form-control" id="fax" style="width: 100%;">
107                         </div>
108
109                 </div>
110
111                 <br>
112                 <div class="input-group">
113
114                         <div class="form-row">
115                                 <label for="textinputID-2a">Cellular</label>
116                                 <input [(ngModel)]="profile.cellular" type="text" name="cellular" class="form-control" id="cellular"
117                                         style="width: 100%;">
118                         </div>
119
120                         <div class="form-row">
121                                 <label for="textinputID-3a">*Email</label>
122                                 <input [(ngModel)]="profile.email" type="text" name="email" class="form-control" id="email"
123                                         style="width: 100%;">
124                         </div>
125                         <div class="form-row">
126                                 <label for="textinputID-3a">Address 1</label>
127                                 <input [(ngModel)]="profile.address1" type="text" name="address1" class="form-control" id="address1"
128                                         style="width: 100%;">
129                         </div>
130
131                         <div class="form-row">
132                                 <label for="textinputID-3a">Address 2</label>
133                                 <input [(ngModel)]="profile.address2" type="text" name="address2" class="form-control" id="address2"
134                                         style="width: 100%;">
135                         </div>
136
137                 </div>
138
139                 <br>
140                 <div class="input-group">
141
142                         <div class="form-row">
143                                 <label for="textinputID-2a">City</label>
144                                 <input [(ngModel)]="profile.city" type="text" name="city" class="form-control" id="city"
145                                         style="width: 100%;">
146                         </div>
147
148                         <div class="form-row">
149                                 <mat-form-field>
150                                         <mat-label> States</mat-label>
151                                         <mat-select [(ngModel)]="profile.state">
152                                                 <mat-option *ngFor="let state of stateList" [value]="state.value">{{state.label}}</mat-option>
153                                         </mat-select>
154                                 </mat-form-field>
155                         </div>
156
157                         <div class="form-row">
158                                 <label for="textinputID-3a">Zip Code</label>
159                                 <input [(ngModel)]="profile.zipCode" type="text" name="zipCode" class="form-control" id="zipCode"
160                                         style="width: 100%;">
161                         </div>
162
163                         <div class="form-row">
164                                 <mat-form-field>
165                                         <mat-label> Country</mat-label>
166                                         <mat-select [(ngModel)]="profile.country">
167                                                 <mat-option *ngFor="let country of ociCountries" [value]="country.value">{{country.label}}
168                                                 </mat-option>
169                                         </mat-select>
170                                 </mat-form-field>
171                         </div>
172                 </div>
173                 <br>
174                 <div class="input-group">
175                         <div class="form-row">
176                                 <mat-form-field>
177                                         <mat-label> TimeZones</mat-label>
178                                         <mat-select [(ngModel)]="profile.timeZoneId">
179                                                 <mat-option *ngFor="let timeZone of ociTimeZones" [value]="timeZone.value">{{timeZone.label}}
180                                                 </mat-option>
181                                         </mat-select>
182                                 </mat-form-field>
183                         </div>
184                 </div>
185                 <div class="form-row">
186                         <button class="btn btn-primary" (click)="saveProfile()" *ngIf="(isAppCentralized=='false')" [disabled]="(!profile.lastName||profile.lastName.length==0) || (!profile.firstName||profile.firstName.length==0) ||
187                                 (!profile.phone||profile.phone.length==0) || (!profile.email||profile.email.length==0)">Save</button>
188                 </div>
189                 <br>
190
191                 <div class="assignedRoles" *ngIf="(isAppCentralized=='false' && isUserSystemAdmin)">
192                         <label>Roles</label> 
193                         <!--<a (click)="addNewRoleFunctionModalPopup(profile.roles);"
194                                 class="ion ion-md-add-circle-outline"></a>-->
195                 </div>
196
197
198                 <table mat-table [dataSource]="dataSource" matSort>
199                         <ng-container matColumnDef="name">
200                                 <th mat-header-cell *matHeaderCellDef id="heading1"> Name</th>
201                                 <td mat-cell *matCellDef="let rowData"> {{rowData.name}} </td>
202                         </ng-container>
203
204                         <!--<ng-container matColumnDef="delete">
205                                 <th mat-header-cell *matHeaderCellDef id="heading2"> Delete</th>
206                                 <td id="rowheader_t1_{{i}}" mat-cell *matCellDef="let rowData; let i=index;">
207                                         <span class="icon-trash" id="{{i}}-button-role-remove" (click)="removeRole(rowData)">
208                                                 <i class="icon ion-md-trash"></i>
209                                         </span>
210                                 </td>
211                         </ng-container>-->
212                         
213                         <!-- Active Column -->
214                         <ng-container matColumnDef="active">
215                         <th id="col3" mat-header-cell *matHeaderCellDef>Active ?</th>
216                         <td id="rowheader_t1_{{i}}-userId" mat-cell *matCellDef="let element; let i=index;">
217                                 <mat-slide-toggle [(ngModel)]="element.selected" (change)="toggleRoles(element)"></mat-slide-toggle>
218                         </td>
219                         </ng-container>
220
221                         <tr mat-header-row *matHeaderRowDef="userRolesHeader"></tr>
222                         <tr mat-row *matRowDef="let rowData; columns: userRolesHeader;">
223
224                 </table>
225                 <span class="ecomp-spinner" *ngIf="showSpinner"></span> 
226         </div>
227 </div>