How to get the lastest workflow approved name in AX2012?
add the display method under the table methods nodes.
public display WorkflowStatusUserName getApproverUserName() { WorkflowTrackingStatusTable trackingStatusTable; WorkflowTrackingTable workflowTrackingTable; ; select firstOnly User from workflowTrackingTable order by CreatedDateTime desc, RecId desc where workflowTrackingTable.TrackingContext == WorkflowTrackingContext::WorkItem && workflowTrackingTable.TrackingType == WorkflowTrackingType::Approval exists join trackingStatusTable where trackingStatusTable.RecId == workflowTrackingTable.WorkflowTrackingStatusTable && trackingStatusTable.ContextTableId == this.TableId && trackingStatusTable.ContextRecId == this.RecId; return SysWorkflowHelper::getDirPartyNameFromUserId(workflowTrackingTable.User); }