openbravo document routing

approval routing

this openbravo tutorial show you how to setup openbravo approval routing. its capable to model document status evolution in your organization. for instance, you may adopt 4 eyes principle using openbravo.by default, openbravo standard approval proses is 1 step. for example, approving sales order is done straight from draft to complete, no intermediate document status available. for example, if you need salesman person submit sales order in RELEASED status, then sales supervisor approve it to change document status from RELEASED to COMPLETE, then openbravo standard can not do this. this openbravo wirabumi module are for. now openbravo refactored with powerful approval routing utility. you can create approval work flow as long as you need. also, you can setup approval hirearchy based on amount on both sales/purchase order/invoice.

to setup openbravo approval routing, we nee two part of configuration:

  1. document routing action handler
  2. document routing role configuration

when document routing action handler, defined in document routing configuration window, we define which library should be executed when document status changed.

based on screenshot above we can see openbravo will use org.wirabumi.gen.oez.porting.OrderActionHandler when sales order completed, openbravo wil use org.wirabumi.gen.oez.porting.InvoiceActionHandler when sales invoice completed. openbravo wirabumi come with several standard action handler (packaged into openbravo wirabumi module dataset), ported form openbravo original, to be executed when document status changed. if openbravo’s standard behaviour for document completion logic is enough for you, then standard these openbravo wirabumi’s action handler above is enough. so, why we need openbravo wirabumi module if its just migrating original code from psql to java (no extra features)? as mentioned before, you can setup, before approval logic executed, document status changed in an evolution to model your approval hierarcy. using openbravo original code, approval hierarcy does not exists, and executed logic upon document completion based on assumption that document status before completion is DRAFT.

next, document routing role configuration used to define previllage for each role. this previllage determine, on certain document, who can change document status. for example, who is authorized to submit sales order, change sales order document status from DRAFT to RELEASED, or who is authorized sales order document status from RELEASED to COMPLETED.

based on screenshot above we can see FnB group admin is able to change document status of sales order from DRAFT to RELEASE if sales order amount start from 0 to USD 1,000,000.

based on screenshot above we can see FnB group admin is able to change document status of sales order from release to complete if sales order amount start from 0 to USD 1,000,000.
now close sub tab document routing to switch from edit mode to grid mode.

you will see 2 records in this tab. its mean, user that assigned to FnB Group Admin role are able to change sales order from DRAFT to RELEASE or from RELEASED to COMPLETE since order amount started from USD 0 to maximum USD 1,000,000. in another word, FnB Group Admin can not change document status from DRAFT to COMPLETE directly nor change document status for any sales with amount exceed USD 1,000,000.

now we will see approval routing in action. open 1 of draft sales order, click approval button

now you can see if FnB international group admin can only change (a.k.a approve) from draft to release). click ok. now sales order changed from draft to released.

click approval button once again.

now you can see if FnB international group admin can only change (a.k.a approve) from release to complete). click ok. now sales order changed from released to complete.

conclution
now you can see now openbravo have approval hierarchy, to approve sales order in 2 steps: (#1) from DRAFT to RELESED, and (#2) from RELEASED to COMPLETED. based on configuration that you just created, its possible for you to setup 3 steps authorization or more. just to remind you that when sales order completed, based on entries inside document routing configuration window, logic inside org.wirabumi.gen.oez.porting.OrderActionHandler executed. if you need specific logic that vary from openbravo’s standard, you can build your own document routing configuration library, and execute it upon order completion.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s