Skip to content

Commit 1ed58e9

Browse files
committed
Merge pull request #401 from alphagov/tweak-debate-states
Small tweaks to the debate functionality
2 parents fd37dda + dc6ec11 commit 1ed58e9

5 files changed

Lines changed: 19 additions & 16 deletions

File tree

app/views/admin/debate_outcomes/_petition_action_debate_outcome.html.erb

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,18 @@
66
<%= f.text_area :overview, tabindex: increment, class: 'form-control' %>
77
<% end %>
88

9+
<h3 class="petition-action-subheading">Was this petition debated?</h3>
10+
11+
<%= form_row class: 'inline' do %>
12+
<%= f.label :debated_true, nil, class: 'block-label' do %>
13+
<%= f.radio_button :debated, true %> Yes
14+
<% end %>
15+
<%= f.label :debated_false, nil, class: 'block-label' do %>
16+
<%= f.radio_button :debated, false %> No
17+
<% end %>
18+
<%= error_messages_for_field petition, :debated %>
19+
<% end %>
20+
921
<div class="debate-outcome-controls" style="overflow: hidden; clear: left;">
1022
<%= form_row :for => [f.object, :debated_on] do %>
1123
<%= f.label :debated_on, class: 'form-label' %>
@@ -26,20 +38,8 @@
2638
<% end %>
2739
</div>
2840

29-
<h3 class="petition-action-subheading">Was this petition debated?</h3>
30-
31-
<%= form_row class: 'inline' do %>
32-
<%= f.label :debated_true, nil, class: 'block-label' do %>
33-
<%= f.radio_button :debated, true %> Yes
34-
<% end %>
35-
<%= f.label :debated_false, nil, class: 'block-label' do %>
36-
<%= f.radio_button :debated, false %> No
37-
<% end %>
38-
<%= error_messages_for_field petition, :debated %>
39-
<% end %>
40-
41-
<%= f.submit "Save without emailing", name: 'save', class: 'button-secondary' %>
4241
<%= email_petitioners_with_count_submit_button(f, petition) %>
42+
<%= f.submit "Save without emailing", name: 'save', class: 'button-secondary' %>
4343
<% end -%>
4444

4545
<%= javascript_tag do %>

app/views/admin/government_response/_petition_action_government_response.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
<%= f.text_area :details, rows: 8, cols: 70, tabindex: increment, class: 'form-control' %>
1414
<% end %>
1515

16-
<%= f.submit "Save without emailing", name: 'save', class: 'button-secondary' %>
1716
<%= email_petitioners_with_count_submit_button(f, petition) %>
17+
<%= f.submit "Save without emailing", name: 'save', class: 'button-secondary' %>
1818
<% end -%>
1919

2020
<%= javascript_include_tag 'character-counter' %>

app/views/admin/schedule_debate/_petition_action_debate_date.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@
66
<%= f.date_field :scheduled_debate_date, tabindex: increment, class: 'form-control' %>
77
<% end %>
88

9-
<%= f.submit "Save without emailing", name: 'save', class: 'button-secondary' %>
109
<%= email_petitioners_with_count_submit_button(f, petition) %>
10+
<%= f.submit "Save without emailing", name: 'save', class: 'button-secondary' %>
1111
<% end %>

app/views/petitions/_debate_threshold.html.erb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@
3131
</section>
3232
<% else %>
3333
<h2 id="debate-threshold-heading">The Petitions Committee decided not to debate this petition</h2>
34+
<% if debate_outcome.overview? -%>
35+
<%= auto_link(simple_format(h(debate_outcome.overview)), html: { rel: 'nofollow' }) %>
36+
<% end -%>
3437
<% end %>
3538
<%# Has a debate date #%>
3639
<% elsif petition.scheduled_debate_date? -%>

config/locales/petitions.en-GB.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ en-GB:
4444
awaiting_debate: "Awaiting a debate in Parliament (%{quantity})"
4545

4646
list_headers:
47-
not_debated: "The Petitions Committee decided not to debate these petition"
47+
not_debated: "The Petitions Committee decided not to debate these petitions"
4848

4949
facets:
5050
public:

0 commit comments

Comments
 (0)