Function/Handler called when creating a new record in a detail

Hi Creatio Community,

 

I would like to know the name of the function/handler that's called when creating a record and saving it in an editable detail in FreedomUI so that we can override it. We also noticed SaveRecordRequest doesn't seem to be called here.

 

Thanks in advance.

 

Regards,

Abilash.S

Like 0

Like

4 comments

Hello,

 

These should be the crt.CreateRecordRequest request and the crt.CreateRecordHandler handler. Try those in either:

 

1) Page where detail is added

2) Detail schema

3) Edit page of the detail

 

and it should be triggered.

Oleg Drobina,

 

Tried these two methods. They don't seem to be called when creating and saving the records in an editable detail.

Abilash,



I tried this handler:

handlers: /**SCHEMA_HANDLERS*/[
			{
				request: "crt.CreateRecordRequest",
				handler: async (request, next) => {
					return next?.handle(request);
				}
			}
		]/**SCHEMA_HANDLERS*/,

on the schema where detail is added and it's successfully triggered:

It also depends on which handler you have specified in the "Add button" properties, you need to find it in the schema diff (in my case it was crt.CreateRecordRequest):

{
				"operation": "insert",
				"name": "GridDetailAddBtn_z5e8jja",
				"values": {
					"type": "crt.Button",
					"caption": "#ResourceString(GridDetailAddBtn_z5e8jja_caption)#",
					"icon": "add-button-icon",
					"iconPosition": "only-icon",
					"color": "default",
					"size": "medium",
					"clicked": {
						"request": "crt.CreateRecordRequest",
						"params": {
							"entityName": "Contact"
						}
					},
					"visible": true,
					"clickMode": "default"
				},
				"parentName": "FlexContainer_n5yrzkv",
				"propertyName": "items",
				"index": 0
			},

 

Oleg Drobina,

 

The detail we are working with uses an inline record to create new records which doesn't seem to be calling CreateRecordHandler or CreateRecordRequest. 











 

Show all comments