Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ <h2 fxLayout="row" fxLayoutAlign="start center" fxLayoutGap="10px">
<mat-form-field appearance="fill" fxFlex="48" fxFlex.xs="100">
<mat-label>Fecha receta</mat-label>
<input matInput [matDatepicker]="picker1" [formControl]="date"
[min]="minDate" [max]="maxDate"
autocomplete="off" required tabIndex="-1" readonly="true">
<mat-datepicker-toggle matSuffix [for]="picker1"></mat-datepicker-toggle>
<mat-datepicker [startAt]="today" #picker1></mat-datepicker>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@ export class ProfessionalFormComponent implements OnInit, OnDestroy, AfterViewIn
readonly maxQSupplies: number = 10;
readonly spinnerColor: ThemePalette = 'primary';
readonly spinnerDiameter: number = 30;
minDate = new Date('1900-01-01');
maxDate = new Date();
minDate = new Date();
maxDate = new Date(new Date().setMonth(new Date().getMonth() + 1));
isSubmit = false;
dniShowSpinner = false;
supplySpinner: { show: boolean }[] = [{ show: false }, { show: false }];
Expand Down Expand Up @@ -272,6 +272,8 @@ export class ProfessionalFormComponent implements OnInit, OnDestroy, AfterViewIn

initProfessionalForm() {
this.today = new Date((new Date()));
this.minDate = new Date();
this.maxDate = new Date(new Date().setMonth(new Date().getMonth() + 1));
this.professionalData = this.authService.getLoggedUserId();

// Obtener el ámbito actual del servicio
Expand Down