OHIF-118 Fix the issue with retrieving AcquisitionDateTime or any DT DICOM attribute via DIMSE
This commit is contained in:
parent
90069329e6
commit
9d279e8626
@ -37,6 +37,7 @@ var getInstanceRetrievalParams = function(studyInstanceUID, seriesInstanceUID) {
|
||||
0x00280102: '', // highBit
|
||||
0x00280103: '', // pixelRepresentation
|
||||
0x00280004: '', // photometricInterpretation
|
||||
0x0008002A: '', // acquisitionDatetime
|
||||
0x00280008: '', // numFrames
|
||||
0x00181063: '', // frameTime
|
||||
0x00281052: '', // rescaleIntercept
|
||||
|
||||
@ -283,13 +283,16 @@ DateTime = function() {
|
||||
util.inherits(DateTime, ValueRepresentation);
|
||||
|
||||
DateTime.prototype.getFields = function(value) {
|
||||
var year = date.getUTCFullYear(),
|
||||
month = paddingLeft('00', date.getUTCMonth()),
|
||||
day = paddingLeft('00', date.getUTCDate()),
|
||||
hour = paddingLeft('00', date.getUTCHours()),
|
||||
minute = paddingLeft('00', date.getUTCMinutes()),
|
||||
second = paddingLeft('00', date.getUTCSeconds()),
|
||||
millisecond = paddingLeft('000', date.getUTCMilliseconds());
|
||||
if (!value)
|
||||
return DateTime.super_.prototype.getFields.call(this, [new StringField("")]);
|
||||
|
||||
var year = value.getUTCFullYear(),
|
||||
month = paddingLeft('00', value.getUTCMonth()),
|
||||
day = paddingLeft('00', value.getUTCDate()),
|
||||
hour = paddingLeft('00', value.getUTCHours()),
|
||||
minute = paddingLeft('00', value.getUTCMinutes()),
|
||||
second = paddingLeft('00', value.getUTCSeconds()),
|
||||
millisecond = paddingLeft('000', value.getUTCMilliseconds());
|
||||
|
||||
return DateTime.super_.prototype.getFields.call(this, [new StringField(year + month + day + hour + minute + second + '.' + millisecond + '+0000')]);
|
||||
};
|
||||
|
||||
@ -11,8 +11,6 @@ Template.registerHelper('sort', (array, sortBy, sortType) => {
|
||||
return array;
|
||||
}
|
||||
|
||||
console.log(array);
|
||||
|
||||
// To keep the order for the same values of the field which is used to sort:
|
||||
// 1. Group the array by the field
|
||||
// 2. Sort the grouped array
|
||||
|
||||
Loading…
Reference in New Issue
Block a user