Hey community,

          The issue is that I have a quick filter field, and when the zoom-in % of the screen is at 75% or greater, the field dropdown visibility is not proper. I'm trying to modify the CSS so that it works irrespective of the screen zoom. Is there a way to do this?





 

Like 0

Like

2 comments

Hello,

 

Please provide a screenshot of how the issue looks on your end.

Hi Mira Dmitruk,

    

In the image provided above, the screen zoom level is below 75%, resulting in the Quick Filters dropdown appearing correctly.

In the image above, with the screen zoomed in beyond 75%, the Quick Filters dropdown remains inaccessible, unless the filter is double-tapped, thereby revealing the dropdown.

Show all comments

Cheers to all.

I'm developing my custom UI component in Angular and I need to get some data from Creatio database inside of my component. I discovered there is EntitySchemaQuery class in Creatio's sdk, so I decided to use it, but I'm stuck when I need to retreive data with that ESQ as I didn't find method for that. In classic ESQ there was getEntityCollection method for that. Could you please suggest how do I retrieve data from the database? Either using ESQ or other class, but user's authorization matters.

Here is the code of component.

import { Component, OnInit, Input, Output, 
        ViewEncapsulation, EventEmitter, SimpleChanges  } from '@angular/core';
import { CrtViewElement, CrtInput, CrtOutput, EntitySchemaQuery,
          ComparisonType,  AggregationType, AggregationEvalType, isGuid} from '@creatio-devkit/common';
 
@Component({
  selector: 'usr-input',
  templateUrl: './input.component.html',
  styleUrls: ['./input.component.scss'],
  encapsulation: ViewEncapsulation.ShadowDom
})
/* Add the CrtViewElement decorator to the InputComponent component. */
@CrtViewElement({
  selector: 'usr-input',
  type: 'usr.Input'
})
export class InputComponent implements OnInit {
  constructor() {}
 
  @Input("recordId")
  @CrtInput()
  /* The input recordId. */
  public recordId!: string;
 
  /* Add decorators to the EventEmitter<string>() event. */
  @Output()
  @CrtOutput()
  /* Track input value changes. */
  public valueChange = new EventEmitter<string>();
 
  ngOnInit(): void {
  }
 
 
  ngOnChanges(changes: SimpleChanges) {
    console.log(changes);
 
    if (isGuid(changes["recordId"]?.currentValue)) {
      let esq = new EntitySchemaQuery("ClvObject");
      esq.addAggregationFunctionColumn("Id", AggregationType.Count, "AppCount", AggregationEvalType.All);
      esq.filters.addSchemaColumnFilterWithParameter(ComparisonType.Equal, "ClvProject", this.recordId, "currentFilter");
 
      let record = esq.getMetadata();
      console.log(record);
    }
  }
}

 

Like 2

Like

3 comments

The EntitySchemaQuery classes in the devkit don't do anything, at least not how it is exposed. The ESQ classes require an executor class that actually *runs* the query and provides the connection. We don't have access to this, the executor that runs the ESQ is not part of the devkit sdk. This is intentional/by design since they want us to use the new Model classes instead. This better anyways, the Model class is far easier and more intuitive IMO.

The intended way to get data now is the Model class, which is in the devkit sdk. Here's some articles on the topic: 

Model Query Using Filters: https://customerfx.com/article/querying-data-using-filter-conditions-vi…

Model Query for a Single Record Given it's Id: https://customerfx.com/article/retrieving-a-record-via-the-model-class-…

Also, the model class does inserts/updates/deletes:

Inserting a Record: https://customerfx.com/article/inserting-a-record-from-client-side-code…

Updating a Record: https://customerfx.com/article/updating-a-record-from-client-side-code-…

Deleting a Record: https://customerfx.com/article/deleting-a-record-from-client-side-code-…

Copying a Record: https://customerfx.com/article/copying-a-record-from-client-side-code-u…

You can also use the Model class to get an object's schema:

Get Object Schema: https://customerfx.com/article/getting-an-object-schema-using-the-model…

