[Bps-public-commit] rtx-calendar branch master updated. 1.05-33-g25b9dd4

BPS Git Server git at git.bestpractical.com
Fri Dec 15 15:19:48 UTC 2023


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "rtx-calendar".

The branch, master has been updated
       via  25b9dd4231a9be1f42b3e3508346cb3c88ed667d (commit)
       via  4860c39e6cdbde5aa70fc7c90f4425491e70b862 (commit)
       via  1e5d63064bdc0d266bdefebcb9390cb32359908b (commit)
       via  4954c22d76c448a600a8445af75bc8213a970c62 (commit)
       via  e13bcde7cc2d6633ff87e7099f6eea5ac32016d6 (commit)
       via  503edd088b911448fdcfc4fcf12f4ca1f252e663 (commit)
       via  03120fdf3db2650da7f9a860bb999a49d7779f9f (commit)
       via  4075214d93a46161010d403868b7c821f4404a4f (commit)
       via  19a098f711ccb891943bbe3eb7ac60926bce03bd (commit)
       via  f6a36781940fbbeb4ec87122ee334805735522b5 (commit)
       via  0c82932894e7a3a6b44999e134668dcc6833bd81 (commit)
       via  21bf94a35b46e69449f2d76b588c7db006b8c03e (commit)
       via  8f7d47ae9f22628b417bdac81a4b4f7b7e07b192 (commit)
       via  5bb25ec21bbd482ef41a3a00ac4c76b18f34b137 (commit)
       via  074f121088429d75ca4a336c559acdd170fe38c8 (commit)
       via  7e24fe3c1f57eba397d8f2bea4c4de35d44351c9 (commit)
       via  df36ef788be32523ea85a38fc1f19f14aa7cf99d (commit)
       via  5acb7fba2f98a8d945841814aebcc98aab939fab (commit)
       via  8779ce3e23de99cc60cb61728d1132669b4787b6 (commit)
       via  d8f5e7f00ac56f6ac81c53becd70894831a5e346 (commit)
       via  0c1ff33d6412ca2eaf9de92bced5ddc54d5fa6c1 (commit)
       via  3b40dcad14f3dd2429c34fc351a0a4e22d908712 (commit)
       via  5eb4908f2106bb16cef969b17526e03ea79bf14d (commit)
       via  c1797ea74c4da67a8a633cc875fd61c490dcc9ad (commit)
       via  afb77469de1483ec19219c5290119b5a4fa1fe40 (commit)
       via  1889d3909dc1d33b2da2a870c1f229df72b9be0d (commit)
       via  bc4093657f5348cb5f089e96ace83b98cde337d7 (commit)
       via  2f43541fd915c6a719a8df2a14593a4b82707504 (commit)
       via  cfc4489af1f557feb808ac5165a0576d604af1a5 (commit)
       via  0ae7e0d929f7079a4c6e1cfce3f0e849f881005d (commit)
       via  a0311dc5d6428890e70e10bc2b6f017e51995380 (commit)
       via  f10215a871ec8d1569bffda969f4c65c3c89938f (commit)
       via  18f093834a14cc6b1b72c9722479497cab594571 (commit)
      from  2de74e5ce5e895101fef6dfa025c3b4b92f13556 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 25b9dd4231a9be1f42b3e3508346cb3c88ed667d
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Dec 15 08:42:04 2023 -0500

    Prep public version 1.08

diff --git a/CHANGES b/CHANGES
index bcfbc3d..d7d09e0 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,11 @@
-1.08 2023-11-17
+1.08 2023-12-15
  - Prevent loss of filter selection when changing months w/select boxes
+ - Restore the default popup configuration
+ - Don't die in the popup helper if attributes are not found
+ - Fix Status Color typo
+ - Add a default color for unmapped states
+
+Versions 1.06 and 1.07 were internal releases and thus not published to CPAN.
 
 1.07 2023-11-16
  - Fix display of multiple day events

commit 4860c39e6cdbde5aa70fc7c90f4425491e70b862
Merge: 4954c22 1e5d630
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Dec 15 09:51:52 2023 -0500

    Merge branch 'multiple-days-events-pod-update'


