connectJira.js 916 B

1234567891011121314151617181920212223242526272829303132333435
  1. /**
  2. * Plugin for embed mode in JIRA Connect.
  3. */
  4. Draw.loadPlugin(function(ui)
  5. {
  6. // Changes support link in Help menu
  7. ui.actions.addAction('support...', function()
  8. {
  9. window.open('https://support.draw.io/display/DFJC/draw.io+for+JIRA+Cloud');
  10. });
  11. // Display footer and alter it
  12. var td = document.getElementById('geFooterItem2');
  13. if (td != null)
  14. {
  15. td.innerHTML = '<a title="Connect review" href="https://marketplace.atlassian.com/plugins/com.mxgraph.jira.plugins.drawio/cloud/reviews" target="_blank">' +
  16. '<img border="0" align="absmiddle" style="margin-top:-4px;" src="images/glyphicons_star.png"/>&nbsp;&nbsp;Enjoying your free plugin? Please help us to a 4 star rating</a>';
  17. }
  18. td = document.getElementById('geFooterItem1');
  19. if (td != null)
  20. {
  21. td.parentNode.removeChild(td);
  22. }
  23. td = document.getElementById('geFooterItem3');
  24. if (td != null)
  25. {
  26. td.parentNode.removeChild(td);
  27. }
  28. });