This Laravel backend serves as the core of our e-commerce platform, handling server-side logic, data storage, and providing API endpoints for our React.js frontend. It includes features such as user authentication, product management, and order processing.
app/
: Contains the application's core logic and models.routes/
: Contains route definitions.database/
: Stores migrations and seeders for database management.storage/
: Image is Uploaded.actions/
: Actions to be executed when creating or updating database actions.
users
: Stores user information.products
: Contains product details.categories
: Manages product categories.
- Define the relationships between tables here.
List and briefly explain the API routes available in your Laravel backend. Include endpoints for user authentication, product listing, product details, order management, and any other significant features.
POST /api/auth/register
: Register a new user.POST /api/auth/login
: Authenticate and log in a user.GET /api/products
: Retrieve a list of products.GET /api/products/{id}
: Retrieve product details by ID.POST /api/orders
: Create a new order.
-
Clone the repository:
git clone ABDALLAH-ATGUIRI/e-commerce-laravel
-
Enter the Project directory
cd e-commerce-laravel
-
Install PHP dependencies using Composer:
composer install
-
Configure the .env file with your database credentials and other necessary environment variables.
-
Run database migrations and seed data if needed using:
php artisan migrate --seed
-
Start the Laravel development server:
php artisan serve
- gh repo clone ABDALLAH-ATGUIRI/e-commerce-react