commit 1e5d63064bdc0d266bdefebcb9390cb32359908b
Author: Ronaldo Richieri <ronaldo at bestpractical.com>
Date:   Wed Nov 22 11:50:16 2023 -0300

    Update POD with new features
    
    Add information about custom field based events, multiple days events
    and new calendar portlets.
    
    Also bring the help section information from the UI to the POD in the
    usage section.

diff --git a/META.yml b/META.yml
index 47bf122..9188ca7 100644
--- a/META.yml
+++ b/META.yml
@@ -1,5 +1,5 @@
 ---
-abstract: 'Calendar for RT due dates'
+abstract: 'Calendar view for RT ticket dates and custom fields'
 author:
   - 'Best Practical Solutions, LLC'
 build_requires:
diff --git a/README b/README
index 7969fdb..e9f281f 100644
--- a/README
+++ b/README
@@ -1,25 +1,19 @@
 NAME
-    RTx::Calendar - Calendar for RT due dates
+    RTx::Calendar - Calendar view for RT ticket dates and custom fields
 
 DESCRIPTION
-    This RT extension provides a calendar view for your tickets and your
-    reminders so you see when is your next due ticket. You can find it in
-    ticket search sub navigation menu.
-
-    Date fields in the search results are displayed/used in the calendar,
-    for example if you have a ticket with a due date, it won't be displayed
-    on that date unless the Due field is included in the search result
-    format.
-
-    There's a portlet to put on your home page (see Prefs/MyRT.html), see
-    the CONFIGURATION section below for details on adding it.
+    RTx::Calendar provides a calendar view to display tickets and reminders
+    based on selected dates. Once the extension is installed, if you perform
+    a ticket search using the Query Builder, you will see a new Calendar
+    entry in the page menu. You can click that menu to see the calendar view
+    of your search. A portlet is also available to add to any dashboard,
+    including on the RT home page.
 
 RT VERSION
     Works with RT 5.
 
-    If you need to install this for RT 4.4.x, install version 1.05:
-
-        cpanm RTx::Calendar at 1.05
+    For older versions of RT, see the CHANGES file for compatible earlier
+    versions.
 
 INSTALLATION
     perl Makefile.PL
@@ -37,26 +31,83 @@ INSTALLATION
 
     Restart your webserver
 
+USAGE
+    To view a Calendar, first perform a ticket search in the ticket Query
+    Builder and load the search results. Then click the Calendar item in the
+    page menu to see the calendar view based on the results from that
+    search.
+
+    By default, RTx::Calendar will display the Starts and Due date fields of
+    each ticket from your search results as events on the Calendar.
+
+    Other date fields added to the Format of a ticket search are displayed
+    on the Calendar as events. You can also display events based on Date or
+    DateTime custom fields by adding them to the Format of a ticket search
+    as well.
+
+    Hover over events in the calendar to see additional details for that
+    event. You can click on entries to go to the ticket.
+
+  Displaying Other Date Fields
+    You can show other date fields as events on the Calendar by adding them
+    to the Format section at the Advanced tab of your query. You can add and
+    remove dates from search results using the Display Columns section at
+    the bottom of the Query Builder.
+
+    Changes made using the Display Columns settings automatically update the
+    search Format. You can also edit the Format directly on the Advanced
+    page.
+
+  Calendar Portlet Saved Searches
+    As described above, you can see a calendar for any ticket search using
+    the calendar link in the search results.
+
+    You can also create a saved search for the calendar to be used in
+    calendar portlets on dashboards. See "CONFIGURATION" for details on
+    adding the calendar portlets.
+
+    By default, the calendar looks for a saved search with the name
+    "calendar" and will use that search for calendar portlets. Saved
+    searches can be saved with different privacy settings, so your system
+    can have multiple saved "calendar" searches. For a given user, the
+    calendar first checks for a user-level saved search (personal to that
+    user), then for a group-level saved search for groups the user is in,
+    and finally, for a system-level saved search.
+
+  Displaying Reminders
+    Reminders are displayed on the Calendar only if you explicitly add the
+    following clause to your query:
+
+        AND ( Type = 'ticket' OR Type = 'reminder' )
+
 CONFIGURATION
-  Use the calendar on Dashboard
-    The calendar comes with 3 different portlets that can be added to your
+  Use the Calendar on Dashboard
+    The Calendar comes with 3 different portlets that can be added to your
     RT dashboards:
 
