Hello.

I have a web services API that requires an Id and an hmac generated with the request parameters and an API Key to be placed in its authorization header.

Is there a way to obtain the call body to perform the HMAC?

In postman I have been able to make the call successfully with a pre-request which is the following:

 

const apiKey = pm.collectionVariables.get("apiKey");;
const webId = pm.collectionVariables.get("webId");
const crypto = require('crypto-js');
 
if(pm.request.method === 'POST') {
 
    const parsedBody = JSON.parse(pm.request.body.raw);
    const jsonParams = JSON.stringify(parsedBody);
 
    // Create HMAC
 
    const hmac = crypto.HmacSHA256(jsonParams, apiKey);
    const hmacb64 = crypto.enc.Base64.stringify(hmac);
 
    // Set computed HMAC as an environment variable (or you could add it directly to the headers)
    pm.environment.set('hmacb64', hmacb64);
 
    // Construct the Authorization header
    const authorizationHeader = "signmage " + webId + ":" + hmacb64;
    pm.environment.set('Authorization', authorizationHeader);
} else if(pm.request.method === 'GET') {
 
    const url = pm.request.url.getPathWithQuery();
 
    const hmac = crypto.HmacSHA256(url, apiKey);
    const hmacb64 = crypto.enc.Base64.stringify(hmac);
 
    // Set computed HMAC as an environment variable (or you could add it directly to the headers)
    pm.environment.set('hmacb64', hmacb64);
 
    // Construct the Authorization header
    const authorizationHeader = "signmage " + webId + ":" + hmacb64;
    pm.environment.set('Authorization', authorizationHeader);
}

 


But in Creatio I'm a little lost if it's possible to do something similar.

I would appreciate it if you could help me know if this is possible. Thank you.

Like 0

Like

0 comments
Show all comments
Question

Hi Community. 
I have this piece of code: 

segmentationBatch is List 

but postgres throws an error that it can't compare uuid with uuid[] - which is understandable, but how do I pass a list of Id's into the update? 

Has anyone came accross this issue? 

 

P.S. I need it that way because it's a batch of records that I need to update and I need to keep those Id's for the following logic so I cannot rebuild the filtering criteria here.

var update = new Update(UserConnection, EntitySchemaName)
                .Set("UsrProfitCenter", Column.Parameter(segmentation.ProfitCenter))
                .Where("Id").In(Column.Parameter(segmentationBatch)) as Update;
            return update.Execute();
Like 0

Like

1 comments

Upd: 
Figured it out myself

 

 .Where("Id").In(Column.Parameters(segmentationBatch))
Show all comments

When we set up a filter on the List page of the web interface, it works on the web interface but not on the mobile interface.

Filtering is not working in the Creatio Mobile (Freedom UI)

Could  you please let us know, how can we setup filter in mobile.

Like 0

Like

0 comments
Show all comments

Hi.

 

I have this simple BP that has a Guid parameter which represents the Id of a real file inside the system. I take this file into a "Process file" element and tries to save it inside a specific Contact's attachment detail:

 

Then, in another "Process file" element up next, I take that file created inside the Contact's attachment detail in order to use it in the "Send Email" element:

 

 

However, upon checking both the email Activity created from this BP, as well as the Process log for this BP, nothing is attached:

Also, the resulting file collection from the second "Process File" element seems to be empty as well:

 

 

What am I doing wrong? I feel like this should work, it's a pretty simple example.

 

Thanks in advance,

Laurentiu

Like 1

Like

1 comments

Your account attachments/files could be using one of two file locations/objects. With Freedom UI a generic " attached file" object was introduced that could be used with any object. However, many objects have specific file/attachments objects, such as "Account files", or "Contact files" (sometimes those are named "File and link of account"). Make sure that you're using the correct object based on what you have on the screens. To check this, open the page in the designer and click on the attachments list, you'll see the object the page is actually using there in the "File storage location" property. 

Ryan

Show all comments

Hi All, 

 

Greetings!

Attaching my source code file.

 

UsrDate -> Date 

UsrStartTime -> Time

CreatedOn -> Date/Time

 

I am getting following error in few records - 

Worklogs Integrations synchronized with errors: {"bd455ee2-8f6e-4aed-bafc-890304110ac3":"SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM.","3d4508d8-bf40-48b4-ab65-d836c7c0b3da":"SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM."}

