An open API service indexing awesome lists of open source software.

https://github.com/tameronline/pro_product_pg


https://github.com/tameronline/pro_product_pg

Last synced: about 1 year ago
JSON representation

Awesome Lists containing this project

README

          

# ๐Ÿ›’ Flask Product Manager - tameronline-pro_product

A simple and professional product management system built with Python and Flask. It includes an admin panel, public product listing, image uploads, and SQLite-based storage.

---

## โœ… Main Features

- ๐Ÿ” Admin dashboard with login protection
- โž• Add products with image, description, specs, and price
- ๐Ÿ–ผ๏ธ Upload and store product images in `static/uploads/`
- ๐Ÿ“ View product details on a separate page
- ๐Ÿ—‚๏ธ Admin page to manage (edit/delete) all products
- ๐Ÿงน Button to reset the entire database
- ๐ŸŒ Fully Arabic user interface with clean design

---

## ๐Ÿ“ Project Structure

```
tameronline-pro_product/
โ”œโ”€โ”€ myapp.py # Main application entry point
โ”œโ”€โ”€ config.py # App configuration
โ”œโ”€โ”€ requirements.txt # Required packages
โ”œโ”€โ”€ instance/products.db # SQLite database
โ”œโ”€โ”€ models/ # Product model definition
โ”œโ”€โ”€ routes/ # Admin and user routes
โ”œโ”€โ”€ templates/ # HTML templates for both admin and user views
โ”œโ”€โ”€ static/ # CSS and image uploads
โ”œโ”€โ”€ utils/logic/ # Helper modules (currently empty)
โ””โ”€โ”€ .env # (Optional) Environment variables
```

---

## โš™๏ธ Running Locally

### 1. Clone the Repository:

```bash
git clone https://github.com/your-username/tameronline-pro_product.git
cd tameronline-pro_product
```

### 2. Create a Virtual Environment and Install Dependencies:

```bash
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -r requirements.txt
```

### 3. Set Environment Variables:

Create a `.env` file with the following:

```env
cv_kay=your_secret_key_here
ADMIN_USERNAME=admin
ADMIN_PASSWORD=your_password
```

### 4. Run the App:

```bash
python myapp.py
```

Open [http://localhost:8030](http://localhost:8030) in your browser.

---

## ๐Ÿ” Admin Login

- Username: as set in `ADMIN_USERNAME` in `.env`
- Password: as set in `ADMIN_PASSWORD` in `.env`

---

## ๐Ÿ—ƒ๏ธ Notes

- Uses SQLite for local development
- Images are saved under `static/uploads/` with unique names
- Only valid image formats are accepted (png, jpg, jpeg, webp)
- No categories, search, or API support yet

---

## ๐Ÿ“Œ Future Improvements

- โœ… Add product categories
- โœ… Implement search functionality
- โœ… Create a RESTful API
- โœ… Add Contact/About pages
- โœ… Enable notifications (e.g., email)
- โœ… Deploy to PythonAnywhere / Render

---

## ๐Ÿ“„ License

Open-source for personal and educational use.