-    MyCalendar, a summary of the events for the current week.
-    Calendar, a full month of the calendar view, without sidebar.
-    CalendarWithSidebar, a full month of the calendar view, with sidebar
-    which includes an extra status filter and legends of the calendars.
+    MyCalendar
+        A summary of the events for the current week.
+
+    Calendar
+        A full-month view of the Calendar.
 
-    $HomepageComponents in etc/RT_SiteConfig.pm:
+    CalendarWithSidebar
+        A full-month view of the Calendar, with a sidebar that includes an
+        extra status filter and legends of the Calendar events.
 
-      Set($HomepageComponents, [qw(QuickCreate Quicksearch
-         MyCalendar Calendar CalendarWithSidebar
-         MyAdminQueues MySupportQueues MyReminders RefreshHomepage)]);
+    To make these portlets available in RT, add them to the
+    $HomepageComponents configuration in your etc/RT_SiteConfig.pm:
 
-  Display configuration
-   Displaying the owner
-    You can show the owner in each day box by adding this line to your
-    etc/RT_SiteConfig.pm:
+        Set($HomepageComponents, [qw(QuickCreate Quicksearch
+            MyAdminQueues MySupportQueues MyReminders RefreshHomepage
+            MyCalendar Calendar CalendarWithSidebar)]);
+
+    Users can then select them when building dashboards.
+
+  Display Configuration
+   Display Owner
+    You can show the owner of the ticket in each event box by adding this
+    line to your etc/RT_SiteConfig.pm:
 
         Set($CalendarDisplayOwner, 1);
 
@@ -93,58 +144,109 @@ CONFIGURATION
     the methods shown in the RT::User documentation to show values like
     EmailAddress or RealName, for example.
 
-   Event colors
-    It's also possible to change the color of the events in the calendar by
-    adding the $CalendarStatusColorMap setting to your etc/RT_SiteConfig.pm:
+   Event Colors
+    The Calendar shows events in different colors based on the ticket
+    status. Use $CalendarStatusColorMap to set alternate colors or add
+    custom statuses. The following is the default configuration:
 
         Set(%CalendarStatusColorMap, (
-            'new'                                   => 'blue',
-            'open'                                  => 'blue',
-            'approved'                              => 'green',
-            'rejected'                              => 'red',
-            'resolved'                              => '#aaa',
+            '_default_'                             => '#5555f8',
+            'new'                                   => '#87873c',
+            'open'                                  => '#5555f8',
+            'rejected'                              => '#FF0000',
+            'resolved'                              => '#72b872',
+            'stalled'                               => '#FF0000',
         ));
 
     You can use any color declaration that CSS supports, including hex
     codes, color names, and RGB values.
 
-   Event filtering by status
-    You can change the statuses available for filtering on the calendar by
-    adding the @CalendarFilterStatuses setting to your etc/RT_SiteConfig.pm:
+    The _default_ key is used for events that don't have a status in the
+    $CalendarStatusColorMap hash. The default color is a dark tone of blue.
+
+   Filter on Status
+    The Calendar has a Filter on Status section that allows you to filter
+    events by status without having to change the original query. The
+    @CalendarFilterStatuses setting controls which statuses are available
+    for filtering. The following is the default:
 
         Set(@CalendarFilterStatuses, qw(new open stalled rejected resolved));
 
-   Default selected status on Filtering on Status field
-    You can change the default selected statuses by adding them to the
-    @CalendarFilterDefaultStatuses setting to your etc/RT_SiteConfig.pm:
+    You can change the default selected statuses of the Filter On Status
+    section by defining @CalendarFilterDefaultStatuses. The following is the
+    default:
 
         Set(@CalendarFilterDefaultStatuses, qw(new open));
 