Ryan

Hi, Ryan. Thanks for quick reply.

Maybe you could suggest how do I need to prepare aggregate columns for the query using Model class? I tried it as described below

  async ngOnChanges(changes: SimpleChanges) {
    console.log(changes);
 
    if (isGuid(changes["recordId"]?.currentValue)) {
      const dataModel = await Model.create("ClvObject");
      const filters = new FilterGroup();
      filters.addSchemaColumnFilterWithParameter(ComparisonType.Equal, "ClvProject", this.recordId, "currentFilter");
      const records = await dataModel.load({
//        attributes: ["Id", "ClvName", "ClvType", "ClvProject.ClvCommissioning"],
        attributes: [{ 
          aggregationConfig: {
            aggregationFunction: AggregationFunction.Count,
          },
          type: "aggregation",
          path: "Id",
          name: "AppCount",
          caption: "AppCountCaption",
          dataValueType: DataValueType.Integer
        }],
        parameters: [{
            type: ModelParameterType.Filter,
            value: filters
        }]
      });
      console.log(records);
 
    }
  }

But instead of getting one record with one column "AppCount" containig 2, I get two records each containg "Id" and "AppCount" 

Ok< I found out the way. Looks like aggregationConfig isn't yet working well and functionConfig should be used instead. Here is working exampe.

  async ngOnChanges(changes: SimpleChanges) {
    console.log(changes);
 
    if (isGuid(changes["recordId"]?.currentValue)) {
 
      const dataModel = await Model.create("ClvObject");
      const filters = new FilterGroup();
      filters.addSchemaColumnFilterWithParameter(ComparisonType.Equal, "ClvProject", this.recordId, "currentFilter");
      const records = await dataModel.load({
//        attributes: ["Id", "ClvName", "ClvType", "ClvProject.ClvCommissioning"],
        attributes: [
          { 
            type: "function",
            path: "Id",
            name: "AppCount",
            caption: "AppCountCaption",
            dataValueType: DataValueType.Integer,
            functionConfig: {
              aggregation: AggregationFunction.Count,
              type: "aggregation",
              aggregationEval: "all",
            }
          }],
          parameters: [{
              type: ModelParameterType.Filter,
              value: filters
          }
        ]
      });
      console.log(records);
 
    }
  }

And result

Show all comments

Dear colleagues,

 

In Classic UI I can solve this by code, but in Freedom is also possible?, somebody know in which schema I need to do this and the related code?

 

Thanks & Regards

Like 0

Like

8 comments
Best reply

Hello Julio,

See this article here: https://customerfx.com/article/adding-row-action-menu-items-to-a-creati…

You can override the menu (usually to add other menu items to it). When you do so you override the "Open", "Copy", "Delete" options and need to add them back in. You could override the menu and then just only add back in the "Open" option. It would look like this (the article will provide more details)

viewConfigDiff: /**SCHEMA_VIEW_CONFIG_DIFF*/[
    {
        "operation": "merge",
        "name": "DataTable",
        "values": {
            //...,
            "rowToolbarItems": [{
                type: 'crt.MenuItem',
                caption: 'DataGrid.RowToolbar.Open',
                icon: 'edit-row-action',
                disabled: "$Items.PrimaryModelMode | crt.IsEqual : 'create'",
                clicked: {
                    request: 'crt.UpdateRecordRequest',
                    params: {
                        "itemsAttributeName": "Items",
                        "recordId": "$Items.PDS_Id"
                    }
                }
            }]
        }
        //...
    },
    //...
]/**SCHEMA_VIEW_CONFIG_DIFF*/

Essentially you're replacing the existing menu with one that only has the Open menu option. This works for any list (section or a list on a page)

Ryan

and the same in a Detail (Freedom page)?

Hello Julio,

See this article here: https://customerfx.com/article/adding-row-action-menu-items-to-a-creati…

You can override the menu (usually to add other menu items to it). When you do so you override the "Open", "Copy", "Delete" options and need to add them back in. You could override the menu and then just only add back in the "Open" option. It would look like this (the article will provide more details)

