From 490069c5f96ad4a5f8ae64e2f2bff8e9c9d5fdf0 Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 21 Jul 2010 13:03:58 +0000 Subject: [PATCH] Updated template adaption -DateOfBirth wasn't adapted correctly, even when it doesn't makes sense to adapt the dob. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@19038 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-core/plugins/personal/generic/class_user.inc | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gosa-core/plugins/personal/generic/class_user.inc b/gosa-core/plugins/personal/generic/class_user.inc index 9d8cae186..f66b36acb 100644 --- a/gosa-core/plugins/personal/generic/class_user.inc +++ b/gosa-core/plugins/personal/generic/class_user.inc @@ -1551,12 +1551,15 @@ class user extends plugin $this->givenName= $this->parent->givenName; } - if ($this->dateOfBirth) { + /* Generate dateOfBirth entry */ + if (isset ($this->attrs['dateOfBirth'])){ /* This entry is ISO 8601 conform */ - list($year, $month, $day)= explode("-", $this->dateOfBirth, 3); + list($year, $month, $day)= explode("-", $this->attrs['dateOfBirth'][0], 3); #TODO: use $lang to convert date $this->dateOfBirth= "$day.$month.$year"; + } else { + $this->dateOfBirth= ""; } } -- 2.30.2