fix: wado-rs retrieve metadata doesn't work with .NET servers #2969 (#2970)

* fix: wado-rs retrieve metadata doesn't work with .NET servers (issue #2969)

* add configuration to ommit the quots from multipart request
This commit is contained in:
Zaid Safadi 2022-11-03 15:19:35 +00:00 committed by GitHub
parent 6698300ace
commit 6b1f9f35a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,7 +52,7 @@ export default function initWADOImageLoader(
// we should set this flag to false.
convertFloatPixelDataToInt: false,
},
beforeSend: function(xhr) {
beforeSend: function (xhr) {
const headers = UserAuthenticationService.getAuthorizationHeader();
// Request:
@ -61,7 +61,7 @@ export default function initWADOImageLoader(
// For now we use image/jls and image/x-jls because some servers still use the old type
// http://dicom.nema.org/medical/dicom/current/output/html/part18.html
const xhrRequestHeaders = {
Accept: 'multipart/related; type=application/octet-stream',
Accept: (appConfig.ommitQuotationFromMultipartRequest) ? 'multipart/related; type=application/octet-stream' : 'multipart/related; type="application/octet-stream"'
// 'multipart/related; type="image/x-jls", multipart/related; type="image/jls"; transfer-syntax="1.2.840.10008.1.2.4.80", multipart/related; type="image/x-jls", multipart/related; type="application/octet-stream"; transfer-syntax=*',
};