Question

How to change the Status with a Auto-Run Workflow Action?


Userlevel 1
Badge

Good Evening,
i’d like to know if i am doing something wrong in my thinking,
or if its something else. Let’s start with the general game plan.

Game Plan

We have created several new Status to symbolice the process after a Sales Order is finished.
For our purpose i tried to start with two new Status.

Y - Billed
X - Partly Billed

My plan is to change the Status based on one field:
SOOrder.UnbilledOrderTotal

This field alone gives me much information to work with,
therefore i created several conditions to use in workflow actions.
(Ignore the placeholder Names)

The Conditions

IsInvoiceCreatedFully | UnbilledOrderTotal = 0

Translation: Field | Condition (Equals) | Scheme | Value

 


IsInvoiceCreatedPartial | UnbilledOrderTotal > 0 AND UnbilledOrderTotal <> [OrderTotal]

Translation Headers: Active | Brackets | Field | Condition | Scheme | Value 1 | Value 2 | Brackets | Operator


Here u can see i check if UnbilledOrderTotal is higher 0 AND if UnbilledOrderTotal is not the same as OrderTotal.


IsInvoicesDeleted | UnbilledOrderTotal = [OrderTotal]
 

Translation Headers: Active | Brackets | Field | Condition | Scheme | Value 1 | Value 2 | Brackets | Operator

 

If UnbilledOrderTotal equals OrderTotal


In my eyes, these should work.

Actions
As described in this wonderful PDF https://openuni.acumatica.com/wp-content/uploads/2017/08/W150_Workflows_2021R2.pdf i tried to create the Auto-Run Action under Example 2.1.4

For that i created several Actions the way its described in the PDF.

AutoAssign-Beendet (Beendet => Finished)
AutoAssign-InFaktura (In Faktura => Billed)
AutoAssign-T-InFaktura (Teilweise in Faktura => Partly Billed)

Those are all Workflow Actions.

Following the Example i’ve added the Actions as Transition to the Status “Completed” to the Status “Partly Billed” (for Example).

Workflow
This is how it looks inside of Status C (Completed)
 

IsInvoiceCreatedFully is set as Auto Run Condition

And this is the Transition itself.
The Trigger Name is correct (Referring to the Action AutoAssign-T-InFaktura)
Target State is Correct also. Nothing else to do here.
 


I tried this with several different Conditions,
but it wont reliable switch the Status. Sometimes it switches to “Billed”,
sometimes it just stays at Completed - Never to “Partly Billed” tho. With my other Transitions (Partly Billed/Billed -> Completed) its the same. If i delete the Invoice, it just stays at the current Status and does not go back to Completed.

I dont really see or know why, so if someone could help,
i’d appreciate it.

Greetings

 

 


11 replies

Userlevel 7
Badge +10

Hi @jwestermann17  We can Auto-Run the actions using workflows based on the conditions. Please find the steps below for your reference.

  • In Customization Project, go to screens (Left Menu) and add the Customize existing screen.
  • Create a condition, when you want to Auto Run the action.
  • Instead of changing the existing workflow, better extend workflow by clicking on the ADD WORKFLOW Action.
  • Open the extended workflow and goto Actions tab, we have Auto-Run action, there we can select the condition created above.
  • So that when condition is satisfied, Action will be executed automatically.

 

Please find the sample screenshots for your reference.

 

 

Userlevel 1
Badge

Hello @Naveen BB,

 

this is sort of the way I tried to use, but either my conditions are completely off, or it doesn't work the way it should. I've set the workflow actions as Auto-Run with Condition, but it's not really working.

Userlevel 7
Badge +10

Hi @jwestermann17  Have you set the conditions properly?

Today, we have used this feature for one of our customizations and it is working as expected.

Userlevel 1
Badge

Hej @Naveen B,

i’d certainly think so.

 

IsInvoiceCreatedFully | UnbilledOrderTotal = 0


IsInvoiceCreatedPartial | UnbilledOrderTotal > 0 AND UnbilledOrderTotal <> [OrderTotal]


IsInvoicesDeleted | UnbilledOrderTotal = [OrderTotal]

In my eyes these should work, if im not wrong.
The Conditions should check if either all shipments are invoiced or not.
If yes, it switches to a status like “Fully Invoiced”
if not, it switches to a status like “partially invoiced”
but it only does it if atleast one invoice exists.
If not, by using IsInvoicesDeleted, i check if there is no invoice atm.

 

Userlevel 7
Badge +10

Hi @jwestermann17  If possible, can you please share this customization package (it would be great only if you have added this to separate package and share it here). I will check from my end and let you know.

Userlevel 1
Badge

Hi @jwestermann17  If possible, can you please share this customization package (it would be great only if you have added this to separate package and share it here). I will check from my end and let you know.


Hi @Naveen B,
atm. i don’t have it as a seperate customization file, as we have it in a kinda big customization that adds a lot of status and changes to the SO Workflow. I’ll can create you a seperate one tomorrow if you want.

But mainly its just these Status:

Y - Billed
X - Partly Billed

The Conditions above and these Workflow Actions

AutoAssign-Beendet (Goes back to the default last Status)
AutoAssign-InFaktura (Goes to “Partly Billed”)
AutoAssign-T-InFaktura (Goes to “Billed”)

Userlevel 7
Badge +10

Sure, that helps a lot to check the where the issue is.

And thanks a lot for describing the issue in more detail. Once I get the sample customization package from you, I will check from my end and let you know.

Userlevel 1
Badge

Hello @Naveen B,
please find attached Customization Package.
 

Userlevel 7
Badge +10

Hi @jwestermann17  Thanks for sharing the package, will check and let you know

Userlevel 7
Badge +10

Hi @jwestermann17  I’m unable to upload and publish the above provided package in 21 R1 version, can you please let me know, in which version you are in? 

 

Userlevel 1
Badge

Hey @Naveen B,

i’m sorry but i am not sure.
We use the german version of Acumatica (Haufe X360, former called Lexbizz).
So it might be, that not every customization can be imported into acumatica.
I’ve tested it myself in 21 R2 and it displays the same error.

Thats somewhat a kinda bad thing to happen :(
 

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2020  Acumatica, Inc. All rights reserved