diff options
| author | erdgeist <erdgeist@erdgeist.org> | 2025-02-06 16:49:06 +0100 |
|---|---|---|
| committer | erdgeist <erdgeist@erdgeist.org> | 2025-02-06 16:49:06 +0100 |
| commit | 375ed745052148faeb34763087fe04214105f1b8 (patch) | |
| tree | 595456cf631087b5530bf5470529faeead1a0aaf /public | |
| parent | 38d80f0af731326fcd5ae16c0129a056eff2fe32 (diff) | |
Improve worklflow
Diffstat (limited to 'public')
| -rw-r--r-- | public/javascripts/admin_interface.js | 52 | ||||
| -rw-r--r-- | public/javascripts/admin_search.js | 4 | ||||
| -rw-r--r-- | public/stylesheets/admin.css | 16 |
3 files changed, 58 insertions, 14 deletions
diff --git a/public/javascripts/admin_interface.js b/public/javascripts/admin_interface.js index ea3ab3d..aacb6f8 100644 --- a/public/javascripts/admin_interface.js +++ b/public/javascripts/admin_interface.js | |||
| @@ -1,3 +1,15 @@ | |||
| 1 | function hide_all() { | ||
| 2 | $('#recent_changes_toggle').attr("class", "unselected"); | ||
| 3 | $('#my_work_toggle').attr("class", "unselected"); | ||
| 4 | $('#current_drafts_toggle').attr("class", "unselected"); | ||
| 5 | $('#admin_sitemap_toggle').attr("class", "unselected"); | ||
| 6 | |||
| 7 | $('#current_drafts_table').hide(); | ||
| 8 | $('#my_work_table').hide(); | ||
| 9 | $('#recent_changes_table').hide(); | ||
| 10 | $('#admin_sitemap_table').hide(); | ||
| 11 | } | ||
| 12 | |||
| 1 | $(document).ready(function () { | 13 | $(document).ready(function () { |
| 2 | admin_search.initialize(); | 14 | admin_search.initialize(); |
| 3 | 15 | ||
| @@ -43,36 +55,48 @@ $(document).ready(function () { | |||
| 43 | } | 55 | } |
| 44 | 56 | ||
| 45 | if ($('#recent_changes_toggle').length != 0) { | 57 | if ($('#recent_changes_toggle').length != 0) { |
| 46 | $('#current_drafts_table').hide(); | 58 | hide_all(); |
| 47 | $('#admin_sitemap_table').hide(); | ||
| 48 | $('#recent_changes_toggle').attr("class", "selected"); | 59 | $('#recent_changes_toggle').attr("class", "selected"); |
| 60 | $('#recent_changes_table').show(); | ||
| 49 | 61 | ||
| 50 | $('#recent_changes_toggle').bind("click", function(){ | 62 | $('#recent_changes_toggle').bind("click", function(){ |
| 63 | hide_all(); | ||
| 51 | $('#recent_changes_toggle').attr("class", "selected"); | 64 | $('#recent_changes_toggle').attr("class", "selected"); |
| 52 | $('#current_drafts_toggle').attr("class", "unselected"); | ||
| 53 | $('#admin_sitemap_toggle').attr("class", "unselected"); | ||
| 54 | $('#recent_changes_table').show(); | 65 | $('#recent_changes_table').show(); |
| 55 | $('#current_drafts_table').hide(); | 66 | return false; |
| 56 | $('#admin_sitemap_table').hide(); | 67 | }); |
| 68 | |||
| 69 | $('#my_work_toggle').bind("click", function(){ | ||
| 70 | hide_all(); | ||
| 71 | $('#my_work_toggle').attr("class", "selected"); | ||
| 72 | $('#my_work_table').show(); | ||
| 73 | return false; | ||
| 74 | }); | ||
| 75 | |||
| 76 | $('#admin_wizard_my_work').bind("click", function(){ | ||
| 77 | hide_all(); | ||
| 78 | $('#my_work_toggle').attr("class", "selected"); | ||
| 79 | $('#my_work_table').show(); | ||
| 57 | return false; | 80 | return false; |
| 58 | }); | 81 | }); |
| 59 | 82 | ||
| 60 | $('#current_drafts_toggle').bind("click", function(){ | 83 | $('#current_drafts_toggle').bind("click", function(){ |
| 61 | $('#recent_changes_toggle').attr("class", "unselected"); | 84 | hide_all(); |
| 62 | $('#current_drafts_toggle').attr("class", "selected"); | 85 | $('#current_drafts_toggle').attr("class", "selected"); |
| 63 | $('#admin_sitemap_toggle').attr("class", "unselected"); | ||
| 64 | $('#current_drafts_table').show(); | 86 | $('#current_drafts_table').show(); |
| 65 | $('#recent_changes_table').hide(); | ||
| 66 | $('#admin_sitemap_table').hide(); | ||
| 67 | return false; | 87 | return false; |
| 68 | }); | 88 | }); |
| 69 | 89 | ||
| 70 | $('#admin_sitemap_toggle').bind("click", function(){ | 90 | $('#admin_sitemap_toggle').bind("click", function(){ |
| 71 | $('#recent_changes_toggle').attr("class", "unselected"); | 91 | hide_all(); |
| 72 | $('#current_drafts_toggle').attr("class", "unselected"); | 92 | $('#admin_sitemap_toggle').attr("class", "selected"); |
| 93 | $('#admin_sitemap_table').show(); | ||
| 94 | return false; | ||
| 95 | }); | ||
| 96 | |||
| 97 | $('#admin_wizard_create_page').bind("click", function(){ | ||
| 98 | hide_all(); | ||
| 73 | $('#admin_sitemap_toggle').attr("class", "selected"); | 99 | $('#admin_sitemap_toggle').attr("class", "selected"); |
| 74 | $('#current_drafts_table').hide(); | ||
| 75 | $('#recent_changes_table').hide(); | ||
| 76 | $('#admin_sitemap_table').show(); | 100 | $('#admin_sitemap_table').show(); |
| 77 | return false; | 101 | return false; |
| 78 | }); | 102 | }); |
diff --git a/public/javascripts/admin_search.js b/public/javascripts/admin_search.js index 98571de..78577e7 100644 --- a/public/javascripts/admin_search.js +++ b/public/javascripts/admin_search.js | |||
| @@ -160,6 +160,10 @@ parent_search = { | |||
| 160 | $("#parent_search_field").hide(); | 160 | $("#parent_search_field").hide(); |
| 161 | }); | 161 | }); |
| 162 | 162 | ||
| 163 | $("#kind_press_release").bind("change", function(){ | ||
| 164 | $("#parent_search_field").hide(); | ||
| 165 | }); | ||
| 166 | |||
| 163 | $("#kind_generic").bind("change", function(){ | 167 | $("#kind_generic").bind("change", function(){ |
| 164 | $("#parent_search_field").show(); | 168 | $("#parent_search_field").show(); |
| 165 | }); | 169 | }); |
diff --git a/public/stylesheets/admin.css b/public/stylesheets/admin.css index fbb8a3f..c7ebb52 100644 --- a/public/stylesheets/admin.css +++ b/public/stylesheets/admin.css | |||
| @@ -106,6 +106,22 @@ input[type=submit], | |||
| 106 | text-transform: lowercase; | 106 | text-transform: lowercase; |
| 107 | } | 107 | } |
| 108 | 108 | ||
| 109 | #admin_wizard { | ||
| 110 | margin-bottom: 2rem; | ||
| 111 | } | ||
| 112 | |||
| 113 | #admin_wizard a { | ||
| 114 | font-size: 1rem; | ||
| 115 | font-weight: bold; | ||
| 116 | padding: 0.5rem; | ||
| 117 | background-color: green; | ||
| 118 | color: white; | ||
| 119 | } | ||
| 120 | |||
| 121 | #admin_wizard a:hover { | ||
| 122 | background-color: lime; | ||
| 123 | } | ||
| 124 | |||
| 109 | #sub_navigation a { | 125 | #sub_navigation a { |
| 110 | color: #969696; | 126 | color: #969696; |
| 111 | } | 127 | } |
