Spiegel von
https://github.com/paviliondev/discourse-custom-wizard.git
synchronisiert 2024-11-22 09:20:29 +01:00
FIX: reset step progress on wizard skip
Dieser Commit ist enthalten in:
Ursprung
249cda4de6
Commit
0d2f3d1cb5
2 geänderte Dateien mit 6 neuen und 1 gelöschten Zeilen
|
@ -69,6 +69,7 @@ class CustomWizard::WizardController < ::ApplicationController
|
|||
end
|
||||
|
||||
submission.remove if submission.present?
|
||||
wizard.cleanup!
|
||||
end
|
||||
|
||||
render json: result
|
||||
|
|
|
@ -286,11 +286,15 @@ class CustomWizard::Wizard
|
|||
end
|
||||
end
|
||||
|
||||
def final_cleanup!
|
||||
def cleanup!
|
||||
if id == user.custom_fields['redirect_to_wizard']
|
||||
user.custom_fields.delete('redirect_to_wizard')
|
||||
user.save_custom_fields(true)
|
||||
end
|
||||
end
|
||||
|
||||
def final_cleanup!
|
||||
cleanup!
|
||||
|
||||
if current_submission.present?
|
||||
current_submission.submitted_at = Time.now.iso8601
|
||||
|
|
Laden …
In neuem Issue referenzieren