[vue] Fix birthdate with wrong date in winter (UNCHECKED)

This commit is contained in:
Mathieu Jaumotte 2023-05-25 09:33:11 +02:00
parent fec2dd0f74
commit 9c85ad74ce

View File

@ -261,9 +261,9 @@ export default {
return this.person.gender === 'woman' ? 'person.gender.woman' : this.person.gender === 'man' ? 'person.gender.man' : this.person.gender === 'neuter' ? 'person.gender.neuter' : 'person.gender.undefined';
},
birthdate: function () {
console.log('debug birthdate', this.person.birthdate.datetime, ISOToDate(this.person.birthdate.datetime), new Date(this.person.birthdate.datetime));
console.log('debug birthdate', this.person.birthdate.datetime, ISOToDate(this.person.birthdate.datetime), new Date(this.person.birthdate.datetime));
if (this.person.birthdate !== null || this.person.birthdate === "undefined") {
return new Date(this.person.birthdate.datetime);
return ISOToDate(this.person.birthdate.datetime);
} else {
return "";
}