{"id":16557,"date":"2022-12-26T04:47:15","date_gmt":"2022-12-26T04:47:15","guid":{"rendered":"https:\/\/44.225.35.201\/testrail\/docs\/801\/user-guide\/administration-and-customizations\/ui-scripts\/ui-scripts-examples\/"},"modified":"2023-09-11T11:28:47","modified_gmt":"2023-09-11T02:28:47","slug":"examples","status":"publish","type":"page","link":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/user-guide\/administration-and-customizations\/ui-scripts\/examples\/","title":{"rendered":"UI \u30b9\u30af\u30ea\u30d7\u30c8\uff1a\u30b5\u30f3\u30d7\u30eb"},"content":{"rendered":"<p>\u3053\u306e\u30da\u30fc\u30b8\u3067\u306f\u3001UI \u30b9\u30af\u30ea\u30d7\u30c8\u3092\u4f7f\u7528\u3057\u3066 TestRail \u306e\u30e6\u30fc\u30b6\u30fc \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3092\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3059\u308b\u65b9\u6cd5\u3092\u3044\u304f\u3064\u304b\u7d39\u4ecb\u3057\u307e\u3059\u3002\u5148\u306b UI \u30b9\u30af\u30ea\u30d7\u30c8\u306b\u95a2\u3059\u308b\u80cc\u666f\u60c5\u5831\u304c\u8a18\u8f09\u3055\u308c\u3066\u3044\u308b <strong><a href=\"\/introduction\" target=\"_self\" rel=\"noopener\">UI \u30b9\u30af\u30ea\u30d7\u30c8\uff1a\u306f\u3058\u3081\u306b<\/a><\/strong>\u3092\u8aad\u3093\u3067\u304a\u304f\u3053\u3068\u3092\u304a\u52e7\u3081\u3057\u307e\u3059\u3002<\/p>\n<div class=\"callout callout--info\">\n<p>\u4e0b\u306e\u30b5\u30f3\u30d7\u30eb\u306b\u52a0\u3048\u3066\u3001\u30d1\u30d6\u30ea\u30c3\u30af\u306a <strong><a href=\"https:\/\/github.com\/gurock\/testrail-custom\/tree\/master\/user-submitted\/ui-scripts\" target=\"_blank\" rel=\"noopener noreferrer\">TestRail \u30ab\u30b9\u30bf\u30de\u30a4\u30ba GitHub \u30ea\u30dd\u30b8\u30c8\u30ea<\/a><\/strong>\u306b UI \u30b9\u30af\u30ea\u30d7\u30c8\u306e\u30b5\u30f3\u30d7\u30eb\u304c\u3042\u308a\u307e\u3059\u3002\u305d\u306e\u307e\u307e\u3067\u3001\u3042\u308b\u3044\u306f\u7c21\u5358\u306a\u5909\u66f4\u3060\u3051\u3067\u304a\u5ba2\u69d8\u306e\u30cb\u30fc\u30ba\u306b\u5408\u3046\u30b9\u30af\u30ea\u30d7\u30c8\u304c\u898b\u3064\u304b\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002<\/p>\n<\/div>\n<h2>\u7ba1\u7406\u30da\u30fc\u30b8\u3092\u5f37\u8abf\u8868\u793a\u3059\u308b<\/h2>\n<p>\u73fe\u5728\u306e\u30da\u30fc\u30b8\u304c\u7ba1\u7406\u30da\u30fc\u30b8\u306e\u4e00\u90e8\u3067\u3042\u308b\u304b\u3069\u3046\u304b\u3092\u3001\u305f\u3068\u3048\u3070\u30bf\u30a4\u30c8\u30eb \u30d0\u30fc\u306e\u80cc\u666f\u8272\u3092\u5909\u3048\u308b\u306a\u3069\u3057\u3066\u8996\u899a\u7684\u306b\u793a\u3059\u3053\u3068\u304c\u3067\u304d\u308c\u3070\u4fbf\u5229\u3067\u3057\u3087\u3046\u3002\u3053\u308c\u306f\u3001CSS \u3060\u3051\u3092\u4f7f\u7528\u3059\u308b\u6bd4\u8f03\u7684\u5358\u7d14\u306a UI \u30b9\u30af\u30ea\u30d7\u30c8\u3067\u7c21\u5358\u306b\u5b9f\u73fe\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>TestRail 4.0 \u4ee5\u964d\u304a\u3088\u3073 TestRail 3.x \u306e\u5834\u5408\u306f\u3001\u6b21\u306e\u30b5\u30f3\u30d7\u30eb\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><strong><span class=\"tabs-link is-active\">TestRail 4.x (\u304a\u3088\u3073\u4ee5\u964d)<\/span> \uff1a<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"css\">name: Highlight administration pages\ndescription: Changes the background of the user menu on admin pages\nauthor: Gurock Software\nversion: 1.0\nincludes: ^admin\n\ncss:\n#top .top-panel {\n  background-color: #8B0000;\n}<\/pre>\n<p><strong>TestRail 3.x\uff1a<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"css\">name: Highlight administration pages\ndescription: Changes the background of the user menu on admin pages\nauthor: Gurock Software\nversion: 1.0\nincludes: ^admin\n\ncss:\n#topBar {\n  background-color: #8B0000;\n}<\/pre>\n<h2><span style=\"color: revert; font-size: revert; font-weight: revert;\">\u30d5\u30a3\u30fc\u30c9\u30d0\u30c3\u30af \u30ea\u30f3\u30af\u306e\u5909\u66f4 (TestRail 3.x \u306e\u307f)<\/span><\/h2>\n<p>\u30ea\u30f3\u30af\u306e\u5834\u6240\u3092\u5909\u66f4\u3057\u305f\u308a\u3001\u30e6\u30fc\u30b6\u30fc \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u304b\u3089\u30ea\u30f3\u30af\u3092\u5b8c\u5168\u306b\u524a\u9664\u3059\u308b\u306a\u3069\u3001TestRail \u306e\u30d5\u30a3\u30fc\u30c9\u30d0\u30c3\u30af \u30ea\u30f3\u30af\u3092\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3057\u305f\u3044\u30b1\u30fc\u30b9\u304c\u3042\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002\u6b21\u306e\u30b5\u30f3\u30d7\u30eb\u306f\u3001UI \u30b9\u30af\u30ea\u30d7\u30c8\u3092\u4f7f\u7528\u3057\u3066\u3053\u308c\u3092\u5b9f\u73fe\u3059\u308b\u65b9\u6cd5\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<h3>\u30ea\u30f3\u30af\u306e\u524a\u9664<\/h3>\n<p>UI \u30b9\u30af\u30ea\u30d7\u30c8\u306e JavaScript \u90e8\u5206\u3067 jQuery \u3092\u4f7f\u7528\u3059\u308b\u3068\u3001\u7c21\u5358\u306b\u30d5\u30a3\u30fc\u30c9\u30d0\u30c3\u30af \u30ea\u30f3\u30af\u3092\u524a\u9664\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"js\">name: Remove feedback link\ndescription: Removes the feedback link from the user menu\nauthor: Gurock Software\nversion: 1.0\nincludes: \nexcludes: \n\njs:\n$(document).ready(\n  function() {\n    $('#userMenu ul li:eq(1)').remove();\n  }\n);<\/pre>\n<p>\u3053\u308c\u306f\u3001jQuery \u306e\u30bb\u30ec\u30af\u30bf\u30fc\u3092\u4f7f\u7528\u3057\u3066\u30da\u30fc\u30b8\u306e\u7279\u5b9a\u306e\u8981\u7d20\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u65b9\u6cd5\u3092\u793a\u3059\u826f\u3044\u4f8b\u3067\u3059\u3002\u3053\u306e\u30bb\u30ec\u30af\u30bf\u30fc\u306e\u69cb\u6587\u306f\u3001\u300c#userMenu \u306e\u756a\u53f7\u306a\u3057\u30ea\u30b9\u30c8\u306e 2 \u756a\u76ee\u306e\u8981\u7d20 (0 \u304b\u3089\u30ab\u30a6\u30f3\u30c8\u3059\u308b) \u3092\u9078\u629e\u3059\u308b\u300d\u3068\u3044\u3046\u610f\u5473\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h3>\u30bf\u30fc\u30b2\u30c3\u30c8 URL \u3092\u5909\u66f4\u3059\u308b<\/h3>\n<p>\u5225\u306e\u9078\u629e\u80a2\u3068\u3057\u3066\u3001\u516c\u5f0f\u306e TestRail \u30b5\u30dd\u30fc\u30c8 \u30d5\u30a9\u30fc\u30e9\u30e0\u306e\u4ee3\u308f\u308a\u306b\u5185\u90e8\u30d5\u30a9\u30fc\u30e9\u30e0\u307e\u305f\u306f\u30d8\u30eb\u30d7 \u30c7\u30b9\u30af \u30da\u30fc\u30b8\u3092\u6307\u3059\u3088\u3046\u306b\u30d5\u30a3\u30fc\u30c9\u30d0\u30c3\u30af \u30ea\u30f3\u30af\u306e\u30ea\u30f3\u30af\u5148\u3092\u5909\u66f4\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"js\">name: Change feedback link\ndescription: Changes the target URL of the feedback link\nauthor: Gurock Software\nversion: 1.0\nincludes: \nexcludes: \n\njs:\n$(document).ready(\n  function() {\n    document.querySelector('.top-menu-highlight').classList.remove('dropdownLink');\n    document.querySelector('.top-menu-highlight').href = 'http:\/\/internal-feedback-url';\n  }\n);<\/pre>\n<h2>\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u306e\u30b0\u30e9\u30d5\u3092\u975e\u8868\u793a\u306b\u3059\u308b<\/h2>\n<p>\u591a\u304f\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u4f5c\u696d\u3057\u3066\u3044\u308b\u3068\u304d\u3001TestRail \u306e\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u306b\u3088\u308a\u591a\u304f\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4e00\u5ea6\u306b\u8868\u793a\u3067\u304d\u308b\u3088\u3046\u3001\u30a2\u30af\u30c6\u30a3\u30d3\u30c6\u30a3 \u30c1\u30e3\u30fc\u30c8\u3092\u975e\u8868\u793a\u306b\u3059\u308b\u3068\u3088\u3044\u3067\u3057\u3087\u3046\u3002\u4e0b\u8a18\u306e\u5404 UI \u30b9\u30af\u30ea\u30d7\u30c8\u306f\u3001\u30da\u30fc\u30b8\u304b\u3089\u30b0\u30e9\u30d5\u3092\u524a\u9664\u3057\u307e\u3059\u3002<\/p>\n<p>TestRail 4.0 \u4ee5\u964d\u304a\u3088\u3073 TestRail 3.x \u306e\u5834\u5408\u306f\u3001\u6b21\u306e\u30b5\u30f3\u30d7\u30eb\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><strong><span class=\"tabs-link is-active\">TestRail 4.x (\u304a\u3088\u3073\u4ee5\u964d)<\/span>\u00a0\uff1a<\/strong><\/p>\n<div class=\"tabs\">\n<div>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"js\">name: Hide dashboard chart\ndescription: Hides the chart on the dashboard page\nauthor: Gurock Software\nversion: 1.0\nincludes: ^dashboard\nexcludes:\n\njs:\n$(document).ready(\n  function() {\n    $('.chart-line:first').hide();\n  }\n);<\/pre>\n<p><strong>TestRail 3.x\uff1a<\/strong><\/p>\n<\/div>\n<div>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"js\">name: Hide dashboard chart\ndescription: Hides the chart on the dashboard page\nauthor: Gurock Software\nversion: 1.0\nincludes: ^dashboard\nexcludes:\n\njs:\n$(document).ready(\n  function() {\n    $('.lineChart:first').hide();\n  }\n);<\/pre>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u3053\u306e\u30da\u30fc\u30b8\u3067\u306f\u3001UI \u30b9\u30af\u30ea\u30d7\u30c8\u3092\u4f7f\u7528\u3057\u3066 TestRail \u306e\u30e6\u30fc\u30b6\u30fc \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3092\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3059\u308b\u65b9\u6cd5\u3092\u3044\u304f\u3064\u304b\u7d39\u4ecb\u3057\u307e\u3059\u3002\u5148\u306b UI \u30b9\u30af\u30ea\u30d7\u30c8\u306b\u95a2\u3059\u308b\u80cc\u666f\u60c5\u5831\u304c\u8a18\u8f09\u3055\u308c\u3066\u3044\u308b UI \u30b9\u30af\u30ea\u30d7\u30c8\uff1a\u306f\u3058\u3081\u306b\u3092\u8aad [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":0,"parent":14738,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_et_pb_use_builder":"","_et_pb_old_content":"","_et_gb_content_width":"","footnotes":""},"class_list":["post-16557","page","type-page","status-publish","hentry"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/pages\/16557","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/comments?post=16557"}],"version-history":[{"count":17,"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/pages\/16557\/revisions"}],"predecessor-version":[{"id":23423,"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/pages\/16557\/revisions\/23423"}],"up":[{"embeddable":true,"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/pages\/14738"}],"wp:attachment":[{"href":"https:\/\/docs.testrail.techmatrix.jp\/testrail\/docs\/9\/wp-json\/wp\/v2\/media?parent=16557"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}