Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Gareth Evans 12 posts 71 karma points c-trib
    Nov 16, 2013 @ 23:56
    Gareth Evans
    0

    Doc Type Dilemma - Multiple answers but which one is best?

    All,

    I have a doc type dilemma for you all, I think I have a possible solution myself but it doesn't feel "tidy" enough for my doc type OCD so I've come here to see what you guys think.

    I have a doc type called "Event Detail", as the name suggests it is used for holding the details of an Event like title, bit of a blurb about whats going on etc. It also holds details on the dates. The event can span multiple dates but will only use one of the following:

    • Single Day, eg - 04 Jan 2014
    • Multiple Consecutive Dates eg - 04 Jan 2014, 05 Jan 2014, 06 Jan 2014.
    • Multiple Non-Consecutive Dates eg - 04 Jan 2014, 05 Jan 2014, 11 Jan 2014, 12 Jan 2014, 18 Jan 2014, 19 Jan 2014.

    The Single Day and Multiple Consecutive Dates are fairly simple, you have a Start Date [Date Picker] (Mandatory field) and an End Date [Date Picker] (optional field / nullable)....the dilemma is this, how to be able to have this doc type span multiple non-consecutive dates but keeping it tidy in the tree structure.

    The options I have available:

    Option One - have the properties Start Date [Date Picker] (Mandatory), End Date [Date Picker] (optional / nullable) on the Event Detail doc type. Then a child type called Event Detail Dates below Event Detail with 2 properties - Start Date [Date Picker] (Mandatory), End Date [Date Picker] (optional / nullable).

    Yes it would work, but there isn't much validation available, for example an editor can set the same Start Date and End Date on the Event Detail and on an Event Detail Dates child type.

    Option Two - Have all of the dates under a Settings node, with the property Date [Date Picker] (mandatory) on, each day would be a seperate node. then have a Mutli Node Tree Picker on the Event Detail which allows the editor to select one or multiple dates from that list.

    This seems tidyier but it would need alot more code for this to figure out which event was on which day.

    Possible Option Three - Any way something like this would work using Relations?

    To give you an idea on the number of dates or events that would need to be entered, here is the timetable from 2013, http://gcrn.co.uk/timetables-prices/timetables/

    Your thoughts please.

    Thank you

    Gareth

Please Sign in or register to post replies

Write your reply to:

Draft