• Skip to main content
  • Skip to primary sidebar

DayBack

The Calendar You've Been Waiting For

  • Calendar
    • For Salesforce
      • DayBack Calendar for Salesforce
      • Field Service
      • Calendar Sharing in Salesforce
    • FileMaker Calendar
    • For Google Calendar
    • For Google Sheets
    • For Microsoft 365
    • For Basecamp
    • Integrations
  • Extensions
  • Pricing
  • Blog
  • Support
    • Support Options
    • Documentation
    • Documentation for DayBack Classic (older)
    • Implementation Packages
  • Contact
    • Our Mission
    • Team & Community
    • Careers
    • Contact Us
    • +1 (855) 733-3263
  • Timelines
    • Overview
    • History of the polio vaccine
    • Women’s Suffrage
    • Science Fiction
    • Your Vote in Context: the 2020 US Elections
    • History of Claris FileMaker
  • Sign In

Jan 22 2023

Add Notes and Comments to Events

Add Notes in Salesforce Calendar

Notes can be a great way to communicate with your team about rescheduling suggestions or to tag events with additional information that a team should see before attending a meeting.

Notes visibility and editing capabilities can also be restricted to specific users or to events with specific statuses or event types. This allows you to use the notes for the workflow scenarios where notes make sense while reducing on-screen clutter for event types where notes are unnecessary.

Download and Install

You can download the code here. Before installing the app actions, you must define a custom field to store your notes either at the source level, or the specific calendars or objects where you want notes available. The app action will show notes icons only for events with this field available. 

Configuration

FileNames:

In the configuration section of the app action, you must define the Field Name of the Custom Field that contains notes for each calendar. If you have multiple sources and all share the same field name, simply declare this as a string variable:

    inputs.notesFieldName = 'notes';

If you have multiple sources with different field names for each source, declare the noteFilename setting as an object containing the calendar name, and the field name that is applicable to that calendar:

    inputs.notesFieldName = {
          'Marketing': 'notesFieldName1',
          'Sales': 'notesFieldName1',
    }

Icon Colors:

By default, events without a note will show an off-white comment icon inside of the colored event pill. The app action will take the current color of the event and brighten the color so that it stands out in your events without being overly obtrusive. You can override this feature by seeing a hard color, like white or black for empty cells, and then changing the default color for events which have a note attached. On Horizon view the icons will be displayed next to the text rather than the colored event pill. You will therefore need to specify a hard default color, as the app action will not attempt to reuse the event color for the icon, since the icon is not overlayed over the event pill. You can configure colors as follows:

// Define default icon color when a notes exists

inputs.iconColorWithNote = "#0000AA";        

// Define default icon color for events without a note.
// The default is to leave this empty, which will automatically paint
// empty icons with 150% brightness of existing event color

inputs.iconColorWithoutNote = "";

// Define default icon for empty notes cells in Horizon view. 
// Since notes icons are not displayed within the event pill, but inside
// the text portion, coloring by event color would be misleading users
// into assuming there is a note. Leave this set to white by default.

inputs.horizonIconColorWithoutNote = "#FFFFFF";

Rules that Govern Notes Eligibility:

By default, all events are eligible for notes if you have defined a notes field for that source. If you would like to exclude some events, you may define a custom exclusion function that must return false if an event should be excluded. 

An exclusion function can be useful if you only want some user accounts to have the ability to comment, or if comments should be allowed only in certain event statuses. If you don’t want to restrict comments, simply remove this function, or have it always return true.

Useful Filters:

// Exclude all-day events in resource view

    let isResourceView = inputs.currentView.name.match(/resource/i);
    return event.allDay == true && isResourceView ? false : true;

// Exclude events in Completed Status 

    return event['status'].includes('Completed') ? false : true;

// Allow for specific users
    
    return inputs.currentUser == 'John' || inputs.currentUser == 'Ann' ? true : false; 

Ways to Customize this Action

App actions like this can also be modified to send an email when a note is written. You can also use this feature as a way of locking events until a note is cleared. This would require creating an On Event Save and On Event Delete app action that would prevent changes until a note has been cleared. This feature can also be extended to set different icons or label colors if you want to quickly flag events in special ways.

Summary

We hope this gives you some inspiration for ways you can use an app action like this to drive productivity. We’d love to hear your ideas of what would make DayBack event easier to use. If you have questions about customizing or creating new features, please get in touch with our team. We’d love to help.

Written by Michael Dabrowski · Categorized: Dev, New Features · Tagged: Custom Actions

Reader Interactions

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Search

Latest Posts

  • Memory is Making
  • Add Notes and Comments to Events
  • Closed Through the New Year
  • Background Gradients on Horizon View
  • Cut and Paste Rescheduling

Pinned Posts

  • Scarcity: the Science of Resource Scheduling
  • Calendars Tell Stories
  • Time Shame – Plan Your Day Like a Road Trip
  • We Can’t See Late
  • You’re Calendar’s Not a Poster

  • Facebook
  • Instagram
  • LinkedIn
  • Twitter
  • Vimeo

© SeedCode, Inc. 2013–2023
+1 (855) 733-3263
who shot this?

X

View Details
Keep me informed
Which calendar sources interest you?
Interested in a calendar source we haven't listed? Have a question for us? Please let us know.
Loading