view Resources/OrthancExplorer.js @ 317:f09050e06811 OrthancWebViewer-2.9

OrthancWebViewer-2.9
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 26 Mar 2024 11:36:15 +0100
parents 5d15a86bad26
children
line wrap: on
line source

$('#series').live('pagebeforecreate', function() {
  //$('#series-preview').parent().remove();

  var b = $('<a>')
    .attr('data-role', 'button')
    .attr('href', '#')
    .attr('data-icon', 'search')
    .attr('data-theme', 'e')
    .text('Orthanc Web Viewer');

  b.insertBefore($('#series-delete').parent().parent());
  b.click(function() {
    if ($.mobile.pageData) {
      var urlSearchParams = {
        "series" : $.mobile.pageData.uuid
      };
      if ("authorizationTokens" in window) {
        for (var token in authorizationTokens) {
          urlSearchParams[token] = authorizationTokens[token];
        }
      }

      window.open('../web-viewer/app/viewer.html?' + $.param(urlSearchParams));
    }
  });
});