Skip to content

Commit

Permalink
Merge pull request #123 from samply/feature/merge-develop-and-project…
Browse files Browse the repository at this point in the history
…-manager-connection

Feature/merge develop and project manager connection
  • Loading branch information
MatsJohansen87 authored Sep 6, 2024
2 parents f0a68d2 + 56de19f commit bd931f2
Show file tree
Hide file tree
Showing 15 changed files with 20,991 additions and 126 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,5 @@ TODO
docker-compose.override.yml
*.priv.pem
traefik.yaml

project-manager.env
22 changes: 22 additions & 0 deletions docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,28 @@ services:
profiles:
- "beam"

project-manager:
image: samply/project-manager:develop
ports:
- 8097:8097
env_file:
- env/project-manager.env
volumes:
- "./templates:/templates"
- "./documents:/documents"
- "./public-documents:/public-documents"
profiles:
- "project-manager"

project-manager-db:
image: postgres:alpine
environment:
POSTGRES_DB: dev
POSTGRES_USER: dev
POSTGRES_PASSWORD: dev
profiles:
- "project-manager"

secrets:
proxy.pem:
file: /etc/lens/pki/${LOCAL_BEAM_ID}.priv.pem
Expand Down
2 changes: 2 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ services:
- OAUTH2_PROXY_CLIENT_SECRET=${OAUTH_CLIENT_SECRET}
- OAUTH2_PROXY_COOKIE_SECRET=${AUTHENTICATION_SECRET}
- OAUTH2_PROXY_COOKIE_DOMAINS=.${GUI_HOST}
- OAUTH2_PROXY_COOKIE_REFRESH=4m
- OAUTH2_PROXY_COOKIE_EXPIRE=24h
- OAUTH2_PROXY_HTTP_ADDRESS=:4180
- OAUTH2_PROXY_REVERSE_PROXY=true
- OAUTH2_PROXY_WHITELIST_DOMAINS=.${GUI_HOST}
Expand Down
20,409 changes: 20,409 additions & 0 deletions packages/demo/public/catalogues/catalogue-dktk-staging.json

Large diffs are not rendered by default.

