Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Joe Dolson

    (@joedolson)

    That’s an interesting idea. How would you be determining that? Based on your current location?

    At the moment there’s no filter available for dynamically setting the default category. You could do it by toggling the option value for the option ‘mc_default_category’, but that’s the only way at the moment. I am curious how you intend to use this, however.

    Thread Starter lwoods

    (@lwoods)

    I have multiple organization “Home Pages” within my single site. Each organization has their own calendar. I have added a custom field to each user that specifies which organization they are associated with. Based upon the value of this custom field I would like to set the default Event Category—in order to guarantee that each event gets put into the correct calendar. In fact what I would REALLY like is to force the category. I CAN do this through your API hooks at event save and event edit. Maybe that would be best.

    Plugin Author Joe Dolson

    (@joedolson)

    If you only want your various organizations to be able to post to their own calendars, then what you really want to be changing is the value at event_save – changing the default value would still allow them to change it, and submit something else. Changing the actual value saved would be much more certain.

    You can then simply hide the event category field from your users, so that they don’t have to think about that factor.

    Thread Starter lwoods

    (@lwoods)

    Hide via CSS or do you have a filter?

    Plugin Author Joe Dolson

    (@joedolson)

    You can turn off the category field in the My Calendar input display settings.

    Thread Starter lwoods

    (@lwoods)

    Under “Calendar Input Fields” I have everything checked except Event Category field. I am logged in as an Administrator and I have also checked “Administrators see all input options”. I saved the changes and verified that the changes were made. Then I went into “Add Event” ( still logged in as an Administrator ) but the “Categories” dropdown doesn’t show! Since I am an Administrator I assumed that I would see ALL input options but it looks like the unchecked “Event Category field” is being recognized.

    What am I missing?

    Plugin Author Joe Dolson

    (@joedolson)

    You can also modify settings on an individual level, through the screen options on the event management page. Do you event categories off there?

    Thread Starter lwoods

    (@lwoods)

    If you are talking about “My Calendar Permissions” there is no option for showing event categories. There is an “Edit Events” that I have unchecked for Editor, for example, but Administrator isn’t a role type here.

    Here is what I have:

    I am an Administrator

    Settings > Input > Show Event Manager

    Everything set except “Event Category”

    I log out and log back in as an Editor. No Event Category dropdown as expected.
    I log back in as Administrator and try to create an event and I don’t have the Event Category dropdown either—but I should since I had checked Administrators see all…..

    Plugin Author Joe Dolson

    (@joedolson)

    No, I’m talking about “Screen Options”.

    On the event management page, find and click on Screen Options, in the upper right corner. See if you need to enable the setting there. Those are your personal settings for which inputs to see.

    Thread Starter lwoods

    (@lwoods)

    Bingo! That’s not the first time that I have gotten burned by that damned “feature”.

    Thanks

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Need to set default event category in Add Event’ is closed to new replies.