Lab 04 Report - Pine Valley Furniture System
Website Pages & Their Purpose
- main.aspx - The main homepage that provides navigation to all other pages such as search, register, and help.
- Register.aspx - Allows customers to create an account by entering their personal information.
- EmployeeLogin.aspx - Login page for employees. Currently uses hardcoded credentials for authentication.
- LoginChoice.aspx - Gives users the option to log in either as a customer or as an employee.
- employee_dashboard.aspx - A dashboard for employees where they can manage system-related tasks.
- Cart.aspx - Displays the products selected by the user for purchase.
- payment.aspx - Handles the payment process for completing orders.
- Help.aspx - Provides instructions to users on how to use the system.
- search.aspx - Enables users to search for products stored in the database.
- update_catalog.aspx - Allows updating of product details in the catalog (admin functionality).
- task1.aspx - Demonstrates the ASP.NET page lifecycle events.
Search Functionality (Database Integration)
The search page is one of the key dynamic features of the system. It is connected to a SQL database and allows users to find products easily based on their input.
- The system takes input from the user through a search textbox.
- When the search button is clicked, the system queries the database and looks for matching product descriptions.
- A flexible matching technique is used, which means users do not need to type the exact product name. Partial matches are also supported.
- The results are fetched from the database and displayed dynamically on the same page.
- Each product is shown with its description, finish, and price in a structured format.
- If no products match the search, a message is displayed to inform the user.
- A "Show All" option is also available to display the complete list of products.
CSS Styling (style.css)
An external stylesheet is used across all pages to maintain consistency in design.
- Background color: Light cream (#FFF2E0) for a soft look.
- Header: Purple (#898AC4) with centered text.
- Navigation bar: Styled with soft purple tones and hover effects.
- Buttons: Rounded with hover color transitions.
- Product cards: Structured layout with spacing and soft background colors.
- Footer: Consistent design across all pages.
- Authentication box: Centered layout with shadow for login/register forms.
Authentication System
- The system provides a login choice between customer and employee.
- Employee login currently uses hardcoded credentials (admin / 1234).
- Customer authentication is not connected to the database yet.
- Database usage is currently implemented only in the search functionality.
Task 1 - Page Lifecycle Demonstration
The task1 page is used to demonstrate how ASP.NET processes a page through different stages.
- Initialization stage when the page is first created.
- Loading stage when the page content is prepared.
- Event handling when a button is clicked.
- Pre-render stage before displaying the page.
- Unload stage when the page is closed.