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 autofill boolean fields #7347

wants to merge 3 commits into
base: staging


3 participants
Copy link

kuzmany commented Mar 25, 2019

Please be sure you are submitting this against the staging branch.

Bug fix?
New feature?
Automated tests included?
Related user documentation PR URL
Related developer documentation PR URL
Issues addressed (#s or URLs) #6096
BC breaks?


Reported issue #6096
Noticed wrong value sanitize for boolean fields.
Also fixed for mapping autofill boolean radio/checkbox group.
This PR fixed it

Steps to reproduce the bug:

  1. Create 2 boolean custom fields (like below)
  2. Create a form and add 3 form field
    2.1 Add email form field map to email custom field
    2.2 Add a radio group form field map to the first boolean custom field previously created.
    In the properties tab, click on YES
    Go on the behavior tab and click on YES to auto fill data
    2.3 do the same for the second radio group form field
  3. Create a landing page and add the form inside (with token or automatic copy, it's up to you)
  4. Save the LP and open a new session.
  5. Fill the form.
  6. After filling the form, refresh the page and see that the first boolean field is checked on YES or NO (depends on what you filled).
    See that the second boolean field is not checked (even if when you set, you clicked on auto fill data YES)
  7. Go back in the form edition, change the order of boolean field
    First I got the the bool1 and bool2
    Now I have bool2 and bool1
    Go back on the landing page and refresh
    See that now bool2 is checked (earlier it was bool1) and the other one is not checked.

Steps to test this PR:

  1. Load up this PR
  2. Check If checkbox group/radio groups works properly for boolean type and autofill

This comment has been minimized.

Copy link

npracht commented Mar 26, 2019

@johbuch please test and confirm it works or not.

@npracht npracht added the Code Review label Mar 26, 2019

@npracht npracht added this to the 2.16.0 milestone Mar 26, 2019

Copy link

johbuch left a comment

tested on mautibox, it works. thanks zdeno !

@npracht npracht modified the milestones: 2.16.0, 2.15.2 Mar 28, 2019

@npracht npracht added this to Ready to Test (confirmation) in Mautic 2 Apr 4, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.