Repository navigation
Conversation
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
7cde8cc to
5b9ddf7
Compare
OpenNSW/core#443 adds the caseflow and caseparty packages to core/platform. Pinning to that PR's head lets the next commit switch over to them; the pin moves to the merge commit once #443 merges. The pin changes no other module version. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…form OpenNSW/core#443 moved the caseflow and caseparty packages into core/platform unchanged. Import them from there, delete internal/caseflow and internal/caseparty, and point the comments and docs/agency.md at the core packages. Behaviour is unchanged. Closes #1238 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
5b9ddf7 to
7ef5ef2
Compare
OpenNSW/core#443 adds the caseflow and caseparty packages to core/platform. Pinning to that PR's head lets the next commit switch over to them; the pin moves to the merge commit once #443 merges. The pin changes no other module version. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…form OpenNSW/core#443 moved the caseflow and caseparty packages into core/platform unchanged. Import them from there, delete internal/caseflow and internal/caseparty, and point the comments and docs/agency.md at the core packages. Behaviour is unchanged. Closes #1238 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
7ef5ef2 to
d73d195
Compare
OpenNSW/core#443 adds the caseflow and caseparty packages to core/platform. Pinning to that PR's head lets the next commit switch over to them; the pin moves to the merge commit once #443 merges. The pin changes no other module version. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…form OpenNSW/core#443 moved the caseflow and caseparty packages into core/platform unchanged. Import them from there, delete internal/caseflow and internal/caseparty, and point the comments and docs/agency.md at the core packages. Behaviour is unchanged. Closes #1238 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
d73d195 to
b2990c0
Compare
|
|
b2990c0 to
f5c3f94
Compare
| // ScopeFlowStart gates POST /api/v1/internal/cases/{caseId}/flows. Starting a client flow | ||
| // creates the case if it is new, so only a system trusted to do that holds it. It is an M2M | ||
| // permission, kept apart from the officer's task:* scopes. | ||
| const ScopeFlowStart = "workflow:inject" |
There was a problem hiding this comment.
Scopes should be defined in the nsw-srilanka/internal/scopes/scopes.go right?
Did we missed anything in the cleanup?
Also it's better to not mention like POST /api/v1/internal/cases/{caseId}/flows in the doc comments. Isn't Endpoint definitions should be defined at deployment repo?
There was a problem hiding this comment.
good catch, fell through the cracks
There was a problem hiding this comment.
fixed in OpenNSW/nsw-srilanka#1361, will pull here post merge to keep the core migration PRs clean
Byte-for-byte copies of nsw-srilanka's internal/caseflow and internal/caseparty at 3f01ae915fba51ec3a2a8b97acb91d61a03a2031 (branch refactor/1245-generic-case-wording, OpenNSW/nsw-srilanka#1339) into platform/, tests included. No other changes. They do not build until the import rewrite in the next commits. Part of OpenNSW/nsw-srilanka#1248 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…uire its dependencies
Mechanical, no other changes:
find platform/caseflow platform/caseparty -name '*.go' -print0 \
| xargs -0 perl -pi -e 's#"github.com/OpenNSW/nsw-srilanka/internal/caseparty"#"github.com/OpenNSW/core/platform/caseparty"#'
make license
cd platform && GOWORK=off go mod tidy
make license and core's pre-commit hook add the SPDX headers to the copied
files. go.mod changes in this commit because the hook lints and builds the
module, which loads only once the imports resolve and go.mod is tidy. go mod
tidy adds DATA-DOG/go-sqlmock v1.5.2, the version nsw-srilanka requires, for
the tests.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
f5c3f94 to
da33200
Compare
Summary
Moves nsw-srilanka's case flows (
caseflow) and case parties (caseparty) intocore/platform, unchanged. Phase 4 of OpenNSW/nsw-srilanka#1248, issue OpenNSW/nsw-srilanka#1238.The code was made generic in nsw-srilanka first (OpenNSW/nsw-srilanka#1339; OpenNSW/nsw-srilanka#1347 put
casepartyondatabase/sql). OpenNSW/nsw-srilanka#1361 then moved the one scope name to nsw-srilanka'sinternal/scopesand rewrote the handlers' comments to name the path values they read instead of route paths, so this PR copies it from nsw-srilanka'smainat OpenNSW/nsw-srilanka#1361's merge commit,d5b188df. A client flow starts with its variables undercaseflow.DefaultVarNames(flowId,workflowId,caseId,input,callbackToken), each named after the start request field or path parameter it holds, unless the host passescaseflow.WithVarNames.The tables stay in the host's migrations. First of three stacked PRs; the task API and then workflowadmin follow.
Type of Change
Changes Made
Review commit by commit.
6c93874internal/caseflowandinternal/casepartyintoplatform/caseflowandplatform/caseparty.b158b24casepartyimport tocore/platform/caseparty, adds the SPDX headers (make licenseand core's pre-commit hook), and runsgo mod tidy.go.mod: go-sqlmock is added for the tests, at nsw-srilanka's version. The rewrite andgo mod tidyshare a commit because core's hook needs both to build and lint.da33200platform/README.md.Blob check
Each file in
6c93874has the same blob as in nsw-srilanka atd5b188df(git rev-parse <commit>:<path>):internal/caseflow/client_handler.go38cb46ea0e48internal/caseflow/client_handler_test.goc41794a59b80internal/caseflow/config.go201907a81d42internal/caseflow/config_test.go4d4bdbbd8442internal/caseflow/repository.go795de0a35299internal/caseflow/repository_test.go6453d17998cbinternal/caseflow/service.gof226d2626806internal/caseflow/service_test.go1f1cf6f0ea75internal/caseflow/view.goecd114de74fcinternal/caseparty/caseparty.go410a36aa2332internal/caseparty/caseparty_test.go5abc7e9db209The core path is the same with
internal/replaced byplatform/.Testing
The tests move with the code.
go build ./...,go test -race ./caseflow/... ./caseparty/...andgolangci-lintpass inplatform/.Related Issues
Related to OpenNSW/nsw-srilanka#1238, OpenNSW/nsw-srilanka#1248, OpenNSW/nsw-srilanka#1339
🤖 Generated with Claude Code