Author: Marjory D. Marquez
This is a portfolio demonstration of a full-stack web application built using Python/Flask for the backend, managing car inventory with Object-Oriented Programming (OOP) principles.
The primary goal of the Car Dealer Pro Management System is to provide a comprehensive, user-friendly, and persistent solution for managing a car dealership's inventory.
This application transitions from a Command Line Interface (CLI) to a web-based interface using the Flask framework, offering a professional, modern user experience for key dealership functions like adding new stock, viewing current inventory, and processing vehicle sales.
This application utilizes a robust object-oriented Python backend to handle business logic and data persistence, while the Flask framework provides the sleek frontend web interface.
- Professional Web Interface: Utilizes Flask, HTML, and CSS for a clean, modern, and responsive user experience.
- Inventory Management: View all cars in a clean, professional table format.
- Persistent Data Storage: Inventory data is saved to a local
cars.jsonfile, ensuring all records are maintained between application sessions. - Add New Stock: A dedicated web form for efficiently adding new vehicles with basic validation for data types and ensuring a unique Vehicle Identification Number (VIN).
- Sales Processing: Functionality to remove a car from the inventory (simulating a sale).
This application handles a complete inventory lifecycle with robust features and recent improvements:
- Full CRUD Functionality: Add, View Detail, Edit, and Sell (Remove) vehicles.
- Data Persistence: Inventory and Sales History are saved using JSON files.
- Dynamic Search & Sorting: Users can filter the inventory instantly and sort columns (Make, Model, Year, Price, VIN) in ascending/descending order.
- Enhanced Reporting: Dedicated views for Sold History and aggregate Sales Reports.
- Improved UX/Styling:
- Cohesive dark theme and high-contrast styling across the header and footer.
- The "Add Car" button and navigation links are professionally styled.
- Visual Flair: Custom logos/icons added to the main header, Sales Report title, and Sold Inventory title.
- Robust form validation with flashing error messages.
The application supports a typical dealership workflow:
- Acquisition: When a new vehicle is purchased, an employee navigates to the 'Add New Car' form, inputs the required details (Make, Model, Year, Price, VIN), and the application validates and saves the entry.
- Reporting: The Sales Manager checks the 'Inventory' page to see real-time stock levels, vehicle details, and total count, aiding sales and marketing decisions.
- Sale: When a car is sold, the employee clicks the 'Sell' button next to the car's entry. The application instantly removes the vehicle from the inventory and updates the local data file.
| Component | Technology | Description |
|---|---|---|
| Backend Logic | Python 3.x | Handles all object creation (Car), data validation, and inventory manipulation. |
| Web Framework | Flask | Lightweight Python micro-framework used for application routing and template rendering. |
| Frontend | HTML5 / Jinja2 | Used to structure the web pages and dynamically display Python data within templates. |
| Styling | CSS3 | Implements the custom, professional, and responsive aesthetic. |
| Data Storage | JSON | Simple, local file storage for persistent inventory data. |
| *Principles: | OOP | Object-Oriented Programming (OOP). |
The project follows a standard modular structure for a Python application integrating the Flask framework:
CarDealerApp/
├── static/ # Contains public assets (linked via Flask)
│ ├── css/
│ │ └── style.css # Custom application styling
│ └── images/
│ ├── logo.jpg # Main header logo
│ ├── image-1.png # Sales Report icon
│ └── image-2.png # Sold History icon
├── cars.json # Persistent data file (IGNORED by Git)
├── .gitignore # Specifies files to ignore (e.g., cars.json)
├── app.py # Flask application entry point and routing logic
├── car.py # Data Model: Defines the Car class
├── dealer_manager.py # Business Logic: Handles all inventory operations (CRUD)
└── templates/
├── base.html # Main layout template (Header, Footer, Nav)
├── index.html # Main Inventory & Search page
├── car_detail.html # Single car view
├── add_car.html # Form to add a new car
├── edit_car.html # Form to edit an existing car
├── sold_cars.html # Detailed list of sold vehicles
└── sales.html # Sales Summary and Aggregate Report
This repository does not contain the complete source code for the "Car Dealer Manager" application.
The files included here are specifically selected for portfolio review purposes to demonstrate my skills in:
- Application Architecture and Flask Routing
- Business Logic (CRUD operations)
- HTML Templating (Jinja2)
- CSS/Frontend Styling
Note: Key backend files like app.py (Flask application) and dealer_manager.py (core logic/data management) are intentionally omitted from this public repository, as are other proprietary or infrastructural files. This repository represents a comprehensive view of the project's structure and my capabilities, not a complete, runnable clone.
These images demonstrate key features and the overall user interface of the Car Dealer Manager application.
Follow these steps to set up and run the application locally on your Windows machine:
-
Clone the Repository:
git clone [https://github.com/Marjory00/CarDealerApp.git](https://github.com/Marjory00/CarDealerApp.git) cd CarDealerApp -
Install Dependencies:
pip install Flask
-
Run the Application:
python app.py
-
Access the App: Open your web browser and navigate to the address shown in your terminal (typically http://127.0.0.1:5000/).