-   Custom icons
-    Custom Icons can be defined for the events in the calendar by adding the
-    $CalendarIcons setting to your etc/RT_SiteConfig.pm:
+   Custom Icons
+    The calendar shows different icons for events based on the date fields
+    used to display the event on that day. The %CalendarIcons setting
+    controls which icons are used for each date field. The following is the
+    default using provided icons:
 
         Set(%CalendarIcons, (
-            'CF.{Maintenance Estimated Start Date/Time - ET}'
-                => 'maint.png',
+            'Reminder'     => 'reminder.png',
+            'Resolved'     => 'resolved.png',
+            'Starts, Due'  => 'starts_due.png',
+            'Created, Due' => 'created_due.png',
+            'Created'      => 'created.png',
+            'Due'          => 'due.png',
+            'Starts'       => 'starts.png',
+            'Started'      => 'started.png',
+            'LastUpdated'  => 'updated.png',
+        ));
+
+    You can also define icons for custom fields by using the following
+    format:
+
+            'CF.{Maintenance Start}' => 'maintstart.png',
+            'CF.{Maintenance Stop}'  => 'maintstop.png',
+
+    To add custom images, create a directory local/static/images in your
+    installed RT directory (usually /opt/rt5) and copy images files there.
+
+    You can use any image format that your browser supports, but PNGs and
+    GIFs with transparent backgrounds are recommended because they will
+    display better to the background color of the events. The recommended
+    size is 10 pixels wide and 7 pixels in high.
+
+   Multiple Days Events
+    By default, calendars display individual events on each day based on the
+    dates in the query.
+
+    To display events that span multiple days, such as the full expected
+    duration of a change blackout period, define the fields using the
+    %CalendarMultipleDaysEvents configuration. This option accepts named
+    keys that each define the field to reference for the start (Starts) and
+    end (Ends) of multi-day events. For example:
+
+        Set( %CalendarMultipleDaysEvents, (
+            'Project Task' => {
+                'Starts' => 'Starts',
+                'Ends'   => 'Due',
+            },
         ));
 
-    The images should be placed on local/static/images.
+    The keys, like Project Task, are arbitrary labels to group each set, so
+    you can use a name that helps you identify the entry.
 
-   Multiple days events
-    You can define multiple days events by adding the
-    %CalendarMultipleDaysEvents setting to your etc/RT_SiteConfig.pm:
+    You can also define multiple day events for custom fields by using the
+    following format:
 
         Set( %CalendarMultipleDaysEvents, (
-                'Maintenance' => {
-                    'Starts' => 'Starts',
-                    'Ends'   => 'Due',
-                },
-            )
-        );
-
-    Note that the Starts and Ends fields must be included in the search
-    result Format in order the event to be displayed on the calendar.
+            'Maintenance' => {
+                "Starts" => "CF.{Maintenance Start}",
+                "Ends"   => "CF.{Maintenance Stop}",
+            },
+            'Project Task' => {
+                'Starts' => 'Starts',
+                'Ends'   => 'Due',
+            },
+        ));
+
+    As with all calendar entries, the date fields referenced in the
+    configuration must be included in the search result Format to display
+    the event on the Calendar.
 
 AUTHOR
     Best Practical Solutions, LLC
diff --git a/lib/RTx/Calendar.pm b/lib/RTx/Calendar.pm
index 4ec03c9..3f91904 100644
--- a/lib/RTx/Calendar.pm
+++ b/lib/RTx/Calendar.pm
@@ -317,28 +317,28 @@ __END__
 
 =head1 NAME
 
-RTx::Calendar - Calendar for RT due dates
+RTx::Calendar - Calendar view for RT ticket dates and custom fields
 
 =head1 DESCRIPTION
 
-This RT extension provides a calendar view for your tickets and your
-reminders so you see when is your next due ticket. You can find it in
-ticket search sub navigation menu.
+C<RTx::Calendar> provides a calendar view to display tickets and
+reminders based on selected dates. Once the extension is installed,
+if you perform a ticket search using the Query Builder, you will see
+a new Calendar entry in the page menu. You can click that menu to see
+the calendar view of your search. A portlet is also available to add
+to any dashboard, including on the RT home page.
 
-Date fields in the search results are displayed/used in the calendar,
-for example if you have a ticket with a due date, it won't be displayed on
-that date unless the Due field is included in the search result format.
+=begin HTML
 
-There's a portlet to put on your home page (see Prefs/MyRT.html), see the
-CONFIGURATION section below for details on adding it.
+<p><img src="https://static.bestpractical.com/images/calendar/calendar.png" alt="Calendar Overview" /></p>
+
+=end HTML
 
 =head1 RT VERSION
 
 Works with RT 5.
 
