Skip to main content
Answer

Execution order of customisations

  • April 23, 2024
  • 2 replies
  • 49 views

Forum|alt.badge.img+1

Hello - I have a situation where 2 different customisations are overriding the same method. In this case it is the ConfirmShipment method of the SOShipmentEntry graph. Like so...

public class SOShipmentEntryExt : PXGraphExtension<SOShipmentEntry>
{
public delegate void ConfirmShipmentDelegate(SOOrderEntry docgraph, SOShipment shiporder);
[PXOverride]
public void ConfirmShipment(SOOrderEntry docgraph, SOShipment shipment, ConfirmShipmentDelegate baseMethod)
{
//do some work
}
}

Is there a way to control which customisation performs it’s actions first?

Best answer by aaghaei

Yes you can. You can implement your graph and their extensions in order you want them to be executed as 

public class MyExt : PXGraphExtension<Ext2, Ext1, BaseGraph> {}

 

up to 10 level if I recall correctly is supported 

2 replies

aaghaei
Captain II
Forum|alt.badge.img+10
  • Captain II
  • Answer
  • April 23, 2024

Yes you can. You can implement your graph and their extensions in order you want them to be executed as 

public class MyExt : PXGraphExtension<Ext2, Ext1, BaseGraph> {}

 

up to 10 level if I recall correctly is supported 


darylbowman
Captain II
Forum|alt.badge.img+15

Yes you can. You can implement your graph and their extensions in order you want them to be executed as 

public class MyExt : PXGraphExtension<Ext2, Ext1, BaseGraph> {}

 

up to 10 level if I recall correctly is supported 

To be clear, this would require extending the other customization’s extension. It’s a great solution if it is appropriately workable.