%# locals: (rule:) %>
<% if displayed_condition.present? %> <%= displayed_condition.filter.label %> <%= displayed_condition.operator %> <%= displayed_condition.value_display %> <% else %> <%= t("rules.no_condition") %> <% end %> <% if additional_condition_count.positive? %> and <%= additional_condition_count %> more <%= additional_condition_count == 1 ? "condition" : "conditions" %> <% end %>
<% if rule.actions.first.nil? %> <%= t("rules.no_action") %> <% else %> <% if rule.actions.first.value && rule.actions.first.options %> <%= rule.actions.first.executor.label %> to <%= rule.actions.first.value_display %> <% else %> <%= rule.actions.first.executor.label %> <% end %> <% end %> <% if rule.actions.count > 1 %> and <%= rule.actions.count - 1 %> more <%= rule.actions.count - 1 == 1 ? "action" : "actions" %> <% end %>
<% if rule.effective_date.nil? %> All past and future <%= rule.resource_type.pluralize %> <% else %> <%= rule.resource_type.pluralize %> on or after <%= rule.effective_date.strftime("%b %-d, %Y") %> <% end %>