-If you need to install this for RT 4.4.x, install version 1.05:
-
-    cpanm RTx::Calendar at 1.05
+For older versions of RT, see the CHANGES file for compatible earlier versions.
 
 =head1 INSTALLATION
 
@@ -366,36 +366,95 @@ Add this line:
 
 =back
 
+=head1 USAGE
+
+To view a Calendar, first perform a ticket search in the ticket Query
+Builder and load the search results. Then click the Calendar item in the
+page menu to see the calendar view based on the results from that search.
+
+By default, RTx::Calendar will display the Starts and Due date fields of
+each ticket from your search results as events on the Calendar.
+
+Other date fields added to the Format of a ticket search are displayed on the
+Calendar as events. You can also display events based on Date or DateTime
+custom fields by adding them to the Format of a ticket search as well.
+
+Hover over events in the calendar to see additional details for that event.
+You can click on entries to go to the ticket.
+
+=head2 Displaying Other Date Fields
+
+You can show other date fields as events on the Calendar by adding them
+to the Format section at the Advanced tab of your query. You can add and
+remove dates from search results using the Display Columns section at
+the bottom of the Query Builder.
+
+Changes made using the Display Columns settings automatically update the
+search Format. You can also edit the Format directly on the Advanced page.
+
+=head2 Calendar Portlet Saved Searches
+
+As described above, you can see a calendar for any ticket search using
+the calendar link in the search results.
+
+You can also create a saved search for the calendar to be used in calendar
+portlets on dashboards. See L</"CONFIGURATION"> for details on adding the
+calendar portlets.
+
+By default, the calendar looks for a saved search with the name "calendar"
+and will use that search for calendar portlets. Saved searches can be
+saved with different privacy settings, so your system can have multiple
+saved "calendar" searches. For a given user, the calendar first checks
+for a user-level saved search (personal to that user), then for a group-level
+saved search for groups the user is in, and finally, for a system-level saved
+search.
+
+=head2 Displaying Reminders
+
+Reminders are displayed on the Calendar only if you explicitly add the
+following clause to your query:
+
+    AND ( Type = 'ticket' OR Type = 'reminder' )
+
 =head1 CONFIGURATION
 
-=head2 Use the calendar on Dashboard
+=head2 Use the Calendar on Dashboard
 
-The calendar comes with 3 different portlets that can be added to your
+The Calendar comes with 3 different portlets that can be added to your
 RT dashboards:
 
 =over
 
-=item C<MyCalendar>, a summary of the events for the current week.
+=item C<MyCalendar>
+
+A summary of the events for the current week.
+
+=item C<Calendar>
+
+A full-month view of the Calendar.
 
-=item C<Calendar>, a full month of the calendar view, without sidebar.
+=item C<CalendarWithSidebar>
 
-=item C<CalendarWithSidebar>, a full month of the calendar view, with
-sidebar which includes an extra status filter and legends of the calendars.
+A full-month view of the Calendar, with a sidebar that includes an extra
+status filter and legends of the Calendar events.
 
 =back
 
-C<$HomepageComponents> in F<etc/RT_SiteConfig.pm>:
+To make these portlets available in RT, add them to the
+C<$HomepageComponents> configuration in your F<etc/RT_SiteConfig.pm>:
 
-  Set($HomepageComponents, [qw(QuickCreate Quicksearch
-     MyCalendar Calendar CalendarWithSidebar
-     MyAdminQueues MySupportQueues MyReminders RefreshHomepage)]);
+    Set($HomepageComponents, [qw(QuickCreate Quicksearch
+        MyAdminQueues MySupportQueues MyReminders RefreshHomepage
+        MyCalendar Calendar CalendarWithSidebar)]);
 
-=head2 Display configuration
+Users can then select them when building dashboards.
 
-=head3 Displaying the owner
+=head2 Display Configuration
 
-You can show the owner in each day box by adding this line to your
-F<etc/RT_SiteConfig.pm>:
+=head3 Display Owner
+
+You can show the owner of the ticket in each event box by adding this line
+to your F<etc/RT_SiteConfig.pm>:
 
     Set($CalendarDisplayOwner, 1);
 
