Submit social housing lettings and sales data (CORE)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

8 lines
373 B

module DeactivateConfirmHelper
def affected_title(affected_logs, affected_locations)
title_parts = []
title_parts << pluralize(affected_logs.count, "log") if affected_logs.count.positive?
title_parts << pluralize(affected_locations.count, "location") if affected_locations.count.positive?
"This change will affect #{title_parts.join(' and ')}."
end
end