Skip to main content

In UI designer is there any way where we can put custom code in tab or  is there any function by which we can know which tab is active on clicking the tab.

Hey @meenakshim 

What is your goal? What should happen after you identify tab is clicked?

Cheers!


@Shneor Cheshin The goal is after clicking the tab it should trigger one client script. 


@meenakshim 

And what this client script should do?

The reason for asking is that what you are looking for does not exists. I am trying to figure out what you need and provide an alternative solution.

Cheers!


@Shneor Cheshin  The client script will update one column of the table in database


Hey @meenakshim 

Why not use the screen event? Like ‘After Data Load’?

Cheers!


@Shneor Cheshin We are already using screen event After Data Load. but it is creating conflict when two users login at same time and clicking same task. So we are trying to attach custom code in tab label


Hey @meenakshim 

What is the conflict? You should resolve it in the script.

Cheers!


@Shneor Cheshin  

We need to pass the logged in user to one of the param in Metrix Browser url. Something like below

https://intranetsite/testapp/equipmentdetails.aspx?taskid={{task.task_id}}&source=web&status={{task.task_status}}&user=loggedinuserid

So we are first updating one column with loogedinuser. 

But the conflict arises when two users logged in at a same time in same task

 


Hey @meenakshim 

How a ‘click tab’ event can help here? 2 users can still click a tab at the same time, no?

First, I am not sure what is Metrix Browser and why 2 users cannot be logged in parallel.

Second, I don’t think a client script will be useful here. As to my understanding you will need to manage sessions, understand when a user is in a session and when it is completed and so on.

Cheers!


@Shneor Cheshin  Metrix Browser is in the UI designer. Below is the screenshot

There is a field url in Metrix Browser where we are passing this url https://wfm-training2.ote.gr/Portalupgrade/FSM_ElementsChangeMeasurementFileMaster.aspx?taskkey={{task.task_id}}&name={{task.cuser_def555}}&source=ClickMobile&status={{task.task_status}}&callid={{task.user_def1}}

So our target is to update the column cuser_def555 on clicking of tab


Hey @meenakshim 

Thanks for the info. 

Again, how can a ‘Click Tab’ event prevent the issue you have? Potentially, the same issue can occour with this event. 

Is this a 1 time value population? Or you wish to change the URL every time this record is accessed?

If the second option is required, as I have written before, it is not manageable via client scripts. You need to manage sessions and understand when a session is ended and when it began, maybe some other details.

Unless I am missing the requirments you have,

Cheers!


Reply