Rails Example Application - Substruct
(E-Commerce Application)
Substruct is an
E-Commerce application. It supports the following features. The
source code is available through Artistic License/GPLv2.
- A simple content management system with blogging capabilities
- Manage your entire site's content from the web - no html
necessary!
- A simple shopping cart that's tied into Authorize.net
and PayPal
(must have an account)
- Product and order management
- A stunning administration interface
- Create and maintain content
- Create, maintain, void orders
- Answer questions from your visitors
In this hands-on lab,
you are going to build and run Substruct example Rails application.
Expected duration: 90 minutes
(excluding homework)
Software Needed
Before you begin, you need to install the following software on your
computer.
- Java Standard Development Kit (JDK™) version
6.0 (download)
- If you already have installed JDK 5.0 or JDK 6.0, you
can skip this.
- NetBeans IDE 6.1 (download)
- When you install NetBeans IDE, it will ask you which JDK
you want to use.
- Select All, which includes Ruby module.
- MySQL (download)
- 5542_rails_substruct_app.zip (download)
- It contains this document and the lab contents
- Download it and unzip in a directory of your choice
OS platforms you can use
- Windows
- Solaris x86, Solaris Sparc
- Linux
- Mac OS X
Change Log
Things to do (by Sang Shin)
- Add additional exercises
- Add more explanation
Lab Exercises
Exercise 1: Build and run
"Substruct" sample application
(2.1)
Open "Substruct" NetBeans project
1. Open
substruct_rel_1-0-a3
NetBeans project.
- Select File->Open Project (Ctrl+Shift+O). The Open Project dialog box appears.
- Browse down to <LAB_UNZIPPED_DIRECTORY>/rails_substruct_app/solutions
directory.
- If you unzipped the 5542_rails_substruct_app.zip
file under C:\handsonlabs
directory under Windows, the directory to which you want
to browse down should be C:\handsonlabs\rails_substruct_app\solutions.
- If you unzipped the 5542_rails_substruct_app.zip
file under $HOME/handsonlabs
directory under Solaris/Linux, the directory to which you want
to browse down should be $HOME/handsonlabs/rails_substruct_app/solutions.
- Select substruct_rel_1-0-a3.
- Click Open Project.
- Observe that the
substruct_rel_1-0-a3 project node appears under Projects tab window.
(2.2)
Install required GEM's
In this step, you are going to install
the following five required GEM's by the application.
- RedCloth
- fastercsv
- mime-types
- mini_magick
- ezcrypto
1. Install
RedCloth gem.
2. Install
fastercsv gem.
3. Install
mime-types gem.
4. Install
mini_magick gem.
5. Install
ezcrypto
gem.
(2.3)
Create database and populate tables
(2.4)
Run the project
1. Run the application.
Summary
In this exercise, you have built
and ran a "Substruct"
sample
application.
return to
the top
Homework
Exercise (for people
who
are taking Sang Shin's "Ruby on Rails online course")
<tbd>