viewConfigDiff: /**SCHEMA_VIEW_CONFIG_DIFF*/[
    {
        "operation": "merge",
        "name": "DataTable",
        "values": {
            //...,
            "rowToolbarItems": [{
                type: 'crt.MenuItem',
                caption: 'DataGrid.RowToolbar.Open',
                icon: 'edit-row-action',
                disabled: "$Items.PrimaryModelMode | crt.IsEqual : 'create'",
                clicked: {
                    request: 'crt.UpdateRecordRequest',
                    params: {
                        "itemsAttributeName": "Items",
                        "recordId": "$Items.PDS_Id"
                    }
                }
            }]
        }
        //...
    },
    //...
]/**SCHEMA_VIEW_CONFIG_DIFF*/

Essentially you're replacing the existing menu with one that only has the Open menu option. This works for any list (section or a list on a page)

Ryan

Ryan Farley,

Thanks Ryan, I promise I looked first, before to publish, in your articles, but didn't found this one. Thanks a lot

 

Regards

Julio

Ryan Farley,

Dear Ryan, I didn't found the crt.DataGrid element in the viewConfigDiff in the code of the listpage, I found it on a FormPage, but I need it also in a the ListPage

solved no need to search crt.DataGrid, jus add it on viewConfigDiff

Julio.Falcon_Nodos,

Yes correct. For the list page, the List (crt.DataGrid) exists in the parent page, you just need to merge in the changes.

Ryan

No worries - there's so much new info now with Freedom UI stuff, it's hard to know what to even search for!

Julio.Falcon_Nodos writes:

Ryan Farley,

Thanks Ryan, I promise I looked first, before to publish, in your articles, but didn't found this one. Thanks a lot

Regards

Julio

This could really do with being configurable using no-code tools, as it's quite cumbersome to apply to every list users will see but is often important - being able to copy records which should have to be created in specific ways is often an issue for business data.

Show all comments

Hello,



Can anyone tell me How to merge duplicate contact records in freedom UI.

I tried using the classic UI but  can't find any duplicate rule or show duplicates in the action button



Thanks in advance.

Like 0

Like

3 comments

Hello,



To find duplicates in Freedom UI, you need to go to System Designer, then select Setup duplicates rules.



There you will be able to perform all the actions you need.

Malika,

Hi ,

Setup duplicates rules is not sowing under System setup. Is it due to the latest version??



Abhishek,

Is this a cloud or local system?

If it's local, you probably need to set up the deduplication components first to have it available.

Show all comments

Hi Everyone,



Is there any way to restrict number of file to be attached in the attachment detail tab in Freedom UI??



Thanks in Advance

Like 0

Like

1 comments

Hello Abhishek,

 

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. 

Show all comments

Dear community,

 

Has anyone been able to use the Excel Reports app in V8?

We installed https://marketplace.creatio.com/app/excel-reports-builder-creatio but the option is only visible in the old UI.

 

Kind regards,

Yosef

Like 6

Like

3 comments
Best reply

Hi Yosef!

The app does not support report download in Freedom UI sections.

As a workaround, you can set up reports that have "Custom report" report type. That way you can generate a report in the Excel reports section.

+1 Also really hoping this gets updated, or even better some enterprise level reporting functionality. 

Yes, I'd rather it become an OOTB functionality in Creatio 8.1 ... an enterprise grade tools requires enterprise grade reporting

Hi Yosef!

The app does not support report download in Freedom UI sections.

As a workaround, you can set up reports that have "Custom report" report type. That way you can generate a report in the Excel reports section.

Show all comments

Hello, 

 

Do you know how to mask first 12 digits of a Credit Card in Freedom UI Creatio?

 

Example :-

Credit Card Number :- 2345-2121-1225-8909

After masking I want to see as ****-****-****-8909 in Freedom UI.

 

Thanks,

Like 1

Like

1 comments

