|
|
|
@ -59,39 +59,35 @@ |
|
|
|
<mat-progress-bar color="warn" mode="indeterminate" *ngIf="isLoading$ | async"> |
|
|
|
</mat-progress-bar> |
|
|
|
<div style="height: 4px;" *ngIf="!(isLoading$ | async)"></div> |
|
|
|
<mat-card-content> |
|
|
|
<section formGroupName="SLACK"> |
|
|
|
<mat-form-field class="mat-block"> |
|
|
|
<mat-label translate>admin.slack-api-token</mat-label> |
|
|
|
<input matInput formControlName="botToken"/> |
|
|
|
</mat-form-field> |
|
|
|
</section> |
|
|
|
<mat-card-content formGroupName="SLACK"> |
|
|
|
<mat-form-field class="mat-block" subscriptSizing="dynamic"> |
|
|
|
<mat-label translate>admin.slack-api-token</mat-label> |
|
|
|
<input matInput formControlName="botToken"/> |
|
|
|
</mat-form-field> |
|
|
|
</mat-card-content> |
|
|
|
<mat-card-header> |
|
|
|
<mat-card-header *ngIf="isSysAdmin()"> |
|
|
|
<mat-card-title> |
|
|
|
<span class="mat-headline-5" translate>admin.mobile-settings</span> |
|
|
|
</mat-card-title> |
|
|
|
<span fxFlex></span> |
|
|
|
<!-- <div tb-help="mobileSettings"></div>--> |
|
|
|
</mat-card-header> |
|
|
|
<mat-card-content> |
|
|
|
<section formGroupName="MOBILE_APP" style="margin-bottom: 16px;"> |
|
|
|
<tb-file-input formControlName="firebaseServiceAccountCredentials" |
|
|
|
dropLabel="{{ 'admin.select-firebase-service-account-file' | translate }}" |
|
|
|
label="{{ 'admin.firebase-service-account-file' | translate }}" |
|
|
|
accept=".json,application/json" |
|
|
|
allowedExtensions="json" |
|
|
|
[existingFileName]="notificationSettingsForm.get('deliveryMethodsConfigs.MOBILE_APP.firebaseServiceAccountCredentialsFileName')?.value" |
|
|
|
(fileNameChanged)="notificationSettingsForm?.get('deliveryMethodsConfigs.MOBILE_APP.firebaseServiceAccountCredentialsFileName').patchValue($event)"> |
|
|
|
</tb-file-input> |
|
|
|
</section> |
|
|
|
<div fxLayout="row" fxLayoutAlign="end center" fxLayout.xs="column" fxLayoutAlign.xs="end"> |
|
|
|
<button mat-button mat-raised-button color="primary" |
|
|
|
[disabled]="(isLoading$ | async) || notificationSettingsForm.invalid || !notificationSettingsForm.dirty" |
|
|
|
type="submit">{{'action.save' | translate}} |
|
|
|
</button> |
|
|
|
</div> |
|
|
|
<mat-card-content formGroupName="MOBILE_APP" *ngIf="isSysAdmin()"> |
|
|
|
<tb-file-input formControlName="firebaseServiceAccountCredentials" |
|
|
|
dropLabel="{{ 'admin.select-firebase-service-account-file' | translate }}" |
|
|
|
label="{{ 'admin.firebase-service-account-file' | translate }}" |
|
|
|
accept=".json,application/json" |
|
|
|
allowedExtensions="json" |
|
|
|
[existingFileName]="notificationSettingsForm.get('deliveryMethodsConfigs.MOBILE_APP.firebaseServiceAccountCredentialsFileName')?.value" |
|
|
|
(fileNameChanged)="notificationSettingsForm?.get('deliveryMethodsConfigs.MOBILE_APP.firebaseServiceAccountCredentialsFileName').patchValue($event)"> |
|
|
|
</tb-file-input> |
|
|
|
</mat-card-content> |
|
|
|
<mat-card-actions fxLayoutAlign="end center" fxLayout.xs="column" fxLayoutAlign.xs="end"> |
|
|
|
<button mat-button mat-raised-button color="primary" |
|
|
|
[disabled]="(isLoading$ | async) || notificationSettingsForm.invalid || !notificationSettingsForm.dirty" |
|
|
|
type="submit">{{'action.save' | translate}} |
|
|
|
</button> |
|
|
|
</mat-card-actions> |
|
|
|
</mat-card> |
|
|
|
</fieldset> |
|
|
|
</form> |
|
|
|
|