https://www.redmine.org/https://www.redmine.org/favicon.ico?16793021292015-12-23T03:36:59ZRedmineRedmine - Patch #21587: Additional view hook for body_tophttps://www.redmine.org/issues/21587?journal_id=680832015-12-23T03:36:59ZToshi MARUYAMA
<ul><li><strong>Related to</strong> <i><a class="issue tracker-2 status-5 priority-4 priority-default closed" href="/issues/17454">Feature #17454</a>: Additional view hook for body_top</i> added</li></ul> Redmine - Patch #21587: Additional view hook for body_tophttps://www.redmine.org/issues/21587?journal_id=686842016-01-18T11:37:27ZGo MAEDA
<ul><li><strong>File</strong> <a href="/attachments/15003">Additional-view-hook-body_top_v2.patch</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/15003/Additional-view-hook-body_top_v2.patch">Additional-view-hook-body_top_v2.patch</a> added</li><li><strong>Priority</strong> changed from <i>High</i> to <i>Normal</i></li><li><strong>Target version</strong> set to <i>3.3.0</i></li></ul><p>+1 for this suggestion. Updated the patch for 3.2.0.devel.15067.</p>
<p>There are following 3 hooks in app/views/layouts/base.html.erb. I think we would be better to add :view_layouts_base_body_head, corresponding with :view_layouts_base_body_bottom.</p>
<ul>
<li>:view_layouts_base_html_head</li>
<li>:view_layouts_base_content</li>
<li>:view_layouts_base_body_bottom</li>
</ul> Redmine - Patch #21587: Additional view hook for body_tophttps://www.redmine.org/issues/21587?journal_id=686872016-01-18T12:28:32ZTobias Fischer
<ul></ul><p>Thanks for review and assigning to 3.3 !</p>
Regarding the naming:<br />I personally would stick to my suggestion <code>:view_layouts_base_body_top</code> and not use <code>:view_layouts_base_body_head</code> as it might be confusing whether it applies to the <code><head></code> or the <code><body></code> element.<br />Also, other view hooks which insert things at the start are named <code>_top</code>:
<ul>
<li><code>:view_issues_new_top</code></li>
<li><code>:view_account_login_top</code> (and correspondant <code>:view_account_login_bottom</code>)</li>
</ul> Redmine - Patch #21587: Additional view hook for body_tophttps://www.redmine.org/issues/21587?journal_id=686912016-01-18T12:44:47ZGo MAEDA
<ul></ul><p>Tobias Fischer wrote:</p>
<blockquote>
<p>I personally would stick to my suggestion <code>:view_layouts_base_body_top</code> and not use <code>:view_layouts_base_body_head</code> as it might be confusing whether it applies to the <code><head></code> or the <code><body></code> element.</p>
</blockquote>
<p>Sorry, my comment on <a class="issue tracker-3 status-5 priority-4 priority-default closed" title="Patch: Additional view hook for body_top (Closed)" href="https://www.redmine.org/issues/21587#note-2">#21587#note-2</a> has an error. Please interpret :view_layouts_base_body_head as :view_layouts_base_body_top.<br />No problem in the patch <a class="attachment" href="https://www.redmine.org/attachments/15003">Additional-view-hook-body_top_v2.patch</a>.</p> Redmine - Patch #21587: Additional view hook for body_tophttps://www.redmine.org/issues/21587?journal_id=687642016-01-20T09:22:18ZJean-Philippe Langjp_lang@yahoo.fr
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>Closed</i></li><li><strong>Assignee</strong> set to <i>Jean-Philippe Lang</i></li></ul><p>Committed, thanks.</p> Redmine - Patch #21587: Additional view hook for body_tophttps://www.redmine.org/issues/21587?journal_id=687802016-01-20T13:57:04ZTobias Fischer
<ul></ul><p>Great, thanks! :)</p>