Skip to content

netteForms.js: Show all error messages at once #65

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

Closed
wants to merge 3 commits into from

Conversation

hranicka
Copy link
Contributor

Nette shows only the first form error. And after user reparation shows the next error etc.

I think show all errors at once is more user friendly.
So I've created PR which adds this behavior.

I think it will be necessary work on it before merge (eg. add options like "show one by one error"/"show all errors at once").

What do you think about that?

/**
* Shows an alert.
*/
Nette.alert = function(message) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've added this while I'm working on "show all messages at once".

Tt would be nice to have an option redefine "show alert" function and create custom handlers.

@dg dg force-pushed the master branch 2 times, most recently from 131f7d2 to 532059a Compare May 21, 2015 11:49
Conflicts:
	src/assets/netteForms.js
@hranicka
Copy link
Contributor Author

I've updated the PR and resolved merge conflicts with current master.

It changes current behavior of error alerts, see my original comment.

Client can override Nette.showErrors and Nette.alert with custom behavior.

@janedbal
Copy link

👍 for showing all errors at once

@hranicka
Copy link
Contributor Author

@janedbal I don't like (as common web user) one-by-one error.
I like to know all errors and fix them at once.

Instead of repair error, send form, get another error, repair another error, send form, ...

@hranicka hranicka force-pushed the feature/alert-messages branch from 4b40023 to 6313660 Compare May 27, 2015 06:47
@dg dg force-pushed the master branch 2 times, most recently from a57a557 to 55d0eb8 Compare June 19, 2015 12:05
@dg dg force-pushed the master branch 2 times, most recently from 9e359e6 to fa84d63 Compare April 5, 2016 23:23
@dg dg force-pushed the master branch 2 times, most recently from 3c1619a to 31bc0a3 Compare April 11, 2016 01:44
@dg dg force-pushed the master branch 7 times, most recently from 6b04b51 to d1c30d6 Compare April 21, 2016 13:03
@dg dg force-pushed the master branch 4 times, most recently from 2b19f43 to fd381fb Compare May 18, 2016 23:49
@dg dg force-pushed the master branch 7 times, most recently from 81549c5 to 98832d3 Compare June 7, 2016 11:43
@dg dg force-pushed the master branch 6 times, most recently from 2b44619 to 4473513 Compare June 30, 2016 00:32
@dg dg closed this in a357520 Jun 30, 2016
@dg
Copy link
Member

dg commented Jun 30, 2016

Merged, thanks.

dg pushed a commit that referenced this pull request Jun 30, 2016
dg pushed a commit that referenced this pull request Jun 30, 2016
dg pushed a commit that referenced this pull request Jun 30, 2016
dg pushed a commit that referenced this pull request Jun 30, 2016
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

Successfully merging this pull request may close these issues.

3 participants