diff --git a/admin/reports_fundraising.inc.php b/admin/reports_fundraising.inc.php index bc70df2..82ce791 100644 --- a/admin/reports_fundraising.inc.php +++ b/admin/reports_fundraising.inc.php @@ -120,6 +120,14 @@ $report_fundraisings_fields = array( 'table' => 'users.year', 'components' => array('users') ), + 'user_filter' => array( + 'name' => 'User Filter by MAX(year)', + 'header' => '', + 'width' => 0.1, + 'table' => 'MAX(users.year)', + 'group_by' => array('users.uid'), + 'components' => array('users') ), + 'static_text' => array( 'name' => 'Static Text (useful for labels)', 'header' => '', @@ -162,7 +170,7 @@ $report_fundraisings_fields = array( } */ - $q = " FROM fundraising_campaigns + $q = " FROM fundraising_campaigns $users_from WHERE 1 diff --git a/db/db.update.147.sql b/db/db.update.147.sql index 004d310..0fcc187 100644 --- a/db/db.update.147.sql +++ b/db/db.update.147.sql @@ -15,5 +15,7 @@ INSERT INTO `reports_items` (`id`, `reports_id`, `type`, `ord`, `field`, `value` ('', LAST_INSERT_ID(), 'col', 0, 'namefl', '', 5, 5, 95, 12, 1, '', 'left vcenter'), ('', LAST_INSERT_ID(), 'col', 1, 'address', '', 5, 30, 95, 24, 2, '', 'left vcenter'), ('', LAST_INSERT_ID(), 'col', 2, 'city_prov', '', 5, 60, 95, 12, 1, '', 'left vcenter'), - ('', LAST_INSERT_ID(), 'col', 3, 'postal', '', 5, 80, 95, 12, 1, '', 'left vcenter'); + ('', LAST_INSERT_ID(), 'col', 3, 'postal', '', 5, 80, 95, 12, 1, '', 'left vcenter'), + ('', LAST_INSERT_ID(), 'col', 4, 'user_filter', '', 99, 99, 1, 1, 1, '', 'center vcenter'); +