Hi everyone,

 

We have a custom section, and we’d like to enhance it by adding a timeline that includes a custom object.

 

Is it possible to include a custom object in the timeline? For example, alongside Tasks, Emails, etc., we’d like to display data from our custom object as well.

 

Additionally, is there a way to customize how one of the existing objects is displayed in the timeline or modify which fields are shown? For instance, in the case of the Opportunity tile, can we change the fields that are displayed?

 

Any guidance or documentation on these topics would be greatly appreciated.

 

Thanks in advance!

Like 0

Like

1 comments

Hello,

 

Both tasks are possible to implement. However, it will include slight low-code development in your system.

Here are the few articles that can be helpful in fulfilling your tasks:

Customize the Timeline component

Customize timeline

Create the Timeline tab tiles bound to custom section

Show all comments

We want to add filters in the same way that you can add them to lookups using code on the page, as there isn't a no-code way to configure additional filters for Timeline components. In our case, it's filtering out non-completed Activity records from the Timeline. We don't seem to be able to using similar methods to lookups though (i.e. adding custom code to the crt.LoadDataRequest handler. Has anyone found a way to add such a filter? It looks like all the Timeline code is in the 9351.xxxxxxx JS file.

Like 0

Like

3 comments

Hello,
We must say that the ability to add filters to a timeline is under development. Unfortunately, we cannot tell when it will be added.

Hi , Any update on this , we have a requirement to add a recipient filter inside timeline component , any idea

Pranshu Basak,

 

Hello,

This feature is currently in the planned stage, but no estimates for its release are available at the moment.

Show all comments

Is it possible to restrict the "Owner" filter for Timeline components to only show Contacts which match a specific filter condition? We are currently seeing every Contact as an option, but for us this should be restricted to only Contacts which have a User record associated with them, and ideally we'd want to add some more customisation to the filter options beyond this.

Like 0

Like

9 comments
Best reply

I've discovered that it's possible to add this using code. To do so, you need to override the crt.LoadDataRequest handler and use the following code:

{
	request: "crt.LoadDataRequest",
	handler: async (request, next) => {
		// Filter Timeline's Owner filter to just Contacts with a User record
		if(request.dataSourceName === "ByOwnerQuickFilterInTimeline_xi3lpgm_ComboBox_List_DS") {
			const filter = new sdk.FilterGroup();
			await filter.addExistsFilter("[SysAdminUnit:Contact:Id].Id");
 
			// workaround for filters
			const newFilter = Object.assign({}, filter);
			newFilter.items = filter.items;
 
			request.parameters.push({
				type: "filter",
				value: newFilter
			});
		}
 
		return await next?.handle(request);
	}
},

You have to replace the name of the Timeline component in the above code from Timeline_xi3lpgm to whatever the component is called on your page.

Hello Harvey,



There is no such option for now, however, we've registered it in our R&D team backlog for consideration and implementation in future application releases.

 

Thank you for helping us to improve our product. 

Thanks Bogdan, it's definitely a feature that's needed - having every Contact show up in the Owner filter with no way to change this on a CRM platform isn't ideal.

I've discovered that it's possible to add this using code. To do so, you need to override the crt.LoadDataRequest handler and use the following code:

{
	request: "crt.LoadDataRequest",
	handler: async (request, next) => {
		// Filter Timeline's Owner filter to just Contacts with a User record
		if(request.dataSourceName === "ByOwnerQuickFilterInTimeline_xi3lpgm_ComboBox_List_DS") {
			const filter = new sdk.FilterGroup();
			await filter.addExistsFilter("[SysAdminUnit:Contact:Id].Id");
 
			// workaround for filters
			const newFilter = Object.assign({}, filter);
			newFilter.items = filter.items;
 
			request.parameters.push({
				type: "filter",
				value: newFilter
			});
		}
 
		return await next?.handle(request);
	}
},

You have to replace the name of the Timeline component in the above code from Timeline_xi3lpgm to whatever the component is called on your page.

Harvey Adcock,

good find, thanks!

You should mark your own answer as solution ;)

Harvey Adcock,

Well done! Thanks for sharing this Harvey. 

Also, if you've moved to 8.1.1 you no longer need the filters workaround - it's finally working properly in 8.1.1, just thought I'd mention.

Ryan

Ryan Farley,

Ahh great to hear, thanks for the info Ryan - and thanks for spreading the info about that workaround in the first place!

