BooksForCOD.Com
This website allows users to order for books online and pay cash when books are delivered, i.e. Cash On Delivery(COD).
It allows user to do the following:
- Search for books by title
- Add book to Cart
- Place order
- Get details of an Order
- Display the Cart
- Delete a book from cart
Architecture Of the Project
This project uses JavaServer Faces 2.0 to build the interface. Managed Beans talk
to DAO (Data Access Objects), which talk to database using JDBC.
So overall architecture is - JSF 2.0 UI Components -> Managed Beans -> DAO -> JDBC -> Oracle Database.
It uses JavaMail to send mail to user when user places an order.
Products and frameworks used in this project
- Java EE 6.0
- JSF 2.0
The following features of JSF 2.0 were used in this project.
- JSF html tags for input
- <ui:repeat> and <ui:dataTable> tags to display data
- Templating
- Validation using Validation tags
- Ajax using <f:ajax>
- Annotations for Managed Beans
- Default navigation
- Oracle11g Express Edition
- NetBeans IDE 7.1
- Jdk 7.0
- GlassFish 3.x
- Java Mail API and Mail Server
Steps to download and deploy this project
- Download booksforcod.rar. The .rar file contains the entire source
code for the project. Unzip the file into c:\ so that c:\booksforcod folder is created with all the components of the project.
- Open the project in NetBeans 7.x
- Go to properties of the project using popup menu. Select libraries
node and delete existing libraries using Remove button. Then add -
Oracle - ojdbc6.jar and mail.jar (assuming you have downloaded
JavaMail API) for Java Mail. You have to add these .jar files to the project using
Add Jar/Folder button.
- Add the .jar files related to JSF 2.x using Add Library option.
- Create books account with password books in Oracle11g
Express Edition. This must be done after you log in as SYSTEM user. Then create
tables and sequences listed below after connecting to Oracle as books. These commands are also present in tables.sql file in your project source code.
- Run home.xhtml. Search for books by title. Add books to cart and test the rest of the options.