Since finishing the module on data modeling, my software engineering class did not assign a new module and wanted everyone to work at full speed on finishing the project. Kale With Friends has been coming along nicely as we got good feedback from the class on how to improve the website. However, we did encounter minor hiccups along the way as we were working on the project.
One of the key requirements for milestone 3 is that we use a persistent database in our application. Changing from the mockup database to a persistent database proved to be nontrivial. A major problem we encountered was that we did not design our models correctly for the MVC design paradigm. Some of our models were subclasses of each other and this caused a problem when trying to have our classes be extended with
play.db.ebean to support PostgreSQL. Since Java does not support classes with multiple super classes, we had to redesign the model infrastructure of our application. Ultimately, we combined subclasses into a single class/model so it can be implemented as a single entity for
Model. We also had to rewrite many of our models’ methods since certain classes disappeared due to being merged.
Besides implemented the database, we also spent some time redesigning our webpages so they are more functional and easier to access. In particular, I focused on the page that displayed fresh ingredients for users to buy. Previously, this page was a simple table that contains the produce a user can buy and their price. A table layout is extremely poor for this type of information since it is hard to navigate effectively. With feedback from class, I redesigned the page to use a tile based system so a buyer can quickly find what they want by just looking at pictures. In addition, having a number for quantity was also meaningless for the buyer because the buyer wants to know quickly if something is available, not how much the farmer has in stock. To solve this problem, I implemented a simple bar type meter using Font Awesome to represent how much quantity the farmer has in stock. This allows the buyer to look at the meter and quickly tell if the farmer is low on inventory.
We still have much to work on for this project as some parts of our application are broken or unimplemented yet. Such features include easy searching for farmers or ingredients. I would also like to load more recipes into the database so our meal planner page can provide more detailed information on what can be made with recipes on hand.