Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
priyapower committed Jul 17, 2024
1 parent 1bea453 commit 77309c9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/components/form/title_component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ def initialize(title:, subtitle:, step: nil, total_steps: nil, notes: nil, autos
@notes = notes
@autosave = autosave
@navigable = navigable

if step && total_steps
@steps_in_text = "Step #{step} of #{total_steps}"
@progress = (step.to_d / total_steps.to_d) * 100
Expand Down
5 changes: 2 additions & 3 deletions app/controllers/case_contacts/form_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def update
@page = wizard_steps.index(step) + 1
@total_pages = steps.count
@nav_step = params[:nav_step]

params[:case_contact][:status] = step.to_s if !@case_contact.active?
remove_unwanted_contact_types
remove_nil_draft_ids
Expand All @@ -32,7 +32,7 @@ def update
respond_to do |format|
format.html {
if @nav_step.present?
jump_to(@nav_step.split('/').last.to_sym)
jump_to(@nav_step.split("/").last.to_sym)
render_wizard @case_contact, {}, {case_contact_id: @case_contact.id}
elsif step == steps.last
finish_editing
Expand Down Expand Up @@ -160,4 +160,3 @@ def set_steps
self.steps = CaseContact.find(params[:case_contact_id]).form_steps
end
end

0 comments on commit 77309c9

Please sign in to comment.