@@ -433,64 +492,124 @@ has other format options. User fields, like Owner, can use the methods shown
 in the C<RT::User> documentation to show values like EmailAddress or
 RealName, for example.
 
-=head3 Event colors
+=head3 Event Colors
 
-It's also possible to change the color of the events in the calendar by
-adding the C<$CalendarStatusColorMap> setting to your F<etc/RT_SiteConfig.pm>:
+The Calendar shows events in different colors based on the ticket status.
+Use C<$CalendarStatusColorMap> to set alternate colors or add custom statuses.
+The following is the default configuration:
 
     Set(%CalendarStatusColorMap, (
-        'new'                                   => 'blue',
-        'open'                                  => 'blue',
-        'approved'                              => 'green',
-        'rejected'                              => 'red',
-        'resolved'                              => '#aaa',
+        '_default_'                             => '#5555f8',
+        'new'                                   => '#87873c',
+        'open'                                  => '#5555f8',
+        'rejected'                              => '#FF0000',
+        'resolved'                              => '#72b872',
+        'stalled'                               => '#FF0000',
     ));
 
 You can use any color declaration that CSS supports, including hex codes,
 color names, and RGB values.
 
-=head3 Event filtering by status
+The C<_default_> key is used for events that don't have a status
+in the C<$CalendarStatusColorMap> hash. The default color is a dark tone of
+blue.
 
-You can change the statuses available for filtering on the calendar by
-adding the C<@CalendarFilterStatuses> setting to your
-F<etc/RT_SiteConfig.pm>:
+=head3 Filter on Status
 
-    Set(@CalendarFilterStatuses, qw(new open stalled rejected resolved));
+The Calendar has a Filter on Status section that allows you to filter
+events by status without having to change the original query.
+The C<@CalendarFilterStatuses> setting controls which statuses are available
+for filtering. The following is the default:
 
-=head3 Default selected status on Filtering on Status field
+    Set(@CalendarFilterStatuses, qw(new open stalled rejected resolved));
 
-You can change the default selected statuses by adding them to the
-C<@CalendarFilterDefaultStatuses> setting to your F<etc/RT_SiteConfig.pm>:
+You can change the default selected statuses of the Filter On Status section
+by defining C<@CalendarFilterDefaultStatuses>. The following is the default:
 
     Set(@CalendarFilterDefaultStatuses, qw(new open));
 
-=head3 Custom icons
+=head3 Custom Icons
 
-Custom Icons can be defined for the events in the calendar by adding the
-C<$CalendarIcons> setting to your F<etc/RT_SiteConfig.pm>:
+The calendar shows different icons for events based on the date fields
+used to display the event on that day. The C<%CalendarIcons> setting
+controls which icons are used for each date field. The following is the
+default using provided icons:
 
     Set(%CalendarIcons, (
-        'CF.{Maintenance Estimated Start Date/Time - ET}'
-            => 'maint.png',
+        'Reminder'     => 'reminder.png',
+        'Resolved'     => 'resolved.png',
+        'Starts, Due'  => 'starts_due.png',
+        'Created, Due' => 'created_due.png',
+        'Created'      => 'created.png',
+        'Due'          => 'due.png',
+        'Starts'       => 'starts.png',
+        'Started'      => 'started.png',
+        'LastUpdated'  => 'updated.png',
+    ));
+
+You can also define icons for custom fields by using the following format:
+
+        'CF.{Maintenance Start}' => 'maintstart.png',
+        'CF.{Maintenance Stop}'  => 'maintstop.png',
+
+To add custom images, create a directory F<local/static/images> in your installed
+RT directory (usually F</opt/rt5>) and copy images files there.
+
+You can use any image format that your browser supports, but PNGs and GIFs
+with transparent backgrounds are recommended because they will display better
+to the background color of the events. The recommended size is 10 pixels wide
+and 7 pixels in high.
+
+=head3 Multiple Days Events
+
+By default, calendars display individual events on each day based on
+the dates in the query.
+
+=begin HTML
+
+<p><img src="https://static.bestpractical.com/images/calendar/calendar-disconnected-events.png" alt="Calendar Disconnected Events" /></p>
+
+=end HTML
+
+To display events that span multiple days, such as the full expected
+duration of a change blackout period, define the fields using the
+C<%CalendarMultipleDaysEvents> configuration. This option accepts
+named keys that each define the field to reference for the start (Starts)
+and end (Ends) of multi-day events. For example:
+
+    Set( %CalendarMultipleDaysEvents, (
+        'Project Task' => {
+            'Starts' => 'Starts',
+            'Ends'   => 'Due',
+        },
     ));
 
