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

Form submission should save number fields as numbers in JSON #16

Open
timwis opened this issue Sep 30, 2016 · 1 comment
Open

Form submission should save number fields as numbers in JSON #16

timwis opened this issue Sep 30, 2016 · 1 comment

Comments

@timwis
Copy link
Member

timwis commented Sep 30, 2016

In order for this event handler to work, cost's type must be an integer.

if data.cost >= 500:
    change_state('Awaiting CFO Approval')

Which means the form data grabber should recongise the <input type="number"> and save it as a number. This is like the one time when JavaScript is easier :P I assume there's no way to enable loose typing in event handlers, @mjumbewu, but worth asking..

@timwis
Copy link
Member Author

timwis commented Sep 30, 2016

Submitted PR to make this automatic at insin/get-form-data#7

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

1 participant