Posted: 3 Jun 2019 16:59 EDT Last activity: 7 Jun 2019 11:18 EDT
Create Work or Open existing case
I have a grid. On each row of the grid I have a button. On click of the button I want to either create a new work object or open an existing one depending upon a certain condition determined at run time NOT AT THE TIME THE SCREEN IS RENDERED. So in other words the condition must be calculated at the time the button is clicked.
So how do I do this? I've seen people trying to implement what "create work" action on click of a button does by calling an activity but I see they are having trouble with it creating a new tab so I'm skeptical that creating an activity to do the same as "create work" action does will work.
You can configure the below action set: You will have to add a when condition for both that checks if the work object already exists or not. If if does, then perform 'Open work item', and if not then 'Create New Work'.
I tried this. When rules only seem to be evaluated at rendering time. They don't get called at run time. They don't even appear in tracer. If you are saying they should get evaluated at runtime then I guess I need to open an SR.
Yeah. I don't know if the refresh is going to work for me. If screen is up and they wait on the screen for a while the conditions could change. I'm not sure what you mean by below. Not sure how that can work for me
As you mentioned this will be decided runtime it should be based on some input or some property, configure a refresh section action at that particular runtime element field to refresh buttons section.
"On click of the button I want to either create a new work object or open an existing one depending upon a certain condition determined at run time NOT AT THE TIME THE SCREEN IS RENDERED. " - What is the certain condition you are trying to configure?
on the grid the user is selecting a row which represents a claim so if they click on the button on that row I want to either create a new case if a case doesn't already exist on that claim (-ie- based on claim number) or if the case already exists on that claim then just open the case. Optionally I could instead display an error in some way if the case already exists instead of opening it. I'm worried that a user might be sitting on this screen for a while while some other user might have already created a case on the the claim and so I do not want 2 cases to be able to be created on the same claim
So I can be a little flexible with the solution but I don't think it changes it much. What I can do is just display an error message in some way if a user clicks on a button to create a case and I find out there already exists a case instead of opening that case. Still I need to be able to check at run time if there is an already existing case to know if I need to create a new case or not.