51 changes: 0 additions & 51 deletions packages/demo/public/catalogues/catalogue-dktk.json
Original file line number Diff line number Diff line change
Expand Up @@ -20354,56 +20354,5 @@
]
}
]
},
{
"key": "project",
"name": "Forschungsprojekte",
"infoButtonText": ["Projekt-Übersicht"],
"childCategories": [
{
"key": "pseudo_projects",
"name": "Projektname",
"fieldType": "single-select",
"type": "EQUALS",
"system": "",
"criteria": [
{
"key": "DKTK000002089",
"name": "EXLIQUID",
"description": ""
},
{
"key": "DKTK000001985",
"name": "RiskY-AML",
"description": ""
},
{
"key": "DKTK000001986",
"name": "MASTER-Programm",
"description": ""
},
{
"key": "DKTK000001950",
"name": "IRCC",
"description": ""
},
{
"key": "DKTK000001951",
"name": "ARMANI",
"description": ""
},
{
"key": "DKTK999999999",
"name": "Testprojekt",
"description": ""
},
{
"key": "DKTK000000791",
"name": "ReKo",
"description": ""
}
]
}
]
}
]
88 changes: 88 additions & 0 deletions packages/demo/public/options-dev.json
Original file line number Diff line number Diff line change
Expand Up @@ -279,5 +279,93 @@
"url": "http://localhost:8080"
}
]
},
"negotiateOptions": {
"negotiateApp": "project-manager",
"newProjectUrl": "http://localhost:8097/create-query-and-design-project",
"editProjectUrl": "http://localhost:8097/edit-project",
"siteMapping": [
{
"site": "Dresden",
"collection": "dresden"
},
{
"site": "Frankfurt",
"collection": "bbmri-eric:ID:DE_iBDF:collection:UCT"
},
{
"site": "Berlin",
"collection": "bbmri-eric:ID:DE_ZeBanC:collection:Onoloy"
},
{
"site": "Würzburg",
"collection": "bbmri-eric:ID:DE_ibdw:collection:bc"
},
{
"site": "Brno",
"collection": "bbmri-eric:ID:CZ_MMCI:collection:LTS"
},
{
"site": "Aachen",
"collection": "bbmri-eric:ID:DE_RWTHCBMB:collection:RWTHCBMB_BC"
},
{
"site": "Leipzig",
"collection": "bbmri-eric:ID:DE_LMB:collection:LIFE_ADULT"
},
{
"site": "München (HMGU)",
"collection": "bbmri-eric:ID:DE_Helmholtz-MuenchenBiobank:collection:DE_KORA"
},
{
"site": "Pilsen",
"collection": "bbmri-eric:ID:CZ_CUNI_PILS:collection:serum_plasma"
},
{
"site": "Regensburg",
"collection": "bbmri-eric:ID:DE_ZBR:collection:Tissue"
},
{
"site": "Heidelberg",
"collection": "bbmri-eric:ID:DE_BMBH:collection:Lungenbiobank"
},
{
"site": "Lübeck",
"collection": "bbmri-eric:ID:DE_ICBL:collection:ICBL"
},
{
"site": "Augsburg",
"collection": "bbmri-eric:ID:DE_ACBB:collection:TISSUE"
},
{
"site": "Mannheim",
"collection": "bbmri-eric:ID:DE_BioPsy:collection:Main_collecion"
},
{
"site": "Marburg",
"collection": "bbmri-eric:ID:DE_CBBMR:collection:main"
},
{
"site": "Göttingen",
"collection": "bbmri-eric:ID:DE_UMGB:collection:UMG-startegy"
},
{
"site": "Hanover",
"collection": "bbmri-eric:ID:DE_HUB:collection:ProBase"
},
{
"site": "Olomouc",
"collection": "bbmri-eric:ID:CZ_UPOL_LF:collection:all_samples"
},
{
"site": "Prague (FFM)",
"collection": "bbmri-eric:ID:CZ_CUNI_PILS:collection:serum_plasma"
},
{
"site": "Prague (IOR)",
"collection": "bbmri-eric:ID:CZ_CUNI_LF1:collection"
}

]
}
}
39 changes: 26 additions & 13 deletions packages/demo/src/AppCCP.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -13,24 +13,35 @@
dktkHistologyMeasure,
} from "./measures";
let catalogueData = "";
let libraryOptions = "";
let catalogueData: string = "";
let libraryOptions: string = "";
let catalogueUrl: string = "";
let optionsFilePath: string = "";
fetch("catalogues/catalogue-dktk.json")
if (import.meta.env.VITE_TARGET_ENVIRONMENT === "production") {
catalogueUrl = "catalogues/catalogue-dktk.json";
optionsFilePath = "options.json";
} else {
catalogueUrl = "catalogues/catalogue-dktk-staging.json";
optionsFilePath = "options-ccp-demo.json";
}
/**
* VITE_TARGET_ENVIRONMENT is set by the ci pipeline
*/
/**
* get catalogue file
*/
fetch(catalogueUrl)
.then((response) => response.text())
.then((data) => {
catalogueData = data;
});
// VITE_TARGET_ENVIRONMENT should be set by the ci pipeline
let optionsFilePath: string = "options-dev.json";
if (import.meta.env.VITE_TARGET_ENVIRONMENT === "production") {
optionsFilePath = "options-ccp-prod.json";
} else if (import.meta.env.VITE_TARGET_ENVIRONMENT === "staging") {
optionsFilePath = "options-ccp-demo.json";
}
/**
* get options file
*/
fetch(optionsFilePath)
.then((response) => response.json())
.then((data) => {
Expand All @@ -52,7 +63,7 @@
];
/**
* move to config file
* TODO: move to config file
*/
const catalogueText = {
group: "Group",
Expand Down Expand Up @@ -138,6 +149,8 @@
<lens-search-modified-display
>Diagramme repräsentieren nicht mehr die aktuelle Suche!</lens-search-modified-display
>
<!-- TODO: comment in when backend is ready -->
<!-- <lens-negotiate-button /> -->
</div>
<div class="chart-wrapper">
<lens-chart
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
<svelte:options
customElement={{
tag: "lens-negotiate-button",
}}
/>

<script lang="ts">
import { negotiate } from "../../stores/negotiate";
import { negotiate, negotiateStore } from "../../stores/negotiate";
export let title: string = "Negotiate with biobanks";
let disabled: boolean = false;
/**
* TODO: implement negotiator connection
*/
</script>

<button
part={`lens-negotiate-button lens-negotiate-button-${
disabled ? "disabled" : "active"
}`}
on:click={() => negotiate([])}
on:click={() => negotiate($negotiateStore)}
{disabled}
>
<div part="lens-negotiate-button-title">
Expand Down
2 changes: 1 addition & 1 deletion packages/lib/src/stores/catalogue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export const activeNumberInputs = writable<QueryItem[]>([]);
* @returns array of strings containing the bottom level items' keys
*/
export const getCriteria = (category: string): string[] => {
let bottomLevelItems = [] as string[];
let bottomLevelItems: string[] = [];

catalogue.subscribe((catalogue) => {
bottomLevelItems = getBottomLevelItems(catalogue, category);
Expand Down
Loading

0 comments on commit bd931f2

Please sign in to comment.