Tagelin Rota - Wordpress Plugin

Description

The plugin is used by embedding shortcodes into your page.

There are 5 setup shortcodes and one for the finished display.

These shortcodes are referred to as Role, People, Location, Event, Schedule and View.

The set of shortcodes all work together in groups to enable multiple, independent schedules to be defined, each with their own people, roles, events.

Each set of shortcodes work as part of a named group, enabling different sets of people/roles to be used in each group.

Download

The latest version of the plugin may be downloaded as a zip file from here.

Installation

  1. Download the zip file and unzip it into your plugins directory or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the 'Plugins' screen in WordPress.
  3. Create pages to contain the setup shortcodes. These could be privately owned if you wish.
  4. Put the View shortcode where you wish to see the finished schedule.

Setup

Setup Roles

  1. In the page editor use the text mode to put the shortcode on the page:
    [tagelin-rota group="whatever" type="edit-role" title="Skills" ]
    

    The group defines the group of resources we will be using. You can give it any name.

    The type must be "edit-role", since we want the Edit Role widget to be embedded in the page.

    The title is the text used in the heading for this editor.

    Publish the page. You may mark it private if you wish.

    When you are finished it should look like this:

  2. View the published page.

    The editor consists of a, currently empty, listbox on the left and an edit panel on the right.

  3. Create a new Role.

    Click on the "New" button.

  4. Enter the name of the Role in the editor panel.

    Click on the "Save" button

    When the Role is saved it is added to the Roles listbox:

  5. Add other Roles, as required.
  6. You may change the Role names by selecting the item in the list and clicking it to enable edit mode.

    You need to use "Save" to save your changes or "Cancel" to revert to the previous name.

  7. You may delete a Role by selecting it and pressing "Delete".

Setup People

  1. Go back to the page editor. Use the text mode to put the person shortcode on the page, below the role one:
    [tagelin-rota group="whatever" type="edit-person" title="People" ]
    

    The group defines the group of resources we are using. It must match that in the edit-role shortcode.

    The type must be "edit-person", since we want the Edit Person widget to be embedded in the page.

    The title is the text used in the heading for this editor.

    Save and update the page.

    When you are finished it should look like this:

  2. View the published page.

    The Person editor is displayed below the Role editor:

  3. Create a new Person.

    Click on the "New" button.

  4. Enter the name of the Person in the editor panel.

    You may enter optional contact details.

    Select the roles for this person by clicking in the attributes list in the right-hand panel.

  5. Click on the "Save" button.

    When the Person is saved it is added to the listbox.

  6. Add other people, as required.

Setup Event Profiles

  1. Go back to the page editor. Use the text mode to put the event shortcode on the page, below the person one:
    [tagelin-rota group="whatever" type="edit-event" title="Activities" ]
    

    The group defines the group of resources we are using. It must match that in the other shortcodes.

    The type must be "edit-event", since we want the Edit Event widget to be embedded in the page.

    The title is the text used in the heading for this editor.

    Save and update the page.

    When you are finished it should look like this:

  2. View the published page.

    The Event editor is displayed below the Person editor:

  3. Create a new Event type.

    Click on the "New" button.

  4. You need to give a name for this type of event. In our example "Games Night".

  5. Then you need to say what roles are needed for this type of event.

    Select the role from the dropdown.

  6. Click on the "Add" button.

    The Role is added to the event roles list in the right-hand panel.

    The checkbox next to each role is used to show you want that Role. This is the default. If a Role is not checked it will be deleted when you save the event.

  7. Add other roles as required.

    If the role has a better name in the context of this event put that in the "Role Name" field. Otherwise leave this blank and we will use the role name as it is.

  8. You may change a role by clicking it in the right-hand-panel then editing the details in the edit boxes.

    Use "Add" to save it.

  9. You may change the order of the Roles by clicking it and using the Up and Down arrows to move it to place.

  10. Click on the "Save" button.

    When the Event is saved it is added to the listbox.

  11. Add other event definitions, as required.

Setup Locations

  1. Go back to the page editor. Use the text mode to put the location shortcode on the page, below the event one:
    [tagelin-rota group="whatever" type="edit-location" title="Location" ]
    

    The group defines the group of resources we are using. It must match that in the other shortcodes.

    The type must be "edit-location", since we want the Edit Location widget to be embedded in the page.

    The title is the text used in the heading for this editor.

    Save and update the page.

    When you are finished it should look like this:

  2. View the published page.

    The Location editor is displayed below the Event editor:

  3. Create a new Location type.

    Click on the "New" button.

    Enter location name.

  4. Click on the "Save" button.

    When the Location is saved it is added to the listbox.

  5. Add other locations, as required.

