Showing posts with label work flow auto approval. Show all posts
Showing posts with label work flow auto approval. Show all posts

Friday, October 31, 2025

workflow auto approval code in X++

 auto approval code:-

      WorkflowWorkItemTable           WorkflowWorkItemTable;
      WorkflowTrackingStatusTable     WorkflowTrackingStatusTable;

 

 

                select   WorkflowWorkItemTable 
                    join WorkflowTrackingStatusTable
                    where WorkflowWorkItemTable.CorrelationId == WorkflowTrackingStatusTable.CorrelationId
&& WorkflowTrackingStatusTable.ContextRecId == _newBudgetTransactionHeader.recid;

 

                WorkflowWorkItemActionManager::dispatchWorkItemAction(
                                WorkflowWorkItemTable,
                                "Auto Approve by ADMIN", // comment
                            curUserId(), //  user ID
                                WorkflowWorkItemActionType::Complete,
                              menuItemDisplayStr(BudgetTransactionHeaderWorkflowDropDialog) //  menu item action approval workflow
                            );



Purchase Orders

 Before confirming a Purchase Order, the system should display a confirmation popup if the purchase order is associated with an active inter...