BlueCat Address Manager Auto-Switch to Tagged Objects

Automatically switch to Tagged Objects if no SubTags exist in BlueCat Address Manager

当前为 2018-06-05 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name BlueCat Address Manager Auto-Switch to Tagged Objects
  3. // @namespace *
  4. // @description Automatically switch to Tagged Objects if no SubTags exist in BlueCat Address Manager
  5. // @include */app*
  6. // @exclude */app*sp=ScontextId%3Dtag
  7. // @license MIT
  8. // @version 2
  9. // @grant none
  10. // @copyright 2018, Marius Galm
  11. // @license MIT
  12. // @icon https://www.bluecatnetworks.com/wp-content/uploads/2018/03/cropped-bluecat-favicon-50x50.png
  13. // ==/UserScript==
  14.  
  15. // Exclude Pattern will prevent endless loop :-)
  16. if (document.readyState === "interactive" ) {
  17. var page = document.childNodes[2].nodeValue;
  18. if (/ Page: Tags /.test(page)) {
  19. if (document.getElementsByClassName("empty-table").length === 1) {
  20. document.getElementById("contextTabLink_1").click();
  21. }
  22. }
  23. }