Customize Time Entry form on Calendar View for D365 PSA

Many times, users come back requesting that they need to be able to add types of time entries of their own. Sure, you can modify the Time Entry Type OptionSet that comes with D365 PSA by default. But that will only reflect on D365 Form Level and not where users go to Calendar View to enter time.

Microsoft has provided to be able to customize the Time Entry form on Calendar View too. This feature was released in the PSA release v1.2.1.51
msRelease

Check here – https://blogs.msdn.microsoft.com/crm/2017/07/14/dynamics-365-for-field-service-and-project-services-automation-update-3/

Customization

I’ve added an option called as Comp-Off for the available types of Time Entries OptionSet.
timeEntryOS

But, this is only reflected on the Form level of Time Entry entity and not on the Calendar View. On the Calendar View, it continues to show as below –

defaultTypes

Hence, you’ll need to make changes to the TimeEntryType.js file provided by Microsoft out-of-the-box.

Here’s the script that comes out-of-the-box which Microsoft says you can change to customize –

  1. To make changes, look for this file – “msdyn_/Common/Models/OptionSets/TimeEntryType.js
    jsInSolution
    jsWebRes
  2. Modify this file. By default, it will have this script as shown below –
    defaultScript
  3. So, I added just this one line and mapped it to the OptionSet I created. The value should match the OptionSet value entered in the Time Entry Type OptionSet.
    lineAdded
  4. Save and Publish changes. Check if your new option appears as shown below –
    modifiedCalendarView

Remember: The Calendar View to enter time entries has been deprecated in v3 of PSA. So this customization will not be needed in versions 3.x onward.

I hope this was helpful.

Also,

Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

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