ShopRide is a web-based platform that enables bicycle shop owners to organize, manage, and host group cycling rides while allowing cyclists to discover and register for rides in their area.
- Frontend: React 18 with TypeScript, Vite, and Tailwind CSS
- Backend: ASP.NET Core 9 Web API with Minimal APIs
- Database: SQL Server with Entity Framework Core
- Authentication: ASP.NET Core Identity with JWT tokens
shopride/
├── docs/ # Documentation
│ ├── shopride-specification.md # Complete feature specification
│ ├── implementationplan1.md # Implementation plan
│ └── RequirementsShopRides.pdf # Original requirements
├── src/
│ ├── frontend/shopride-web/ # React TypeScript frontend
│ │ ├── src/
│ │ │ ├── App.tsx # Main React component
│ │ │ ├── main.tsx # React entry point
│ │ │ └── index.css # Tailwind CSS styles
│ │ ├── tailwind.config.js # Tailwind configuration
│ │ ├── vite.config.ts # Vite configuration
│ │ └── package.json # Frontend dependencies
│ └── backend/ShopRide.Api/ # ASP.NET Core Web API
│ ├── Models/ # Data models
│ │ ├── ApplicationUser.cs # User model (extends Identity)
│ │ ├── Shop.cs # Shop entity
│ │ ├── Ride.cs # Ride entity
│ │ └── Registration.cs # Registration entity
│ ├── Data/
│ │ └── ApplicationDbContext.cs # Entity Framework context
│ ├── Program.cs # API configuration
│ └── appsettings.json # Configuration settings
-
ApplicationUser (extends IdentityUser)
- Custom user properties (FirstName, LastName)
- Navigation to Shop (for shop owners)
- Navigation to Registrations
-
Shop
- Shop details (Name, Description, Address, Contact Info)
- Business information (Hours, Services, Logo)
- One-to-one relationship with ApplicationUser (Owner)
- One-to-many relationship with Rides
-
Ride
- Ride details (Title, Description, DateTime, Location)
- Ride properties (Difficulty, MaxParticipants, Distance)
- Route information (Description, GPX file)
- Status management (Draft, Published, Cancelled, Completed)
- Many-to-one relationship with Shop
- One-to-many relationship with Registrations
-
Registration
- User registration for rides
- Status tracking (Confirmed, Waitlisted, Cancelled)
- Attendance confirmation
- Unique constraint per user per ride
✅ Project Setup and Infrastructure
- Created React + TypeScript frontend with Vite build system
- Configured Tailwind CSS for styling
- Created ASP.NET Core 9 Web API with Minimal APIs
- Set up Entity Framework Core with SQL Server
- Configured development environment
- Integrated ASP.NET Core Identity for authentication
- Configured JWT Bearer authentication
- Set up CORS for frontend-backend communication
- Created comprehensive data models with relationships
- Configured Entity Framework relationships and constraints
✅ Database Schema and Models
- Designed core entities (User, Shop, Ride, Registration)
- Implemented Entity Framework Code First approach
- Configured proper relationships and constraints
- Set up enum properties for Difficulty and Status
- Added validation attributes and business rules
- .NET 9 SDK
- Node.js (v18 or later)
- SQL Server LocalDB or SQL Server instance
-
Navigate to the backend directory:
cd src/backend/ShopRide.Api
-
Restore packages:
dotnet restore
-
Create database migration:
dotnet ef migrations add InitialCreate dotnet ef database update
-
Run the API:
dotnet run
The API will be available at
https://localhost:7075
-
Navigate to the frontend directory:
cd src/frontend/shopride-web
-
Install dependencies:
npm install
-
Run the development server:
npm run dev
The frontend will be available at
http://localhost:5173
GET /api/health
- Returns API health statusGET /api/info
- Returns API information
- Implement user registration and login APIs
- Create frontend authentication components
- Set up protected routes
- Implement role-based authorization
- Create shop management APIs (CRUD operations)
- Build shop profile management UI
- Implement shop verification system
- Create ride management APIs
- Build ride creation and management UI
- Implement ride discovery and filtering
- Create registration APIs
- Build registration UI
- Implement capacity management and waitlists
- Connect frontend to backend APIs
- Implement state management
- Add error handling and loading states
- Implement email notification service
- Create notification templates
- Set up background job processing
The API uses JWT tokens for authentication. Configure the following in appsettings.json
:
{
"JwtSettings": {
"SecretKey": "YourSecretKey",
"Issuer": "ShopRideApi",
"Audience": "ShopRideWeb",
"ExpiryInHours": 24
}
}
Configure the database connection string in appsettings.json
:
{
"ConnectionStrings": {
"DefaultConnection": "Server=(localdb)\\mssqllocaldb;Database=ShopRideDb;Trusted_Connection=true;MultipleActiveResultSets=true;TrustServerCertificate=true"
}
}
Please refer to the implementation plan in docs/implementationplan1.md
for detailed development guidelines and next steps.
This project is part of a development exercise and is for educational purposes.