Skip to main content

Notifications

Microsoft Dynamics AX (Archived)

How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

(0) ShareShare
ReportReport
Posted on by 1,811

Hii,

We have two separate line review workflows for purchase requisitions and purchase orders.

We manually release purchase requisition to purchase order when PR workflow status is approved. Its our business requirement to run two separate workflows for PR and PO. 

Problem: On PR to PO release, Purchase Order approval status remains Approved and PO workflow do not activate. We want newly created PO from PR approval status should be Draft, so that PO workflow could be applied. For manual PO workflow works.

Please guide how we can achieve this?
Do we need customization?

Best Regards.

*This post is locked for comments

  • Doug Lehmkuhl Profile Picture
    Doug Lehmkuhl 5 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    Thank you very much. I typically turn off Public Sector as Microsoft has identified that config key as a considerable performance impact.  Specifically speaking, enabling the "Vendor bidding" sub config key under Public Sector will allow this purchase order draft status flag to appear.

  • BryanHoo Profile Picture
    BryanHoo 45 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    hi,

    I have turned this parameter on. However, my PRs are still released in POs with the status approved. Am I missing something?

  • Trey S Profile Picture
    Trey S 15 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    For anyone who has the same issue as I did, a developer tracked it to the Public Sector section of the license key configs that were disabled in that environment.

  • saransh321 Profile Picture
    saransh321 212 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    thanks rana anees

  • Trey S Profile Picture
    Trey S 15 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    Thank you for checking.  Can you think of a reason why I would not be able to see it?  I have already checked every license configuration that made sense to me.

    Any help is much appreciated.

  • qianwang Profile Picture
    qianwang 7,151 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    Hi Trey S,

    It isn't removed.

    7206.png

    Regards,

    QianQW

  • Trey S Profile Picture
    Trey S 15 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    David Key  I have looked on Procurement and sourcing parameters do not have that button shown in your picture.  My environment is D365 version 10.0.7 (Update 31 platform) - was it removed?

  • Suggested answer
    David Key Profile Picture
    David Key 35 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    In D365 version 10.0.6, it is Standard. Plz check ON on Procurement and sourcing parameter Give purchase orders created via purchase requisitions Draft approval status.  When relesed PR to PO, approval status's PO is Draft.

    4152.Capture.PNG

  • Verified answer
    Rana Anees Profile Picture
    Rana Anees 1,811 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    This customization is if you are creating PO from PR manually.

    PO auto approved status will be turned to draft so the PO workflow could be applied.

    Class Name: PurchAutoCreate_PurchReq 
    Method Name: endUpdate()

    public void endUpdate()
    
    {
    
    super();
    
    // Calculate discount before purchTable is automatically changed to approval status
    
    if (purchTable.ChangeRequestRequired)
    {
    
    purchTable.reread();
    
    if(PurchParameters::find().AutomaticTotalDiscount)
    
    {
    
    purchTable.updateFinalDisc();
    
    }
    
    }
    
    //purchTable.autoApproveChangeRequest(); only commented this line
    
    }


  • Rana Anees Profile Picture
    Rana Anees 1,811 on at
    RE: How to convert PO approval status from approved to draft when manually releasing PR? AX 2012 R2

    Hii ievgen Miroshnikov,

    That's great. Could you please share the customization details, code and where to apply.

    We appreciate that.

    Best Regards,

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,965 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,817 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans