The Final Application We're Going to Build
By combining a large number of Rails components, this is the final application that we'll build out during this course.
Guide Tasks
  • Read Tutorial
  • Watch Guide Video
Video locked
This video is viewable to users with a Bottega Bootcamp license

Hello everyone. Welcome to the Professional Rails Code Along course where you'll learn how to create applications using Ruby on Rails.

We'll start by looking at the application that we're going to build in this course. This application is called Time Tracker and it consolidates all the payroll/overtime details entered by employees in an organization. It follows a particular workflow pattern. An employee can request overtime, enter the details, and submit it to the manager, who in turn, can view these details and approve it. The employees cannot access or edit the overtime requests, as this task is accessible only for the manager.

Near the end of the course we'll deploy it to the web.

This is what it the first page looks like.

large

If you look at the top, we have Entries tab that takes us to a page where we can see through all our entries like this:

large

This page contains details of all the overtime entered by a particular user. For security reasons, a user can see only his or her details.

You can navigate from one page to another too. If you notice, we use Ajax-based pagination. When you click on the tabs numbered from 1, you'll see that nothing changes in the URL.

The other primary tab on top is Request Overtime. When you click on this tab, you'll see a new page where an employee can create an overtime request.

large

Now, if you go back to the main screen, you'll see three clickable buttons that allow users to confirm if they've done any overtime for a particular week. These values are not hard-coded, rather they are filled from the database. Also, each of these buttons have a custom action that we control with our code. For example, when you click on the first button, you can see a pop-up window that asks you to confirm your action.

large

Further, we provide ground notifications using some cool Javascript code.

large

This notification stays for some time, and then eventually fades off.

All this functionality is available when you log in as an employee.

However, if you log in as an administrator, you'll see a completely different interface.

large

As an admin, you can approve or review every overtime. You can also see a log of all the information, including those that are confirmed.

large

The above details are displayed using custom code, and they are not hard-coded into the application. We follow some of the established best practices of programming and use many cool features of Rails such as using application view helpers instead of putting code in view files. In addition, we write dozens of automated test scripts throughout the application, so you'll learn all about RSpec, and follow a test-driven development process.

At the top of the screen, you'll see a link called "Audit log" and when you click on this link, you can see a gist of all the time entries.

large

If you see, we have a color code generator for each label and this is generated dynamically with information from the database.

Next, you can navigate to the admin dashboard, and here you'll see a list of users, posts, admin users and employees.

large

You'll also learn about an advanced concept called STI (Single Table Inheritance) that is used to scope different types of users based on the features you want to give them.

In addition to the above functionality, we are also going to create a functionality to send text messages to the registered mobile numbers of employees. We will build these messages into a scheduling system that will send out messages from the server, when a particular task is completed. A text message will also be sent out to every employee at the end of the week to remind them to log in and enter their overtime.

large

An email will be sent to the manager with a consolidated list of all the overtime requests for a particular batch.

In short, this is a real-world project that you can use in any almost any company to manage their personnel records.

In this project, I show you how I go about designing and creating the project including identifying and debugging problems. In addition, you'll also have all the source code of this project. I've uploaded all of it on github, and you can access it here.

If you have any questions whatsoever, please feel free to get in touch with me.

I'm excited to get started, and I hope you're too.

Let's begin!