Skip to content

Commit 3b33893

Browse files
author
Diogo Ferraz
committed
Merge branch 'feat-spa-refactor-server-connection'
2 parents 9e2f6ac + ed10cef commit 3b33893

145 files changed

Lines changed: 31175 additions & 1923 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 31 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,44 @@
11
# TaskManagementClient
22

3-
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 18.2.11.
3+
Angular SPA for a Jira-style task management system, integrated with an existing .NET 8 backend.
44

5-
## Development server
5+
## Highlights
66

7-
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The application will automatically reload if you change any of the source files.
7+
- OIDC authentication (Authorization Code + PKCE) against OpenIddict
8+
- Role-aware UX for `Administrator`, `ProjectManager`, and `User`
9+
- Real-time activity updates via SignalR
10+
- Project Kanban board with drag/drop and inline task editing
11+
- Dashboard, calendar, search/filters, admin tools, activity views, and settings
12+
- Preview mode support for frontend-only workflows
813

9-
## Code scaffolding
14+
## Tech Stack
1015

11-
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
16+
- Angular 18 (standalone components)
17+
- PrimeNG UI
18+
- RxJS
19+
- SignalR JavaScript client
1220

13-
## Build
21+
## Architecture
1422

15-
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory.
23+
- `src/app/core`: auth, api clients, config, layout, realtime, preferences
24+
- `src/app/features`: page-level feature components by domain
25+
- `src/app/shared`: shared module and reusable UI pieces
1626

17-
## Running unit tests
27+
The SPA is API-contract-first: typed DTOs and clients are aligned with backend endpoints.
1828

19-
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
29+
## Sidebar Information Architecture
2030

21-
## Running end-to-end tests
31+
- Overview: Dashboard
32+
- Workspaces: Projects, Project Details, Project Members, Kanban
33+
- Delivery: All Tasks, My Tasks, Create Task
34+
- Activity: My Activity, Activity Log, Calendar, Search & Filters
35+
- Account: Profile & Security, Settings
36+
- Administration: Admin Dashboard
37+
- About: Project Docs
2238

23-
Run `ng e2e` to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.
39+
## Run
2440

25-
## Further help
26-
27-
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.dev/tools/cli) page.
41+
- Install dependencies: `npm install`
42+
- Development server: `npm start`
43+
- Build: `npm run build`
44+
- Tests: `npm test`

angular.json

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@
2929
{
3030
"glob": "**/*",
3131
"input": "public"
32+
},
33+
{
34+
"glob": "**/*",
35+
"input": "src/assets",
36+
"output": "assets"
3237
}
3338
],
3439
"styles": [
@@ -58,7 +63,13 @@
5863
"development": {
5964
"optimization": false,
6065
"extractLicenses": false,
61-
"sourceMap": true
66+
"sourceMap": true,
67+
"fileReplacements": [
68+
{
69+
"replace": "src/environments/environment.ts",
70+
"with": "src/environments/environment.development.ts"
71+
}
72+
]
6273
}
6374
},
6475
"defaultConfiguration": "production"
@@ -91,6 +102,11 @@
91102
{
92103
"glob": "**/*",
93104
"input": "public"
105+
},
106+
{
107+
"glob": "**/*",
108+
"input": "src/assets",
109+
"output": "assets"
94110
}
95111
],
96112
"styles": [

docs/SPA_ARCHITECTURE_PLAN.md

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
# SPA Architecture Plan (Angular + .NET 8 API)
2+
3+
## Current architecture status
4+
- Angular standalone-first architecture is active (no feature NgModules used in runtime).
5+
- Clear boundaries are in place:
6+
- `core`: auth, api clients/models, config, layout, realtime, preferences.
7+
- `shared`: shared module + reusable cross-feature UI.
8+
- `features`: page-level domain slices.
9+
- API contracts are typed and aligned under `core/api/models` and consumed through `core/api/clients`.
10+
- RxJS is used for async/server orchestration; Signals/computed are used for local/session/preferences state.
11+
12+
## Implemented folder structure
13+
- `src/app/core/config`: app environment token + runtime config plumbing.
14+
- `src/app/core/auth`: OIDC PKCE auth service + guards (`auth`, `admin`, `managerOrAdmin`).
15+
- `src/app/core/http`: query param/url helpers and HTTP integration utilities.
16+
- `src/app/core/api`: typed DTOs + API clients (`projects`, `taskitems`, `activity`, `dashboard`, `users`).
17+
- `src/app/core/realtime`: SignalR hub integration for activity feed/log updates.
18+
- `src/app/core/preferences`: persisted app preferences service (density/date/notification/kanban defaults).
19+
- `src/app/features`: dashboard, projects, tasks, search, calendar, activity, profile, settings, docs, admin.
20+
21+
## Routing and authorization (implemented)
22+
- Public routes:
23+
- `/` (landing)
24+
- `/login`
25+
- `/callback`
26+
- Protected routes:
27+
- dashboard/workspaces/delivery/activity/account/about.
28+
- Role-restricted routes:
29+
- `/admin` -> `Administrator`.
30+
- `/activity/log` -> `Administrator` or `ProjectManager`.
31+
32+
## Sidebar information architecture (current)
33+
- Overview: Dashboard
34+
- Workspaces: All Projects, Project Details, Project Members, Create Project, Kanban
35+
- Delivery: All Tasks, My Tasks, Create Task
36+
- Activity: My Activity, Activity Log, Calendar, Search & Filters
37+
- Account: Profile & Security, Settings
38+
- Administration: Admin Dashboard
39+
- About: Project Docs
40+
41+
## Core feature status
42+
- Auth foundation:
43+
- OIDC Authorization Code + PKCE, callback handling, guarded routes.
44+
- Dashboard:
45+
- Summary KPIs + activity history + SignalR live updates + preview fallback.
46+
- Kanban:
47+
- Project picker, grouped status columns, drag/drop, create/edit dialogs, optimistic patch flows.
48+
- Search & filters:
49+
- Cross-entity filtering flows aligned with current API clients.
50+
- Project tools:
51+
- All Projects, Project Details, Project Members.
52+
- Task tools:
53+
- All Tasks, My Tasks, Create Task.
54+
- Activity tools:
55+
- My Activity (personal timeline) + Activity Log (admin/pm audit).
56+
- Account:
57+
- Profile & Security, Settings (persisted app preferences).
58+
59+
## Contract alignment rules (enforced)
60+
- Frontend uses backend enums/contracts from typed models (no ad-hoc enum invention).
61+
- Patch semantics preserve omitted vs `null` behavior.
62+
- Date values sent to API follow ISO conventions.
63+
- Problem Details responses are surfaced consistently at UI layer.
64+
65+
## Quality and cleanup status
66+
- Legacy scaffold artifacts removed:
67+
- unused dummy services (`ProjectService`, `TaskItemService`, `LoginService`) and associated specs.
68+
- empty unused feature modules (`projects.module.ts`, `task-item.module.ts`).
69+
- UI consistency pass completed across major pages:
70+
- header card + kpi cards + main content card patterns.
71+
- PrimeNG built-in table filter strategy on table-centric pages.
72+
73+
## Known backend/API gaps worth addressing
74+
- Activity endpoint filtering:
75+
- Current contract used by SPA does not expose server-side actor/type/date filters.
76+
- Activity Log currently applies these filters client-side after fetching feed data.
77+
- Authorization matrix check:
78+
- `GET /api/projects/{id}` policy should be verified against intended `User` read capabilities.

0 commit comments

Comments
 (0)