Great news! We ended up getting past the major errors and the web server is now generating our reports! However, they are not yet being populated with information from the database, but that is a wonderful task to hand off to next years wonderful group of Intelligineers.
The team has spent a lot of time trying to implement the attendance sheets, but that does not come without its own large set of bugs and errors. They are an unfortunate part of coding. We are attempting to use various plugins (Originally wkhtmltopdf) to output our HTML code to PDF, however, we are working with a system created by someone else, so this brings up challenges for us to appropriately identify and alter code for our needs. That said, we are still making progress!
The end of the semester is nearing, and we are still hoping to get part of this working in the next week. After that, it will be an exciting transition to a new team who can continue to do great things for IntelliChoice. Stay tuned for hopefully one more update on our success!
The first step we are taking on putting our new attendance documents on the IntelliChoice website is adding the individual attendance charts for students/parents (See example in the post below). We added the buttons for this a few weeks ago, so now we are creating fake parents and children to implement the feature and test it. So far, we have enabled the button and began working on functionality. We are hoping to get the attendance sheets working soon!
Progress is coming along!
We worked with the IntelliChoice IT folks to come up with an attendance sheet design that meets their needs and legal requirements. We have different reports for students, volunteers, and branch managers. After creating the initial design using graphic art tools, we adapted it in HTML/CSS code, the first step in making it a part of the IntelliChoice website.
To convert attendance data to a PDF document, we are using a NodeJS plugin called wkhtmltopdf which allows us to create a PDF from HTML webpages. By creating the HTML templates for the attendance sheets, we have already been able to test out the functionality of wkhtmltopdf. The attached PDFs were actually created by the plugin, and are exactly what we hoped to see!
Now that we have the template code down, all we need to do is feed it the correct data on the website. We’ll see you when that’s done!
We are getting closer to implementing the attendance reports, but we had to plan for their arrival first!
In that light, we planned for their functionality by creating disabled buttons for use when we have created PDF generation functionality. This is a significant step, because ensuring we have the right permissions set for the correct users is one of the most integral parts of the process. Only branch managers should be able to get the branch attendance report. Only parents and branch managers should be able to look at their students’ attendance. Only volunteers and branch managers should be able to look at the volunteer’s attendance. By creating these buttons, we have successfully mapped out this hierarchy.
From here, we just have to make those buttons do something when they are clicked. We re on our way to success!
Branch Manager View
The quest of the three adventurers has led to some exciting discoveries, but only after long and arduous trials.
The process for getting the front end and back end communicating took some time to refine, but our team finally has it down. While the process requires some knowledge of different UNIX, Node.js and MongoDB commands, we have now created an instructions document (with pictures) to speed the process up.
After getting that part down, we began digging into data. Our primary project goal right now is to find attendance data, print out reports with that data, and ultimately help the IntelliChoice team have an easier time working with students and giving out scholarships.
We have just achieved step 1! If you look below, you will see a lot of jumbled characters, but those characters represent the data we need to begin printing out attendance charts. This means that we have created a data set and successfully extracted data from it, which is a huge step in the right direction. Next on our list, print out some attendance!
We have begun work on our project! We are starting off by creating attendance sheets that can be exported by PDF from the webpage. We found a tool called pdfkit that is open source to aid us in this task. Our primary goals coming up are to work with the database to extract the exact attendance information, and then we will go from there!
To read more about pdfkit, check out it’s source files: PDFKit
EDIT: After careful consideration, we switched to wkhtmltopdf as it better suits our needs.
We are not the first to embark on this journey. Before us, other brave souls ventured into the EPICS class and worked with IntelliChoice to create a working database system. While these wonderful people excelled, they have left it up to us to carry the torch, but before we can carry it, we have to understand how it works.
As a team, we are in the process of refining our semester goals, creating a project plan, and learning the necessary skills to be able to make a positive impact for our sponsor, IntelliChoice. We hope to provide top of the line support and creation in database management to help aid them in aiding our community. Through spreading educational opportunity, we can create a better world for many!