Web Geek

Collection of web development resources written for beginners!

Ruby on Rails

This Section offers a step by step application build right through to deployment with Heroku. These instruction sets are for use on mac osx and assume some prior knowledge of programming concepts.

1. Quick set up your local Rails env

Quick set up your local env with Rails for a new application. The following tutorial takes you through the first steps I took to generate my blank rails application on mac os x. This is where I will begin…

2. Layouts with Bootstrap

For quick and easy layout designs I have integrated Bootstrap. It means you don’t need to waste a whole lot of time learning/designing how your application is going to look. It gives you enough, though to present a professional looking front end.

3. Development Process

I am going to build a very simple Personal Budgeting App with Ruby on Rails. This tutorial will go through the development process I have taken to get started.

4. Render Base Scaffold

In this tutorial, I am endeavouring to get the base of my app looking how I would like it, so I can create an initial building block to start from. It will enable me to complete models as I go.

5. Create partials

What are partials? Partials in rails are views which enable you to create layouts with multiple content sections. I am going to nest three content partial views within the right hand column (also a partial) of my app to render a budgets summary section which will each eventually draw information from different models.

6. Create Models

In this example I will be using rake and Active Record Migrations to create a new income model backed by a posgreSQL database.

7. Create Controllers

Now that I have successfully created a model and migrated a database for income, it’s time to create controllers and views to be able to access the income information visually.

8. Page Links

Now that I have my layouts set up and some working partials. I can follow my previous partials instruction set to render a form which will update my income information. Of course I’ll need a few modifications in my income controller as well.

9. Create Forms

First, I’m going to create an _incomes_form.html.erb partial is a data entry form which will allow me to input data regarding income information and then save it to the main page. It will also redirect back to an updated index page once data entry is complete.

10. Refactor routes

When refactoring, it’s a good idea to visualise or draw a diagram of how the outcome is going to look. I’m going to use what I’ve created so far and refactor the working parts that I want to use into my main page.