You can try using the password input which will mask the entire text as ****. This control doens't appear in the toolbox, so to add it, you could add an input, then in the code change "type": "crt.Input" to "type": "crt.PasswordInput". You can see an example of this control in the page SysUserProfilePage (user profile page)

 

If you need it more how you described, showing the last 4 digits, you would need to implement your own custom control. You can see details for that here: https://academy.creatio.com/docs/8.x/dev/development-on-creatio-platfor…

 

Ryan

Show all comments

I have a problem filtering a lookup filed using Freedom UI.

The issue here:

The first lookup filed linked to the Contact entity

The second lookup filed's entity Account, contains a field "SMPrimaryAccountOwner" and it should be equal to the first filed value. 



Here is the filter:

 

{
				request: "crt.LoadDataRequest",
				handler: async (request, next) => {
					// filter the contact lookup for the account
					debugger;
					if(request.dataSourceName !== "LookupAttribute_emk4fel_List_DS") {
						return await next?.handle(request);
					}
 
 
					const account = await request.$context.LookupAttribute_r6avpkd;
					if (account) {
						const filter = new sdk.FilterGroup();
						await filter.addSchemaColumnFilterWithParameter(sdk.ComparisonType.Equal, "SMPrimaryAccountOwner.Id", account.value);
 
						// note, these lines are only needed due to an issue with filters in Creatio-DevKit SDK
						// expected to be fixed in Creatio 8.1
						//const newFilter = Object.assign({}, filter);
						//newFilter.items = filter.items;
 
						request.parameters.push({
							type: sdk.ModelParameterType.Filter,
							value: filter
						});
					}
 
					return await next?.handle(request);
 
				}
			}



And here is the error on the console:



 

Maybe anyone here had the same issue.

Like 0

Like

2 comments
Best reply

Try changing to just the field "SMPrimaryAccountOwner" and not the ".Id" part at the end.

await filter.addSchemaColumnFilterWithParameter(sdk.ComparisonType.Equal, "SMPrimaryAccountOwner", account.value);

Also, even if you're on 8.1 the commented lines are necessary - the issue that works around was *not* fixed in 8.1.

Ryan

Try changing to just the field "SMPrimaryAccountOwner" and not the ".Id" part at the end.

await filter.addSchemaColumnFilterWithParameter(sdk.ComparisonType.Equal, "SMPrimaryAccountOwner", account.value);

Also, even if you're on 8.1 the commented lines are necessary - the issue that works around was *not* fixed in 8.1.

Ryan

Try adding the filter for "SMPrimaryAccountOwner" and not "SMPrimaryAccountOwner.Id", as in: 

await filter.addSchemaColumnFilterWithParameter(sdk.ComparisonType.Equal, "SMPrimaryAccountOwner", account.value);

Also, the workaround that is commented out is still needed in 8.1. It was not fixed in 8.1.

Ryan

Show all comments

Hi everyone,

 

How can we override the onClick functionality of the attachment link? Or is there any way to disable the link?



Thanks & regards,

Ramya

Like 0

Like

3 comments

Hello Ramya,

 

We thought on overriding the logic of the crt.DownloadEntityFileRequest request, but the handler doesn't trigger upon clicking the file. I will ask our R&D team to make it possible to control the download of files out-of-the-box and do it in the nearest releases.

 

Thank you!

Oleg Drobina,

 

Thank you for the swift response. Since overriding is not possible as of now, is there any way to disable the link? Something similar to the Classic UI diff value "showValueAsLink" : false?



Regards,

Ramya

Oleg Drobina,

 

Can you also elaborate what handler is getting called if it is not "crt.DownloadEntityFileRequest" ?

Show all comments

Is there any way  to change the color of all tabs on all the  record pages across the system by using low code

Like 0

Like

3 comments

Hello,

 

There is no such functionality for now. 

But we've registered it in our R&D team backlog for consideration and implementation in future application releases. 

 

hank you for helping us to improve our product. 

 

So now if we have to use this functionality how we can achieve  this using by code?

Surbhi Garg,

 

We don't have an example of it's implementation for now.

Show all comments