A modern, feature-rich eCommerce platform built with Laravel 12. Perfect for online stores with a powerful admin panel and beautiful storefront.
- PHP 8.2+
- Composer
- MySQL/PostgreSQL/SQLite
- Node.js 18+ (for asset compilation)
- Clone and install:
git clone https://github.com/needyamin/eCommerceLaravel
cd eCommerceLaravel
composer install
npm install- Start server:
php artisan serve- Access web installer:
Visit
http://localhost:8000/installer- The installer will automatically:
- β Check system requirements (PHP, extensions, permissions)
- β Test database connection
- β Create database tables
- β Seed sample data
- β Create admin account
- β Disable installer after completion
That's it! The installer handles everything automatically.
Default Login (if using manual seeding):
Admin Panel:http://localhost:8000/admin/login
Email:needyamin@gmail.com
Password:needyamin@gmail.com
Role: Super Admin (has all permissions)
After installation, you'll have:
- β 1 Admin Account - Super Admin with all permissions
- β 1 User Account - Test customer account
- β 6 Categories - With subcategories
- β 72 Products - 12 products per category with images
- β 216 Product Images - 3 images per product
- β 4 Currencies - BDT, USD, EUR, GBP
- β 5 Sample Coupons - Ready-to-use discount codes
- β Bangladesh Data - All divisions, districts, upazilas
- β 124+ Permissions - All admin route permissions
- β Default Pages - About, Terms, Privacy, etc.
- Auto-Disable: Installer is automatically disabled after successful installation
- Database Control: Installer status stored in
site_settingstable - Re-enable: Update
installer_enabled = truein database to re-enable - Security Check: Validates PHP version, extensions, and folder permissions
- Database Testing: Tests database connection before proceeding
The system includes 30+ database tables organized into:
Core E-commerce Tables:
admins,users- User accountscategories,products,product_images- Product managementorders,order_items- Order processingcarts,cart_items- Shopping cartcoupons,coupon_usages- Discount systemwishlists,guest_wishlists- Wishlist functionalityproduct_reviews- Reviews and ratingsuser_addresses- Customer addressesuser_points- Coins/loyalty pointscurrencies- Multi-currency support
Location Data:
districts- Bangladesh districts (64 districts)upazilas- Bangladesh upazilas (500+ upazilas)
Settings & Configuration:
site_settings- Site config, SEO, theme, licenseemail_settings- SMTP configurationotp_settings- OTP/SMS settingspayment_gateway_settings- Payment gatewaysshipping_settings- Shipping and taxstorage_settings- Storage/CDN configcoin_settings- Coins system settingsnewsletter_settings- Newsletter configpages- Static pages
System Tables:
roles,permissions- RBAC (Spatie Permissions)model_has_roles,model_has_permissions- Role assignmentscache,sessions- Application cache and sessionsjobs,failed_jobs- Queue systemnewsletter_subscribers- Newsletter subscribers
Database File: ecommerce.sql - Complete database dump with all tables and sample data
- Product catalog with categories and subcategories
- Live search, shopping cart, and wishlist
- Checkout with Bangladeshi address system (Division, District, Upazila)
- Multiple payment gateways (bKash, Nagad, Rocket, SSL Commerce, Stripe, PayPal, COD)
- Coupon/Discount system with usage limits
- Product reviews and ratings
- Newsletter subscriptions
- Coins (Loyalty Points) system
- Referral system with user codes
- Responsive design with Tailwind CSS 4.0
- Dashboard with analytics and statistics
- Role-Based Access Control (RBAC) - Complete permission system
- Advanced Product Management
- Product images with drag-and-drop upload
- Image reordering and primary image selection
- Rich HTML descriptions with Quill Editor
- Category and subcategory support
- Stock management
- Featured products
- Sale pricing (Original Price vs Current Price)
- Advanced Product Filters β NEW
- Collapsible filter section
- Product name search with Select2 (AJAX search)
- Category and subcategory filters
- Stock status filter (In Stock, Out of Stock, Low Stock)
- Featured products filter
- On Sale filter
- Price range filter (Min/Max)
- Status filter (Active/Inactive)
- "ALL" indicator when no filter is selected
- Clear filters button
- Auto-reset on page reload
- Enhanced DataTables β NEW
- Product images in table view
- Category and subcategory columns
- Price and Original Price columns (centered)
- Stock quantity with color-coded badges
- Consistent button group styling for actions
- CSV export (all data and current view)
- Server-side processing for performance
- Orders Management - View and manage customer orders
- Users Management - Manage customers, coins, and referrals
- Coupons Management - Create and manage discount codes
- Categories Management - Hierarchical categories with subcategories
- Multi-Currency Support - BDT, USD, EUR, GBP with switching
- Payment Gateways - Configure multiple gateways with sandbox mode
- Shipping & Tax - Configure rates for Bangladeshi divisions/districts
- Email & SMS OTP - Multiple SMS providers support
- Storage & CDN - S3, Cloudflare R2, DigitalOcean Spaces, Wasabi, Backblaze B2
- Site Settings - SEO, Schema.org, Sitemap, Newsletter, Reviews
- Backup & Restore - Export/import products, WordPress/Shopify import
- Pages Management - Create and manage static pages
If you prefer manual installation instead of the web installer:
- Environment setup:
cp .env.example .env
php artisan key:generate- Configure database in
.env:
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=ecommerce_laravel
DB_USERNAME=your_username
DB_PASSWORD=your_password- Run migrations and seeders:
php artisan migrate --seed- Build assets (optional):
npm run build
# or for development
npm run dev- Start server:
php artisan serveVisit http://localhost:8000 and login with default credentials.
Configure from Admin β Payment Gateways:
- bKash - Mobile banking (Tokenized Checkout API) - Sandbox credentials pre-configured
- Nagad - Mobile banking - Sandbox mode supported
- Rocket - Mobile banking - Sandbox mode supported
- SSL Commerce - Card payments - Test store credentials pre-configured
- Stripe - Card payments - Test keys pre-configured
- PayPal - Online payments - Sandbox mode supported
- Cash on Delivery (COD) - Always available
All gateways support sandbox/test mode for testing. Default test credentials are seeded automatically.
Configure from Admin β Shipping Settings:
- Enable/disable shipping
- Flat rate shipping
- Free shipping threshold
- Division-based rates (flat or percentage)
- District-based rates (flat or percentage)
- Tax settings (flat or percentage)
- Default currency: BDT (ΰ§³) - Pre-configured with BDT, USD, EUR, GBP
Bangladesh Address System:
- Complete Division, District, and Upazila data seeded automatically
- Address fields support all administrative levels
- Email Settings: Admin β Email Settings (SMTP configuration with cPanel auto-detection)
- OTP Settings: Admin β OTP Settings (Email & SMS OTP with multiple SMS providers: Twilio, Vonage, MessageBird, AWS SNS, Clickatell, Plivo, Laravel BDSMS, Custom)
- Image Upload: Drag-and-drop multiple images with preview
- Image Management: Reorder, set primary, delete images
- HTML Descriptions: Rich HTML content with Quill Editor (image/video options removed)
- Subcategories: Hierarchical category system with parent/child relationships
- Select2 Search: Enhanced dropdowns with search functionality
- Product Factory: Generates sample products with images automatically during seeding
The products page includes a powerful filtering system:
- Collapsible Filters: Filters are hidden by default, click "Show Filters" to expand
- Product Name Search: Select2 AJAX search - type to find products instantly
- Category Filter: Select parent categories with Select2 search
- Subcategory Filter: Automatically loads when category is selected
- Stock Status: Filter by In Stock, Out of Stock, or Low Stock (<10 items)
- Featured Filter: Show only featured or non-featured products
- Sale Status: Filter products on sale or regular price
- Price Range: Set minimum and maximum price filters
- Status Filter: Filter by Active or Inactive products
- Visual Indicators: All filters show "ALL" when no filter is applied
- Auto Reset: All filters reset on page reload
- Clear Filters: One-click button to clear all filters
- Coupon Types: Percentage or fixed amount discounts
- Usage Limits: Global and per-user usage limits
- Minimum Amount: Set minimum order value requirements
- Maximum Discount: Cap discount amounts for percentage coupons
- Validity Period: Start and expiration dates
- Category/Product Specific: Apply coupons to specific categories or products
- Pre-seeded Coupons: 5 sample coupons created during seeding (WELCOME10, SAVE20, FREESHIP, HOLIDAY25, STUDENT15)
Configure from Admin β Storage & CDN:
- Local Storage (default)
- AWS S3
- Cloudflare R2 (S3-compatible)
- DigitalOcean Spaces (S3-compatible)
- Wasabi (S3-compatible)
- Backblaze B2 (S3-compatible)
- CDN Support - Configure CDN URL for static assets
- List View: Enhanced DataTable with images, categories, prices, stock
- Advanced Filters: Collapsible filter section with multiple filter options
- Product Search: Select2 AJAX search for quick product finding
- Image Display: Product thumbnails in table view
- Bulk Actions: Export to CSV (all data or current view)
- Create/Edit: Rich form with Select2 dropdowns, Quill Editor, image management
- Product Images: Small thumbnails displayed in table
- Category Display: Shows parent category and subcategory separately
- Price Columns: Current Price and Original Price (centered alignment)
- Stock Badges: Color-coded badges (green for in stock, red for out of stock)
- Action Buttons: Consistent button group styling across all tables
- CSV Export: Export all data or current filtered view
- Server-Side Processing: Fast loading even with thousands of products
- Categories: Hierarchical with subcategories, shows all categories/subcategories
- Orders: View and manage customer orders
- Users: Manage customer accounts, coins, referrals
- Coupons: Create discount codes with usage limits
- Currencies: Multi-currency support with switching
- Roles & Permissions: Complete RBAC system
- Payment Gateways: Configure with sandbox/test mode
- Shipping Settings: Bangladeshi divisions/districts support
- Email & SMS: SMTP and multiple SMS providers
- Storage & CDN: S3-compatible storage options
- Site Settings: SEO, Schema.org, Sitemap configuration
- Backup & Restore: Export/import products, WordPress/Shopify import
- Pages: Manage static pages
- Automatic Permission Discovery: All admin routes are automatically discovered and permissions created
- Super Admin Role: Pre-configured with all permissions
- Route-Based Permissions: Each admin route requires specific permission
- Permission Middleware:
admin.permissionmiddleware checks route permissions automatically
The application includes a built-in license validation system to protect against unauthorized use:
- License Key Management: Activate and manage license keys from Admin β Site Settings β Theme tab
- Remote Validation: Validates license with your server (optional)
- Offline Mode: 7-day grace period if license server is unreachable
- Domain Locking: License can be tied to specific domain
- Automatic Checks: Validates every 24 hours
- License Removal: Option to remove active license from admin panel
-
Run Migration:
php artisan migrate
-
Activate License:
- Visit Admin β Site Settings β Theme tab
- Enter your license key and click "Validate"
- Or visit
/admin/license/activatefor dedicated activation page
-
Enable License Middleware (Optional):
- Edit
bootstrap/app.phpand uncommentCheckLicensemiddleware - This will block frontend and admin access without a valid license
- Edit
-
License Server (Optional):
- Update
app/Support/LicenseHelper.phpwith your license server URL - Server should accept POST with
license_keyanddomain, return JSON:{"valid": true/false}
- Update
For additional protection, consider:
- Code Obfuscation: Use IonCube Encoder or Zend Guard for PHP encryption
- Domain Restrictions: Add domain/IP whitelisting in middleware
- Legal Protection: Create license agreements and copyright notices
- Monitoring: Log license validation attempts and track usage
Note: Complete code protection is impossible for interpreted languages like PHP. The goal is to make unauthorized use difficult and legally risky, not impossible.
MIT License - see LICENSE file
After running php artisan migrate --seed or using the installer, the following data is automatically created:
- 1 Admin Account - Super Admin role with all permissions
- Email:
needyamin@gmail.com(or custom if using installer) - Password:
needyamin@gmail.com(or custom if using installer)
- Email:
- 1 User Account - Test customer account (same credentials as admin)
- 6 Parent Categories - Electronics, Clothing, Books, Home & Garden, Sports, Toys
- Multiple Subcategories - Under each parent category
- 72 Products - 12 products per category
- Each product includes: name, description, price, stock, SKU
- Featured products included
- Products with sale prices (compare_at_price)
- 216 Product Images - 3 images per product
- Images are automatically generated/assigned
- Primary images are set
- 4 Currencies - BDT (ΰ§³), USD ($), EUR (β¬), GBP (Β£)
- BDT set as default currency
- 5 Sample Coupons:
WELCOME10- 10% off (Welcome coupon)SAVE20- 20% offFREESHIP- Free shippingHOLIDAY25- 25% off (Holiday special)STUDENT15- 15% off (Student discount)
- 8 Divisions - All administrative divisions of Bangladesh
- 64 Districts - All districts under divisions
- 500+ Upazilas - All upazilas under districts
- 124+ Route Permissions - All admin routes automatically discovered
- 1 Super Admin Role - With all permissions assigned
- Default Pages - About Us, Terms & Conditions, Privacy Policy, etc.
- Payment Gateway Settings - Pre-configured with test/sandbox credentials
- Email Settings - SMTP configuration template
- OTP Settings - Email and SMS OTP providers configured
- β Advanced Product Filters - Collapsible filter section with Select2 search
- β Product Name Search - AJAX-powered product search with Select2
- β Enhanced DataTables - Product images, improved columns, better styling
- β Button Group Styling - Consistent action buttons across all tables
- β Filter Auto-Reset - Filters reset on page reload
- β "ALL" Indicators - Clear visual feedback when no filters are applied
- β Category Improvements - Shows all categories/subcategories, removed slug column
- β Price Display - Original Price column (renamed from Compare at Price)
- β Centered Columns - Image, Price, and Original Price columns centered
- β Stock Badges - Color-coded stock quantity indicators
Email: needyamin@gmail.com or create an issue on GitHub.
Built with β€οΈ using Laravel 12