From d71247ebe6b5015d169a0f6883dd6d1e2409a1bc Mon Sep 17 00:00:00 2001 From: jengo Date: Mon, 6 Nov 2000 09:50:33 +0000 Subject: [PATCH] Fixed notes field not showing up in view --- addressbook/add.php | 2 +- addressbook/edit.php | 7 ++++++- addressbook/view.php | 5 +++++ 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/addressbook/add.php b/addressbook/add.php index 67ad457076..76731ee804 100755 --- a/addressbook/add.php +++ b/addressbook/add.php @@ -31,7 +31,7 @@ } else if (! $submit && ! $add_email) { form("","add.php","Add","","",""); } else { - if ($bday_month == "" && $bday_day == "" && $bday_year == "") { + if (! $bday_month && ! $bday_day && ! $bday_year) { $bday = ""; } else { $bday = "$bday_month/$bday_day/$bday_year"; diff --git a/addressbook/edit.php b/addressbook/edit.php index 6cfe29394a..499108d165 100755 --- a/addressbook/edit.php +++ b/addressbook/edit.php @@ -59,7 +59,12 @@ form("","edit.php","Edit",$fields); } else { - $bday = $bday_month . "/" . $bday_day . "/" . $bday_year; + if (! $bday_month && ! $bday_day && ! $bday_year) { + $bday = ""; + } else { + $bday = "$bday_month/$bday_day/$bday_year"; + } + if ($access != "private" && $access != "public") { $access = $phpgw->accounts->array_to_string($access,$n_groups); } diff --git a/addressbook/view.php b/addressbook/view.php index 1771de24d5..81f067cf33 100755 --- a/addressbook/view.php +++ b/addressbook/view.php @@ -47,6 +47,11 @@ $i++; } } + + if ($phpgw->db->f("ab_notes")) { + $columns_to_display[$i]["field_name"] = "Notes"; + $columns_to_display[$i]["field_value"] = $phpgw->db->f("ab_notes"); + } echo ''; for ($i=0;$i<200;) { // The $i<200 is only used for a brake