Options

Workflow Condition in Dynamics NAV 2016

Hello,

How can I do an approval workflow with a complex condition (could be a function from a codeunit)?

Thank You!

Best Answer

Answers

  • Options
    samlieshoutsamlieshout Member Posts: 7
    Maybe you could create an event that does the condition?
    Thanks, Sam.
    Microsoft Dynamics NAV | App Service Engineer | Comments are my own
  • Options
    catitieneicatitienei Member Posts: 5
    Yes, I tried, but I have the following business case which I didn't succeed to implement with workflows:

    Sales Order needs approvals from different users depending on following conditions:
    - Customer Credit Limit is exceeded (exist a workflow template for this) (Approval request from Sales Director)
    - Customer is blocked (Approval request from Sales Director Assistant)
    - Item from Sales Line has an available quantity under a value setup on Location (Approval Request from Inventory Manager)
    - Sales Price is changed in Sales Line. (Approval Request from Product Manager)

    How can I setup different workflows to send approval request to a Workflow User Group depending on conditions described above?

    I think I have to request approvals also for Sales Order Lines (for Inventory Level and Sales Price), how can I do this?
  • Options
    samlieshoutsamlieshout Member Posts: 7
    Sadly workflow doesn't really support 'or' conditions like this. You could get around this by creating 4 workflows with a custom event to handle the relevant approval loops.
    Thanks, Sam.
    Microsoft Dynamics NAV | App Service Engineer | Comments are my own
  • Options
    catitieneicatitienei Member Posts: 5
    I've tried with two workflows, one on Customer credit limit (standard workflow template) and second one with a custom event on Sales Header (All most the same as Customer credit limit but on Customer Blocked this time).

    The main event of both workflows is "Approval of a sales document is requested" (with an additional filter on Sell-to Customer No <> '' in order to enable both workflows).

    And here I have the following steps:
    1. First workflow send the approval request if the credit limit is exceeded. If the approval request is approved then the Order is released.
    2. First workflow release the Order if the credit limit is not exceeded.
    In both cases the second workflow is never triggered.

    Any ideea how to link the workflows, or how to trigger more than one on the same event to check different conditions?
  • Options
    MartinStrategixMartinStrategix Member Posts: 2
    Hi Catitienei, have you managed to source a solution to this worklfow scenario? I have the same challenge and looking for possible standard NAV solution or will there have to be dev done?
    Thanks
  • Options
    catitieneicatitienei Member Posts: 5
    Hi,

    I didn't succeed to manage this with standard functionality. I did some development as I remember.
  • Options
    sunnyksunnyk Member Posts: 276
    Hi
    On credit Limit Approval, is it possible to set approval based on credit limit Exceeds? Like if Credit Limits exceeds by 1000 then go to XX approver, if it is more than 5000 then go to ZZZ approver.
Sign In or Register to comment.