diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index 230f09ba2..c99884c36 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -59,7 +59,7 @@ def sentence_type_label(offender)
def vlo_tag(offender)
return '' unless offender.active_vlo? || offender.victim_liaison_officers.any?
- tag.span('VLO CONTACT', class: 'govuk-tag govuk-tag--red')
+ tag.span('VLO contact', class: 'govuk-tag govuk-tag--red')
end
def humanized_bool(bool_value)
diff --git a/app/helpers/early_allocation_helper.rb b/app/helpers/early_allocation_helper.rb
index 8ba0981ab..5604a3bda 100644
--- a/app/helpers/early_allocation_helper.rb
+++ b/app/helpers/early_allocation_helper.rb
@@ -70,10 +70,10 @@ def pom_full_name(early_allocation)
end
EARLY_ALLOCATION_STATUSES = {
- eligible: 'ELIGIBLE',
- decision_pending: 'DECISION PENDING',
- assessment_saved: 'ASSESSMENT SAVED',
+ eligible: 'eligible',
+ decision_pending: 'decision pending',
+ assessment_saved: 'assessment saved',
# in status terms we don't care about the need to make a new assessment
- call_to_action: 'ASSESSMENT SAVED'
+ call_to_action: 'assessment saved'
}.freeze
end
diff --git a/app/views/prisoners/review_case_details.html.erb b/app/views/prisoners/review_case_details.html.erb
index 8af50c8fa..a4dd72ac6 100644
--- a/app/views/prisoners/review_case_details.html.erb
+++ b/app/views/prisoners/review_case_details.html.erb
@@ -396,7 +396,7 @@
Victim liaison officer (VLO)
- NON-DISCLOSABLE
+ Non-Disclosable
|
<% if @prisoner.active_vlo? && @prisoner.victim_liaison_officers.none? %>
diff --git a/app/views/shared/_badges.html.erb b/app/views/shared/_badges.html.erb
index 268dd2b9b..744367b8d 100644
--- a/app/views/shared/_badges.html.erb
+++ b/app/views/shared/_badges.html.erb
@@ -5,7 +5,7 @@
<% status = offender.early_allocation_state %>
<% if EarlyAllocationHelper::EARLY_ALLOCATION_STATUSES.key?(status) %>
- EARLY ALLOCATION <%= EarlyAllocationHelper::EARLY_ALLOCATION_STATUSES.fetch(status) %>
+ Early allocation <%= EarlyAllocationHelper::EARLY_ALLOCATION_STATUSES.fetch(status) %>
<% end %>
<% if offender.restricted_patient? %>
@@ -13,10 +13,10 @@
<% end %>
<% if @prison.womens? %>
<% if offender.complexity_level == 'high' %>
- <%= render('shared/badges/complexity_badge', complexity_badge_text: 'HIGH COMPLEXITY') %>
+ <%= render('shared/badges/complexity_badge', complexity_badge_text: 'High complexity') %>
<% elsif offender.complexity_level == 'medium' %>
- <%= render('shared/badges/complexity_badge', complexity_badge_text: 'MEDIUM COMPLEXITY') %>
+ <%= render('shared/badges/complexity_badge', complexity_badge_text: 'Medium complexity') %>
<% elsif offender.complexity_level == 'low' %>
- <%= render('shared/badges/complexity_badge', complexity_badge_text: 'LOW COMPLEXITY') %>
+ <%= render('shared/badges/complexity_badge', complexity_badge_text: 'Low complexity') %>
<% end %>
<% end %>
diff --git a/app/views/shared/badges/_restricted_patient_badge.html.erb b/app/views/shared/badges/_restricted_patient_badge.html.erb
index 77e73758b..66289043e 100644
--- a/app/views/shared/badges/_restricted_patient_badge.html.erb
+++ b/app/views/shared/badges/_restricted_patient_badge.html.erb
@@ -1 +1 @@
-RESTRICTED PATIENT
\ No newline at end of file
+Restricted patient
diff --git a/spec/features/complexity_level_feature_spec.rb b/spec/features/complexity_level_feature_spec.rb
index b339d9e85..79cf3823a 100644
--- a/spec/features/complexity_level_feature_spec.rb
+++ b/spec/features/complexity_level_feature_spec.rb
@@ -28,7 +28,7 @@
expect(page).to have_text('Complexity of need level')
expect(page).to have_css('#complexity-level', text: 'High')
- expect(page).to have_css('#complexity-badge', text: 'HIGH COMPLEXITY')
+ expect(page).to have_css('#complexity-badge', text: 'High complexity')
within(:css, "td#complexity-level") do
click_link('Change')
@@ -65,7 +65,7 @@
expect(page).to have_current_path(prison_prisoner_allocation_path(prisoner_id: offender.fetch(:prisonerNumber), prison_id: womens_prison.code), ignore_query: true)
expect(page).to have_css('#complexity-level', text: 'Low')
- expect(page).to have_css('#complexity-badge', text: 'LOW COMPLEXITY')
+ expect(page).to have_css('#complexity-badge', text: 'Low complexity')
end
it 'can click back link to return to the prisoner profile page' do
@@ -130,7 +130,7 @@
expect(page).to have_current_path(prison_prisoner_allocation_path(womens_prison.code, offender_no))
expect(page).to have_css('#complexity-level-row', text: 'Low')
- expect(page).to have_css('#complexity-badge', text: 'LOW COMPLEXITY')
+ expect(page).to have_css('#complexity-badge', text: 'Low complexity')
end
end
end
diff --git a/spec/features/early_allocation_badge_feature_spec.rb b/spec/features/early_allocation_badge_feature_spec.rb
index c71a49cfb..d116ec07d 100644
--- a/spec/features/early_allocation_badge_feature_spec.rb
+++ b/spec/features/early_allocation_badge_feature_spec.rb
@@ -11,9 +11,9 @@
sentenceStartDate: sentence_start))
end
let(:offender_no) { nomis_offender.fetch(:prisonerNumber) }
- let(:notes_badge) { 'EARLY ALLOCATION ASSESSMENT SAVED' }
- let(:active_badge) { 'EARLY ALLOCATION DECISION PENDING' }
- let(:approved_badge) { 'EARLY ALLOCATION ELIGIBLE' }
+ let(:notes_badge) { 'Early allocation assessment saved' }
+ let(:active_badge) { 'Early allocation decision pending' }
+ let(:approved_badge) { 'Early allocation eligible' }
before do
signin_spo_user([prison.code])
diff --git a/spec/views/prisoners/show.html.erb_spec.rb b/spec/views/prisoners/show.html.erb_spec.rb
index 45ad82fb8..d3de7044b 100644
--- a/spec/views/prisoners/show.html.erb_spec.rb
+++ b/spec/views/prisoners/show.html.erb_spec.rb
@@ -27,7 +27,7 @@
let(:complexity) { 'low' }
it 'shows low complexity badge' do
- expect(page).to have_content 'LOW COMPLEXITY'
+ expect(page).to have_content 'Low complexity'
end
end
@@ -35,7 +35,7 @@
let(:complexity) { 'medium' }
it 'shows medium complexity badge' do
- expect(page).to have_content 'MEDIUM COMPLEXITY'
+ expect(page).to have_content 'Medium complexity'
end
end
@@ -43,7 +43,7 @@
let(:complexity) { 'high' }
it 'shows high complexity badge' do
- expect(page).to have_content 'HIGH COMPLEXITY'
+ expect(page).to have_content 'High complexity'
end
end
end
diff --git a/spec/views/shared/early_allocation_badge.html.erb_spec.rb b/spec/views/shared/early_allocation_badge.html.erb_spec.rb
index 42d55db0c..a41dc8821 100644
--- a/spec/views/shared/early_allocation_badge.html.erb_spec.rb
+++ b/spec/views/shared/early_allocation_badge.html.erb_spec.rb
@@ -25,10 +25,10 @@
let(:early_allocation) { build(:early_allocation, :pre_window) }
let(:sentence) { attributes_for(:sentence_detail, :outside_early_allocation_window) }
- it 'displays a badge text EARLY ALLOCATION NOTES' do
+ it 'displays corresponding badge' do
expect(badge_count).to eq(1)
expect(early_allocation_badge.attributes['class'].value).to include 'govuk-tag--blue'
- expect(early_allocation_badge.text.strip).to eq 'EARLY ALLOCATION ASSESSMENT SAVED'
+ expect(early_allocation_badge.text.strip).to eq 'Early allocation assessment saved'
end
end
@@ -39,39 +39,39 @@
context 'when rejected' do
let(:early_allocation) { build(:early_allocation, :discretionary_declined) }
- it 'displays badge text EARLY ALLOCATION NOTES' do
+ it 'displays corresponding badge' do
expect(badge_count).to eq(1)
expect(early_allocation_badge.attributes['class'].value).to include 'govuk-tag--blue'
- expect(early_allocation_badge.text.strip).to eq 'EARLY ALLOCATION ASSESSMENT SAVED'
+ expect(early_allocation_badge.text.strip).to eq 'Early allocation assessment saved'
end
end
context 'when it is awaiting review by NSD/LDU' do
let(:early_allocation) { build(:early_allocation, :discretionary) }
- it 'displays badge text EARLY ALLOCATION ACTIVE' do
+ it 'displays corresponding badge' do
expect(badge_count).to eq(1)
expect(early_allocation_badge.attributes['class'].value).to include 'govuk-tag--blue'
- expect(early_allocation_badge.text.strip).to eq 'EARLY ALLOCATION DECISION PENDING'
+ expect(early_allocation_badge.text.strip).to eq 'Early allocation decision pending'
end
end
context 'when it has been approved by NSD/LDU' do
let(:early_allocation) { build(:early_allocation, :discretionary_accepted) }
- it 'displays badge text EARLY ALLOCATION APPROVED' do
+ it 'displays corresponding badge' do
expect(badge_count).to eq(1)
expect(early_allocation_badge.attributes['class'].value).to include 'govuk-tag--blue'
- expect(early_allocation_badge.text.strip).to eq 'EARLY ALLOCATION ELIGIBLE'
+ expect(early_allocation_badge.text.strip).to eq 'Early allocation eligible'
end
end
context 'when it is automatic' do
let(:early_allocation) { build(:early_allocation, :eligible) }
- it 'displays badge text EARLY ALLOCATION APPROVED' do
+ it 'displays corresponding badge' do
expect(early_allocation_badge.attributes['class'].value).to include 'govuk-tag--blue'
- expect(early_allocation_badge.text.strip).to eq 'EARLY ALLOCATION ELIGIBLE'
+ expect(early_allocation_badge.text.strip).to eq 'Early allocation eligible'
end
end
end