2

In Workorder tracking , there is a field "LEAD" which will display ID of lead. In our requirement we have to display Leadname along with Lead ID. SO I created a new field for Leadname in Workorder and used crossover domain with a new relation between Wordorder and Person. Relation where clause being personid=:lead

The crossover domain copies over the value of Leadname from Displayname attribute of PERSON object and is working fine when we give an ID in Lead attribute of Workorder.

However in case if I give a Lead ID and then remove the lead ID in WO , then leadname still remains It doesnt get modified to null. I believe its because the crossover condition (personid=:lead ) is not satisfied and hence no action is being performed. I tried setting condition on Source and Destination as well but that also is not working.

Is there any way to default a field to null in case if crossover where clause condition is not met.

I was able to get this implemented by using automation script , but would like to know whether same can be achieved by some other means.

stackuser11
  • 31
  • 1
  • 8
  • Different thought. How about you just have a read-only that is a relationship from WORKORDER to PERSON. If the LEAD field is blank, the corresponding read-only field becomes blank. Unless you have a business reason to record displayname in workorder table, why create a new field in the database? – Sun Feb 14 '17 at 20:42
  • Business wanted the name information as well along with ID. If I make it readonly , at any point ,users wont be able to modify the Lead value on WO – stackuser11 Feb 15 '17 at 05:35
  • I meant making the displayname read-only. Same suggestion as Jeroen from 5 days ago. – Sun Feb 15 '17 at 19:23

2 Answers2

0

If it is just displaying the information you should use a multipart textbox to show lead and displayname of the person. You need to add a relation from workorder to person using the lead attribute. Then normal Maximo logic will clear the 'description' when you clear the actual lead field.

There is a way to cross-over fixed values, including null, to clear another field on a crossover action. Just make an ALNDOMAIN with a empty value (leave description empty) In the crossover domain use a relation that points to this specific domain/value and use dot-notation to crossover the description. Use relationname.description as the sourcefield in your crossover

Jeroen
  • 1,638
  • 3
  • 23
  • 48
  • Have you tried this? Problem 1: Changing the value of an attribute to null won't cause validation via an attached domain (and subsequent CO Domain firing, if applicable).Problem 2: PERSON.PERSONID is required (can't be null). So, even if validation happened (i.e. if Problem 1 wasn't a problem), if Lead is changed to null, the Validation Where Clause on the CO Domain would fail to find a match / something to crossover. So, I don't think this will work. – Preacher Feb 11 '17 at 00:29
  • yes the cross overdomain where clause doesnt get satisfied when we make the Lead as null and hence no action is performed. Alos I dint understand how to add ALNDOMAIN to work along with existing person ID and displayname crossover – stackuser11 Feb 13 '17 at 05:24
0

RFE 72680 / crossovers, option to set targets to null or default value when trigger field becomes null is intended to address this shortfall in functionality. Please cast your vote!

Preacher
  • 2,127
  • 1
  • 11
  • 25