Inspiration

I was inspired by the clean design I saw on many websites. I figured out that they used bootstrap, and I figured making a Hack K-State website utilizing it would be cool. I researched possible frameworks to make it speedy and settled on Ruby on Rails after seeing its beautiful and simple syntax.

What it does

The Rails application functions as a back-end to communicate with front-end users and act as a Hackathon registration + information + team-building website. It acts to make registering easy, as well as getting information, building teams, and submitting products. It would become even more powerful with webhooks to devpost and the Discord server.

How we built it

I installed WSL2 (linux subsystem on windows) and used the console to install ruby, rails, gems, etc. and then set up my rails project. From there, I began developing the main application template and the header, footer, and site-content structure. I implemented models where I saw fit, which were incorporated into the built-in sqlite3 database. These models included registration forms, users, teams, submissions, and competition data. The controller files figure out how to handle these models and distribute according views, which are present to the client.

Challenges we ran into

Backend migrations through Rails are always tricky (you can locate these through "db/migrate"). Those definitely gave me trouble, especially with optionality; furthermore, namespacing with the admin path to put things in "/admin" was a little new to me (see "config/routes.rb").

Another thing that gave me trouble was handling how to present form errors to the front-end. I eventually settled on the _ very _ useful flash system, where I can type

flash[:danger] = "The username and/or password were incorrect."
flash[:success] = "You have logged in successfully!"

and I was able to use this system in my main template to automatically display the contents to the front end in an alert-like manner.

Time was the main constraint. It definitely made the visual aspect of it a bit more botched than I would have liked with infinite time, and hopefully that can be improved in the future. It also stopped me from making my hopes to streamline the submission system to just the one website.

Time was also definitely the main constraint when my computer BSODed, restarted, and then BSODed AGAIN with an even more troubling error message, and then got stuck at the Dell logo for 20 minutes. So, I took out the battery and pressed the power button to drain out the power, then put it all back in, booted it into safe mode where the startup repairer said it couldn't fix it. Me, thinking my project and computer were done, tried starting it again in a last-ditch attempt--and it just worked normally -_-

Accomplishments that we're proud of

It was very satisfying for me to get the user system to work. It's almost completely native to rails, and I got to directly manage the forms, database structure, and authentication involved with signing in. I'm also really proud of the header and the aesthetic choices I made there. The prizes page is another one of my favorites.

What we learned

Do not underestimate front-end development. It seems semi-simple, but it takes TIME. I also learned a lot more about the intimacies of relations, validations, and migrations that I hadn't been too familiar with before. It was fun to manage my own database and learn what that's like.

What's next for Hack K-State Website

I want to implement more support for teams and add on-site uploading of profile pictures, and actual video and image submissions. I want to streamline the process of registration, and add frameworks for making schools/colleges/districts. I also think the implementation of a sidebar would be beneficial for the overall flow of the website.

Share this project:

Updates