From 4a8caa3efb1c16c49873e70af3bf0d03f2947cbb Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Tue, 26 Apr 2011 14:01:47 +0200 Subject: [PATCH] Fixes date storage for next reminder (Closes #1475). MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- ChangeLog | 3 +++ include/reminder.inc.php | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 001e140..adce71d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -11,6 +11,9 @@ Bug/Wish: - #1110: Improves email combobox -JAC - #1459: Lists and administrates aliases on main domain -JAC + * Events: + - #1475: Fixes date storage for next reminder -JAC + * Profile: - #1445: Add job entry year -JAC diff --git a/include/reminder.inc.php b/include/reminder.inc.php index 72b987d..6b8e5bf 100644 --- a/include/reminder.inc.php +++ b/include/reminder.inc.php @@ -72,7 +72,7 @@ abstract class Reminder private static function UpdateStatus($uid, $type_id, $status, $next_ask) { XDB::execute('INSERT INTO reminder (uid, type_id, status, remind_last, remind_next) - VALUES ({?}, {?}, {?}, NOW(), {?}) + VALUES ({?}, {?}, {?}, NOW(), FROM_UNIXTIME({?})) ON DUPLICATE KEY UPDATE status = VALUES(status), remind_last = VALUES(remind_last), remind_next = VALUES(remind_next)', $uid, $type_id, $status, ($next_ask > 0 ? time() + $next_ask * 24 * 60 * 60 : null)); -- 2.1.4