fix(url): series query param filtering (#4328)
This commit is contained in:
parent
c6d3990341
commit
9b10303a2e
@ -13,7 +13,6 @@ const StudyMetaDataPromises = new Map();
|
||||
* @param {boolean} enableStudyLazyLoad Whether the study metadata should be loaded asynchronously.
|
||||
* @param {Object} [filters] Object containing filters to be applied on retrieve metadata process
|
||||
* @param {string} [filters.seriesInstanceUID] Series instance uid to filter results against
|
||||
* @param {array} [filters.SeriesInstanceUIDs] Series instance uids to filter results against
|
||||
* @param {function} [sortCriteria] Sort criteria function
|
||||
* @param {function} [sortFunction] Sort function
|
||||
*
|
||||
@ -48,7 +47,7 @@ export function retrieveStudyMetadata(
|
||||
|
||||
let promise;
|
||||
|
||||
if (filters && filters.SeriesInstanceUIDs) {
|
||||
if (filters && filters.seriesInstanceUID && Array.isArray(filters.seriesInstanceUID)) {
|
||||
promise = retrieveMetadataFiltered(
|
||||
dicomWebClient,
|
||||
StudyInstanceUID,
|
||||
|
||||
@ -8,7 +8,6 @@ import RetrieveMetadata from '../wado/retrieveMetadata';
|
||||
* @param {*} enableStudyLazyLoad Whether the study metadata should be loaded asynchronously
|
||||
* @param {object} filters Object containing filters to be applied on retrieve metadata process
|
||||
* @param {string} [filters.seriesInstanceUID] Series instance uid to filter results against
|
||||
* @param {array} [filters.SeriesInstanceUIDs] Series instance uids to filter results against
|
||||
* @param {function} [sortCriteria] Sort criteria function
|
||||
* @param {function} [sortFunction] Sort function
|
||||
*
|
||||
@ -22,10 +21,10 @@ function retrieveMetadataFiltered(
|
||||
sortCriteria,
|
||||
sortFunction
|
||||
) {
|
||||
const { SeriesInstanceUIDs } = filters;
|
||||
const { seriesInstanceUID } = filters;
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
const promises = SeriesInstanceUIDs.map(uid => {
|
||||
const promises = seriesInstanceUID.map(uid => {
|
||||
const seriesSpecificFilters = Object.assign({}, filters, {
|
||||
seriesInstanceUID: uid,
|
||||
});
|
||||
|
||||
@ -10,7 +10,6 @@ import RetrieveMetadataLoaderAsync from './retrieveMetadataLoaderAsync';
|
||||
* @param {*} enableStudyLazyLoad Whether the study metadata should be loaded asynchronously
|
||||
* @param {object} filters Object containing filters to be applied on retrieve metadata process
|
||||
* @param {string} [filters.seriesInstanceUID] Series instance uid to filter results against
|
||||
* @param {array} [filters.SeriesInstanceUIDs] Series instance uids to filter results against
|
||||
* @param {function} [sortCriteria] Sort criteria function
|
||||
* @param {function} [sortFunction] Sort function
|
||||
*
|
||||
|
||||
Loading…
Reference in New Issue
Block a user