opensourcecatholic / marriage-booklet

To help Catholic couples plan their wedding mass
4 stars 2 forks source link

define our `enum`s #32

Closed JohnRDOrazio closed 3 years ago

JohnRDOrazio commented 3 years ago

Now that the Projects model has been generated, it needs to be completed by defining our enums.

liturgy was defined as an integer, since it can become an enum of withMass, withoutMass, and catholicNonCatholic.

Likewise for the Users model, when it will be generated, role can be defined as an enum of bride, groom, celebrant (in reference to the users that have access to the project). Perhaps we could add something like guest to this list, for any other user that the first the couple would like to invite, for example the Graphic Designer / Typographer / Printing Shop.

In the WeddingPartyMembers model, should we define partyMemberRole as an enum also? With a predefined set of roles such as Father, Mother, Parent, Grandparent, Grandfather, Grandmother, Brother, Sister, Friend, Aunt, Uncle etc. ? Or would that be better left as a string, for greater freedom, simply offering some of these suggestions in the UI?

Some suggestions on creating enums here: https://naturaily.com/blog/ruby-on-rails-enum

JohnRDOrazio commented 3 years ago

with the new git history, enums have been defined