プロジェクト

全般

プロフィール

Vote #75531

完了

Ability to render multiple partials with view hook

Admin Redmine さんが4年以上前に追加. 4年以上前に更新.

ステータス:
Closed
優先度:
通常
担当者:
-
カテゴリ:
Plugin API_20
対象バージョン:
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
20
version_id:
80
issue_org_id:
17763
author_id:
73259
assigned_to_id:
1
comments:
7
status_id:
5
tracker_id:
2
plus1:
0
affected_version:
closed_on:
affected_version_id:
ステータス-->[Closed]

説明

Added ability to render multiple partials with view hook


journals

Isn't it easier to add a "parent" partial that groups the other ones you'd want to render ? Maybe you can explain why this is needed.

Plus we need to have some tests if we ever want to merge this in.
--------------------------------------------------------------------------------
It's easier, in case of multiple partials within one plugin, but if you have multiple plugins using the same hook - it's a problem.
--------------------------------------------------------------------------------
any thoughts?
--------------------------------------------------------------------------------
This patch assumes that we're rendering partials which is just one of the many #render options.
I'd like something that does not depend on that.
--------------------------------------------------------------------------------
Here is another option, feedback is welcome. Basically, the syntax would be:

<pre>
render_on :some_hook, :partial => "show_more_data"
render_on :some_hook, {:partial => "show_more_data"}, {:partial => "show_even_more_data"}
render_on :some_hook, {:partial => "show_more_data"}, {:inline => "<%= show_even_more_data %>"}
</pre>
--------------------------------------------------------------------------------
Feature added in r13449.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

Admin Redmine さんが4年以上前に更新

  • カテゴリPlugin API_20 にセット
  • 対象バージョン3.0.0_80 にセット

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0