Question

On Lookup Change - Freedom UI Creatio

Hello,

 

Please note that I tried to trigger a function on lookup change using the below code:

 

{

    request: "crt.HandleViewModelAttributeChangeRequest",

    handler: async (request, next) => {

        // listen for changes to the EmployeesNumber field

        if (request.attributeName === "EmployeesNumber" && !request.silent) {

            console.log("EmployeesNumber changed", request.oldValue, request.value);

        }

         

        return next?.handle(request);

    }

}

 

 

and I changed "EmployeesNumber" field by "UsrTicketStatus" 

you can find attached image below:<br />
<img alt="" data-entity-type="file" data-entity-uuid="e29bb553-d205-4a9f-b729-c90862b674e0" src="/sites/community.com/files/inline-images/Screenshot%202024-01-09%20140020.png" />





What is the issue here ?



Thank you

-Georges

Like 0

Like

2 comments

Hello Georges,

 

Are you sure that the attribute name "EmployeesNumber" is correct (and it doesn't have a name like "StringAttribute_ljc6yh6")? Do you stop at

 

console.log("EmployeesNumber changed", request.oldValue, request.value);

 

if you set a breakpoint in code at this row? The issue is that you don't receive a console message? 

Hello Oleg,

 

Thank you so much I checked the attribute name and changed it and it works normally

 

Thank you,

-Georges

Show all comments