File tree Expand file tree Collapse file tree 3 files changed +6
-3
lines changed
Expand file tree Collapse file tree 3 files changed +6
-3
lines changed Original file line number Diff line number Diff line change 1414 < div class ="row mb-5 ">
1515 < div class ="form-group mt-3 col-12 ">
1616 < label class ="form-label " for ="name "> {{'USERS.FORM.NAME' | translate}}</ label > *
17- < input type ="text " class ="form-control " id ="name " name ="name "
17+ < input type ="text " class ="form-control " id ="name " name ="name " [disabled] =" isKombit "
1818 [placeholder] ="'USERS.FORM.NAME-PLACEHOLDER' | translate " maxlength ="50 " required
1919 [(ngModel)] ="user.name "
2020 [ngClass] ="{'is-invalid' : formFailedSubmit && errorFields.includes('name'), 'is-valid' : formFailedSubmit && !errorFields.includes('name')} ">
2323 < div class ="row mb-5 ">
2424 < div class ="form-group mt-3 col-12 ">
2525 < label class ="form-label " for ="email "> {{'USERS.FORM.EMAIL' | translate}}</ label > *
26- < input type ="text " class ="form-control " id ="email " name ="email "
26+ < input type ="text " class ="form-control " id ="email " name ="email " [disabled] =" isKombit "
2727 [placeholder] ="'USERS.FORM.EMAIL-PLACEHOLDER' | translate " maxlength ="50 " required
2828 [(ngModel)] ="user.email "
2929 [ngClass] ="{'is-invalid' : formFailedSubmit && errorFields.includes('email'), 'is-valid' : formFailedSubmit && !errorFields.includes('email')} ">
3333 < div class ="row mb-5 ">
3434 < div class ="form-group mt-3 col-12 ">
3535 < label class ="form-label " for ="password "> {{'USERS.FORM.PASSWORD' | translate}}</ label > *
36- < input type ="text " class ="form-control " id ="password " name ="password "
36+ < input type ="text " class ="form-control " id ="password " name ="password " [disabled] =" isKombit "
3737 [placeholder] ="'USERS.FORM.PASSWORD-PLACEHOLDER' | translate " minlength ="6 " maxlength ="50 " required
3838 [(ngModel)] ="user.password "
3939 [ngClass] ="{'is-invalid' : formFailedSubmit && errorFields.includes('password'), 'is-valid' : formFailedSubmit && !errorFields.includes('password')} ">
Original file line number Diff line number Diff line change @@ -29,6 +29,7 @@ export class UserEditComponent implements OnInit {
2929 id : number ;
3030 subscription : Subscription ;
3131 isGlobalAdmin = false ;
32+ isKombit : boolean ;
3233
3334 constructor (
3435 private translate : TranslateService ,
@@ -66,6 +67,7 @@ export class UserEditComponent implements OnInit {
6667 this . user . id = response . id ;
6768 this . user . active = response . active ;
6869 this . user . globalAdmin = response . permissions . some ( x => x . type == PermissionType . GlobalAdmin ) ;
70+ this . isKombit = response . nameId != null ;
6971 // We cannot set the password.
7072 } ) ;
7173 }
Original file line number Diff line number Diff line change @@ -14,6 +14,7 @@ export interface UserResponse {
1414 createdAt : string ;
1515 updatedAt : string ;
1616 name : string ;
17+ nameId : string ;
1718 email : string ;
1819 active : boolean ;
1920 lastLogin : Date ;
You can’t perform that action at this time.
0 commit comments