summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2026-07-16 16:43:11 +0200
committererdgeist <erdgeist@erdgeist.org>2026-07-16 16:43:11 +0200
commit35dc05de97677d57123617a7c4e78aad1611b28d (patch)
tree2960f3a8d363a12edd497fc96a022a9da77929fd /app/views
parentb701669d0d9a5d7be01f99b8e725c05c6c5d52ce (diff)
managed RRULE constructs now include week selection
Improve the humanizer to also understand weekly patters that an editor can manually select, on top of the single week rules. Extend template and javascript controller to reflect these changes.
Diffstat (limited to 'app/views')
-rw-r--r--app/views/events/edit.html.erb8
1 files changed, 7 insertions, 1 deletions
diff --git a/app/views/events/edit.html.erb b/app/views/events/edit.html.erb
index b6564a4..bf8cb35 100644
--- a/app/views/events/edit.html.erb
+++ b/app/views/events/edit.html.erb
@@ -56,9 +56,15 @@
56 <div id="rrule_monthly_options" style="display: none;"> 56 <div id="rrule_monthly_options" style="display: none;">
57 <p><label><%= check_box_tag "rrule_monthly_ordinal" %> On a specific weekday each month</label></p> 57 <p><label><%= check_box_tag "rrule_monthly_ordinal" %> On a specific weekday each month</label></p>
58 <p id="rrule_ordinal_fields" style="display: none;"> 58 <p id="rrule_ordinal_fields" style="display: none;">
59 <%= select_tag "rrule_ordinal", options_for_select([["1.", 1], ["2.", 2], ["3.", 3], ["4.", 4], ["letzter", -1], ["vorletzter", -2]]) %> 59 <%= select_tag "rrule_ordinal", options_for_select([["1.", 1], ["2.", 2], ["3.", 3], ["4.", 4], ["letzter", -1], ["vorletzter", -2], ["Selected weeks", "custom"]]) %>
60 <%= select_tag "rrule_ordinal_day", options_for_select(%w[MO TU WE TH FR SA SU].map { |c| [RruleHumanizer::WEEKDAY_NAMES[:de][c], c] }) %> 60 <%= select_tag "rrule_ordinal_day", options_for_select(%w[MO TU WE TH FR SA SU].map { |c| [RruleHumanizer::WEEKDAY_NAMES[:de][c], c] }) %>
61 </p> 61 </p>
62 <p id="rrule_custom_ordinal_fields" style="display: none;">
63 Weeks of the month:
64 <% (1..5).each do |ordinal| %>
65 <label><%= check_box_tag "rrule_custom_ordinal_#{ordinal}" %> <%= ordinal %>.</label>
66 <% end %>
67 </p>
62 </div> 68 </div>
63 <p> 69 <p>
64 <label><%= check_box_tag "rrule_exclude_month" %> Except in one month</label> 70 <label><%= check_box_tag "rrule_exclude_month" %> Except in one month</label>