screenshot from the source code is below - 


Screenshot of the record is below - 

 

 

Is it because Start time is NULL ?

If yes how can I handle this in the code so that the records gets synchronized with NULL ?


 

Thanks.

File attachments
Like 0

Like

0 comments
Show all comments

Hello, I have a [Object A] form page where I have an Expanded List (detail) inside it [Object B] created. In [Object B] I need to have multiple records, so now I need to make a relationship between [Object A] and [Object B], but the app doesn't show me a relationship between IDs or anything like that.

I've already tried manually creating a Lookup inside [Object B] pointing to [Object A], but I was wondering if there's a better way to do it?

Like 1

Like

1 comments

Hello,

You need to create one-to-many relations between these objects. To do this, you need to create a lookup column in each object that will refer to another object. After that, you will be able to use filters and relationships to display and customize the necessary lists.
You can't do it using no-code elements because this connection is set up at the object level.

Show all comments

Hello.

Question: Is it not possible to add Virtual Detail in Modal?

I tried to add a Virtual detail in a Modal, but it do not shows Detail.
In Contact Page I have Virtual Detail and after clicking in row I open Modal where I added  Virtual Detail but it do not shows and there  are no errors also in Console.

This is A Modal after clicking in row and its empty.

 

Code For Modal:

define("UsrCreateVirtualFinancialAccountsModalPage", ["ModalBox", "css!UsrCustomStylesCss"], function(ModalBox, UsrCustomStylesCss) {
	return {
		attributes: {
 
		},
		messages: {
			"DataFromModal": {
				mode: Terrasoft.MessageMode.PTP,
				direction: Terrasoft.MessageDirectionType.BIDIRECTIONAL
			}
		},
		methods:{
			init: function(callback, scope) {
				this.callParent(arguments);
            	console.log('test')
			},
		},
		details: /**SCHEMA_DETAILS*/{
			"UsrFinancialAccountsVirtualDetail": {
				"schemaName": "UsrFinancialAccountsVirtualDetail"
			},
		},
		diff: [
			{
				"operation": "insert",
				"name": "MyContainer",
				"propertyName": "items",
				"values": {
					"itemType": Terrasoft.ViewItemType.CONTAINER,
					"items": []
				}
			},
			{
				"operation": "insert",
				"name": "MyGridContainer",
				"parentName": "MyContainer",
				"propertyName": "items",
				"values": {
					"itemType": Terrasoft.ViewItemType.GRID_LAYOUT,
					"items": []
				}
			}, 
 
			{
				"operation": "insert",
				"name": "UsrFinancialAccountsVirtualDetail",
				"values": {
					"itemType": 2,
					"markerValue": "added-detail"
				},
				 "layout": {
                        "column": 0,
                        "colSpan": 25,
 
                        "row": 5,
                        "rowSpan": 5
                    },
				"parentName": "MyGridContainer",
				"propertyName": "items",
				"index": 1
			},
		]
	};
});
Like 0

Like

1 comments

Hello. 
I implemented similar logic but instead of opening a modal page, i open card for the detail. In case section i added a test detail. When double clicking on a record in this detail onGridRowDoubleClick method is called which set values of record to sessionStorage and opens a UsrTestCardPage. Than init method is called while page is initializing which sets the field values.

