DarkmiraTour / community-event-manager

Web application with a collection of tools helping people organising community events such as multi-days conference with reminders, CRM and such
GNU General Public License v3.0
21 stars 22 forks source link

Remove the mandatory title when adding a slot and chosing a talk #216

Closed kevinjhappy closed 4 years ago

kevinjhappy commented 4 years ago

Description

When you want to add a slot, you can add a coffee break, a workshop, a talk or other stuff For all options the title is mandatory, but when you pick a talk you have to choose between a list of recorded talks, identified by their title, but the field title is still present and mandatory, so you have a double input for the same iinformation, which is wrong

Behavior to get : When you choose the talk option in this page, the field title disapears and the talk you choose with the dropdown list ill be the title

Screen new issue

Scenarios

Feature : remove title from the add a slot option when choosing a talk

Scenario: User select add a slot Given the user is connected with a role_admin When the user land on a add a slot from And user choose type talk Then the field Title must be hidden And the user complete the form choosing a talk as title

saadismail commented 4 years ago

Please assign this to me. I want to work on it tomorrow.

tdutrion commented 4 years ago

Done, you're assigned!

saadismail commented 4 years ago

Thank you.

I have done the changes using JS: https://github.com/saadismail/community-event-manager/commit/3bc8abafb097eb862f3398f8fb1c3c1673749c4e

I am not sure if this is the right way or we should do it from Symfony Form/Entity/Dto level since I have no former experience with Symfony. Please let me know if this is not how it should be, otherwise I will submit a PR.

tdutrion commented 4 years ago

This way is totally fine given it's an admin tool. I would probably be in favour of a Symfony based solution if we had to do a hard validation, but in this case it does not really matter I guess.