I'd like to share my solution on lookup filtering.

We wanted to have only contacts from our company and in certain functional role.

{
	request: "crt.LoadDataRequest",
	handler: async (request, next) => {
		if (request.dataSourceName !== "FbContact_List_DS") {
			return await next?.handle(request);
		}
 
		const ourCompanyFilter = new sdk.CompareFilter(
			sdk.ComparisonType.Equal, 
			new sdk.ColumnExpression({
				columnPath: "Account.Type"
			}), 
			new sdk.ParameterExpression({
				value: Constants.AccountType.OurCompany
			})
		);
 
		const funcRoleFilter = new sdk.CompareFilter(
			sdk.ComparisonType.Equal, 
			new sdk.ColumnExpression({
				columnPath: "[SysAdminUnit:Contact:Id].[SysUserInRole:SysUser:Id].SysRole.Id"
			}), 
			new sdk.ParameterExpression({
				value: Constants.FunctionalRole.MyCustomFunctionalRole
			})
		);
 
		request.parameters.push({
			type: sdk.ModelParameterType.Filter,
			value: ourCompanyFilter
		});
 
		request.parameters.push({
			type: sdk.ModelParameterType.Filter,
			value: funcRoleFilter
		});
 
		return await next?.handle(request);
	}
}

 

Alex Zaslavsky,

Interesting, it hadn't occurred to me to push multiple filters to the parameters. I've always added the multiple filters to a FilterGroup and then added the group to the parameters. I guess it's an array for a reason :) Nice to know it works that way as well.

Ryan

Hello , 

Can we set a current user as a default in timeline quickfilter ? 

Show all comments
Question

Hi,



I am trying to add a new entry in the following because I enrolled a new Activity Type: Notes.



Do you know how to modify this, addon?



Below is the TimelineEntityValues where I want to add another entry.

 

Like 2

Like

1 comments

Hello Solem,

To make changes to the addon, you can modify the Modifications package node of the addon structure.

There is an article in Creatio Academy with an example of how you can customize the Timeline component: https://academy.creatio.com/docs/8.x/dev/development-on-creatio-platfor…

Show all comments

Is it possible within Freedom UI to trigger a refresh of the Timeline/Feed/Next Steps components using JS? We seem to have an issue where the "Enable live data update" option does not seem to be working in Creatio CRM 8.1 for our Activities on certain pages, and while we've raised a support request for this, we were trying to find a workaround by manually updating the components from code for a specific use case, but we can't see what the data source is called for these types of components. Does anybody know what it would be? I presume refreshing the PDS would refresh them, but this seems heavy handed and might end up with data being lost on the main form page while the data actually being refreshed is just a child entity, so I would expect it to have its own data source.

Like 4

Like

3 comments

+1

Hello Harvey and Damien!

In Freedom UI Pages, the structure of the page is different and along with this a new way to refresh anything on the page. In this article you can find the way to achieve your goal:

https://customerfx.com/article/refreshing-reloading-page-or-list-data-on-a-creatio-freedom-ui-page/

Here's example of handler which you can use:

handlers: /**SCHEMA_HANDLERS*/[
 {
  request: "crt.HandleViewModelAttributeChangeRequest"/* The custom implementation of the system query handler. */
  handler: async (request, next) => {
   await next?.handle(request); 
   if (request.attributeName === 'Your Attribute Name' )
   {
    const handlerChain = sdk.HandlerChainService.instance;
    await handlerChain.process({
     type: 'crt.LoadDataRequest', $context: request.$context,
     config: { loadType: 'reload' },
    dataSourceName: 'Data Source Of Obj You Want To Refresh'
    });   
   }
  }
 },

You may also find this article useful:

https://customerfx.com/article/receiving-server-side-messages-in-a-creatio-freedom-ui-page/

 

Anhelina,

 

How can we find what the data source is for a component like a Timeline or Next Steps component though? The article suggests looking at the modelConfig elements in the page code, but none of these seem to relate to the timeline or timeline tiles. I expect there is some data source being created behind the scenes but finding out what it's called is the main problem for applying the theory of being able to reload anything on the page as is suggested.

 

Many thanks,

Harvey

Show all comments

Hello community,

 

I am trying to bring timeline for custom section. I have created a record in TimelinePageSettings table. To update the data i used the below script. So when i am using the full json ,timeline tab is not showing on the UI. When i am using the json with only SocialMessage it is working properly for messages. I have checked appending Id to reference column name but it didnt work .  I might be missing a step , please help me out.

 

 

UPDATE TimelinePageSetting

SET Data = CONVERT(varbinary, '[

  {

    "entityConfigKey": "706f803d-6a30-4bcd-88e8-36a0e722ea41",

    "entitySchemaName": "Activity",

    "referenceColumnName": "UsrCreditCheck",

    "masterRecordColumnName": "Id"

  },

  {

    "entityConfigKey": "09a70391-b767-40ab-97b8-6d1b538adbe6",

    "entitySchemaName": "Activity",

    "typeColumnName": "Type",

    "typeColumnValue": "e2831dec-cfc0-df11-b00f-001d60e938c6",

    "referenceColumnName": "UsrCreditCheck",

    "masterRecordColumnName": "Id"

  },

{

    "entityConfigKey": "35b5c45f-36e7-450f-a282-81c56624d29e",

    "entitySchemaName": "SocialMessage",

    "referenceColumnName": "EntityId",

    "masterRecordColumnName": "Id"

  },

  {

    "entityConfigKey": "aeca6df0-5c89-4066-bdfa-eff486ae8fed",

    "entitySchemaName": "Call",

    "referenceColumnName": "UsrCreditCheck",

    "masterRecordColumnName": "Id"

  },

  {

    "entityConfigKey": "59de07a7-28dd-4dc9-a106-a07cb9981423",

    "entitySchemaName": "UsrCreditCheckFile",

    "typeColumnName": "Type",

    "typeColumnValue": "529bc2f8-0ee0-df11-971b-001d60e938c6",

    "referenceColumnName": "UsrCreditCheck",

    "masterRecordColumnName": "Id"

  },

 

  {

    "entityConfigKey": "09a6dad5-036b-4075-a813-e8278a5360ea",

    "referenceColumnName": "UsrCreditCheck",

    "typeColumnName": "Type",

    "typeColumnValue": "539bc2f8-0ee0-df11-971b-001d60e938c6",

    "entitySchemaName": "UsrCreditCheckFile",

    "masterRecordColumnName": "Id"

  },

  {

    "entityConfigKey": "a5900576-dca5-4d82-aed3-91c8909a3028",

    "entitySchemaName": "Document",

    "referenceColumnName": "UsrCreditCheck",

    "masterRecordColumnName": "Id"

  }

]')

WHERE Id = 'D15FD665-AAD3-4AC7-8F1A-54DC5342E616';

 

Like 1

Like

1 comments

Hello,

 

You need to create a custom item view module based on the Contact object and add it to the Leads section. Please use this article as a reference where the same task is described using a custom "Books" section added as timeline item to the "Accounts" section.

Show all comments

Hello,



Anyone experience that Email are not visible in Section > Timeline > Email for other users?



Note:

- Object permission for Activity is set as All Employees > All Employees.

- User I tried logging in has no Email Account.



What could possible be the solution/issue?



Regards,

Solem A.

Like 0

Like

4 comments
Best reply

Solem Khan Abdusalam,

 

Please find more information here.



Best regards,

Bogdan

Hello Solem,

 

The emails on the timeline are only visible to the users, who have access to the 'can read/edit any data' operation permission.



Best regards,

Bogdan

Bogdan,



I saw the option and the Object "Activity" already has the user's role and Create/Edit/Delete are already check.



Regards.

Solem A.

Solem Khan Abdusalam,

 

Please find more information here.



Best regards,

Bogdan

Bogdan,

 

Work's like magic!



Thanks,

Solem A.

Show all comments

Hi community,

 

I was wondering if there was a way to add a "PRINT" button to a section which when clicked will export a whole tab (in this case the timeline tab) to PDF or directly print the whole timeline tab ?

 

I am pretty sure that it needs some coding to be done but in which way ?

Is it necessary to call some APIs via C# code ?

 

Many thanks for the help provided.

 

Best regards,

Jonathan

Like 1

Like

5 comments

Hi Jonathan,

 

The timeline tab displays information from connected entities (like activities or orders and so on). That's why this task can be completed without additional development by the correct specifying of the table part in the printable and exporting data needed.

Hi Oleg,

 

Thank you for the answer. I have searched a bit in the system but did not found how to achieve this.

 

Can you explain me a bit further "by the correct specifying of the table part in the printable and exporting data needed."

 

Many thanks,

Jonathan

Jonathan Quendoz,

 

there is no separate documentation on this matter since this functionality is similar to the details functionality on the page. You can setup table part in printalbes here:

Once you select adding a new record there you will see the page where you can select the object you are interested in and the connection setup between your master object (from which the print will be performed) and the target object (where connected data is located). In this example below:

my master entity is the "Contacts" section (since I create a Word report based on it) and the target entity is the "Activity" section. Once saved you can get the information on the "Subject", "Start" and "Due" columns of all activities connected to the contact from which the printable was generated and only activities where this contact is specified as "Owner" will be displayed. Additional filtration of activity records can be added to the "Table filters" tab (in the screenshot above).

 

In the report designer you can add this table part as in this example below:

As a result once you print data you will get this file:

Just perform a couple of tests using report tables and using them you will be able to get the same data that is located in the timeline.

Oleg Drobina,

 

When exporting the "Email" Activity type, how can I export the whole email text ? I have tried with the "body" column but it print the whole html body and not only the text.

 

In addition, how can I export all the activites from the timeline ? I have tried to implement it your way but id has printed only the last activity of the concerned contact.

 

Many thanks for the clarifications.

 

Best regards,

Jonathan

Jonathan Quendoz,

 

It should export all activities related to the contact, maybe the filtration or the connection was specified in the way that made the system to get only one activity instead of several activities. Maybe its because the contact you are interested in is not an owner or reported of missing activities, but is present as the activity participant in those activities.

 

As for the email - the body column in the object contains the HTML code as well (that is then displayed in the "Rich_text" column type so that's why you don't see HTML tags). In this case a custom macro should be created to process the subject column and remove HTML tags from it. For example you can create a custom macro as described here for the "Subject" column and inside this macro process the received HTML code using the code below (received from base method that is used in the incident registration from incoming emails where email body goes to the case description):

protected virtual string ClearHtmlText(string inputString) {
			var htmlWithoutImages = Regex.Replace(inputString, @"(<img\/?[^>]+>)", string.Empty, RegexOptions.IgnoreCase);
			var noCss = Regex.Replace(htmlWithoutImages, @"/\*.+?\*/", string.Empty, RegexOptions.Singleline);
			var noFormatting = Regex.Replace(noCss, @"/<!--[\s\S]*?-->/g", string.Empty, RegexOptions.IgnoreCase);
			var noStyle = Regex.Replace(noFormatting, "<style.*?</style>", string.Empty, RegexOptions.Singleline);
			var noScript = Regex.Replace(noStyle, "<script.*?</script>", string.Empty, RegexOptions.Singleline);
			var noHTML = noScript.Replace("\r\n</span>", " </span>");
			noHTML = noHTML.Replace("</span>\r\n", " </span>");
			noHTML = Regex.Replace(noHTML, @"<div>|<li>", "\r\n");
			noHTML = Regex.Replace(noHTML, @"\r\n{2,}", "\r\n");
			noHTML = Regex.Replace(noHTML, @"<[^>]+>|", string.Empty);
			noHTML = Regex.Replace(noHTML, "<.*?>", string.Empty);
			noHTML = HttpUtility.HtmlDecode(noHTML);
			noHTML = Regex.Replace(noHTML, @"^\s+$[\r\n]*", "\r\n", RegexOptions.Multiline);
			noHTML = Regex.Replace(noHTML, @"<base[^>]*>", string.Empty, RegexOptions.IgnoreCase);
			if (noHTML.StartsWith("\r\n")) {
				noHTML = noHTML.Substring(2, noHTML.Length - 2);
			}
			return noHTML;
		}

 

Show all comments

Activities are a powerful tool, but it seems that their functionality is limited by cut features.

 

A key one is the Timeline view.  Can that tab be added to the standard Acitivities page?

 

I am using Sales Team module, version 8.0.1.1990.

1 comments

Dear John,

 

Thanks for sharing your idea!

 

We have registered it for R&D team to implement this feature in future releases.

 

Best regards,

Anastasiia

Show all comments

It would be nice to have the ability to review the comments people make on feed posts when looking at the timeline of the case. Currently you can only see the feed post on the timeline, to see if there are comments, you have to open the feed tab.

1 comments

Hello Mitch, 



Thank you for sharing this idea with us. 

We will register it for the responsible R&D team for the further consideration.



Kind regards,

Roman 

Show all comments