Card schema:
 define("UsrTestCardPage", [], function() {
    return {
        entitySchemaName: "UsrTestDetail",
        attributes: {},
        modules: /**SCHEMA_MODULES*/{}/**SCHEMA_MODULES*/,
        details: /**SCHEMA_DETAILS*/{}/**SCHEMA_DETAILS*/,
        businessRules: /**SCHEMA_BUSINESS_RULES*/{}/**SCHEMA_BUSINESS_RULES*/,
        methods: {
            init: function() {
                this.callParent(arguments);
                this.getSessionStorage();
            },
            
            getSessionStorage: function() {
                var UsrName_SessionValue = sessionStorage.getItem("UsrName_Session");
                var UsrIntColumn_SessionValue = sessionStorage.getItem("UsrIntColumn_Session");
                var Id_SessionValue = sessionStorage.getItem("Id_Session");
                this.set("UsrName", UsrName_SessionValue);
                this.set("UsrIntColumn", UsrIntColumn_SessionValue);
                this.set("Id", Id_SessionValue);
            }
        },
        dataModels: /**SCHEMA_DATA_MODELS*/{}/**SCHEMA_DATA_MODELS*/,
        diff: /**SCHEMA_DIFF*/[
            {
                "operation": "insert",
                "name": "UsrName2a0f6821-93ff-4f8b-a8c0-e58bb9032171",
                "values": {
                    "layout": {
                        "colSpan": 24,
                        "rowSpan": 1,
                        "column": 0,
                        "row": 0,
                        "layoutName": "ProfileContainer"
                    },
                    "bindTo": "UsrName"
                },
                "parentName": "ProfileContainer",
                "propertyName": "items",
                "index": 0
            },
            {
                "operation": "insert",
                "name": "INTEGER406f5583-84ac-4659-9ff8-46b9c72de82a",
                "values": {
                    "layout": {
                        "colSpan": 24,
                        "rowSpan": 1,
                        "column": 0,
                        "row": 1,
                        "layoutName": "ProfileContainer"
                    },
                    "bindTo": "UsrIntColumn",
                    "enabled": true
                },
                "parentName": "ProfileContainer",
                "propertyName": "items",
                "index": 1
            },
            {
                "operation": "insert",
                "name": "LOOKUPcb467c2f-f352-4ac0-90ea-f25c2ed22119",
                "values": {
                    "layout": {
                        "colSpan": 24,
                        "rowSpan": 1,
                        "column": 0,
                        "row": 2,
                        "layoutName": "ProfileContainer"
                    },
                    "bindTo": "UsrCase",
                    "enabled": true,
                    "contentType": 5
                },
                "parentName": "ProfileContainer",
                "propertyName": "items",
                "index": 2
            }
        ]/**SCHEMA_DIFF*/
    };
});

 

 

Detail schema:


Hope this helps

Show all comments

Hello
Is there any possibility to show in a filter only the legal entities that I select in advance?

For example, in the "Branch" lookup, I would like to see only the legal entities with a property set by me, not all of the LE.

 

Like 2

Like

2 comments

Hello,

Unfortunately, the basic functionality of the platform doesn't allow you to filter values specified by you. However, we've registered this idea in our R&D team backlog for consideration and implementation in future application releases. Thank you for helping us to improve our product.

Great idea :) It's like also making sure some inactive values are not only inactive in dropdowns, but also in filters. 

Show all comments

Hi, mentors, 

 

      I'd like to have the function to auto save for specific field when lookup change,  instead of clicking the Save button. 

I think it might need the handler function is js, if existed, please kindly share. 

 

Jeffrey. 

 

Like 0

Like

1 comments
Best reply

You'll need to add a change request handler to know when the lookup value has changed. See https://customerfx.com/article/responding-to-an-event-when-a-field-is-changed-on-a-creatio-freedom-ui-page/

Then you'll execute a crt.SaveRecordRequest to save the record. See https://customerfx.com/article/saving-a-page-before-some-action-on-a-creatio-freedom-ui-page/

Ryan

You'll need to add a change request handler to know when the lookup value has changed. See https://customerfx.com/article/responding-to-an-event-when-a-field-is-changed-on-a-creatio-freedom-ui-page/

Then you'll execute a crt.SaveRecordRequest to save the record. See https://customerfx.com/article/saving-a-page-before-some-action-on-a-creatio-freedom-ui-page/

Ryan

Show all comments

Dears

 

Again in Creatio 8.1.4 we found not available the selection of a contact to create a new Creatio User.

 

To enable this you need to enable the SysAdminUnitFeatures.ShowContactInAdminUnit Feature.

 

But when did it, and try to save get an error "Name field must be filled in".

 

Had somebody try this?, is some workorund? or another way to enable select a contact to cerate a New User in STUDIO Creatio instance (JUST Studio)

 

Thanks

 

Julio Falcón

 

 

Like 2

Like

2 comments

Hello,

1) When adding this feature, you should specify "For all employees".
2) Save for current user. 
3) Enable the feature in general.
 
Then the error shouldn't occur.

 

Ivan Savenko,

Thanks Ivan

 

I saw I need to 

1.- Open the Feature page, 

2.- Add the All Employees group, 

3.- Check enable the feature to all Employees,

4.- Click on Status to Enable

5.- Save (Still getting the error, but saves)

6.- Logout & Login and voila, the contact search in System Users is available.

 

Show all comments