Files
MireaFrontend/src/components/admin/schedule-file-upload/schedule-file-upload.component.html
Polianin Nikita 004671c006
All checks were successful
Build and Deploy Angular App / build (push) Successful in 43s
feat: add support for the new api
2025-02-03 03:37:30 +03:00

37 lines
1.1 KiB
HTML

<app-configuration-card
[title]="'Загрузка расписания Excel'"
[isSaveEnabled]="selectedFiles.length > 0"
[saveFunction]="saveFunction()"
(onSaveFunction)="onUpload($event)">
<input type="file" #fileInput (change)="onFileSelected($event)" multiple accept=".xlsx, .xls" style="display: none;">
@if (fileLoading) {
<app-data-spinner/>
} @else {
<button mat-raised-button color="primary" (click)="onFileChooseClick()">
Выберите файлы
<mat-icon>attach_file</mat-icon>
</button>
}
@if (selectedFiles.length > 0) {
<div style="margin-top: 15px;">
<p>Выбранные файлы:</p>
@for (item of selectedFiles; track $index) {
<div>
<p>
{{ item.file.name }}
</p>
<mat-form-field color="accent">
<mat-label>
Кампус по умолчанию
</mat-label>
<input matInput type="text" [(ngModel)]="item.campus"/>
</mat-form-field>
</div>
}
</div>
}
</app-configuration-card>