From fb1918124dd85a97489d3810734807769bdc15c5 Mon Sep 17 00:00:00 2001 From: HsuTzu26 Date: Fri, 10 Jan 2025 13:21:24 +0800 Subject: [PATCH 1/2] feat: add WSI viewer config and fit its server URL - add server name to search config - define config for server name - create a URL for WSI viewer --- search/data/config.json | 6 ++++-- search/scripts/onload.js | 3 ++- search/scripts/readsome.js | 3 +++ 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/search/data/config.json b/search/data/config.json index f1bc5a8..6b50011 100644 --- a/search/data/config.json +++ b/search/data/config.json @@ -14,7 +14,8 @@ "enableRetrieveURI": true, "includefield": false, "target": "../../bluelight/html/start.html", - "target-SM": "../../bluelight/html/start.html", + "target-SM": "https://ditto-wsiviewer.dicom.tw/viewer", + "server-SM": "NewRaccoon", "token": { "apikey":"", "bearer":"" @@ -34,7 +35,8 @@ "enableRetrieveURI": true, "includefield": false, "target": "../../bluelight/html/start.html", - "target-SM": ".../../bluelight/html/start.html", + "target-SM": "https://ditto-wsiviewer.dicom.tw/viewer", + "server-SM": "NewRaccoon", "token": { "apikey":"", "bearer":"" diff --git a/search/scripts/onload.js b/search/scripts/onload.js index be0315e..5a714c1 100644 --- a/search/scripts/onload.js +++ b/search/scripts/onload.js @@ -255,7 +255,8 @@ function createTable() { if (!this.Modality.includes("SM")) cell.alt = ConfigLog.QIDO.target + '?' + "StudyInstanceUID=" + this.Study.StudyUID; else - cell.alt = ConfigLog.QIDO.targetSM + '?' + "StudyInstanceUID=" + this.Study.StudyUID; + // cell.alt = ConfigLog.QIDO.targetSM + '?' + "StudyInstanceUID=" + this.Study.StudyUID; + cell.alt = ConfigLog.QIDO.targetSM + "?server=" + ConfigLog.QIDO.serverSM + '&' + "studyUid=" + this.Study.StudyUID; cell.onclick = function () { window.open(this.alt, '_blank'); } var cell = row1.insertCell(1); cell.innerHTML = "StudyInstanceUID=" + this.Study.StudyUID; diff --git a/search/scripts/readsome.js b/search/scripts/readsome.js index bf13919..641c347 100644 --- a/search/scripts/readsome.js +++ b/search/scripts/readsome.js @@ -141,6 +141,7 @@ function readConfigJson(url, onLosdSerch) { tempConfig.includefield = tempDicomResponse["includefield"]; tempConfig.target = tempDicomResponse["target"]; tempConfig.targetSM = tempDicomResponse["target-SM"]; + tempConfig.serverSM = tempDicomResponse["server-SM"]; tempConfig.enableRetrieveURI = tempDicomResponse["enableRetrieveURI"]; tempConfig.token = tempDicomResponse["token"]; @@ -156,6 +157,7 @@ function readConfigJson(url, onLosdSerch) { tempConfig.includefield = tempDicomResponse["includefield"]; tempConfig.target = tempDicomResponse["target"]; tempConfig.targetSM = tempDicomResponse["target-SM"]; + tempConfig.serverSM = tempDicomResponse["server-SM"]; tempConfig.enableRetrieveURI = tempDicomResponse["enableRetrieveURI"]; tempConfig.token = tempDicomResponse["token"]; @@ -171,6 +173,7 @@ function readConfigJson(url, onLosdSerch) { tempConfig.includefield = tempDicomResponse["includefield"]; tempConfig.target = tempDicomResponse["target"]; tempConfig.targetSM = tempDicomResponse["target-SM"]; + tempConfig.serverSM = tempDicomResponse["server-SM"]; tempConfig.enableRetrieveURI = tempDicomResponse["enableRetrieveURI"]; tempConfig.token = tempDicomResponse["token"]; From 7711e16a7bc796bd8fe633dc6493cac3cd0748ca Mon Sep 17 00:00:00 2001 From: HsuTzu26 Date: Fri, 10 Jan 2025 13:36:20 +0800 Subject: [PATCH 2/2] fix: change the server name --- search/data/config.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/search/data/config.json b/search/data/config.json index 6b50011..f442c60 100644 --- a/search/data/config.json +++ b/search/data/config.json @@ -15,7 +15,7 @@ "includefield": false, "target": "../../bluelight/html/start.html", "target-SM": "https://ditto-wsiviewer.dicom.tw/viewer", - "server-SM": "NewRaccoon", + "server-SM": "RACCOONORG", "token": { "apikey":"", "bearer":"" @@ -36,7 +36,7 @@ "includefield": false, "target": "../../bluelight/html/start.html", "target-SM": "https://ditto-wsiviewer.dicom.tw/viewer", - "server-SM": "NewRaccoon", + "server-SM": "RACCOONORG", "token": { "apikey":"", "bearer":""