CoderDojo / community-platform

Zen, the CoderDojo Community Platform!
https://zen.coderdojo.com
MIT License
121 stars 55 forks source link

Event creation form: default event data to the previous one #1259

Closed Wardormeur closed 4 years ago

Wardormeur commented 5 years ago

Epic: https://github.com/CoderDojo/community-platform/issues/1230 Requires https://github.com/CoderDojo/community-platform/issues/1230 Porting the previous "copy event" to a simpler state: copy the previous state of an event by default. This means :

conoramurphy-zz commented 5 years ago

To clarify

Wardormeur commented 5 years ago

To clarify

  • the description should be defaulted to the latest event's one or the dojos if there is none

Agreed

  • the address type and value should be defaulted to the latest event's one or the dojos if there is none

Which is the Dojo one by default, but fair as this is dictated by the front-end

  • the date should be bumped to the next occurence of the day in the future (previous event on Monday 23; form being created 3 days later as a new event; new date is Monday 30) I think we're getting too clever here and just leave date empty, time I think should be copied

Agreed on time, I didn't mention it. For day, the one described is the current behavior, and is honestly quite useful, I'm hoping we keep it, but it's your call.

  • event name should be copied from last event's should we not leave this blank?, you'll have the wrong name in there

It depends if you put the day in it or not. No hard feeling on that one, you decide.

  • the status of the event should be defaulted to 'draft', not published or cancelled explain this, do you mean saved automatically? Or the default on the main button? If the latter I disagree, publish should be default

It means when copying an event, it copies all these fields, but ensure that the status of the new event will not be saved as canceled when publishing it.

  • Any unexpected ticket (coming from the old event UI) should be reset to the 2 default ones, how could we get an unexpected ticket to a new event?

By copying the latest event. All the latest events will not match the new UI's format (example, I have a hardware ticket, or 2 sessions). We ensure that despite the format, we're not trying to match nor the quantity, nor the tickets from existing events if they have more than 3 tickets type and it's not "parent, mentor and kids"

conoramurphy-zz commented 5 years ago

the date should be bumped to the next occurence of the day in the future (previous event on Monday 23; form being created 3 days later as a new event; new date is Monday 30) I think we're getting too clever here and just leave date empty, time I think should be copied Agreed on time, I didn't mention it. For day, the one described is the current behavior, and is honestly quite useful, I'm hoping we keep it, but it's your call.

Had not realised this. Once we use somethign very akin to the current logic I'm fine with this.

Let's leave the title blank.

the status of the event should be defaulted to 'draft', not published or cancelled explain this, do you mean saved automatically? Or the default on the main button? If the latter I disagree, publish should be default It means when copying an event, it copies all these fields, but ensure that the status of the new event will not be saved as canceled when publishing it. Any unexpected ticket (coming from the old event UI) should be reset to the 2 default ones, how could we get an unexpected ticket to a new event? By copying the latest event. All the latest events will not match the new UI's format (example, I have a hardware ticket, or 2 sessions). We ensure that despite the format, we're not trying to match nor the quantity, nor the tickets from existing events if they have more than 3 tickets type and it's not "parent, mentor and kids"

I don't think you should have the "copy last event" functionality in this. The defaults basically make that mostly pointless unless you've complex requirements which we should avoid with this. ANd that covers these two use cases?

Wardormeur commented 5 years ago

We're speaking of the same thing, except I'm using the old terminology. By copying, I mean defaulting for a new event. I'm not speaking of bringing back the action, just that the new event will be based off the previous event. That's where some things are tricky, because very few of the previous events from existing Dojos will fit the new format. Hence those questions regarding "what to do with the existing Dojo's event when defaulting is a non-match"