Commit graph

538 commits

Author SHA1 Message Date
b7b22a8893
chore(repo): add PR template and README, retire stale root files
The org PR template pre-filled Summary / Validation / Tests / Notes here while
REVIEW_AND_PR_FRAMEWORK.md section 8 prescribes Summary / Changes and value /
Ticket. A repo template now overrides the org one, and the framework notes the
divergence from the org pr-policy workflow, which is not wired in.

README.md orients a reader: environments, architecture in one line, project
map, local commands, the governance gate, deployment, and a documentation map.

Cleanup: TODO.md is removed because Jira owns work status and its items are
stale or done. BACKEND_ARCHITECTURE.md is removed as superseded; the two
references now point at git history. .env.example loses its BOM and mojibake
dashes. .gitattributes keeps its one active rule.
2026-09-18 19:05:30 -04:00
Adam Moussa
1888b66940
ci: run required checks on merge_group for the merge queue (#159)
Some checks are pending
Architecture and changed-file quality / architecture (push) Waiting to run
Backend CI / Build and test (push) Waiting to run
Build and test, architecture, and dependency-review are the required checks
on main. A merge queue only counts checks that ran on the merge_group event,
so each workflow now triggers on it. The architecture gate reads the merge
group's own base and head because github.event.before is empty there. The
dependency-review action cannot diff a merge group, so that event reports the
same check name from a pass-through job; the real review already gated the
pull request before it could be queued.
2026-09-18 18:16:10 -04:00
Adam Moussa
4fb4159df2
fix(iam): scope staging githubdeploy uploads to the staging release prefix (#158)
Some checks are pending
Architecture and changed-file quality / architecture (push) Waiting to run
Terraform CI / terraform (push) Waiting to run
Backend CI / Build and test (push) Waiting to run
2026-09-18 17:10:13 -04:00
Adam Moussa
9eb51b528f
chore(terraform): complete staging environment adoption (#156)
Some checks are pending
Architecture and changed-file quality / architecture (push) Waiting to run
Terraform CI / terraform (push) Waiting to run
Backend CI / Build and test (push) Waiting to run
* chore(terraform): complete staging environment adoption

* test(terraform): include deploy SSM parameters in the import ownership boundary
2026-09-18 15:13:18 -04:00
Adam Moussa
facc6ef71e
fix(iam): let staging githubdeploy GetObject the release zip (#154)
Some checks are pending
Architecture and changed-file quality / architecture (push) Waiting to run
Terraform CI / terraform (push) Waiting to run
Backend CI / Build and test (push) Waiting to run
* fix(iam): let staging githubdeploy GetObject the release zip

* fix(iam): allow staging githubdeploy to cache EB processed extensions

* fix(iam): allow staging githubdeploy GetObjectAcl for EB updates

* fix(iam): grant staging githubdeploy named S3 reads on EB resources prefix

* fix(iam): allow staging githubdeploy to delete EB version cache objects

* fix(iam): scope staging githubdeploy S3 object access to the EB bucket

* fix(iam): allow staging githubdeploy PutObjectVersionAcl on EB artifacts

* fix(iam): allow staging githubdeploy GetBucketPolicy on the EB bucket

* fix(iam): scope staging githubdeploy S3 objects to SHOC and staging EB prefixes
2026-09-18 15:29:15 -03:00
Adam Moussa
90303f0e40
Merge pull request #153 from Sea-Haven-Industries/chore/retire-leftover-app-cd
Some checks are pending
Architecture and changed-file quality / architecture (push) Waiting to run
Terraform CI / terraform (push) Waiting to run
Backend CI / Build and test (push) Waiting to run
chore(cd): retire leftover Terraform app CD path
2026-09-18 13:08:07 -04:00
b696a414a5
fix(cd): grant caller id-token write for reusable deploy workflows 2026-09-18 12:42:42 -04:00
f42576e2db
chore(cd): retire leftover Terraform app CD path 2026-09-18 12:38:15 -04:00
Adam Moussa
68ad7362df
Merge pull request #150 from Sea-Haven-Industries/dev
Some checks are pending
Architecture and changed-file quality / architecture (push) Waiting to run
Terraform CI / terraform (push) Waiting to run
Backend CI / Build and test (push) Waiting to run
chore: promote GitHub-owned Elastic Beanstalk CD onto main
2026-09-18 11:52:35 -04:00
23f69307dd
chore: sync main into dev after #147
Some checks failed
Validate and deploy / Validate deployable source bundle (push) Has been cancelled
Validate and deploy / Deploy shoc-backend-dev through Terraform (push) Has been cancelled
Validate and deploy / Deploy shoc-backend-staging through Terraform (push) Has been cancelled
2026-09-18 11:44:02 -04:00
Adam Moussa
e74fff7722
Merge pull request #148 from Sea-Haven-Industries/refactor/main-branch-cd
refactor(cd): ship Elastic Beanstalk versions from GitHub on main
2026-09-18 11:43:03 -04:00
Adam Moussa
60a3fcc308
Merge pull request #147 from Sea-Haven-Industries/dev
chore: promote current dev onto main
2026-09-18 11:42:50 -04:00
396b1c690b
fix(cd): honor reusable workflow inputs when resolving deploy target 2026-09-18 11:33:34 -04:00
7eaa7fb3f9
docs(cd): document GitHub Environment branch and tag policies 2026-09-18 11:22:50 -04:00
8f4fa36647
refactor(cd): ship Elastic Beanstalk versions from GitHub on main
Keep application and Terraform changes in separate PRs so a merge cannot race an HCP apply against an app deploy.
2026-09-17 15:54:31 -04:00
Alexandre Brandizzi
63f80990cf
Merge pull request #144 from Sea-Haven-Industries/feat/ab/sh-207-uplift-queue-flags
Some checks are pending
Validate and deploy / Validate deployable source bundle (push) Waiting to run
Validate and deploy / Deploy shoc-backend-dev through Terraform (push) Blocked by required conditions
Validate and deploy / Deploy shoc-backend-staging through Terraform (push) Blocked by required conditions
SH-207: Complete uplift queue list contract (closed flag, attachments, decider, pending exposure)
2026-09-17 14:30:23 -03:00
Adam Moussa
8dfb01cba7
Merge branch 'dev' into feat/ab/sh-207-uplift-queue-flags 2026-09-17 13:22:38 -04:00
Alexandre Brandizzi
d02aa11285
Merge pull request #124 from Sea-Haven-Industries/fix/ab/sh-287-backend-staging-lane
feat(deploy): rebuild protected backend staging lane
2026-09-17 14:22:11 -03:00
Adam Moussa
b9bcaea9f3
Merge branch 'dev' into feat/ab/sh-207-uplift-queue-flags 2026-09-17 13:17:04 -04:00
Alexandre Brandizzi
5e70163941
Merge branch 'dev' into fix/ab/sh-287-backend-staging-lane 2026-09-17 14:16:10 -03:00
Alexandre Brandizzi
455ff5568c
Merge pull request #139 from Sea-Haven-Industries/feat/ab/sh-326-team-member
SH-326: add team member detail editing
2026-09-17 14:14:11 -03:00
Alexandre Brandizzi
6db9ad758f
Merge branch 'dev' into fix/ab/sh-287-backend-staging-lane 2026-09-17 14:10:11 -03:00
Alexandre Brandizzi
8a4de283dc Merge remote-tracking branch 'origin/dev' into feat/ab/sh-326-team-member
# Conflicts:
#	Api.SeaHavenIndustries.Tests/TeamMemberServiceTests.cs
#	SeaHaven.DataServices/Implementation/TeamPermissionOverrideDataService.cs
2026-09-17 14:06:12 -03:00
Alexandre Brandizzi
0dc9ec288e
Merge pull request #137 from Sea-Haven-Industries/feat/ab/sh-325-create-team-member
SH-325: support pending team member creation
2026-09-17 14:00:18 -03:00
1a290ea2f7
Merge remote-tracking branch 'origin/dev' into HEAD 2026-09-17 12:50:09 -04:00
Alexandre Brandizzi
bc88ef0577 Merge remote-tracking branch 'origin/dev' into feat/ab/sh-326-team-member 2026-09-17 13:49:21 -03:00
Alexandre Brandizzi
2657be3108
Merge pull request #135 from Sea-Haven-Industries/feat/ab/sh-329-account-owner
Some checks are pending
Validate and deploy / Validate deployable source bundle (push) Waiting to run
Validate and deploy / Deploy shoc-backend-dev through Terraform (push) Blocked by required conditions
Validate and deploy / Deploy shoc-backend-staging to Elastic Beanstalk (push) Blocked by required conditions
SH-329: protect configured account owner
2026-09-17 13:44:13 -03:00
Adam Moussa
1f905fc7dd
Merge branch 'dev' into feat/ab/sh-329-account-owner 2026-09-17 12:36:26 -04:00
Alexandre Brandizzi
45519c1a82
Merge pull request #140 from Sea-Haven-Industries/feat/ab/sh-207-uplift-queue
SH-207: Deliver the uplift approval queue read contract
2026-09-17 13:28:16 -03:00
Alexandre Brandizzi
7b94ab9455 Merge remote-tracking branch 'origin/dev' into feat/ab/sh-207-uplift-queue 2026-09-17 13:05:07 -03:00
Alexandre Brandizzi
41957d52a7 merge: rebase queue flags onto SH-210 decisions, drop duplicated contract fields
#144 branched from the SH-210 decision-actions commit before the SH-207/SH-208
read-contract corrections landed, so it re-implemented workOrderClosed,
attachmentCount, decidedByName, and pendingExposureTotal with stale semantics:
it projected WorkerOrderNumber (the CRM external id) instead of InternalWONumber
(what the board renders) and summed raw RequestedNTE, which double-counts the new
NTE total on vendor-portal rows across sequential approvals.

Merge origin/feat/ab/sh-210-uplift-decisions (#141, what lands) in and resolve
every conflict in #141's favour, so those fields and their granted-amount
exposure math now come from #141 rather than being duplicated here. Keep only the
two deltas #144 actually adds on top of #141:

- attachmentCount counts non-deleted UpliftEvidence documents on the dispatch,
  not every completion document, so completion photos no longer inflate the chip;
- the queue read resolves the effective work order via the primary-plus-linked
  (DispatchWorkOrders) convention the sibling reads use, so a dispatch linked only
  through that table surfaces its WO context, closed flag, and exposure. Covered
  by an in-memory test and a SQLite relational test that proves the fallback
  translates to SQL.

Drop the superseded attachment-count test that asserted completion documents
count, and align the relational test to seed InternalWONumber.
2026-09-17 12:52:13 -03:00
Alexandre Brandizzi
0ae64f9ab9
Merge pull request #141 from Sea-Haven-Industries/feat/ab/sh-210-uplift-decisions
SH-210: Route uplift decisions through the work-order flow
2026-09-17 12:50:22 -03:00
Alexandre Brandizzi
046dee99bf
Merge branch 'dev' into feat/ab/sh-207-uplift-queue 2026-09-17 12:44:15 -03:00
Alexandre Brandizzi
679822733a
Merge branch 'dev' into feat/ab/sh-210-uplift-decisions 2026-09-17 12:44:12 -03:00
Alexandre Brandizzi
cc9a5ade21
Merge pull request #146 from Sea-Haven-Industries/feat/ab/sh-348-region-filter
SH-348: Work Orders board region filter
2026-09-17 12:42:12 -03:00
Alexandre Brandizzi
f4860a3dd9
Merge branch 'dev' into feat/ab/sh-348-region-filter 2026-09-17 12:36:15 -03:00
Adam Moussa
ef371b5917
Merge branch 'dev' into feat/ab/sh-210-uplift-decisions 2026-09-17 11:35:00 -04:00
Alexandre Brandizzi
3e301ac9da
Merge pull request #145 from Sea-Haven-Industries/feat/ab/sh-347-dashboard-contract
Some checks are pending
Validate and deploy / Validate deployable source bundle (push) Waiting to run
Validate and deploy / Deploy shoc-backend-dev through Terraform (push) Blocked by required conditions
Validate and deploy / Deploy shoc-backend-staging to Elastic Beanstalk (push) Blocked by required conditions
SH-347: Scoped dashboard metrics contract
2026-09-17 12:34:22 -03:00
Alexandre Brandizzi
1eadb82f28
Merge branch 'dev' into feat/ab/sh-210-uplift-decisions 2026-09-17 12:30:20 -03:00
Alexandre Brandizzi
ba8907fad0 fix(team-members): keep full-name round-trip stable on update
Storing the submitted full name in FirstName while leaving a seeded
LastName intact made an unchanged save project a duplicated name
(e.g. "Legacy Manager Manager"). Leave FirstName/LastName untouched when
the submitted name already matches the stored first+last projection, and
otherwise split the submitted name across FirstName/LastName so renames
round-trip cleanly.
2026-09-17 04:22:02 -03:00
Alexandre Brandizzi
9388e7a987 style(uplift): fix comment indentation in queue list query 2026-09-17 03:56:18 -03:00
Alexandre Brandizzi
468522c3f7 fix(uplift): resolve linked-only work order in queue list read
GetPagedAsync resolved WorkOrderNumber/Site/Service, WorkOrderClosed, and
WorkOrderId only through Dispatch.WorkOrderId, so a dispatch linked to its
work order solely through DispatchWorkOrders surfaced blank WO context,
workOrderClosed:false, and zero exposure. Resolve the effective work order
using the same primary-plus-linked convention as GetWorkOrderIdForUpliftAsync
and GetApprovedExposureForWorkOrdersAsync via a single work-order lookup.
2026-09-17 03:47:09 -03:00
Alexandre Brandizzi
564bd70301 fix(dashboard): scope Trend by picker and admit Scheduler to dispatcher picker
ResolveDispatcherScope now admits the Scheduler role, which owns the
viewAllDispatchersOnDashboard permission, so it can load Stats, Workload,
Performance, Regions and Trend instead of being denied.

GetTrendAsync now resolves scope via the shared ResolveDispatcherScope so a
picker DispatcherId selection scopes Trend consistently with the other
endpoints and unauthorized roles fail closed.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-09-17 03:37:36 -03:00
Alexandre Brandizzi
146fe6fdb0 style: satisfy dotnet format whitespace gate for region board files
Break collection initializer entries onto one line each in
WorkOrderBoardRegions and WorkOrderBoardSearchTests so the changed-file
formatting gate (dotnet format --verify-no-changes) passes.
2026-09-17 02:26:19 -03:00
Alexandre Brandizzi
5c93e4ecec Merge remote-tracking branch 'origin/dev' into feat/ab/sh-348-region-filter
# Conflicts:
#	SeaHaven.Services/Helpers/DashboardRegions.cs
2026-09-17 02:20:44 -03:00
Alexandre Brandizzi
f564e1b112 Merge remote-tracking branch 'origin/dev' into feat/ab/sh-347-dashboard-contract
# Conflicts:
#	Api.SeaHavenIndustries.Tests/DashboardServiceTests.cs
2026-09-17 02:18:22 -03:00
Alexandre Brandizzi
daf3ed9210 fix(team-members): map duplicate-email race to conflict error (SH-325)
CreateAsync checks FindByEmailAsync and then inserts, so two concurrent
creates with the same email can both pass the check and hit the unique
user-name index. That DbUpdateException was unhandled and surfaced as a
500. Catch it at the CreateAsync call and return the existing
"Email is already in use." message, matching the check-then-insert
converge pattern already used by SetOverrideCoreAsync.
2026-09-17 01:40:40 -03:00
Alexandre Brandizzi
782165a4cf
Merge pull request #133 from Sea-Haven-Industries/feat/ab/sh-348-dashboard-region
Some checks are pending
Validate and deploy / Validate deployable source bundle (push) Waiting to run
Validate and deploy / Deploy shoc-backend-dev through Terraform (push) Blocked by required conditions
Validate and deploy / Deploy shoc-backend-staging to Elastic Beanstalk (push) Blocked by required conditions
SH-348: Add dashboard region metrics
2026-09-17 01:36:09 -03:00
Alexandre Brandizzi
7e06d1c51b
Merge branch 'dev' into feat/ab/sh-348-dashboard-region 2026-09-17 01:30:08 -03:00
Alexandre Brandizzi
e07f04a6af
Merge pull request #131 from Sea-Haven-Industries/feat/ab/sh-187-service-picker
SH-187: Connect work-order service selection to the registry
2026-09-17 01:28:09 -03:00