mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
[DURACOM-194] fixed year input value on input type date
(cherry picked from commit c412c1fa13
)
This commit is contained in:

committed by
github-actions[bot]
![github-actions[bot]](/assets/img/avatar_default.png)
parent
e54723aa85
commit
c99487babc
@@ -89,9 +89,8 @@ export class DsDatePickerComponent extends DynamicFormControlComponent implement
|
||||
}
|
||||
}
|
||||
|
||||
this.maxYear = this.initialYear + 100;
|
||||
|
||||
}
|
||||
this.maxYear = now.getUTCFullYear() + 100;
|
||||
}
|
||||
|
||||
onBlur(event) {
|
||||
this.blur.emit();
|
||||
|
@@ -103,13 +103,12 @@ export class NumberPickerComponent implements OnInit, ControlValueAccessor {
|
||||
|
||||
if (i >= this.min && i <= this.max) {
|
||||
this.value = i;
|
||||
this.emitChange();
|
||||
} else if (event.target.value === null || event.target.value === '') {
|
||||
this.value = null;
|
||||
this.emitChange();
|
||||
} else {
|
||||
this.value = undefined;
|
||||
}
|
||||
this.emitChange();
|
||||
} catch (e) {
|
||||
this.value = undefined;
|
||||
}
|
||||
|
Reference in New Issue
Block a user