Implement etiquette validator on meetings#12876
Implement etiquette validator on meetings#12876arpi-tremend wants to merge 18 commits intodecidim:developfrom
Conversation
|
@arpi-tremend we need to discuss this on @decidim/product - as I mentioned in #12713 (comment) I'm not sure if the proposed solution (extend this validation in Meetings and then everywhere for consistency) is the correct one. The last times that we've talked about this feature we were really hesitant if this was actually useful or if it was a problem (and it should be go away). |
After some discussion with @carolromero, she proposes:
To give more detail in how this would look like, this is what we've come up with:
@arpi-tremend @alecslupu let me know if you agree with these criteria and if you can work on all of these (or some or none). Thanks! |
…e/update-meeting-with-empty-body
|
There are some failing specs that should be fixed if you merge/rebase with develop. Can you do it @arpi-tremend 🙏🏽 ? Thanks |
As @arpi-tremend is in my other team, i will take over this one. |
…ate-meeting-with-empty-body
|
@alecslupu let me know when this is ready for a review |
…ate-meeting-with-empty-body
…ate-meeting-with-empty-body
…ate-meeting-with-empty-body
…ate-meeting-with-empty-body
…ate-meeting-with-empty-body
| validates :registration_type, presence: true | ||
| validates :available_slots, numericality: { greater_than_or_equal_to: 0 }, presence: true, if: ->(form) { form.on_this_platform? } | ||
| validates :registration_terms, presence: true, if: ->(form) { form.on_this_platform? } | ||
| validates :registration_terms, presence: true, etiquette: true, if: ->(form) { form.on_this_platform? } |
There was a problem hiding this comment.
| validates :registration_terms, presence: true, etiquette: true, if: ->(form) { form.on_this_platform? } | |
| validates :registration_terms, presence: true, if: ->(form) { form.on_this_platform? } |
There was a problem hiding this comment.
No need to implement the ettiquette validator in the ToS of the meeting
| validates :iframe_embed_type, inclusion: { in: Decidim::Meetings::Meeting.participants_iframe_embed_types } | ||
| validates :title, presence: true | ||
| validates :description, presence: true | ||
| validates :title, presence: true, etiquette: true |
There was a problem hiding this comment.
Can you add a spec for this?
| validates :title, presence: true | ||
| validates :description, presence: true | ||
| validates :title, presence: true, etiquette: true | ||
| validates :description, presence: true, etiquette: true |
There was a problem hiding this comment.
Can you add a spec for this?
|
Closing in favor of #12874 |
Meeting can be updated with an empty body
📌 Related Issues
Link your PR to an issue
Testing
TitleandDescriptionfields contentcan't be blank,must start with a capital letteris using too many capital letters (over 25% of the text)Registration termfield, if theRegistration typeis set to 'On this platform'📷 Screenshots
b2b2-74e3dff22590)