From 528c0fc78ebafc7b44a6400a74af76cfde80474b Mon Sep 17 00:00:00 2001 From: cajus Date: Fri, 5 Feb 2010 14:18:37 +0000 Subject: [PATCH] Correct dob if forked from template git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@15598 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-core/plugins/personal/generic/class_user.inc | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gosa-core/plugins/personal/generic/class_user.inc b/gosa-core/plugins/personal/generic/class_user.inc index d38f46ee2..8214ef77c 100644 --- a/gosa-core/plugins/personal/generic/class_user.inc +++ b/gosa-core/plugins/personal/generic/class_user.inc @@ -1485,6 +1485,14 @@ class user extends plugin $this->sn= $this->parent->sn; $this->givenName= $this->parent->givenName; } + + if ($this->dateOfBirth) { + /* This entry is ISO 8601 conform */ + list($year, $month, $day)= explode("-", $this->dateOfBirth, 3); + + #TODO: use $lang to convert date + $this->dateOfBirth= "$day.$month.$year"; + } } -- 2.30.2