Sample Project Implementation Document Introduction This document describes the project implementation for developing the online store. The project implements PHP 5, MySQL 4.1 and standard HTML. The project will be capable of running on standard internet web browsers, although, the project is designed primarily around MS Internet Explorer. The interface for the project will provide a point of sale for the customer and administrative capabilities for the store owner. Flow Chart: Customer Customer Main Page Catalog Shopping Cart Customer visits main website. Customer browses around looking for products. Customer adds products to purchase to shopping cart. Customer Preferences Order Tracking Checkout Customer Signup Customer changes personal information. Customer looks up previous orders. Customer verifies information and pays for products. Customer signs up for user account. Flow Chart: Administrator Store Owner Main Page Reports Owner opens admin portion of website. Owner can print out reports on stock and various items. Shipping Customer Accounts Inventory Owner can view what orders need to be shipped. Owner can modify account information for the customers. Owner can increase or decrease inventory for the store. Customer Pages / Modules Main Page Introduction: The main page of the online store if the entry point for all other pages contained in the website. The customer will be able to begin shopping, track orders or change user preferences from this point. Details: The main page will be developed in HTML / PHP. The page will contain links to the other pages / modules. The layout of the page is based on page frames. Each frame will contain a link to a module. A login box for customers that already have accounts will be located in the upper right hand side of the page. Database Tables: The main page will not be linked to a database table. The page will simply point to other pages that have database connections. Error Handling: The page will handle page errors by attempting to reload the module or report that the module is unavailable. If an invalid username or password is entered, the customer will be prompted to retry the login. Catalog Page Introduction: The catalog page will be the main page for customers to browse available products for the website. Details: The page will query the database and extract the product information. The products will then be sorted based on the category and sub-category. The page will have a side menu on the left that will contain the main category listing. The customer can click on a category to bring up the list of products that are available. If the category contains sub-categories these will be displayed in the middle of the page and the customer can proceed to drill down on the products. An option to show all products will disregard the category and sub-category listings. The items in the database will have a visible tag that the administrator can select. Some products may be out of stock, so the owner may choose not to display these items. When a customer chooses to select an item for purchase the item product id, quantity and customer id (if logged on) will be passed to the shopping cart module to store the information. Database Tables: Table Name: Product Table Fields: Product ID Number (VARCHAR(5), Not Null, Primary Key) Item Name (VARCHAR(50), Not Null) Item Description (TEXT, Not Null) Quantity In Stock (INT, Not Null) Price (INT, Not Null) Category (VARCHAR(20), Not Null) Sub-Category (VARCHAR(20), Not Null) Visible (TINYINT, Not Null) Picture (TEXT, Not Null) Error Handling: Errors that could occur if the customer selects too large of a quantity for purchase. The software will have a limit based on how many are in stock. To resolve this issue a pull down menu with the quantity in stock will be provided for the customer to choose. Products displayed to the page should be complete with information. When the products are entered into the database by the administrator the fields will all be required. By making sure that all information is entered from the start the output will not contain partial information. Customer Signup Page Introduction: Customers will be able to sign up for an account with the website. Details: The customer will need to provide certain information to the website in order to purchase products. The customer will be prompted with a form to provide name, address, phone, email and password. The customer may choose to input an additional shipping address if different from the billing address. The email address will be used as the login for the customer. The page will input to the database. Changes to the customer account cannon occur at this page in the website. Database Tables: Table Name: Customer Table Fields: Customer ID (VARCHAR(5), Not Null, Primary Key) First Name (VARCHAR(20), Not Null) Last Name (VARCHAR(20), Not Null) Billing Address (VARCHAR(50), Not Null) Billing City (VARCHAR(20), Not Null) Billing State (VARCHAR(2), Not Null) Billing Zip (VARCHAR(5), Not Null) Shipping Address (VARCHAR(50), Not Null) Shipping City (VARCHAR(20), Not Null) Shipping State (VARCHAR(2), Not Null) Shipping Zip (VARCHAR(5), Not Null) Phone (VARCHAR(10), Not Null) Email (VARCHAR(50), Not Null) Password (VARCHAR(12), Not Null) Error Handling: Incomplete information will be dropped from the database. Only information that is complete will allow to be submitted to the website. The page should check the values be submitted and determine if the value is null. Customer Preference Page Introduction: The customer preference page will allow the customer to modify their personal information. Details: The customer will be allowed to modify information that is currently on file in the database. The customer will be able to make changes to the name, address, phone number and password fields. Since the email address is being used as the username they will not be allowed to modify the data. The page will submit and update the information in the database. Database Tables: The customer preference page will connect to the same table as the customer signup page. The table name is customer. Error Handling: Incomplete or partial data will be dropped from the database. All fields need to be filled in. The page will poll the database and the current values will be displayed to the screen. If the customer submits to the database and nothing has changed the information will not be updated. Shopping Cart Page Introduction: Shopping cart will hold the products the customer has chose to purchase. Details: As the customer is shopping, products will be added to the shopping cart. Information from the catalog page (product id, quantity, customer id, and a timestamp of when the product was added) will be passed to the Order Processing table. The processed and shipped flag will be set to zero. This will be changed later in the checkout page. At this point the customer will be able to drop products, increase/decrease quantities and continue shopping. After an item is added to the cart it will remain for a period of time. After this time frame, items that do not have the processed flag turned on will be deleted from the table. Database Tables: Table Name: Order Processing Table Fields: Transaction ID (INT, Auto Increment, Not Null, Primary Key) Customer ID (VARCHAR(5), Not Null) Product ID Number (VARCHAR(5), Not Null) Quantity (INT, Not Null) Date / Time (TIMESTAMP) Processed (TINYINT, Not Null) Shipped (TINYINT, Not Null) Date Shipped (DATE) Tracking Number (VARCHAR(50)) Error Handling: Incomplete data passed from the catalog page will be dropped. When a customer tries to update the product quantity, the current amount in stock will be provided in a drop down menu to prevent the customer from trying to order too many of one product. Checkout Page Introduction: The final page of the checkout process. Details: The customer will be able to review shipping and billing information at this page. If the customer needs to make changed to the information, they can do so at this time. The page will update the database at the end of the process. The customer can look at the products they have chose to purchase, but to make changes they will need to back out and make those changed on the shopping cart page. After the customer has verified the information, they will click a purchase product button. In the future they will be directed to a secure site to provide payment information. Currently the page will update customer information and for the products listed on the page the processed flag will be set to on. The customer will then be directed to a page that will thank them for their order and provide a transaction id that can later be used to track shipments. Database Tables: The checkout page will utilize the same table as the shopping cart page. The table name is Order Processing. Error Handling: Incomplete or partial information will be dropped. Invalid information will generate an error and the customer will be asked to make changes. Order Tracking Page Introduction: The customer will be able to track shipments. Details: The customer will input a transaction number and the page will query the database. The transactions matching the number will be provided to the screen. The page will show if the package was shipped, what date and who is the carrier. This information will be stored until the owner decides to purge the database. Database Tables: The order tracking page will utilize the same table as the shopping cart page. The table name is Order Processing. Error Handling: Invalid transaction numbers will be rejected and the customer will be asked to enter the number again. If the number returns no results the customer will be informed. Administrator Pages /Modules Main Admin Page Introduction: The main admin page will be the central point for the store owner to modify inventory, run reports and ship products. Details: The page will be similar to the main page of the website. The links will refer only to those pages that can be access by the admin. The admin will need to login before any access will be granted. Database Tables: Table Name: Admin Table Fields: Username (VARCHAR(10), Not Null) Password (VARCHAR(12), Not Null) Error Handling: The page will verify the username and password entered. If incorrect the customer will be prompted to reenter the information. Reports Page Introduction: Various canned reports will be available for the store owner. Details: The page will be a simple page that will contain links. The links will be SQL queries that will query the various tables. Queries: Customer Base: Query the database and return a list of customers. Product Base: Query the database and return a list of all products. Category List: Query the database and return the categories. Specific Category: Drop down box choice, query the db and return those products in the category. Out of Stock: Query the database and return those products that have a quantity 0. Items Need Shipping: Query the database and return the items that the shipped field is set to 0. Items Shipped: Query the database and return the items with the shipped field se to 1. Database Tables: The page will be connected to all database tables. Error Handling: The queries should return the results to the page. If data is unavailable the page will show 0 results and notify the owner with an error message. Inventory Page Introduction: Inventory page will display all the products in the database. Details: The admin will be able to update quantities, change product names, descriptions, price, category and sub-category. The page will contain a list of all the items that can be clicked and then redirected to a new page that will contain a form. The information in the form can be modified and the data resubmitted to the database. Database Tables: The page will be connected to the product table. Error Handling: Invalid or incomplete information will be dropped when submitted. The page will check the data being submitted. Customer Accounts Page Introduction: The customer accounts page will be a way for the store owner to update accounts if a customer calls or emails with problems. Details: The admin will be able to update all information relating to the customer accounts. The only information that cannot be changed is the email address. The page will contain a list of customers that can be clicked and then redirected to a new page that will contain a form. The information in the form can be modified and the data resubmitted to the database. Database Tables: The page will be connected to the customer table. Error Handling: Invalid or incomplete information will be dropped when submitted. The page will check the data being submitted. Shipping Page Introduction: The owner will be able to see what orders need to be shipped. Details: The page will query the database and return the transactions that have the shipped flap set to zero. Once the owner ships a product they can logon and set the shipped flag to one, enter the tracking number and the shipping company. The information will be reflected on the report that the owner runs in order to see what items need to be shipped. This page will be very similar to the other update pages. Database Tables: The page will be connected to the Order Process table. Error Handling: Invalid or incomplete information will be dropped when submitted. The page will check the data being submitted. Summary This document shows flowchart diagrams of how the customer and administrator can access the various pages / modules. The pages / modules are then described in detail the transactions that will take place along with the tables needed to fulfill the transactions. The database tables are described in detail with field names, field categories and other important information. The tables can be built with the information provided in MySQL.