-
Notifications
You must be signed in to change notification settings - Fork 102
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2509 from sap-labs-france/master-qa
Merge master-qa
- Loading branch information
Showing
28 changed files
with
161 additions
and
54 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
24 changes: 24 additions & 0 deletions
24
...ges/settings-integration/asset/connection/lacroix/lacroix-asset-connection.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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<div class="row"> | ||
<!-- User --> | ||
<div class="col-md-6"> | ||
<div class="form-group"> | ||
<mat-form-field> | ||
<input appAutofocus matInput | ||
placeholder="{{'settings.asset.connection.user' | translate}}" | ||
type="text" [formControl]="user" required> | ||
<mat-error *ngIf="user.errors?.required">{{"general.mandatory_field" | translate}}</mat-error> | ||
</mat-form-field> | ||
</div> | ||
</div> | ||
<!-- Password --> | ||
<div class="col-md-6"> | ||
<div class="form-group"> | ||
<mat-form-field> | ||
<input matInput | ||
placeholder="{{'settings.asset.connection.password' | translate}}" | ||
type="password" [formControl]="password" required> | ||
<mat-error *ngIf="password.errors?.required">{{"general.mandatory_field" | translate}}</mat-error> | ||
</mat-form-field> | ||
</div> | ||
</div> | ||
</div> |
51 changes: 51 additions & 0 deletions
51
...pages/settings-integration/asset/connection/lacroix/lacroix-asset-connection.component.ts
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,51 @@ | ||
import { Component, Input, OnInit } from '@angular/core'; | ||
import { AbstractControl, FormControl, FormGroup, Validators } from '@angular/forms'; | ||
|
||
import { AssetLacroixConnectionType } from '../../../../../types/Setting'; | ||
|
||
@Component({ | ||
selector: 'app-settings-lacroix-connection', | ||
templateUrl: './lacroix-asset-connection.component.html' | ||
}) | ||
export class LacroixAssetConnectionComponent implements OnInit { | ||
@Input() public formGroup!: FormGroup; | ||
@Input() public lacroixConnection!: AssetLacroixConnectionType; | ||
|
||
public lacroixLoginForm!: FormGroup; | ||
public user!: AbstractControl; | ||
public password!: AbstractControl; | ||
|
||
public ngOnInit(): void { | ||
// Set login credentials form | ||
this.lacroixLoginForm = new FormGroup({ | ||
user: new FormControl('', | ||
Validators.compose([ | ||
Validators.required, | ||
])), | ||
password: new FormControl('', | ||
Validators.compose([ | ||
Validators.required, | ||
])), | ||
}); | ||
if (!this.formGroup.disabled) { | ||
this.formGroup.addControl('lacroixConnection', this.lacroixLoginForm); | ||
} else { | ||
this.lacroixLoginForm.disable(); | ||
} | ||
this.user = this.lacroixLoginForm.controls['user']; | ||
this.password = this.lacroixLoginForm.controls['password']; | ||
// Load existing credentials | ||
this.loadCredentials(); | ||
} | ||
|
||
public loadCredentials(): void { | ||
if (this.lacroixConnection) { | ||
if (this.lacroixConnection.user) { | ||
this.lacroixLoginForm.controls.user.setValue(this.lacroixConnection.user); | ||
} | ||
if (this.lacroixConnection.password) { | ||
this.lacroixLoginForm.controls.password.setValue(this.lacroixConnection.password); | ||
} | ||
} | ||
} | ||
} |
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
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
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
Submodule configs-aws
updated
from c643cc to d60f6b
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
Oops, something went wrong.