-The images should be placed on F<local/static/images>.
+=begin HTML
+
+<p><img src="https://static.bestpractical.com/images/calendar/calendar-multiple-days-events.png" alt="Calendar Multi-days Events" /></p>
+
+=end HTML
 
-=head3 Multiple days events
+The keys, like C<Project Task>, are arbitrary labels to group each
+set, so you can use a name that helps you identify the entry.
 
-You can define multiple days events by adding the C<%CalendarMultipleDaysEvents>
-setting to your F<etc/RT_SiteConfig.pm>:
+You can also define multiple day events for custom fields by using the
+following format:
 
     Set( %CalendarMultipleDaysEvents, (
-            'Maintenance' => {
-                'Starts' => 'Starts',
-                'Ends'   => 'Due',
-            },
-        )
-    );
-
-Note that the Starts and Ends fields must be included in the search result
-Format in order the event to be displayed on the calendar.
+        'Maintenance' => {
+            "Starts" => "CF.{Maintenance Start}",
+            "Ends"   => "CF.{Maintenance Stop}",
+        },
+        'Project Task' => {
+            'Starts' => 'Starts',
+            'Ends'   => 'Due',
+        },
+    ));
+
+As with all calendar entries, the date fields referenced in the
+configuration must be included in the search result Format to
+display the event on the Calendar.
 
 =head1 AUTHOR
 

commit 4954c22d76c448a600a8445af75bc8213a970c62
Merge: 2de74e5 e13bcde
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Fri Dec 15 08:34:30 2023 -0500

    Merge branch 'multiple-days-events-2'


-----------------------------------------------------------------------

Summary of changes:
 CHANGES                            |  23 ++
 MANIFEST                           |   8 +-
 META.yml                           |  10 +-
 Makefile.PL                        |   2 +-
 README                             | 254 ++++++++++++++++---
 etc/RTxCalendar_Config.pm          |  39 +++
 etc/tabs_privileged_callback.patch |  32 ---
 html/Elements/Calendar             | 334 +++++++++++++++++++++++++
 html/Elements/CalendarEvent        | 155 ++++++------
 html/Elements/CalendarFooter       |  38 +++
 html/Elements/CalendarSidebar      |  97 ++++++++
 html/Elements/CalendarWithSidebar  |   3 +
 html/Elements/MyCalendar           |  89 +++++--
 html/Helpers/CalendarEventInfo     |  84 +++++++
 html/Search/Calendar.html          | 263 +-------------------
 inc/Module/Install.pm              |   2 +-
 inc/Module/Install/Base.pm         |   2 +-
 inc/Module/Install/Can.pm          |   2 +-
 inc/Module/Install/Fetch.pm        |   2 +-
 inc/Module/Install/Include.pm      |   2 +-
 inc/Module/Install/Makefile.pm     |   2 +-
 inc/Module/Install/Metadata.pm     |  12 +-
 inc/Module/Install/Win32.pm        |   2 +-
 inc/Module/Install/WriteAll.pm     |   2 +-
 inc/YAML/Tiny.pm                   |   4 +-
 lib/RTx/Calendar.pm                | 489 +++++++++++++++++++++++++++++++++----
 static/css/calendar.css            | 129 +++++++++-
 static/js/calendar.js              |  71 ++++++
 28 files changed, 1660 insertions(+), 492 deletions(-)
 create mode 100644 etc/RTxCalendar_Config.pm
 delete mode 100644 etc/tabs_privileged_callback.patch
 create mode 100644 html/Elements/Calendar
 create mode 100644 html/Elements/CalendarFooter
 create mode 100644 html/Elements/CalendarSidebar
 create mode 100644 html/Elements/CalendarWithSidebar
 create mode 100644 html/Helpers/CalendarEventInfo
 create mode 100644 static/js/calendar.js


hooks/post-receive
-- 
rtx-calendar


More information about the Bps-public-commit mailing list