Moved javascript into ViewLayoutsHookListener

This commit is contained in:
2026-01-20 21:02:40 -05:00
parent f74f3ad72e
commit b54eb86b7f
2 changed files with 21 additions and 8 deletions

View File

@@ -10,14 +10,6 @@
class IssuesFormHookListener < Redmine::Hook::ViewListener class IssuesFormHookListener < Redmine::Hook::ViewListener
# Load the javascript to support the autocomplete forms
def view_layouts_base_html_head(context = {})
js = javascript_include_tag 'application.js', :plugin => 'redmine_qbo'
js += javascript_include_tag 'autocomplete-rails.js', :plugin => 'redmine_qbo'
js += javascript_include_tag 'checkbox_controller.js', :plugin => 'redmine_qbo'
return js
end
# Edit Issue Form # Edit Issue Form
# Here we build the required form components before passing them to a partial view formatting. # Here we build the required form components before passing them to a partial view formatting.
def view_issues_form_details_bottom(context={}) def view_issues_form_details_bottom(context={})

View File

@@ -0,0 +1,21 @@
#The MIT License (MIT)
#
#Copyright (c) 2026 rick barrette
#
#Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
#
#The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
#
#THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
class ViewLayoutsHookListener < Redmine::Hook::ViewListener
# Load the javascript to support the autocomplete forms
def view_layouts_base_html_head(context = {})
js = javascript_include_tag 'application.js', :plugin => 'redmine_qbo'
js += javascript_include_tag 'autocomplete-rails.js', :plugin => 'redmine_qbo'
js += javascript_include_tag 'checkbox_controller.js', :plugin => 'redmine_qbo'
return js
end
end