Browse Source

feat: wip update scheme summary page

pull/980/head
natdeanlewissoftwire 2 years ago
parent
commit
c9dada8d89
  1. 2
      app/helpers/tag_helper.rb
  2. 6
      app/models/scheme.rb

2
app/helpers/tag_helper.rb

@ -6,6 +6,7 @@ module TagHelper
cannot_start_yet: "Cannot start yet",
in_progress: "In progress",
completed: "Completed",
active: "Active",
}.freeze
COLOUR = {
@ -13,6 +14,7 @@ module TagHelper
cannot_start_yet: "grey",
in_progress: "blue",
completed: "green",
active: "green",
}.freeze
def status_tag(status, classes = [])

6
app/models/scheme.rb

@ -168,6 +168,8 @@ class Scheme < ApplicationRecord
{ name: "Secondary client group", value: secondary_client_group },
{ name: "Level of support given", value: support_type },
{ name: "Intended length of stay", value: intended_stay },
{ name: "Availability", value: "Available from #{available_from.to_formatted_s(:govuk_date)}" },
{ name: "Status", value: "" },
]
if arrangement_type_same?
@ -230,4 +232,8 @@ class Scheme < ApplicationRecord
end
end
end
def available_from
created_at
end
end

Loading…
Cancel
Save