Skip to content

Commit

Permalink
Merge pull request #1258 from FNNDSC/pacs-progress-websockets
Browse files Browse the repository at this point in the history
Pacs progress websockets
  • Loading branch information
PintoGideon authored Oct 18, 2024
2 parents f2e5401 + 2ca5227 commit b911366
Show file tree
Hide file tree
Showing 133 changed files with 9,622 additions and 3,619 deletions.
9 changes: 8 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ VITE_CHRIS_UI_AUTH_URL="http://localhost:8000/api/v1/auth-token/"
VITE_ALPHA_FEATURES='production'

# Set PFDCM_URL to the root url of the running pfdcm instance
VITE_PFDCM_URL="http://localhost:4005/"
# note: must *not* have trailing slash
VITE_PFDCM_URL="http://localhost:4005"

# (optional) set URL of an OHIF browser which has the same studies as the PFDCM
# VITE_OHIF_URL="http://localhost:8042/ohif/"
Expand All @@ -34,7 +35,13 @@ VITE_PFDCM_URL="http://localhost:4005/"
# VITE_ACKEE_SERVER="http://localhost:3050"
# VITE_ACKEE_DOMAIN_ID="lol-lol-lol"

# How often to poll CUBE, in milliseconds.
VITE_CUBE_POLL_INTERVAL_MS=2000

VITE_SOURCEMAP='false'

# URI for support requests
VITE_SUPPORT_URL='mailto:[email protected]'

# Set URL for the store if you want to see it in the sidebar
VITE_CHRIS_STORE_URL= "https://cube.chrisproject.org/api/v1/"
2 changes: 2 additions & 0 deletions .env.production
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ VITE_OHIF_URL="ea1cf042-73f0-43a1-93da-86ff93e5ac19"
VITE_ACKEE_SERVER="79a96963-2e17-405e-94bd-4f2433e5cce8"
VITE_ACKEE_DOMAIN_ID="e8fe722b-986c-4aaf-ba04-c10d21e4aca1"

VITE_CUBE_POLL_INTERVAL_MS="ca4bef0b-95c9-4a02-abda-590b51b9b07e"

VITE_ALPHA_FEATURES='production'

VITE_SOURCEMAP='false'
Expand Down
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,21 @@ pnpm run test:e2e:local # run tests using "local" backend
For more information, consult the wiki:
https://github.com/FNNDSC/ChRIS_ui/wiki/E2E-Testing-with-Playwright

## Pfdcm Client

The code in `src/api/pfdcm/generated` were automatically generated using the [OpenAPI generator](https://openapi-generator.tech).

```shell
docker run --rm --net=host -u "$(id -u):$(id -g)" \
-v "$(npm prefix)/src:/src" \
docker.io/openapitools/openapi-generator-cli:v7.8.0 \
generate -g typescript-fetch -i http://localhost:4005/openapi.json -o /src/api/pfdcm/generated
```

## Development Notes

- Do not use `ReadonlyArray` because it is not supported by `antd` prop types.

<!-- Image Links -->

[license-badge]: https://img.shields.io/github/license/fnndsc/chris_ui.svg
Expand Down
9 changes: 6 additions & 3 deletions biome.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@
"package.json",
"biome.json",
"*.config.ts",
"vitest.*.ts",
"tsconfig*.json",
"testing/*.mjs"
],
"ignore": ["package-lock.json"]
"ignore": ["package-lock.json", "pfdcm/generated"]
},
"organizeImports": {
"enabled": true
Expand All @@ -24,10 +25,12 @@
"rules": {
"recommended": true,
"style": {
"noNonNullAssertion": "off"
"noNonNullAssertion": "off",
"useTemplate": "off"
},
"complexity": {
"noForEach": "off"
"noForEach": "off",
"noUselessFragments": "off"
},
"correctness": {
"useExhaustiveDependencies": "warn"
Expand Down
2 changes: 2 additions & 0 deletions docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ find -type d -exec mkdir -p "$target/{}" \;

# set default values
CHRIS_STORE_URL="${CHRIS_STORE_URL-https://cube.chrisproject.org/api/v1/}"
CUBE_POLL_INTERVAL_MS="${CUBE_POLL_INTERVAL_MS-2000}"
# OHIF_URL, ACKEE_SERVER, ACKEE_DOMAIN_ID default values are empty

# required values
Expand All @@ -66,6 +67,7 @@ find -type f -exec sh -c "cat '{}' \
| sed 's#$VITE_OHIF_URL#$OHIF_URL#g' \
| sed 's#$VITE_ACKEE_SERVER#$ACKEE_SERVER#g' \
| sed 's#$VITE_ACKEE_DOMAIN_ID#$ACKEE_DOMAIN_ID#g' \
| sed 's#$VITE_CUBE_POLL_INTERVAL_MS#$CUBE_POLL_INTERVAL_MS#g' \
> $target/{}" \;

# run specified command
Expand Down
10 changes: 8 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"chrisomatic": "testing/chrisomatic.sh",
"get-dicoms": "./testing/getDicoms.mjs",
"list-mrns": "./testing/miniChRIS/scripts/list_mrns.sh",
"upload-dicom": "./testing/miniChRIS/scripts/upload2orthanc.sh",
"lint": "biome lint .",
"fix": "biome check --apply .",
"fix:unsafe": "biome check --apply-unsafe .",
Expand All @@ -37,6 +38,7 @@
"print-version": "node printVersion.js"
},
"dependencies": {
"@ant-design/icons": "^5.5.1",
"@cornerstonejs/core": "^1.84.4",
"@cornerstonejs/dicom-image-loader": "^1.84.4",
"@cornerstonejs/streaming-image-volume-loader": "^1.84.4",
Expand Down Expand Up @@ -91,6 +93,7 @@
"react-responsive": "^10.0.0",
"react-router": "^6.26.2",
"react-router-dom": "^6.26.2",
"react-use-websocket": "^4.8.1",
"redux-saga": "^1.3.0",
"rusha": "^0.8.14",
"sanitize-html": "^2.13.0",
Expand All @@ -106,6 +109,9 @@
"@faker-js/faker": "^9.0.1",
"@playwright/test": "^1.46.1",
"@redux-devtools/extension": "^3.3.0",
"@testing-library/dom": "^10.4.0",
"@testing-library/jest-dom": "^6.5.0",
"@testing-library/react": "^16.0.1",
"@types/d3-hierarchy": "3.1.7",
"@types/d3-selection": "3.0.10",
"@types/d3-shape": "^3.1.6",
Expand All @@ -125,8 +131,8 @@
"redux-logger": "4.0.0",
"vite": "5.4.6",
"vite-plugin-istanbul": "^6.0.2",
"vite-plugin-node-polyfills": "^0.22.0",
"vitest": "2.1.1"
"vitest": "^2.1.1",
"vitest-websocket-mock": "^0.4.0"
},
"type": "module",
"packageManager": "[email protected]+sha512.0a203ffaed5a3f63242cd064c8fb5892366c103e328079318f78062f24ea8c9d50bc6a47aa3567cabefd824d170e78fa2745ed1f16b132e16436146b7688f19b"
Expand Down
Loading

0 comments on commit b911366

Please sign in to comment.