# HG changeset patch # User Sebastien Jodogne # Date 1346330113 -7200 # Node ID 2cefaf5b3c2ecd36e3c8c120a5fbcf95de84b70b # Parent 88f537ca35a521a8179f8c5a3f65c081b9b2fbce improvements diff -r 88f537ca35a5 -r 2cefaf5b3c2e Core/DicomFormat/DicomMap.cpp --- a/Core/DicomFormat/DicomMap.cpp Thu Aug 30 12:45:17 2012 +0200 +++ b/Core/DicomFormat/DicomMap.cpp Thu Aug 30 14:35:13 2012 +0200 @@ -30,25 +30,25 @@ { static DicomTag patientTags[] = { - DicomTag(0x0008, 0x0050), // AccessionNumber DicomTag(0x0010, 0x0010), // PatientName DicomTag(0x0010, 0x0020), // PatientID DicomTag(0x0010, 0x0030), // PatientBirthDate DicomTag(0x0010, 0x0040), // PatientSex - DicomTag(0x0010, 0x1000), // OtherPatientIDs - DicomTag(0x0010, 0x1010), // PatientAge - DicomTag(0x0010, 0x1040) // PatientAddress + DicomTag(0x0010, 0x1000) // OtherPatientIDs + //DicomTag(0x0010, 0x1010), // PatientAge + //DicomTag(0x0010, 0x1040) // PatientAddress }; static DicomTag studyTags[] = { DicomTag(0x0008, 0x0020), // StudyDate DicomTag(0x0008, 0x0030), // StudyTime + DicomTag(0x0008, 0x0050), // AccessionNumber DicomTag(0x0008, 0x1030), // StudyDescription DicomTag(0x0020, 0x000d), // StudyInstanceUID - DicomTag(0x0020, 0x0010), // StudyID - DicomTag(0x0010, 0x1020), // PatientSize - DicomTag(0x0010, 0x1030) // PatientWeight + DicomTag(0x0020, 0x0010) // StudyID + //DicomTag(0x0010, 0x1020), // PatientSize + //DicomTag(0x0010, 0x1030) // PatientWeight }; static DicomTag seriesTags[] = @@ -59,7 +59,8 @@ DicomTag(0x0008, 0x0070), // Manufacturer DicomTag(0x0008, 0x1010), // StationName DicomTag(0x0008, 0x103e), // SeriesDescription - DicomTag(0x0010, 0x1080), // MilitaryRank + //DicomTag(0x0010, 0x1080), // MilitaryRank + DicomTag(0x0018, 0x0015), // BodyPartExamined DicomTag(0x0018, 0x0024), // SequenceName DicomTag(0x0018, 0x1030), // ProtocolName DicomTag(0x0020, 0x000e), // SeriesInstanceUID diff -r 88f537ca35a5 -r 2cefaf5b3c2e PalantirExplorer/explorer.js --- a/PalantirExplorer/explorer.js Thu Aug 30 12:45:17 2012 +0200 +++ b/PalantirExplorer/explorer.js Thu Aug 30 14:35:13 2012 +0200 @@ -197,18 +197,44 @@ } +function FormatMainDicomTags(tags, tagsToIgnore) +{ + var s = ''; + + for (var i in tags) + { + if (tagsToIgnore.indexOf(i) == -1) + { + var v = tags[i]; + + if (v == "PatientBirthDate") + { + v = FormatDicomDate(v); + } + else if (v == "DicomStudyInstanceUID") + { + v = SplitLongUid(v); + } + + + s += ('

{0}: {1}

').format(i, v); + } + } + + return s; +} + function FormatPatient(patient, link, isReverse) { - var s = ('

{1}

' + - '

Patient ID: {2}

' + - '

Accession Number: {3}

' + - '

Date of Birth: {4}

' + - '

Sex: {5}

' + - '{6}' + var s = ('

{0}

' + + '

Patient ID: {1}

' + + '

Accession aaNumber: {2}

' + + '

Date of Birth: {3}

' + + '

Sex: {4}

' + + '{5}' ).format - (link, - patient.MainDicomTags.PatientName, + (patient.MainDicomTags.PatientName, patient.DicomPatientID, patient.MainDicomTags.AccessionNumber, FormatDicomDate(patient.MainDicomTags.PatientBirthDate), @@ -224,11 +250,13 @@ function FormatStudy(study, link, isReverse) { var s = ('

{0}

' + - '

Study Instance UID: {1}

' + + //'

Study Instance UID: {1}

' + + '{1}' + '{2}' ).format (study.MainDicomTags.StudyDescription, - SplitLongUid(study.DicomStudyInstanceUID), + //SplitLongUid(study.DicomStudyInstanceUID), + FormatMainDicomTags(study.MainDicomTags, [ "StudyDescription", "StudyTime" ]), study.Series.length );