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

Required checkboxes #1372

Closed
nilshoerrmann opened this issue Jun 16, 2012 · 9 comments
Closed

Required checkboxes #1372

nilshoerrmann opened this issue Jun 16, 2012 · 9 comments

Comments

@nilshoerrmann
Copy link
Contributor

It should be possible to make checkboxes required (thinking of terms of service that users/members have to agree with).

@michael-e
Copy link
Member

As far as I remember, there is an extension which provides a required checkbox field. But yes, it would be nice to have this functionality in the core field.

@klaftertief
Copy link
Contributor

The extension: http://symphony-cms.com/download/extensions/view/51603/

I used it in some projects some time ago. Haven't tested it with recent versions though.

@nilshoerrmann
Copy link
Contributor Author

Yeah, I've seen the extension but thought it was a joke that I need to install anything at all for this task :)

@nickdunn
Copy link
Contributor

I don't think this should be a core thing, because the vast majority of the time you don't need it. A compulsory checkbox for agreeing to T&Cs isn't part of a data model; it's a one-time validation before you create the entry. Having a field that would always be ticked for every entry doesn't make sense to me.

To satisfy this requirement in the past I either add a small custom check to my event, or add a Text Input field with a regex validator for a string "yes" (and set thi to be the checkbox value in the form). But I prefer the custom event method because it means I don't muddy my data model with one-off validation.

@nilshoerrmann
Copy link
Contributor Author

I don't agree. Requiring a field is a core functionality – a functionality all fields should share.

@nilshoerrmann
Copy link
Contributor Author

Just to make my point clear: I don't think a front-end TOS is the only situation where you might need a required checkbox. Think of an inventory control system that is using the backend directly where the user – due to some legal requirements – has to confirm certain regulation each time he places an order.

And even if you think that you most likely will never have a need for this yourself, others should be able to create such a setup. Symphony's philosophy is not to make assumptions – and it should stick to this idea for checkboxes as well.

@brendo brendo closed this as completed in 8c625f1 Jun 19, 2012
@patrickyan
Copy link

Is this supposed to work? I have a checkbox set to "make this a required field", but I'm allowed to make entries without it checked.

@michael-e
Copy link
Member

See #1730. You will need the latest code.

@patrickyan
Copy link

Thanks!

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

6 participants