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

Editing entires in Number Field with value of 0 returns a blank field #3024

Closed
stonge85 opened this issue Feb 27, 2019 · 6 comments
Closed

Comments

@stonge85
Copy link

PLEASE READ THIS LINE & Then Delete - We need this information to best understand your issue, please answer all questions!

Do You Need Immediate Help?

Is This A Feature Request?

  • If so, that's fine, please describe your desired featured and delete the rest of this template.

What Version Of Caldera Forms, WordPress and PHP Are You Using?

*You can copy the "Short Debug" line from the Caldera Forms support menu's debug tab

Does Your Issue Persist When You Disable All Other Plugins and Switch To The Default Theme?

What Is The Unexpected Behaviour?

  • Please explain what you did, what you expected to happen, and what happened instead.

What PHP Errors Have You Logged While Reproducing This Bug?

What JavaScript Errors Have You Seen While Reproducing This Bug?

@stonge85 stonge85 changed the title Editing entires Editing entires in Number Field with value of 0 returns a blank field Feb 27, 2019
@stonge85
Copy link
Author

When editing a number field entry that is set to 0, the entry form does not populate; meaning the field is blank. If this is a required field, the entry will not save until the field is repopulated.

@stonge85
Copy link
Author

This issue has been open for over a year. How do we get this on the roadmap to get it resolved.

@Shelob9
Copy link
Collaborator

Shelob9 commented Jan 28, 2020

Added tests in f692ea7

Bug is most likely introduced here: f14ec74#diff-f81f3dff36bf04b7a070d642c858e883

@Shelob9
Copy link
Collaborator

Shelob9 commented Jan 28, 2020

Here, we're checking if saved value is empty, whioch '0' and 0 are.

https://github.com/CalderaWP/Caldera-Forms/blob/master/classes/field/input.php#L21

Shelob9 added a commit that referenced this issue Jan 28, 2020
@Shelob9
Copy link
Collaborator

Shelob9 commented Jan 28, 2020

Should be fixed via #3471

@New0
Copy link
Collaborator

New0 commented Jan 30, 2020

Closed via - d19d7d9 -

@New0 New0 closed this as completed Jan 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants