Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #10624 - Prevent Multiple Submissions on Survey Forms #10625

Open
wants to merge 1 commit into
base: hotfix
Choose a base branch
from

Conversation

SinergiaCRM
Copy link
Contributor

Description

As described in #10624 , survey response forms allowed multiple identical submissions when users repeatedly clicked the "submit" button before the usual redirection occurred.

This issue has been resolved by modifying the survey response form code. The "submit" button is now disabled upon the first activation (submission) to prevent additional clicks.

Motivation and Context

This change is required to ensure data integrity and avoid multiple identical responses from a single user. By disabling the "submit" button immediately after submission, it eliminates the possibility of repeated actions before redirection, improving the reliability of survey results.

How To Test This

  1. Create a survey and make it public.
  2. Access the survey link, respond to the survey, and try pressing the "submit" button repeatedly.
  3. Verify that it is no longer possible to press the "submit" button multiple times.
  4. Check the CRM to ensure that only the correct (single) response has been recorded and that no duplicate responses appear.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Final checklist

  • My code follows the code style of this project found here.
  • My change requires a change to the documentation.
  • I have read the How to Contribute guidelines.

Copy link
Member

@mattlorimer mattlorimer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍🏻

@mattlorimer mattlorimer added Status: Passed Code Review Mark issue has passed code review reviewed PR 1-3 Complexity Score given to PRs once assessed labels Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR 1-3 Complexity Score given to PRs once assessed Status: Passed Code Review Mark issue has passed code review reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants