Skip to content

ANcpLua/TourPlanner

Repository files navigation

TourPlanner (Blazor)

Tests and Coverage codecov

SWEN2 2026 -- Tour planning application with .NET 10 backend and Blazor WebAssembly frontend.

Quick Start (Docker)

Requires Docker or OrbStack.

docker compose up -d
Service URL
Frontend http://localhost:7226
API http://localhost:7102
pgAdmin http://localhost:5050
Health http://localhost:7102/health

pgAdmin login: admin@admin.com / admin

Open the frontend and register an account — all tour data is user-scoped.

To stop:

docker compose down

Port conflicts

If any port is already in use, copy the example env file and adjust:

cp .env.example .env
# edit .env, then:
docker compose up -d

Local Development

Prerequisites

  • .NET SDK 10.0
  • Docker or OrbStack (for PostgreSQL)

Steps

  1. Start the database:
docker compose up -d postgres
  1. Start the API:
dotnet run --project API/API.csproj
  1. Start the Blazor client (separate terminal):
dotnet run --project UI.Client/UI.Client.csproj

Open http://localhost:7226, register an account, and log in.

Build

dotnet build

Tests

dotnet run --project Tests/Tests.csproj

Architecture

See ARCHITECTURE.md for layer ownership rules.

Project Responsibility
UI.Client Blazor WASM, ViewModels, components
API HTTP endpoints, transport validation
BL Business rules, orchestration
DAL Persistence, external service access
Contracts Shared DTOs (including auth models)
Tests Unit tests across all layers

Authentication

Cookie-based auth via ASP.NET Core Identity. All tour and log data is scoped to the authenticated user.

Endpoint Description
POST /api/account/register Create account
POST /api/account/login Sign in (sets cookie)
POST /api/account/logout Sign out
GET /api/account/me Current user info

All other API endpoints require authentication (return 401 without a valid session cookie).

AI Policy

AI may be used as a pair-programming and review assistant. Every submitted change must be understood by the student who submits it. Students must be able to explain what changed, why, and which project owns the responsibility.

About

2023/2024 SWEN2

Topics

Resources

License

Stars

6 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors