Mercurial > hg > orthanc-stl
comparison Sources/OrthancExplorer.js @ 53:83b1abee3ece nexus
improved handling of CreatorVersionUID
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sat, 18 May 2024 11:35:54 +0200 |
parents | 9b2a2fcc9878 |
children | 9ed0cb5d6082 |
comparison
equal
deleted
inserted
replaced
52:f9e49dc63817 | 53:83b1abee3ece |
---|---|
23 | 23 |
24 | 24 |
25 const STL_PLUGIN_SOP_CLASS_UID_STL = '1.2.840.10008.5.1.4.1.1.104.3'; | 25 const STL_PLUGIN_SOP_CLASS_UID_STL = '1.2.840.10008.5.1.4.1.1.104.3'; |
26 const STL_PLUGIN_SOP_CLASS_UID_RT_STRUCT = '1.2.840.10008.5.1.4.1.1.481.3'; | 26 const STL_PLUGIN_SOP_CLASS_UID_RT_STRUCT = '1.2.840.10008.5.1.4.1.1.481.3'; |
27 const STL_PLUGIN_SOP_CLASS_UID_RAW = '1.2.840.10008.5.1.4.1.1.66'; | 27 const STL_PLUGIN_SOP_CLASS_UID_RAW = '1.2.840.10008.5.1.4.1.1.66'; |
28 | |
29 const STL_PLUGIN_NEXUS_CREATOR_VERSION_UID = '1.2.826.0.1.3680043.8.498.90514926286349109728701975613711986292'; | |
30 | 28 |
31 | 29 |
32 function AddStlViewer(target, name, callback) { | 30 function AddStlViewer(target, name, callback) { |
33 var li = $('<li>', { | 31 var li = $('<li>', { |
34 name: name, | 32 name: name, |
397 function AddOpenStlNexusButton(instanceId, id, parent) { | 395 function AddOpenStlNexusButton(instanceId, id, parent) { |
398 if (${IS_NEXUS_ENABLED}) { | 396 if (${IS_NEXUS_ENABLED}) { |
399 $.ajax({ | 397 $.ajax({ |
400 url: '/instances/' + instanceId + '/content/0008,9123', | 398 url: '/instances/' + instanceId + '/content/0008,9123', |
401 success: function(creatorVersionUid) { | 399 success: function(creatorVersionUid) { |
402 if (creatorVersionUid == STL_PLUGIN_NEXUS_CREATOR_VERSION_UID) { | 400 if (creatorVersionUid == '${ORTHANC_STL_CREATOR_VERSION_UID_MAINLINE}') { |
403 var b = $('<a>') | 401 var b = $('<a>') |
404 .attr('id', id) | 402 .attr('id', id) |
405 .attr('data-role', 'button') | 403 .attr('data-role', 'button') |
406 .attr('href', '#') | 404 .attr('href', '#') |
407 .attr('data-icon', 'search') | 405 .attr('data-icon', 'search') |