Schedule Events

  1. Go back to the page editor. Use the text mode to put the schedule shortcode on the page, below the location one:
    [tagelin-rota group="whatever" type="edit-schedule" title="Schedule" ]
    

    The group defines the group of resources we are using. It must match that in the other shortcodes.

    The type must be "edit-schedule", since we want the Edit Schedule widget to be embedded in the page.

    The title is the text used in the heading for this editor.

    Save and update the page.

    When you are finished it should look like this:

  2. View the published page.

    The Schedule editor is displayed below the Location editor.

  3. Create a new Scheduled Event.

    Click on the "New" button.

    The "Name" field is the optional.

    You need to say what type of event this is. Use the "Event" dropdown.

    The appropriate roles are then shown in the right-hand panel.

    Select a time and location for the scheduled event.

    The "Until" finish time is optional but wil be displayed if set.

    Use the dropdowns next to each Role to select an appropriate Person to fill each role.

  4. Click on the "Save" button.

    When the Scheduled event is saved it is added to the listbox.

  5. Add other entries to the schedule, as required.

  6. The "Description" field is used to give additional information to display about an event.

  7. The text boxes below each Person in the Role selection are used to provide additional information about the particular Role in the context of this scheduled event and will be printed next to their name.

Display the Schedule

  1. Go back to the page editor. Go to the page where you wish to display the forthcoming events. Use the text mode to put the schedule-view shortcode on the page.
    [tagelin-rota group="whatever" type="view-schedule" title="Forthcoming Events" ]
    

    The group defines the group of resources we are using. It must match that in the other shortcodes.

    The type must be "view-schedule", since we want the View widget to be embedded in the page.

    The title is the text used in the heading for this editor.

    Save and update the page.

    When you are finished it should look like this:

  2. View the published page.

    The Schedule is displayed like this:

Shortcodes

A summary of the [tagelin-rota] shortcode parameters.

Shortcode edit-role

typeedit-role
groupThe group of resources we are using. It must match that in the other shortcodes
titleThe display heading

Shortcode edit-person

typeedit-person
groupThe group of resources we are using. It must match that in the other shortcodes
titleThe display heading

Shortcode edit-event

typeedit-event
groupThe group of resources we are using. It must match that in the other shortcodes
titleThe display heading

Shortcode edit-location

typeedit-location
groupThe group of resources we are using. It must match that in the other shortcodes
titleThe display heading

Shortcode edit-schedule

typeedit-schedule
groupThe group of resources we are using. It must match that in the other shortcodes
titleThe display heading
date-formatThe format code used to display date in editor.
list-date-formatThe format code used to display date in listbox.
range-fromThe range code used to specify the start date for display in the listbox.
range-toThe range code used to specify the end date for display in the listbox.

Shortcode view-schedule

typeview-schedule
groupThe group of resources we are using. It must match that in the other shortcodes
titleThe display heading
date-formatThe format code used to display date in editor.
list-date-formatThe format code used to display date in listbox.
range-fromThe range code used to specify the start date for display.
range-toThe range code used to specify the end date for display.
range-selectorthe CSS class of a ui.datepicker to display dates or "none" if no date select widget is required.

Date Formats

Dates and times are stored as UTC but displayed in the local time.

The format of dates is specified in the shortcode using an ordered pattern of symbols:

dday of month (no leading zero)
ddday of month (two digit)
Dday name short
DDday name long
mmonth of year (no leading zero)
mmmonth of year (two digit)
Mmonth name short
MMmonth name long
yyear (two digit)
yyyear (four digit)

For example,

date-format="dd-mm-yy"
This will show 2nd of December 2018 as "02-12-2018"

Range Format

The to and from dates are calculated from the specified date according to a pattern:

A sign "+" or "-" for the direction

A count number.

A symbol for the scale ( "y" for years, "m" for months, "d" for days, "f" for forever ). For example:

+1y	next year
-1y 	last year
+0y	end of year
-0y	start of year
+0m	end of month
-0m	start of month
+1d	tomorrow
+0f	to forever
-0f	from forever
These may be joind together to make compund expressions:
+0m+3d		the 3rd day of next month

Custom Display

Advanced users may override the default display in two ways.

The CSS stylesheet "tagelin-rota-view.css" can be created in your in your theme directory. This will override any setting in the plugin file "tagelin-rota.css".

The templates used for the structure of the view-schedule shortcode are in the plugin template directory. You can copy these to your theme folder and edit them there.