one-stop report page


I´m using project pier for managing meetings and tasks for a regional bank. The tool will be used by several board members. One of the administrative users asked me to integrate a custom report to output tasks with filters for users, milestones, completed tasks, pending task lists, etc. Pretty much a one-stop reporting page.

How can I best integegrate this report with what has already been coded? I don´t want to mess with the core code at all so as not to lose any work when updates come out. I want this pretty much stand-alone, but would still like it to sit behind the login, use the navigation menu, etc.

I´d be more than happy to share the code when done. Cheers!
Erik Flores
Monterrey, Mexico

Hello Erik, I was thinking of developing something similar as well. I'm happy to collaborate to develop that reporting section.



Hello Omar,

I had this on pause since other projects came up, but will restart sometime soon. Do you have any ideas? Right now I´m just going to start building a .php from scratch with the different filters and the output, and a different php with the sql calls.

let me know what your thoughts are.


i wanted to add this at the top-most level, not at a project view or anything like that...FYI
The report has 3 criteria to choose from - project, milestone, user

so here´s how to do it:::

1) CREATE A DASHBOARD VIEW FILE (this will be the content of your report)
for example - you can copy one of the existing files like contacts or index - just keep the top lines where you set the title, tabbed navigation, and crumbs (modify parameters accordingly) and delete the rest

After those 3 lines, you place the rest of your script for your report. for example, ive got some ajax where once you select a project, the corresponding milestones appear for you to choose from in a select box

then comes whatever html you need to have...

i broke it down using 4 files
myreport - this is the main file that links to the following 3
dbconn - defines the connection to the database
load_milestones - sql logic called via ajax from myreport to query for milestones based on the project selected
load_results - sql logic called via ajax from myreport to query for results based on user selection of project, milestone and user

2) ADD A FUNCTION TO THE CONTROLLER (this is the function that gets called from the tabbed navigation...)
i added the following after the index() function

* Show myreport page
* @param void
* @return null
function myreport() {
trace(__FILE__, 'myreport'); //the name of the file you used in step 1
$this->addHelper('textile'); //not sure what this does
tpl_assign('active_projects', logged_user()->getActiveProjects());
tpl_assign('finished_projects', logged_user()->getFinishedProjects());
$this->setSidebar(get_template_path('my_projects_sidebar', 'dashboard')); //you can choose a different sidebar if you like
} // end myreport


define('DASHBOARD_TAB_OVERVIEW', 'overview');
define('DASHBOARD_TAB_MY_PROJECTS', 'my_projects');
define('DASHBOARD_TAB_MY_TASKS', 'my_tasks');
define('DASHBOARD_TAB_WEEKLY_SCHEDULE', 'weekly_schedule');
define('DASHBOARD_TAB_CONTACTS', 'contacts');
define('DASHBOARD_TAB_brreporte', 'myreport'); // <----- ADD THIS LINE!!!!4

if (logged_user()->isMemberOfOwnerCompany()) {
get_url('dashboard', 'contacts')
ADD THIS PART (this will add your tab after the contacts tab)
get_url('dashboard', 'myreport')

Took me a while to figure it all out. Hope it guides someone!

Hey Erik! That seems like a great job, man! I couldn't keep working on that, but I hope to find some time and get back to it.

Thanks for sharing your code!



There are some report building tools available like Jaspersoft iReport that can dig into the MySQL database and generate a report. I tested it and it's promising :)

iReport is the free, open source report designer for JasperReports. Create very sophisticated layouts containing charts, images, subreports, crosstabs and much more. Access your data through JDBC, TableModels, JavaBeans, XML, Hibernate, CSV, and custom sources. Then publish your reports as PDF, RTF, XML, XLS, CSV, HTML, XHTML, text, DOCX, or OpenOffice.


thanks broncoisl, but i was looking for something that would integrate with project pier - not a stand alone reporting software.