business process management course 10.0.700

60
Epicor ERP Business Process Management Course 10.0.700

Upload: nerz8830

Post on 08-Apr-2016

281 views

Category:

Documents


21 download

DESCRIPTION

BPM Course

TRANSCRIPT

Page 1: Business Process Management Course 10.0.700

Epicor ERPBusiness Process ManagementCourse10.0.700

Page 2: Business Process Management Course 10.0.700

Disclaimer

This document is for informational purposes only and is subject to change without notice. This document and itscontents, including the viewpoints, dates and functional content expressed herein are believed to be accurate as of itsdate of publication. However, Epicor Software Corporation makes no guarantee, representations or warranties withregard to the enclosed information and specifically disclaims any applicable implied warranties, such as fitness for aparticular purpose, merchantability, satisfactory quality or reasonable skill and care. As each user of Epicor software islikely to be unique in their requirements in the use of such software and their business processes, users of this documentare always advised to discuss the content of this document with their Epicor account manager. All information containedherein is subject to change without notice and changes to this document since printing and other important informationabout the software product are made or published in release notes, and you are urged to obtain the current releasenotes for the software product. We welcome user comments and reserve the right to revise this publication and/ormake improvements or changes to the products or programs described in this publication at any time, without notice.The usage of any Epicor software shall be pursuant to an Epicor end user license agreement and the performance ofany consulting services by Epicor personnel shall be pursuant to Epicor's standard services terms and conditions. Usageof the solution(s) described in this document with other Epicor software or third party products may require the purchaseof licenses for such other products. Where any software is expressed to be compliant with local laws or requirementsin this document, such compliance is not a warranty and is based solely on Epicor's current understanding of such lawsand requirements. All laws and requirements are subject to varying interpretations as well as to change and accordinglyEpicor cannot guarantee that the software will be compliant and up to date with such changes. All statements ofplatform and product compatibility in this document shall be considered individually in relation to the products referredto in the relevant statement, i.e., where any Epicor software is stated to be compatible with one product and alsostated to be compatible with another product, it should not be interpreted that such Epicor software is compatiblewith both of the products running at the same time on the same platform or environment. Additionally platform orproduct compatibility may require the application of Epicor or third-party updates, patches and/or service packs andEpicor has no responsibility for compatibility issues which may be caused by updates, patches and/or service packsreleased by third parties after the date of publication of this document. Epicor® is a registered trademark and/ortrademark of Epicor Software Corporation in the United States, certain other countries and/or the EU. All othertrademarks mentioned are the property of their respective owners. Copyright © Epicor Software Corporation 2014.All rights reserved. No part of this publication may be reproduced in any form without the prior written consent ofEpicor Software Corporation.

ED849905

90521-10-9221-58310700

10.0.700

Revision: June 08, 2014 5:20 p.m.

Total pages: 60

course.ditaval

Page 3: Business Process Management Course 10.0.700

Contents

Business Process Management Course.................................................................................5Before You Begin....................................................................................................................6

Audience.........................................................................................................................................................6

Prerequisites....................................................................................................................................................6

Environment Setup..........................................................................................................................................6

Workshop Constraints..............................................................................................................................7

Business Process Management Overview.............................................................................8The Trace Log........................................................................................................................11

Workshop - Use the Trace Log.......................................................................................................................11

Set Up the Trace.....................................................................................................................................11

Add a Part..............................................................................................................................................12

View the Trace........................................................................................................................................12

Create an XML File.................................................................................................................................13

Disable Tracing Log.................................................................................................................................13

Restart System Monitor...........................................................................................................................13

Method Directives................................................................................................................15Workshop - Make a Field Mandatory.............................................................................................................15

Add a Method Code...............................................................................................................................16

Add a Pre-Processing Directive................................................................................................................16

Add First Condition.................................................................................................................................17

Extend First Condition.............................................................................................................................18

Add First Action......................................................................................................................................19

Add Another Condition..........................................................................................................................19

Extend Second Condition........................................................................................................................20

Add Second Action.................................................................................................................................21

Test the BPM for the Part Class...............................................................................................................22

Test the BPM for the Part Group.............................................................................................................22

Disable Directives....................................................................................................................................23

Workshop - Set Log Created By and Date......................................................................................................23

Add User Defined Columns.....................................................................................................................23

Synchronize Table...................................................................................................................................24

Regenerate Data Model..........................................................................................................................25

Add a Method Directive..........................................................................................................................25

Add a Pre-Processing Directive................................................................................................................26

Add an Action........................................................................................................................................26

Create a Customized Text Field...............................................................................................................28

Create Another Customized Text Field....................................................................................................28

Add Labels to Text Fields.........................................................................................................................29

Save and Test Customizations.................................................................................................................29

Disable Directive ....................................................................................................................................30

3Epicor ERP | 10.0.700

ContentsBusiness Process Management Course

Page 4: Business Process Management Course 10.0.700

BPM Workflow Designer......................................................................................................31General Principles..........................................................................................................................................31

Availability of Workflow Elements..................................................................................................................33

Hold Type..............................................................................................................................34Workshop - Create and Use a Hold Type........................................................................................................34

Create the Hold Type..............................................................................................................................34

Add a Method Code...............................................................................................................................35

Add a Pre-Processing Directive................................................................................................................35

Add an Action........................................................................................................................................36

Add a Pre-Processing Directive................................................................................................................36

Add an Action........................................................................................................................................37

Add a Post-Processing Directive..............................................................................................................37

Add an Action........................................................................................................................................38

Add a Post-Processing Directive..............................................................................................................39

Add an Action........................................................................................................................................39

Add a Method Code...............................................................................................................................40

Add a Pre-Processing Directive................................................................................................................40

Add an Action........................................................................................................................................41

Update a Customer Record.....................................................................................................................41

Create a Sales Order...............................................................................................................................42

Disable Directives....................................................................................................................................42

Data Directives......................................................................................................................44Workshop - Use Auto Print Action.................................................................................................................44

Locate the OrderHed Table.....................................................................................................................44

Add Standard Directive...........................................................................................................................45

Add an Action........................................................................................................................................45

Test the BPM..........................................................................................................................................46

Disable Directive.....................................................................................................................................47

Multiple Dirty Rows..............................................................................................................48Updatable BAQ Directives....................................................................................................49BPM and Service Connect Workflows.................................................................................51BPM Utilities..........................................................................................................................52

Action Processing...........................................................................................................................................52

BPM User Rights............................................................................................................................................53

BPM Logging.................................................................................................................................................53

Disable BPM...................................................................................................................................................57

Conclusion.............................................................................................................................59

Epicor ERP | 10.0.7004

Business Process Management CourseContents

Page 5: Business Process Management Course 10.0.700

Business Process Management Course

This course focuses on the Business Process Management (BPM). Using the BPM functionality, you can modifythe flow of business processes through the Epicor ERP application. This allows individual companies to tailor thebusiness flow to their specific requirements.

The course provides an introduction to the fundamentals of the BPM application. It begins with discussion onhow to set up a Tracing Log that captures all the calls the user interface makes to the server. When you activatethis log, any business logic (BL) calls sent to the server are automatically recorded within this log. The MethodDirectives section includes an overview of method directive workflow elements - actions and conditions. You areprovided with an understanding of the tool, as well as an opportunity to create a method directive. The HoldType section of the course explains how to assign a status to a record and take appropriate action when beingprocessed. You then learn how to apply a Data Directive to a specific table and trigger BPM execution using adatabase event. The course concludes with an overview of techniques you can use to manage BPM functionalityof your Epicor ERP application.

The course includes examples that can be created with BPM, that require little or no programming knowledge.

The course format includes presentation, demonstrations, and hands-on workshops that enable you to quicklyand efficiently learn Business Process Management basics in correlation with modifying the flow of processes inthe application.

Upon successful completion of this course, you will be able to:

• Set up a Trace Log to review business logic calls triggered by your application activity.

• Understand the basic methods within a business object.

• Understand the features and functionality of Method Directives.

• Become familiar with the available workflow elements and corresponding User Texts.

• Use many of the pre-defined condition statements to define criteria that must be met before a method directiveaction can be performed.

• Initiate application tasks based on conditions defined in the Method Directive.

• Perform actions in a method directive based on BPM Hold Types.

• Comprehend the differences of the Pre-, Base, and Post-Processing directives.

• Apply a standard Data Directive on a table to execute an action after the data is saved to the database.

• Work with the dependent post process capability.

• Understand the impact of RowMod being set to Added, Updated, Changed, or Deleted.

5Epicor ERP | 10.0.700

Business Process Management CourseBusiness Process Management Course

Page 6: Business Process Management Course 10.0.700

Before You Begin

Read this topic for information you should know in order to successfully complete this course.

Audience

Specific audiences will benefit from this course.

• System Administrator

• IT/Technical Staff

Prerequisites

To complete the workshops in this course, the necessary modules must be licensed and operating in your trainingenvironment. For more information on the modules available, contact your Epicor Customer Account Managerat [email protected]. It is also important you understand the prerequisite knowledge contained in othervaluable courses.

• Navigation Course - This course introduces navigational aspects of the Epicor application's user interface.Designed for a hands-on environment, general navigation principles and techniques available in two userinterface modes - Classic Menu and Modern Shell Menu. Workshops focus on each of these modes andguide you through each navigational principle introduced.

• Advanced Personalization - This course will show you how to personalize the system in a way that bestsuits your company's needs and how to export these personalizations so that others can import thepersonalizations into their computers.

• Embedded Customization - This course explores the customization tools embedded within the Epicorapplication. Unlike personalization, users can customize a form and then make it available to multiple usersin a company.

Environment Setup

The environment setup steps and potential workshop constraints must be reviewed in order to successfullycomplete the workshops in this course.

Your Epicor training environment, in which the Epicor demonstration database is found, enables you to experienceEpicor functionality in action but does not affect data in your live, production environment.

The following steps must be taken to successfully complete the workshops in this course.

1. Verify the following or ask your system administrator to verify for you:

• Your Epicor training icon (or web address if you are using Epicor Web Access) points to yourEpicor training environment with the Epicor demonstration database installed. Do not completethe course workshops in your live, production environment.

Epicor ERP | 10.0.7006

Business Process Management CourseBefore You Begin

Page 7: Business Process Management Course 10.0.700

Note It is recommended that multiple Epicor demonstration databases are installed. ContactSupport or Systems Consulting for billable assistance.

• The Epicor demonstration database is at the same service pack and patch as the Epicorapplication. Epicor's education team updates the Epicor demonstration database for each service packand patch. If your system administrator upgrades your Epicor application to a new service pack or patch,he or she must also download the corresponding Epicor demonstration database from EPICweb > Support> Epicor > Downloads and install it. If this is not performed, unexpected results can occur when completingthe course workshops.

• Your system administrator restored (refreshed) the Epicor demonstration database prior tostarting this course. The Epicor demonstration database comes standard with parts, customers, salesorders, and so on, already defined. If the Epicor demonstration database is shared with multiple users(that is, the database is located on a server and users access the same data, much like your live, productionenvironment) and is not periodically refreshed, unexpected results can occur. For example, if a courseworkshop requires you to ship a sales order that came standard in the Epicor demonstration database,but a different user already completed this workshop and the Epicor demonstration database was notrestored (refreshed), then you will not be able to ship the sales order. Epicor's education team has writtenthe course workshops to minimize situations like this from occurring, but Epicor cannot prevent usersfrom manipulating the data in your installation of the Epicor demonstration database.

2. Log in to the training environment using the credentials manager/manager. If you are logged into yourtraining environment as a different user, from the Options menu, select Change User.

3. From the Main menu, select the company Epicor Education (EPIC06).

4. From the Main menu, select the Main site.

5. To complete the Workshop - Use Auto Print Action, SQL Server Reporting Service (SSRS) must beinstalled and operational in your environment in order to run SSRS reports.

If necessary, work with your system administrator and see Install Epicor SQL Server Reporting Service(SSRS) topics found within the Epicor 10 Installation Guide.

Workshop Constraints

For the purpose of this course and the training environment, it is important to follow all of the steps provided ineach workshop. While this course provides education on creating and using various BPMs, it is essential that allcreated BPMs are disabled or deleted. Disabling or removing the BPMs ensure the appropriate default trainingenvironment is available.

Important Note that restoring (refreshing) the demonstration database does not automatically removeexisting BPM directives. All BPM directives must be manually removed or disabled.

7Epicor ERP | 10.0.700

Before You BeginBusiness Process Management Course

Page 8: Business Process Management Course 10.0.700

Business Process Management Overview

Use Business Process Management (BPM) to modify the flow of business processes through the application. Thisincludes modifying the behavior of individual business objects and adding human workflow elements such asemail, tasks, and so on.

The key characteristics of BPM is its availability on every business process throughout the application and it isentirely activated on the Epicor ERP Server. This means the behavior is adopted whether the transaction originatedfrom the Epicor ERP Client or from web services. For this reason, BPM is the best place to make systemmodifications, rather than adding functionality into the Client customization.

Basic Use Cases for BPM:

• Validate data (includes making mandatory)

• Raise exceptions (conditional)

• Modify data (GetNew or Update)

• Send email, preview or print a report

• Display an informational message when a BPM condition is met

• Write table changes to the applicable program change log

• Post a data notification message to the Epicor Social Enterprise message stream

• Create tasks (from Template)

• Attach and Remove BPM Holds

• Create Data Forms (to control BPM processing flow)

• Create Updatable BAQ directives

Advanced Use Cases for BPM:

• Call Service Connect (to extend business flows)

• Call .Net Assemblies (C# or VB .Net)

BPM directives work by intercepting calls to the application server logic. They are embedded into server logic andget invoked by method calls. You can validate, manipulate, or create workflows based on the data passed throughthe application. Because BPM methods are server side customizations, you can change business logic withoutmodifying the source code.

Epicor ERP | 10.0.7008

Business Process Management CourseBusiness Process Management Overview

Page 9: Business Process Management Course 10.0.700

The key elements of using BPM directives within the application include the following:

• A user performs an action in a program.

• The program calls a business object method to carry out the action.

• Before the business object executes its program code, Pre-Processing directives are executed.

Note If at least one non-empty Base Processing directive is in effect, the Base Processing directive willrun instead of the Epicor program code.

Important Epicor strongly recommends you do not create Base Processing directives. If you change abase method incorrectly, you can harm the normal function of the application. This option is mainlyincluded for partners, consultants, and power users who need to directly modify the method for majorbusiness modifications. Work with an Epicor consultant before you create a base processing methoddirective.

• After the Pre-Processing directive, the Epicor program code performs its function, or Base directives areexecuted.

• When data transaction is about to be applied to the database, In-Transaction directives are executed.

• After the Epicor program code or Base directive is run, Post-Processing directives are executed.

• Standard data directives are executed with accumulated transaction database changes passed to them.

• Data is returned to the program according to the actions run by the directives and Epicor program.

9Epicor ERP | 10.0.700

Business Process Management OverviewBusiness Process Management Course

Page 10: Business Process Management Course 10.0.700

Business Object Basics

• Business objects control all input and output from the database

• Can be called by web services, smart client, web client, or other programs

• Contain all rules for processing records

• Contain a normalized relationship between tables and fields in the actual database

• Contain methods for interfacing with data

Business Object Methods

The following is a list of commonly used BO methods:

DescriptionMethod

Use to delete records (sometimes), Group delete (for example, order + lines+ rel)

Delete by ID

Use to retrieve records for specific ID, returns all dataGet by ID

Use in searches, returns key dataGet List

Use to create a new recordGet New

Use to retrieve specific data for a group of recordsGet Rows

Use to add, update, and delete records, most common method to use in BPMUpdate

Use to add, update, and delete records for use with updatable BAQsUpdate Ext

Use to add, update, and delete master records of specific business objectsMaster Update

Epicor ERP | 10.0.70010

Business Process Management CourseBusiness Process Management Overview

Page 11: Business Process Management Course 10.0.700

The Trace Log

Use the Trace Log to view datasets sent to and returned from the application database. The Trace Log is enabledfrom the Main Menu (Classic Style) or from the Home Page (Modern Shell Menu) and writes information to afile you can review.

Workshop - Use the Trace Log

In this workshop, use a trace to learn which values are in the part dataset during a part update.

Key concepts are:

• Use the interface to simulate actions used in a method directive.

• Read the values used in an update transaction.

Verify you are logged into Epicor ERP using the following credentials:

DataField

managerUser Name

managerPassword

Set Up the Trace

Navigate to Part Maintenance.

Menu Path: Material Management > Inventory Management > Setup > Part

1. Minimize Part Maintenance.

2. To create a cleaner log that doesn’t contain idle times from the System Monitor, locate the Epicor's SystemMonitor icon on the desktop task bar. Right-click this icon and select Exit.

3. Launch Tracing Options.

• When you run the application using the Classic Style, on the Main menu, from the Options menu,select Tracing Options.

• When you run the application using the Modern Shell, on the Home Page, click Settings and withinthe General Operations category, click Tracing Options.

4. Select the Enable Trace Logging check box.

5. Review the available options:

DescriptionTracing Option

Records all call data in the tracing log. If this option is not selected, onlythe header information is stored in the log.

Write Full DataSet

Only changes to the dataset are recorded in the tracing log.Track Changes Only

11Epicor ERP | 10.0.700

The Trace LogBusiness Process Management Course

Page 12: Business Process Management Course 10.0.700

DescriptionTracing Option

Used to review the performance of BPM methods and customizations. TheCall Context Dataset initializes when a user activates a program (UIApp)

Write Call Context Dataset

that either launches a customized form or a BPM directive. As long as theprogram is active, method calls are sent to the Call Context Dataset.

When a method call has a <returnType> other than void, selecting thischeck box causes the dataset returned from the server to display on thetracing log.

Write Response Data

Includes the information from the server processing in the client trace log.Include Server Trace

6. For this workshop, select the Write Full Dataset check box.

7. Click Apply.

8. Leave the Tracing Options Form open.

Add a Part

1. Maximize Part Maintenance.

2. In the Part field, enter XXX-TestPart1 (where XXX are your initials) and press Tab.

3. In the Add New Confirmation window, click Yes.

4. In the Description field, enter XXX Test Part 1 (where XXX are your initials).

5. Click Save.

6. Exit Part Maintenance.

View the Trace

1. In the Tracing Options Form, click the View button.

2. View the method calls and dataset information.

This file indicates a change was made to the Part field. Notice the various methods that run when you adda new part record to the database. You can create BPM directives that monitor the data entered or changedthrough each directive. The Trace Log helps you identify which method you need to monitor.

Example

The following trace log snippet displays the Update method called on new record creation.

<tracePacket> <businessObject>Erp.Proxy.BO.PartImpl</businessObject> <methodName>Update</methodName> <returnType>System.Void</returnType> <localTime>29/11/2013 13:30:29:1069295 PM</localTime> <executionTime>481</executionTime> <parameters> <parameter name="ds" type="PartDataSet"> <PartDataSet xmlns="http://www.epicor.com/Ice/300/BO/Part/Part"> <Part>

Epicor ERP | 10.0.70012

Business Process Management CourseThe Trace Log

Page 13: Business Process Management Course 10.0.700

<Company>EPIC06</Company> <PartNum>XXX-TestPart1</PartNum> <SearchWord>XXX Test</SearchWord> <PartDescription>XXX Test Part 1</PartDescription> <ClassID></ClassID> <IUM>EA</IUM> <PUM>EA</PUM> <TypeCode>P</TypeCode>

3. Close the TraceData file.

Create an XML File

1. In the Tracing Options Form, next to the XML File field, click Browse.

2. In the Save As window, select your Desktop.

3. In the File Name field, enter XXX.PartTrace.xml (where XXX are your initials).

4. Click Save.

5. Click the Create XML button.

6. Minimize all programs so the desktop is visible.

7. Double-click XXX.PartTrace.xml.

8. Review the method calls and dataset information.

9. Close the .xml file.

Disable Tracing Log

1. Maximize the Tracing Options Form.

2. Clear the Enable Trace Logging check box.

The Write Full DataSet check box automatically is disabled.

3. Click the Apply button.

4. Click OK.

The Tracing Options Form window closes.

Restart System Monitor

Navigate to System Monitor.

Menu Path: System Setup > System Maintenance > System Monitor

Important This program is not available in the Epicor Web Access.

13Epicor ERP | 10.0.700

The Trace LogBusiness Process Management Course

Page 14: Business Process Management Course 10.0.700

1. In the desktop task bar (in the lower right corner of the screen), verify the System Monitor icon displays.

2. Minimize the System Monitor window.

Epicor ERP | 10.0.70014

Business Process Management CourseThe Trace Log

Page 15: Business Process Management Course 10.0.700

Method Directives

Use the Method Directives program to create and update BPM method directives.

Menu Path: System Management > Business Process Management > Method Directives Maintenance

Important This program is not available in the Epicor Web Access.

A method directive defines a workflow, composed of conditions and actions associated with a business objectmethod. All data transactions in the application are controlled by business objects such as Update, GetList orGetNew. A business object represents some type of data managed by the application, such as a customer, part,or sales order. Objects contain methods that perform a specific task. For example, the Customer.Update methodvalidates and posts edited customer records to the database.

Tip Two other directive types are available:

• Data Directives - applied to database table transactions.

• Updatable BAQ Directives - applied to business activity query methods that can update the database.

Business Process Management (BPM) tools can manipulate how these methods perform before, during, or afterdatabase transactions. Create method directives that first evaluate the data being processed and then, if thedirectives' conditions are met, perform one or more actions based on this data (for example, prevent data entry,launch other business processes, and so on). Method directives are invoked entirely on the Epicor ERP Server andnot on the client.

Example You can create a method directive for the Customer.Update method to send an email to a SalesManager when a customer's credit limit changes. The same directive can also attach a hold to the customerrecord and display a message that indicates the customer record has been placed on hold. Additionalmethod directives can check for the hold on the customer record and prevent it from being modified untilthe Sales Manager releases the hold.

When a business object method is called, all enabled directives associated with the method activate. The BPMworkflow you create for the directive does it's job by executing workflow items in the order you specify.

While the method is active, these directives run at three different processing points:

• Pre-Processing – These directives execute before the base method runs. After these actions finish, the businessobject then runs the base method.

• Base Processing – These directives run in place of the base method. The base method does not execute.

• Post-Processing – These directives run after the base method finishes its process.

Workshop - Make a Field Mandatory

Many customers want to ensure when they create new parts, they have a part class or product group named. Inthis example, the naming depends on whether the part type is purchased or manufactured. This exampledemonstrates the Business Process Management (BPM) features to make a field mandatory based on a condition.

Key concepts are:

• Use built-in BPM functionality.

• Use conditional actions.

15Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 16: Business Process Management Course 10.0.700

Create a new method directive based on the Part Business Object Update method.

Navigate to Method Directives.

Menu Path: System Management > Business Process Management > Method Directives Maintenance

Important This program is not available in the Epicor Web Access.

Add a Method Code

1. On the Detail sheet, click the Method Code button.

The Method Search window displays.

2. In the Search by Business Object section, verify Product is selected.

By selecting this option, the Business Objects belonging to the application part of the system becomeavailable for selection.

3. In the Business Object field, select Part.

4. In the Where Method Name Starts At field, enter U.

5. Click Search.

6. In the Search Results grid, select the Update method.

7. Click OK.

The Business Object returns on the form.

8. In the Method Description field, enter XXX Set Part Class or Product Group Mandatory (where XXXare your initials).

9. Click Save.

Add a Pre-Processing Directive

1. From the New menu, select New Pre-Processing.

2. In the Directive Name field, enter XXX Mandatory Part Class and Group (where XXX are your initials).

3. In the Group field, enter XXX (where XXX are your initials).

This field signifies the group to which the current directive belongs. You can select an existing value or entera value to create a new group. This field is optional but can help organize directives for searches and is usedwhen exporting directives.

4. Click Save.

5. Click Design to launch the BPM Workflow Designer.

The available workflow items display on the left portion of the screen. In the following tasks, you will usethe items to build a BPM workflow.

Example The following image displays the BPM workflow you will build throughout this workshop.You may use it for a reference as you proceed with tasks that follow.

Epicor ERP | 10.0.70016

Business Process Management CourseMethod Directives

Page 17: Business Process Management Course 10.0.700

Add First Condition

1. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,below the Start item.

2. Hover your mouse over the Start item.

The small black triangles surrounding the item represent the available connectors.

3. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of the Conditionelement entry points.

The connection between the two elements is now established.

You will now build the first condition that checks if the Part Type is set to Purchased and Part Class is empty.

4. In the workflow, click the Condition item.

5. In the Condition pane at the bottom, click the Add Line icon.

6. In the Condition field, invoke the list and select The specified field of the changed row is equal to thespecified expression.

7. Click the first specified.

8. In the Table field, verify ttPart displays.

17Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 18: Business Process Management Course 10.0.700

Note

The “tt” prefix indicates this table is a temporary table - an intermediate table used to validate databefore it is saved to your physical database.

9. In the Fields search box, enter type.

10. From the list of available fields, select the TypeCode check box.

11. Click OK.

12. At the end of the Condition field, click specified.

13. In the Editor text box, enter "P" (this expression stands for Purchased parts, remember to include thequotation marks).

14. In the Specify an expression window, click OK.

Extend First Condition

1. In the Condition pane, click the Add Line icon.

2. In the second line, in the Operator field, verify And displays.

3. In the Condition field, from the list, select the specified field of the changed row is equal to thespecified expression.

4. Click the first specified.

5. In the Table field, verify ttPart displays.

6. Select the ClassID field name check box and click OK.

7. At the end of the Condition field, click specified.

8. In the Editor text box, enter "" (quotation marks represent a blank).

9. In the Specify an Expression window, click OK.

10. The Condition pane should now read:

PostfixConditionPrefixOperator

The ttPart.TypeCode field of the changed row is equal tothe "P" expression

None

The ttPart.ClassID field of the changed row is equal to the"" expression

And

This states that when the Type field in Part Maintenance of the changed row is P (for Purchased) and theClass field of the changed row is blank, execute the following action(s). You will define these actions in thefollowing workshops.

11. Click Validate and verify BPM reports no errors.

Epicor ERP | 10.0.70018

Business Process Management CourseMethod Directives

Page 19: Business Process Management Course 10.0.700

Add First Action

Complete this step to display an error message which halts user actions. This action will display when the conditionevaluates to True, which means, when in a purchased part, the Part Class field is left blank.

1. In the workflow items tollbar, click the Raise Exception icon and drag it to the workflow pane of theDesigner, below the Condition item.

2. Click the Condition element.

3. On the left side of the Condition element, verify True displays.

4. Select the True exit point, drag the line and point it to any of the Raise Exception element entry points.

5. Click the Raise Exception element.

6. In the Actions pane, verify raise exception based on the designed template displays.

7. Select designed to launch the Design Exception Template window.

8. In the Name field, enter Mandatory Part Class.

9. In the text box, enter Purchased parts must have a Part Class - BPM.

10. In the Design Exception Template window, click OK.

11. The Actions pane should now read:

Terminate on errorActionAction Name

selectedRaise exception based on the Mandatory PartClass template

Raise Exception 0

You are now ready to extend the workflow by adding a second condition to make the Group field mandatoryfor manufactured or kit parts.

Add Another Condition

Recall the first Condition evaluates to True when purchased part has no part class selected. When this conditionis not met, for example, when the Update Method is triggered with manufacturing or sales kit part in focus, theBPM Condition sends the information to the False exit point and routes the BPM using another workflow branch.

You will now add another Condition that will be called when first condition evaluates to False. The secondcondition will check if manufacturing or kit parts have the part group selected. If not, the BPM will raise anotherexception.

1. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,to the right of the first Condition.

2. Create a connection between the False exit point of the first Condition and any entry point of the secondCondition.

3. In the workflow, click the newly added Condition item.

4. In the Condition pane at the bottom, click the Add Line icon.

19Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 20: Business Process Management Course 10.0.700

5. In the Condition field, invoke the list and select The specified field of the changed row is equal to thespecified expression.

6. Click the first specified.

7. In the Table field, verify ttPart displays.

8. In the Fields search box, enter type.

9. From the list of available fields, select the TypeCode check box.

10. Click OK.

11. At the end of the Condition field, click specified.

12. In the Editor text box, enter "M" for (Manufactured, including the quotations).

13. In the Specify an expression window, click OK.

14. In the Conditions window, click the Add Line icon.

15. In the Operator field, select Or.

16. In the Condition field, invoke the list and select The specified field of the changed row is equal to thespecified expression.

17. Click the first specified.

18. In the Table field, verify ttPart displays.

19. In the Fields search box, enter type.

20. From the list of available fields, select the TypeCode check box.

21. Click OK.

22. At the end of the Condition field, click specified.

23. In the Editor text box, enter "K" for (Sales Kit, including the quotations).

24. In the Specify an expression window, click OK.

You now extend the condition by adding another line.

Extend Second Condition

1. In the Condition pane, click the Add Line icon.

2. In the third condition line, in the Operator field, verify And displays.

3. In the Condition field, from the list, select the specified field of the changed row is equal to thespecified expression.

4. Click the first specified.

Epicor ERP | 10.0.70020

Business Process Management CourseMethod Directives

Page 21: Business Process Management Course 10.0.700

5. In the Table field, verify ttPart displays.

6. In the Fields search box, enter prod.

7. Select the ProdCode field name check box and click OK.

8. At the end of the Condition field, click specified.

9. In the Editor text box, enter "" (recall quotation marks represent a blank).

10. In the Specify an Expression window, click OK.

11. The Condition pane should now read:

The Condition pane should now read:

PostfixConditionPrefixOperator

The ttPart.TypeCode field of the changed row is equal to the"M" expression

None

The ttPart.TypeCode field of the changed row is equal to the"K" expression

Or

The ttPart.ProdCode field of the changed row is equal to the ""expression

And

This states when the Type field in Part Maintenance is M (for manufactured) or K (for sales kit) and theGroup field blank, then execute the action.

12. Click Validate and verify BPM reports no errors.

Add Second Action

This action will display when the second condition evaluates to True, which means, when in a manufactured orkit part, the Part Group field is left blank.

1. In the workflow items tollbar, click the Raise Exception icon and drag it to the workflow pane of theDesigner, below the second Condition item.

2. Click the Condition 1 element.

3. Select the True exit point, drag the line and point it to any of the Raise Exception 1 element entry points.

4. Click the Raise Exception 1 element.

5. In the Actions pane, verify raise exception based on the designed template displays.

6. Select designed to launch the Design Exception Template window.

7. In the Name field, enter Mandatory Group.

8. In the text box, enter Group is mandatory for manufactured or kit parts - BPM.

9. In the Design Exception Template window, click OK.

10. The Actions pane should now read:

21Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 22: Business Process Management Course 10.0.700

Terminate on errorActionAction Name

selectedRaise exception based on the MandatoryGroup template

Raise Exception 0

11. Click Validate and verify the BPM reports no errors.

12. Click Save and Exit.

13. On the Pre-Processing > Detail sheet, select the Enabled check box.

14. Click Save.

15. Minimize Method Directives.

Test the BPM for the Part Class

Navigate to Part Maintenance.

Menu Path: Material Management > Inventory Management > Setup > Part

1. In the Part field, enter XXX-4334 (where XXX are your initials) and press Tab.

2. In the Add New Confirmation dialog box, click Yes.

3. In the Description field, enter XXX Purchase Test (where XXX are your initials).

4. Leave the Type field as Purchased.

5. Click Save.

The first BPM condition is met and the exception message is fired.

6. To the error message from the BPM that says you must specify a Part Class, click OK.

7. In the Class field, select Hardware.

8. Click Save.

The part saves with no errors.

9. Remain in Part Maintenance.

Test the BPM for the Part Group

1. On the Standard toolbar, click Clear.

2. In the Clear Confirmation window, click Yes.

3. In the Part field, enter XXX-3443 (where XXX are your initials) and press Tab.

4. In the Add New Confirmation window, click Yes.

5. In the Description field, enter XXX Mfg Test (where XXX are your initials)

Epicor ERP | 10.0.70022

Business Process Management CourseMethod Directives

Page 23: Business Process Management Course 10.0.700

6. In the Type field, select Manufactured and click Save.

The second BPM condition is now met.

7. To the error message from the BPM that says you must specify a Group field, click OK.

8. In the Type field, select Sales Kit and click Save.

Note the same error message from the BPM.

9. To the error message, click OK.

10. In the Group field, select Configured Parts.

11. Click Save.

The part saves with no errors.

12. Exit Part Maintenance.

Disable Directives

1. Maximize the Method Directives window.

2. In the tree view, select the verify the Pre-Processing XXX Mandatory part and group directive displays.

3. Clear the Enabled check box.

The method directive is now disabled.

4. Click Save.

5. Exit Method Directives.

Workshop - Set Log Created By and Date

In this workshop, enable an audit trail of who created a new record for a master table. In this example, use ABCCode Maintenance but keep in mind you can apply the concepts to any master table.

Key concepts are:

• Free form functionality of Business Process Management

• BPM C# syntax to write to a field in the dataset

• Global variables

Add User Defined Columns

In this task, create two user-defined fields available for use on the ABCCode table. In the following tasks, youwill customize the ABCCode form by placing these fields on the form and have BPM write data in them.

Navigate to Extended User Defined Table Maintenance.

Menu Path: System Setup > System Maintenance > Extended UD Table Maintenance

23Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 24: Business Process Management Course 10.0.700

Important This program is not available in the Epicor Web Access.

1. Click New.

The Table Search window displays.

2. Search for and select ABCCode.

3. Verify the Table Name field displays ABCCode_UD.

4. In the Description field, enter Added User and Date fields - BPM.

5. Click New > New Column.

The Column > Detail sheet displays.

6. In the Column Name field, enter XXXUser (where XXX are your initials).

Notice the _c suffix is automatically added to the column name.

7. In the Description, enter Current User ID.

8. In the Data type field, verify String displays.

9. In the Format field, enter x(20).

10. In the Label field, enter User.

11. Click Save.

12. Repeat steps 5 - 11 to add another field. Use the parameters from the below table.

LabelFormatData typeDescriptionColumn Name

Date{datetime}DateTimeCurrent DateXXXDate (where XXX are yourinitials)

Synchronize Table

To complete this user-defined table, you synchronize it. This formats the table so it can be linked to the database.Note this process does not make the table available for display; you need to update the data model to finishincorporating this user-defined table in your database.

1. Click on the Actions menu.

2. To synchronize the active table, select the Sync Current Table to DB option.

3. To the confirmation message, click OK.

4. Exit User-Defined Table Maintenance.

You are now ready to update the database to include this new table.

Epicor ERP | 10.0.70024

Business Process Management CourseMethod Directives

Page 25: Business Process Management Course 10.0.700

Regenerate Data Model

To finish adding the user-defined table, the data model for the Epicor database needs to be regenerated. Youor your system administrator runs this task on the server that contains your database. You regenerate the datamodel through the Epicor Administration Console.

1. On your server, press <Windows> + F to display the Search bar.

2. Click on the Apps button.The Apps screen displays.

3. Locate the Epicor Software section on this screen and click the Epicor Administration Console icon.

4. Expand the Database Server Management node and the XXX database server node (where XXX is thename of your database server) that contains the database you need to update.

5. Select the database icon.The properties for the database displays in the center pane.

6. From the Actions pane, click the Regenerate Data Model button.The Generate Data Model window displays.

7. Verify the Deployment folder field displays the root path location for the server. For example:C:\inetpub\wwwroot\EpicorERP10

8. Click Generate.

Important If you receive an error that the .dll file for the data model generation is in use by anotherprocess, end the task and close the Epicor Administration Console. Return to the Apps screen andlaunch the Command Prompt (under the Windows System section). In the Command Prompt window,enter IISRESET and press <Enter>. After IIS stops and restarts, close the Command Prompt windowand return to the Epicor Administration Console. You should be able to regenerate the data model.

9. To complete functionality, the latest data model must be pulled from the DB and copied to the local appserver by restarting IIS. To do so, launch the Command Prompt window and enter IISRESET and press <Enter>.

Note Restarting IIS is a mandatory task after the successful data model regeneration.

10. After IIS stops and restarts, close the Command Prompt window.

The data model generates, adding the extended user-defined table to the database. Now that the data modelis regenerated, Epicor users can view and enter data in the extended user-defined table.

Important User Defined columns appear to be part of the base table from the programming/customizationpoint of view, as the data model merges the two tables into one logical entity.

Add a Method Directive

Navigate to Method Directives.

Menu Path: System Management > Business Process Management > Method Directives Maintenance

Important This program is not available in the Epicor Web Access.

25Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 26: Business Process Management Course 10.0.700

1. Click the Method Code button.

2. In the Search by Business Object section, verify Product is selected.

3. In the Business Object field, verify ABCCode displays.

4. In the Where Method Name Starts At field, enter U.

5. Click Search.

6. Select Update and click OK.

The Method Code displays Erp.ABCCode.Update.

7. In the Method Description field, enter XXX Log Created By and Date (where XXX are your initials).

8. Click Save.

Add a Pre-Processing Directive

1. Navigate to the Pre-Processing sheet.

2. From the New menu, select New Pre-Processing.

3. In the Directive Name field, enter XXX Log Created By and Date (where XXX are your initials).

4. In the Group field, enter XXX (where XXX are your initials).

There will not be any conditions for this method directive. Run this directive whenever the method is called.

5. Click Save.

Add an Action

Note You do not need to create a condition statement for this directive. When you do not define acondition, the directive just executes each time its method is called – in this case, the ABCCode.Updatemethod. This causes the custom C# code to run automatically with the method.

1. Click Design to launch the BPM Workflow Designer.

2. In the workflow items tollbar, click the Execute Custom Code icon and drag it to the workflow pane ofthe Designer, below the Start item.

3. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of the ExecuteCustom Code element entry points.

The connection between the two elements is now established.

4. Click the Execute Custom Code workflow item.

5. In the Actions pane found at the lower portion of the screen, view the Action statement:

Synchronously execute custom code ... record nothing

Epicor ERP | 10.0.70026

Business Process Management CourseMethod Directives

Page 27: Business Process Management Course 10.0.700

Note Synchronously means the call is made immediately when the action executes. WhenAsynchronous execution is selected, the call is queued and executed according to the schedule definedin the BPM Async Process program. In this example, accept the Synchronous execution.

6. Click the code link.

The Custom Code Action window displays.

7. Verify the Code sheet is selected.

8. Enter the code below:

//* Set User and Date *//foreach (var ttAbcCode_iterator in (from ttABCCode_Row in ttABCCode where string.Compare(ttABCCode_Row.RowMod, "A", true) == 0 select ttABCCode_Row)){ var ttABCCode_xRow = ttAbcCode_iterator; ttABCCode_xRow.XXXUser_c = Session.UserID; ttABCCode_xRow.XXXDate_c = DateTime.Now;}

Important

Within the code replace XXX with your initials to create correct references of your newly createduser-defined columns.

Tip

When you copy and paste the above code, you may need to adjust it to make sure logical statementsare kept together on their respective line.

When you refer to a user-defined column through the c# code, you can either:

• refer to it as row.column_c - for example, ttABCCode_xRow.ABUser_c = Session.UserID. (preferredway)

• refer to it as row.["column_c"] - for example, ttABCCode_xRow["ABUser_c"] = Session.UserID.

9. In the Custom Code Action window, click OK.

10. In the Actions pane, verify the Action field displays the following:

synchronously execute custom /* Set User and Date */... record nothing

11. Click the Validate button and verify BPM reports no errors.

12. Click Save and Exit to return to the Method Directives window.

13. Select the Enabled check box to activate the directive.

14. Click Save.

15. Minimize Method Directives.

27Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 28: Business Process Management Course 10.0.700

Create a Customized Text Field

Launch the Developer Mode.

• When you run the application using the Classic Style, on the Main menu, from the Options menu, selectDeveloper Mode.

• When you run the application using the Modern Shell, on the Home Page, click Settings and within theGeneral Operations category, click Developer Mode.

Navigate to ABC Code Maintenance.

Menu Path: Material Management > Inventory Management > Setup > ABC Code

1. In the Select Customization window, select the Base Only check box.

2. Click OK.

3. Maximize the ABC Code Maintenance window.

4. From the Tools menu, select Customization.

5. In the ABC Code Maintenance window, select the Variance Tolerances group box and move it down.

6. Click the Cycle Count group box and make it larger so you can place two extra fields under the CountFrequency field.

7. In the Customization Tools Dialog window, from the Tools menu, select ToolBox.

8. From the Toolbox, select EpiTextBox.

9. Click inside the Cycle Count group box.

10. In the Select Layer Type window, select Customization and click OK.

11. Place the new text box directly below the Count Frequency text box.

12. Click the new text box.

13. Navigate to the Customization Tools Dialog > Properties sheet.

14. In the Epibinding field, select AbcCode.XXXUser (where XXX are your initials).

15. In the Enabled field, select False.

Create Another Customized Text Field

1. In the Toolbox, click EpiDateTimeEditor.

2. Add a second text box inside the Groupbox under the field you just created.

3. Navigate to the Customization Tools Dialog > Properties sheet.

4. In the Epibinding field, select AbcCode.XXXDate (where XXX are your initials).

5. In the Enabled field, select False.

Epicor ERP | 10.0.70028

Business Process Management CourseMethod Directives

Page 29: Business Process Management Course 10.0.700

Add Labels to Text Fields

1. In the Toolbox, click the EpiLabel button.

2. Draw a label next to the first text box you created.

3. Navigate to the Customization Tools Dialog > Properties sheet.

4. In the Text field, enter Created By.

5. In the Toolbox, click the EpiLabel button again.

6. Draw a label next to the second text box created.

7. Navigate to the Customization Tools Dialog > Properties sheet.

8. In the Text field, enter Date.

9. Close the Toolbox.

Save and Test Customizations

1. In the Customization Tools Dialog window, click Save.

The Customization Save Dialog window displays.

2. In the Name and Description fields, enter XXXabc (where XXX are your initials).

3. Click Save.

4. In the Customization Comment text box, enter Added two text box fields and click OK.

5. Close the Customization Tools Dialog window.

6. Exit ABC Code Maintenance.

7. Re-open ABC Code Maintenance.

8. In the Select Customization window, select the XXXabc customization and click OK.

9. Click New.

10. In the ABC Code field, enter a letter of your choice to create a new record.

If the record is already present, try another one.

11. In the Count Frequency field, enter 60 and

12. Click Save.

Verify the BPM populates the information in the Created By and Date fields.

Example Your results should look similar to the following.

29Epicor ERP | 10.0.700

Method DirectivesBusiness Process Management Course

Page 30: Business Process Management Course 10.0.700

13. Exit ABC Code Maintenance.

14. Disable the Developer Mode.

Disable Directive

1. Maximize the Method Directives window.

2. In the tree view, select the Pre-Processing directive XXX Log Created by and Date.

3. In the Pre-Processing > Detail sheet, clear the Enabled check box.

The method directive is now disabled.

4. Click Save.

5. Exit Method Directives.

Epicor ERP | 10.0.70030

Business Process Management CourseMethod Directives

Page 31: Business Process Management Course 10.0.700

BPM Workflow Designer

Use the BPM Workflow Designer to construct your BPM workflow using a graphical design surface.

To access the BPM Workflow Designer, click the Design button when you build a directive through followingprograms:

• Method Directives

• Data Directives

• Updatable BAQ Method Directives

Example

General Principles

This topic discusses general principles of creating a BPM workflow by using the workflow elements.

Example

31Epicor ERP | 10.0.700

BPM Workflow DesignerBusiness Process Management Course

Page 32: Business Process Management Course 10.0.700

Follow these rules to construct a BPM Workflow:

• The available items display in the left pane of the Designer. Workflow elements are grouped by categoriesand except the Flow Chart category, they all represent Actions the workflow will take.

• For each workflow item representing Actions, you can select the Terminate on Error option to halt theworkflow execution when it encounters an error. The Raise Exception action has this option selected by default.

• The Condition block found in the Flow Chart category represents a set of conditions the BPM workflowmay evaluate prior to executing the following workflow item.

• To use a BPM item in the workflow, drag it and drop it in the BPM Designer surface.

• Connect the workflow elements in the logical order they should be executed. When you hover your cursorover each element, the small black triangles surrounding the item represent the available connectors. Toconnect elements, click your mouse, select any of the connector symbols, drag the line and point it to anotheritem's connector.

• The initial point of the BPM workflow is the Start element.

• The following workflow elements may utilize multiple inbound connectors but only one outbound connector.The exception is the Condition block that allows usage of two outbound connectors True & False.

• When you delete any workflow item (block), its links will be automatically deleted with it.

• To set up the behaviour of a workflow item representing Action, click on it and supply required parametersin the pane below the designer surface.

• For the Condition block, build criteria using pre-built condition statements. You can enter more than onecondition statement within a single block and use the And/Or logical Operators to define the relationshipbetween the current statement and the preceding statement.

• Once you build your BPM workflow, use the Validate function to control if all element parameters are setup in the way BPM expects. This function also checks that the directive references existing objects (assemblies,users, BAQ constants, DB tables and fields, etc) correspond to selected BO method signature. This control isparticularly useful for directives imported from previous Epicor ERP releases.

Epicor ERP | 10.0.70032

Business Process Management CourseBPM Workflow Designer

Page 33: Business Process Management Course 10.0.700

Note The Validate function does not check syntax in expressions or custom code.

• Once you finish, click Save and Exit to return to the respective Directive Maintenance program from whichyou called the Designer.

Availability of Workflow Elements

The list of available workflow elements you can use to build the BPM workflow is influenced by the followingfactors:

• Directive Type used to invoke BPM Workflow Designer - Method Directives, Data Directives and UpdatableBAQ method Directives.

• BPM Advanced User rights - enables Auto Print, Change Log, Call Service Connect Workflow, Execute CustomCode, Invoke External Method, Notify Me, Set By Query and Custom Code Condition.

• Presence of Table parameters within the selected method - Field Changed Condition, Field Condition, RowWith Status Condition, Notify Me, Data Tag Condition, Attach/Remove Data Tag Actions, Set By Query Actionand Set Field Action.

• Presence of Simple parameters within the selected method - Argument Condition, Word In Argument Conditionand Set Argument Action.

• Workflow items not available in uBAQ Method Directives - Holds and Tags and Method Query Field ChangedCondition.

• Valid Business Object Instance - cases when Business Object's primary key cannot be obtained from parameters- Attach and Remove Hold Actions and Hold Condition.

• Presence of the Change Log table - Change Log Action.

33Epicor ERP | 10.0.700

BPM Workflow DesignerBusiness Process Management Course

Page 34: Business Process Management Course 10.0.700

Hold Type

Use Hold Type Maintenance to create, maintain, and delete hold types - flags you can place on records.

Menu Path: System Management > Business Process Management > Hold Type Maintenance

Important This program is not available in the Epicor Web Access.

A Hold is a flag you place on a record; it indicates the record should not be processed until it is reviewed andapproved. A hold by itself does not perform any actions. You define the actions by creating directives whichdefine how the application handles a record that has a hold placed on it. You can attach a BPM hold to a recordin two ways:

• Manually – You can manually attach a hold onto a field by using the BPM Holds program. You do this bylaunching the BPM Holds program from the field’s context menu. This adds the hold to the record.

• Programmatically – A hold can also be attached to a record using a directive action. It can be attachedbefore, during, or after the business process is run. Typically you use holds to interrupt the processing of thebusiness object. This hold can then cause custom actions you define for the directive to run. You use MethodDirective Maintenance or Data Directive Maintenance to create these directives.

If the hold is present, the method directive can perform several actions, but a common use is to intercept themethod before processing occurs (pre-processing) to prevent the method from performing its normal routine(for example, by raising an exception). This type of method directive is known as an inhibitor.

Workshop - Create and Use a Hold Type

BPM Holds can prohibit data transaction processing for specified reasons. In this example, a simple conditionchecks if the State field has been entered for a Customer record. If not, a Customer Review BPM hold is attachedto the record. You then prevent creation or update of sales orders for customers on a Customer Review hold.

In this example, place or remove the hold during the Post Update process for a customer. You do not want toaccidentally place a record on hold before it passes through validation and update. It is not possible to usecondition tests that rely on the RowMod identifier (Add, Update, or Delete) during the Post Update Process. Usea Pre-Processing directive to test for conditions to place or remove holds, but use a Post-Processing directive toperform the actions.

Create the Hold Type

Navigate to Hold Type Maintenance.

Menu Path: System Management > Business Process Management > Hold Type Maintenance

Important This program is not available in the Epicor Web Access.

1. In the Hold Type field, enter XXX Customer Review (where XXX are your initials) and press Tab.

2. In the Add New Confirmation, click Yes.

3. Click the Business object button.

4. In the Starting At field, enter Cus and click Search.

Epicor ERP | 10.0.70034

Business Process Management CourseHold Type

Page 35: Business Process Management Course 10.0.700

5. Select Customer and click OK.

6. In the Description field, enter XXX Customer Review (where XXX are your initials).

7. Click Save.

8. Exit Hold Type Maintenance.

Add a Method Code

Navigate to Method Directives.

Menu Path: System Management > Business Process Management > Method Directives Maintenance

Important This program is not available in the Epicor Web Access.

1. On the Detail sheet, click the Method Code button.

The Method Search window displays.

2. In the Search by Business Object section, verify Product is selected.

Recall by selecting this option, the Business Objects belonging to the application part of the system becomeavailable for selection.

3. In the Business Object field, select Customer.

4. In the Where Method Name Starts At field, enter U.

5. Click Search.

6. Select the Update method and click OK.

The Business Object returns on the form.

7. In the Method Description field, enter XXX Customer Review (where XXX are your initials).

8. Click Save.

Add a Pre-Processing Directive

1. From the New menu, select New Pre-Processing.

2. In the Directive Name field, enter XXX Condition Test to Set Hold (where XXX are your initials).

3. In the Group field, enter XXX (where XXX are your initials).

4. Click Design to launch the BPM Workflow Designer.

5. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,below the Start item.

6. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of the Conditionelement entry points.

The connection between the two elements is now established.

35Epicor ERP | 10.0.700

Hold TypeBusiness Process Management Course

Page 36: Business Process Management Course 10.0.700

7. In the workflow, click the Condition item.

8. In the Condition pane at the bottom, click the Add Line icon.

9. In the Condition field, invoke the list and select The specified field of the changed row is equal to thespecified expression.

10. Click the first specified.

11. In the Table field, verify ttCustomer displays.

12. In the Fields search box, enter state.

13. From the list of available fields, select the State check box.

14. Click OK.

15. At the end of the Condition field, click specified.

16. In the Editor text box, enter "".

This indicates that directive should execute when the Customer.Update method initiates and the State fieldis blank.

17. In the Specify an expression window, click OK.

Add an Action

1. In the workflow items tollbar, click the Enable Post Directive icon and drag it to the workflow pane ofthe Designer, below the Condition item.

2. Click the Condition's True exit outbound connector (found on the left) and connect it to any of the EnablePost Directive entry points.

3. Click Validate and verify the BPM reports no errors.

4. Click Save and Exit to return to Method Directives.

5. Select the Enabled check box.

6. Click Save.

Add a Pre-Processing Directive

1. From the New menu, select New Pre-Processing.

2. In the Directive Name field, enter XXX Condition Test to Remove Hold (where XXX are your initials).

3. In the Group field, enter XXX (where XXX are your initials).

4. Click Design to launch the BPM Workflow Designer.

5. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,below the Start item.

Epicor ERP | 10.0.70036

Business Process Management CourseHold Type

Page 37: Business Process Management Course 10.0.700

6. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of theCondition element entry points.

7. In the workflow, click the Condition item.

8. In the Condition pane at the bottom, click the Add Line icon.

9. In the Condition field, invoke the list and select The specified field of the changed row is equal to thespecified expression.

10. Click the first specified.

11. In the Table field, verify ttCustomer displays.

12. In the Fields search box, enter state.

13. From the list of available fields, select the State check box.

14. Click OK.

15. In the Condition field, click the drop-down next to is equal to.

16. From the list, select is not equal to.

17. At the end of the Condition field, click specified.

18. In the Editor text box, enter "".

This indicates that directive should execute when the Customer.Update method initiates and the CustomerState field is NOT blank.

19. In the Specify an expression window, click OK.

Add an Action

1. In the workflow items tollbar, click the Enable Post Directive icon and drag it to the workflow pane ofthe Designer, below the Condition item.

2. Click the Condition's True exit outbound connector (found on the left) and connect it to any of the EnablePost Directive entry points.

3. Click Validate and verify the BPM reports no errors.

4. Click Save and Exit to return to Method Directives.

5. Select the Enabled check box.

6. Click Save.

Add a Post-Processing Directive

1. From the New menu, select New Post-Processing.

2. In the Directive Name field, enter XXX Take Customer Off Hold (where XXX are your initials).

37Epicor ERP | 10.0.700

Hold TypeBusiness Process Management Course

Page 38: Business Process Management Course 10.0.700

3. In the Group field, enter XXX (where XXX are your initials).

4. Click Design to launch the BPM Workflow Designer.

5. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,below the Start item.

6. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of theCondition element entry points.

7. In the workflow, click the Condition item.

8. In the Condition pane at the bottom, click the Add Line icon.

9. In the Condition field, invoke the list and select this directive has been enabled from the specifieddirective.

10. In the Condition text, click specified.

11. In the Stage field, verify Pre (Pre-Processing directive) is selected.

12. In the Directive field, select XXX Condition Test to Remove Hold (where XXX are your initials) and clickOK.

This way, you specify which pre-processing directive enables the post-processing directive you are currentlyconfiguring.

Add an Action

1. In the workflow items tollbar, click the Remove Holds icon and drag it to the workflow pane of the Designer,below the Condition item.

2. Click the Condition's True exit outbound connector (found on the left) and connect it to any of the RemoveHolds entry points.

3. Click the Remove Holds item.

4. Verify the Action displays Remove holds of the specified type.

5. In the Action text, click specified.

6. In the Hold Type field, select XXX Customer Review (where XXX are your initials) and click OK.

Recall you created this hold type at the beginning of this workshop.

7. Click Validate and verify the BPM reports no errors.

8. Click Save and Exit to return to Method Directives.

9. Select the Enabled check box.

10. Click Save.

Epicor ERP | 10.0.70038

Business Process Management CourseHold Type

Page 39: Business Process Management Course 10.0.700

Add a Post-Processing Directive

Add a Post-Processing Directive to set the hold.

1. From the New menu, select New Post-Processing.

2. In the Directive Name field, enter XXX Place Customer on Hold (where XXX are your initials).

3. In the Group field, enter XXX (where XXX are your initials).

4. Click Design to launch the BPM Workflow Designer.

5. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,below the Start item.

6. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of theCondition element entry points.

7. In the workflow, click the Condition item.

8. In the Condition pane at the bottom, click the Add Line icon.

9. In the Condition field, invoke the list and select this directive has been enabled from the specifieddirective.

10. In the Condition text, click specified.

11. In the Stage field, verify Pre (Pre-Processing directive) is selected.

12. In the Directive field, select XXX Condition Test to Set Hold (where XXX are your initials) and click OK.

This indicates the directive should execute after the Condition Test to Set Hold directive executes.

Add an Action

1. In the workflow items tollbar, click the Attach Hold icon and drag it to the workflow pane of the Designer,below the Condition item.

2. Click the Condition's True exit outbound connector (found on the left) and connect it to any of the AttachHold entry points.

3. Click the Attach Hold item.

4. Verify the Action displays Attach hold of the specified type.

5. In the Action text, click specified.

6. In the Hold Type field, select XXX Customer Review (where XXX are your initials).

7. In the Comment field, enter BPM Hold - Customer.Update and click OK.

8. Click Validate and verify the BPM reports no errors.

9. Click Save and Exit to return to Method Directives.

39Epicor ERP | 10.0.700

Hold TypeBusiness Process Management Course

Page 40: Business Process Management Course 10.0.700

10. Select the Enabled check box.

11. Click Save.

Add a Method Code

1. Navigate to the Detail sheet.

2. Click the Method Code button.

3. In the Search by Business Object section, verify Product is selected.

4. In the Business Object field, select SalesOrder.

5. Click Search.

6. Select ChangeCustomer and click OK.

The method defaults to Erp.SalesOrder.ChangeCustomer.

7. Click Save.

Add a Pre-Processing Directive

1. From the New menu, select New Pre-Processing.

2. In the Directive Name field, enter XXX Customer Sales Order (where XXX are your initials).

3. In the Group field, enter XXX (where XXX are your initials).

4. Click Design to launch the BPM Workflow Designer.

5. In the workflow items tollbar, click the Condition icon and drag it to the workflow pane of the Designer,below the Start item.

6. Click your mouse, select any of the Start connector symbols, drag the line and point it to any of the Conditionelement entry points.

7. In the workflow, click the Condition item.

8. In the Condition pane at the bottom, click the Add Line icon.

9. In the Condition field, invoke the list and select the hold of the specified type is attached to thebusiness object.

10. Click specified type is attached to the business object.

The Select Business Object window displays.

11. Expand the following nodes: Erp.SalesOrder > Objects, linked with the object "Erp.Sales Order" >via OrderHed.

12. Select the first Erp.Customer object.

Epicor ERP | 10.0.70040

Business Process Management CourseHold Type

Page 41: Business Process Management Course 10.0.700

13. In the Hold Type field, verify XXX Customer Review (where XXX are your initials) and is attachedpopulates.

14. In the Select Business Object window, click OK.

This indicates the directive should execute when the ChangeCustomer method is called and the customeron the order is on Customer Review hold.

Add an Action

Define an action to display an exception message.

1. In the workflow items tollbar, click the Raise Exception icon and drag it to the workflow pane of theDesigner, below the Condition item.

2. Click the Condition element.

3. On the left side of the Condition element, verify True displays.

4. Select the True exit point, drag the line and point it to any of the Raise Exception element entry points.

5. Click the Raise Exception element.

6. In the Actions pane, verify raise exception based on the designed template displays.

7. Select designed to launch the Design Exception Template window.

8. In the Name field, enter Customer Hold.

9. In the text box, enter This customer is on hold because a required field has not been entered - BPM.

This action executes when the Customer.Update method initiates and specified conditions are met.

10. In the Design Exception Template window, click OK.

11. Click Validate and verify BPM reports no errors.

12. Click Save and Exit to return to Method Directives.

13. Click the Enabled check box.

14. Click Save.

15. Minimize the Method Directives window.

Update a Customer Record

Navigate to Customer Maintenance.

Menu Path: Sales Management > Order Management > Setup > Customer

Tip The CRM menu path is: Customer Relationship Management > Order Management > Setup > Customer

1. In the Customer field, enter ADDISON and press Tab.

41Epicor ERP | 10.0.700

Hold TypeBusiness Process Management Course

Page 42: Business Process Management Course 10.0.700

2. In the State field, delete the entry and click Save.

3. Exit Customer Maintenance.

Create a Sales Order

To test the BPM, you updated a customer record and left the State field blank; next, enter a sales order. Whenyou add a customer to an order, the application displays the exception, but you can continue to complete theorder.

Navigate to Sales Order Entry.

Menu Path: Sales Management > Order Management > General Operations > Order Entry

Tip The CRM menu path is: Customer Relationship Management > Order Management > GeneralOperations > Order Entry

1. Click New.

2. In the Customer field, enter Addison and press Tab.

Note the BPM message.

3. To the Error message, click OK.

4. Exit Sales Order Entry.

5. In the Save Confirmation window, click No.

Tip

In the real environment, to prevent the order from being completed, you can create a pre-processingdirective for the SalesOrder.Update method to check for the hold and raise the same exception.

Disable Directives

1. Maximize the Method Directives window.

2. In the tree view, select the Pre-Processing directive XXX Customer Sales Order.

3. On the Pre-Processing > Detail sheet, clear the Enabled check box.

4. Navigate to the Detail sheet.

5. Click the Method Code button.

6. In the Business Object field, select Customer.

7. Click the Search button to search for and select Customer.Update.

8. In the tree view, select the Pre-Processing directive XXX Condition Test to Set Hold.

9. On the Pre-Processing > Detail sheet, clear the Enabled check box.

10. Click Save.

Epicor ERP | 10.0.70042

Business Process Management CourseHold Type

Page 43: Business Process Management Course 10.0.700

11. Disable the remaining directives created for the Customer.Update method :

• XXX Condition Test to Remove Hold

• XXX Take Customer Off Hold

• XXX Place Customer on Hold

12. Click Save.

13. Exit Method Directives.

43Epicor ERP | 10.0.700

Hold TypeBusiness Process Management Course

Page 44: Business Process Management Course 10.0.700

Data Directives

Use Data Directives Maintenance to view, create, edit, and delete data directives applied to database tabletransactions.

A data directive is similar to a method directive, but instead of being launched by a business object method, adata directive is linked to a database table and is triggered by a database event, such as add, delete, or update.By applying the directive to a specific table, data directives are used to control data that may be affected byseveral business objects.

You can apply most of the conditions and actions from method directives to data directives as well, except incases where the condition or action depends on information available in the business object that is not availablein the data itself. Two types of data directives are available:

• In-Transaction - Affects data before it is saved to the database. This directive type can only process one rowat a time; it cannot process multiple dirty rows - rows that contain data not yet saved to the database. Multipledirty rows are explained later in this course.

• Standard - Does not affect data in the database. A Standard directive executes after a data transaction issaved to the database. This directive type processes multiple dirty rows modified in the database at once. Itruns after base methods and method directives.

Workshop - Use Auto Print Action

You can use BPM to automatically preview or print a report when the BPM data directive executes. In thisworkshop, apply the standard data directive on the OrderHed table to preview the Sales Order Acknowledgementreport when user enables a check box.

To configure the Auto-Print action, select a report, select a printer and print options, and configure the mappingof input values for report parameters. The Auto Print action is typically triggered by the execute custom codeaction or after a certain condition is met.

Locate the OrderHed Table

Navigate to Data Directives.

Menu Path: System Management > Business Process Management > Data Directives Maintenance

Important This program is not available in the Epicor Web Access.

1. Click the Table button.

The Table Search window displays.

2. Verify the Search by Table option is selected.

3. In the Table Name Starting At field, enter Order.

4. Click Search.

5. Select OrderHed and click OK.

Epicor ERP | 10.0.70044

Business Process Management CourseData Directives

Page 45: Business Process Management Course 10.0.700

Add Standard Directive

1. Click New and select New Standard Directive.

2. In the Directive Name field, enter XXX-Auto Print (where XXX are your initials).

3. In the Group field, enter XXX (where XXX are your initials).

4. Click Design to launch the BPM Workflow Designer.

5. Click the Condition icon and drag it to the workflow pane of the Designer, below the Start item.

6. Create a connection between the Start and Condition elements.

7. In the workflow, click the Condition item.

8. In the Condition pane at the bottom, click the Add Line icon.

9. In the Condition field, invoke the list and select The specified field has been changed from any toanother.

10. Click the specified link.

11. In the Table field, verify ttOrderHed displays.

12. From the list of available fields, select the AutoPrintReady check box and click OK.

13. Click the another link.

14. Clear the Any Value check box.

15. In the Value field, select true and click OK.

This condition will trigger the subsequent action when a user selects the Auto-Print Ready check box foundon Sales Order's Summary sheet.

Add an Action

1. In the workflow items tollbar, click the Auto Print icon and drag it to the workflow pane of the Designer,below the Condition item.

2. Click the Condition's True exit outbound connector connect it to any of the Auto Print entry points.

3. Click the Auto Print workflow element.

4. In the Actions pane, verify Automatically print specified report with specified options displays.

5. Click the first specified link.

In the search dialog box, the Basic tab presents fields for entering search criteria specific to reports.

6. In the Report Type, verify SQL Server Reporting (SSRS) displays.

7. In the Report Table Level field, verify 'OrderHed' is the Primary table displays.

45Epicor ERP | 10.0.700

Data DirectivesBusiness Process Management Course

Page 46: Business Process Management Course 10.0.700

This means only the reports where OrderHed is defined as the primary table will become available forselection.

8. Click Search.

9. From the list, select OrderAck (Sales Order Acknowledgement) and click OK.

10. Click the specified link.

11. In the Run Schedule field, verify Immediate displays.

This means the action will execute right after the condition is satisfied.

12. For the Print Action, select Auto Preview.

Now you must specify the Report Parameters. On this sheet, you can add or edit the actions associatedwith the listed parameters so that values can be passed to the report in the context of the Auto Print action.

13. Select the Report Parameters sheet.

14. In the OrderNum parameter, click the arrow on the right-hand side and select The specified table andfield value.

15. Click the specified link to launch the Select Table Field(s) window.

16. Select ttOrderHed.OrderNum field and click OK.

Verify the OrderNum parameter is set to The ttOrderHed.OrderNum table and field value.

17. In the Set up Auto Print window, click OK.

18. Click the Validate button and verify BPM reports no errors.

19. Click Save and Exit to return to the Data Directives window.

20. Select the Enabled check box to activate the directive.

21. Click Save and minimize Data Directives.

Test the BPM

Navigate to Sales Order Entry.

Menu Path: Sales Management > Order Management > General Operations > Order Entry

Tip The CRM menu path is: Customer Relationship Management > Order Management > GeneralOperations > Order Entry

1. Click New.

2. In the Customer field, enter Dalton and press Tab.

3. Click New > New Line.

4. On the Lines Detail sheet at the bottom, enter the following details:

Epicor ERP | 10.0.70046

Business Process Management CourseData Directives

Page 47: Business Process Management Course 10.0.700

ValueField

DSS-1010Part

10Order Quantity

5. Select the Auto-Print Ready check box.

6. Click Save.

The Sales Order Acknowledgement report displays for the order in focus.

7. Exit the report and Sales Order Entry.

Disable Directive

1. Maximize Data Directives.

2. Clear the Enabled check box to disable the BPM.

3. Click Save and exit Data Directives.

47Epicor ERP | 10.0.700

Data DirectivesBusiness Process Management Course

Page 48: Business Process Management Course 10.0.700

Multiple Dirty Rows

A dirty row is a row of modified data not yet saved to the database. For example, when the user modifies a row,like a currency exchange rate, then moves to another row (another exchange rate), modifies it, and then savethe two rows together, these two rows are called multiple "dirty" rows.

Some methods only allow changed rows to process one at a time, and so do not support multiple dirty rows.However, some methods can send multiple dirty rows together as a set to the server for update.

When multiple rows are sent to the server at the same time, you can specify a directive to take action on thebatch of rows in a specific way. These actions are available for both method directives, if the method is markedas supporting Multiple Dirty Rows, and standard data directives:

• Once passing all matching rows - The action executes once as it moves through the data within the set ofdirty rows, but it only gets the rows that match the selection criteria.

• Once passing all existing rows - The action executes one time as it moves through the data within the setof dirty rows, and it checks all rows within the dirty row set.

• For each matching - The action executes for as many times as the number of rows that match the selectioncriteria in the dirty row set. Each row processes individually.

• For each existing - The action executes for as many times as the number of rows within the dirty row set(the overall number of dirty rows). Each row processes individually.

Epicor ERP | 10.0.70048

Business Process Management CourseMultiple Dirty Rows

Page 49: Business Process Management Course 10.0.700

Updatable BAQ Directives

Use Updatable BAQ Method Directives to view, edit and define directives specific to an updatable BusinessActivity Query (BAQ).

Updatable BAQ method directives are similar to the method directives described earlier, except they apply tomethods used specifically by updatable BAQs, custom queries you can create for data entry. Updatable BAQmethods are used to run processes on Updatable Dashboards. This chapter details the conditions and actionsavailable for Updatable BAQ method directives. For more information about creating and implementing thesemethods, review the Updatable Dashboards chapter.

Updatable BAQ directives initiate BPM actions based on method calls launched from an updatable BAQ. Anupdatable BAQ is a customized query tool that displays on smart client dashboards and mobile device dashboardsthrough which users can update and add data; like a business object, BAQ methods are required so the databasecan be updated. An updatable BAQ directive can be run before, after, or in place of the BAQ method call.

Updatable BAQ method directives are similar to the method directives, except that they apply to methods usedspecifically by updatable BAQs. Each updatable BAQ has the following methods:

• GetList - Retrieves the data specified by the query.

• GetNew - Creates an empty row where a new record can be entered and submitted to the database.

• Update - Performs database updates for changed and added rows.

• RunCustomAction - Runs a custom action. You define the ID of the custom action in the Business ActivityQuery Designer program and define the action using one or more directives.

• FieldUpdate - This method occurs after the user's change to a field is committed. If you want this field togenerate a Business Process Management (BPM) method, select the Raise Events check box in Updatable FieldEditor. You can use this method to perform additional processing against the changed row. For example,when you enter a part number, you want the part description field to populate automatically.

• Field Validate - This method occurs before the proposed change to a field is committed. If you want thisfield to generate a Business Process Management (BPM) method, select the Raise Events check box in UpdatableField Editor. You can use this method to validate proposed changes. For example, you can prevent users fromentering an incorrect value in a certain field such as non-existent state.

Important You must be a BPM Advanced User to modify pre-processing and post-processing updatableBAQ method directives with a limited number of actions. To utilize the whole uBAQ Method Directivestoolset including modifications of base processing directives, a user must be provided with BAQ AdvancedUser rights.

The Updatable BAQ Method Directives program can be accessed in two ways:

• By clicking Define Custom Actions on the Update > General Properties sheet of the Business Activity QueryDesigner program.

• From the Main Menu path shown below.

Custom Actions

You may create custom actions for updatable BAQs in the Business Activity Designer program by defining theaction ID and label. The custom actions can then be added to the Actions menu of a dashboard that uses thequery. In the Updatable BAQ Method Directives program, you create a pre-processing, base processing, orpost-processing directive for the RunCustomAction method.

Use "the specified argument is equal to the specified expression" condition statement to identify whichaction to run. The first "specified" variable can be set to "actionID." The second "specified" variable can be set

49Epicor ERP | 10.0.700

Updatable BAQ DirectivesBusiness Process Management Course

Page 50: Business Process Management Course 10.0.700

to the ID of the action called by the user as it was specified in the BAQ. Then create directive actions to performcustom operations.

Menu Path: System Management > Business Process Management > Updatable BAQ Directives Maintenance

Important This program is not available in the Epicor Web Access.

Epicor ERP | 10.0.70050

Business Process Management CourseUpdatable BAQ Directives

Page 51: Business Process Management Course 10.0.700

BPM and Service Connect Workflows

Epicor Service Connect is a business integration platform that functions as a central integration point for secureworkflow processes within the Epicor application, as well as external connectivity to Epicor and non-Epicorapplications. You can re-compose business components, represented as web services outside of application,within Service Connect to eliminate non-value added steps or potentially speed up any process.

You can create a method directive to call a Service Connect workflow. Service Connect automates tasks andprocesses within the application to allow employees to focus on value added activities and management byexception, instead of repetitive data (re)entry tasks. For example, you can create a method directive to call aService Connect workflow to update customer information in an offline file or other application when changesare made in Customer Maintenance.

The workflow can be called synchronously or asynchronously. Synchronously allows the record to be modifiedas it comes through the pre-process. Asynchronously takes a copy of the record and calls the Service Connectworkflow out of the scope of the main transaction. Asynchronously is typically faster since you do not have towait for the Service Connect workflow to complete before the transaction processes. Consideration should bemade before calling Service Connect synchronously.

You must enable the BPM Advanced User option in User Account Maintenance to access the call ServiceConnect workflow action.

To create a method directive to call Service Connect, select the Call SC Workflow workflow item in BPM WFDesigner. When the specified hot link is selected to identify the workflow, BPM creates a query against ServiceConnect on the designated server to find all the available workflows.

For additional information on Epicor Service Connect, see the ESC Help and Epicor 10 Service Connect Courses.

51Epicor ERP | 10.0.700

BPM and Service Connect WorkflowsBusiness Process Management Course

Page 52: Business Process Management Course 10.0.700

BPM Utilities

Various utilities are available in the Business Process Management (BPM) module.

Action Processing

After you define the method directives your application runs, you are ready to set up the action process schedule.This regular schedule causes the Business Process Management (BPM) functionality to run and subsequently,update the BPM task queue and process asynchronous method directives.

To set up the BPM Process task to run on a recurring schedule, create the schedule and set up the process to runusing this schedule.

System Agent

Use System Agent Maintenance to create recurring schedules. Use this program to create the different schedulesyou need to run your method directives.

Menu Path: System Setup > System Maintenance > System Agent

Important This program is not available in the Epicor Web Access.

Action Process

Use BPM Async Process to set up a task that deletes outdated BPM Data Form states, processes all asynchronousExecute Custom Code actions and invokes asynchronous External Method actions in the queue.

Other asynchronous actions such as Send E-mail or Call ESC Workflow are launched asynchronously when thedirective executes; they are not put in the queue and don't require this task to launch them.

You can set up this task to run on a recurring schedule. This automatically processes all calls made by the methoddirectives.

Menu Path: System Management > Business Process Management > Action Process

Important This program is not available in the Epicor Web Access.

BPM Async Processing Log

If you are running any asynchronous actions, you can use the BPM Async Processing Log to review eachasynchronous action. The log location is specified during BPM Action Process setup. It lists the following informationabout each action:

• Startup timestamp

• Error message (if an issue occurs)

• Completion timestamp

Epicor ERP | 10.0.70052

Business Process Management CourseBPM Utilities

Page 53: Business Process Management Course 10.0.700

BPM User Rights

Two levels of Business Process Management (BPM) functionality are available - a base level and an advancedlevel.

All users who have menu access to BPM can use the base level of BPM functionality to create holds and directivescontaining pre-built actions. Users with access to the advanced BPM functions can use the entire BPM toolset.These users can also create method directives that run in place of the base methods; however users should workwith Epicor or a partner organization before replacing a base method.

You give specific user rights to the advanced BPM features through User Account Maintenance. These rightsare assigned on the Options sheet.

Users with BPM Advanced User privileges can use the entire BPM toolset that includes the following:

• Create programming actions using the Programming Interface Generator Form

• Create and edit Base Processing directives

• Create and edit In-Transaction Data directives

• Modify pre-processing and post-processing updatable BAQ method directives with a limited number of actions.To utilize the whole uBAQ Method Directives toolset, a user must be provided with BAQ Advanced Usersrights.

• Use the whole set of BPM Workflow Actions including:

• Auto Print

• Change Log

• Call Service Connect Workflow

• Execute Custom Code

• Invoke External Method

• Notify Me

• Set By Query

• Use the whole set of BPM Workflow Conditions including:

• The custom code condition is valid

BPM Logging

The server trace log is an important tool for managing both application and performance issues. You can configurethe trace log to record the BPM specific transaction data you need to review.

Use the Epicor Administration Console to set up server logging settings. The following outlines the processof enabling the BPM tracing functionality.

1. You launch the Epicor Administration Console from your server machine. Depending on your operatingsystem, you launch this tool in different ways:

a. If you are on Windows SQL Server 2008 R2, click Start > All Programs > Epicor Software > EpicorAdministrative Tools > Epicor Administration Console.

53Epicor ERP | 10.0.700

BPM UtilitiesBusiness Process Management Course

Page 54: Business Process Management Course 10.0.700

b. If you are on Windows SQL Server 2012, press the <Windows> + F button to display the Charms bar;from the Apps screen, select Epicor Administration Console.

The Epicor Administration Console displays.

2. From the tree view, expand the Server Management node and Epicor Server node.

3. Select the application server you need to monitor.

4. Now from either the Action menu or the Actions pane, select Application Server Settings.

5. In the Application Server Settings window, Enable the Trace Log and configure Log File Location.

6. Within the Standard Logging information, select the BPM Logging check box to record Business ProcessManagement (BPM) database calls.

Each time user activity activates a BPM, the application server log records the information and gathers thedata results.

Epicor ERP | 10.0.70054

Business Process Management CourseBPM Utilities

Page 55: Business Process Management Course 10.0.700

By selecting the BPM Logging check box, you enable the following trace flag in the trace.config configurationfile:

<add uri="trace://ice/fw/BPM" />

The above trace URI tracks the complete BPM information that includes the following:

• Business Object customizations made through Method Directives

• Data Triggers created using Data Directives

• uBAQ customizations - method directives of Updatable BAQs with BPM update

For a detailed analysis, the trace URI can be manually configured to narrow down the information beingtracked:

• trace://ice/fw/BPM/BO - to track BO customizations only

• trace://ice/fw/BPM/DB - to track data triggers only

• trace://ice/fw/BPM/DQ - to track UBAQ customizations only

7. As a result, the server log records the following information:

Example

Op Utc="2013-10-30T13:40:45.2677063Z" act="Ice:BO:Tip/TipSvcContract/Update" dur="1006.1712" cli="fe80::d147:d8f4:e54e:5149%10:42111" usr="manager" machine="MOS-TLS-DEV-AAA" pid="10788" tid="5"> <BpmCustomization Source="BO" BpMethodCode="ICE.Tip.Update" Type="BO Customization" ExecutionInterruptedOnDirective="6300f64f-ccd6-4617-9105-a9784736eb54" Duration="530.9098"> <BpmDirective Type="PreProcessing" ID="6300f64f-ccd6-4617-9105-a9784736eb54" Name="MyBPMDataForm" IsCompanyIndependent="false" Duration="7.9992" />

55Epicor ERP | 10.0.700

BPM UtilitiesBusiness Process Management Course

Page 56: Business Process Management Course 10.0.700

</BpmCustomization></Op>

For each BPM call, the BpmCustomization node is created with following attributes:

DescriptionNode

Displays the source of the BPM information. Possible values:Source

• BO - Method Directives

• DB - Data Triggers

• DQ - uBAQ Method Directives

The method invoked by the BPM.BpMethodCode

Displays the Type of the BPM call. Possible values:Type

• In Transaction Trigger

• Standard Trigger

• BO Customization

• uBAQ Update Processing

Applies to BPM Data Form execution only. When the BPM Form invokes,the service call exits and returns control back to the client. The client then

ExecutionInterruptedOnDirective

calls the service again. Therefore, in case of BPM Data Forms two differentoperations are tracked.

This value displays the directive's GUID from which the service call wasinterrupted.

For the second BPM Data Form operation, this value displays the directive'sGUID from which the service call was resumed.

ExecutionResumedFromDirective

Time spent on executing a BPM call.Duration

Within the BpmCustomization node, the BpmDirective node holds the following attributes:

DescriptionNode

Type of the Directive. Possible values:Type

• Pre, Base, Post - for Method Directives and uBAQ Method Directives

• Standard, In Transaction - for Data Directives

Displays the directive's GUID.ID

Name of the directive.Name

Displays if the directive is active for all companies in the application.IsCompanyIndependent

The duration of the directive's preparation step. If there was no preparationfor this directive, this attribute is absent.

PreparationStepDuration

The directive's execution time.Duration

Tip

• A single service call may trigger a lot of BPM customizations, even the customizations of differentBOs and tables. They all will be listed under the Op node of this operation.

Epicor ERP | 10.0.70056

Business Process Management CourseBPM Utilities

Page 57: Business Process Management Course 10.0.700

• The execution of one directive may lead to other customizations being executed, and in case ofsynchronous execution (in-transaction triggers, sync invocations of other BO methods), the durationof the "child" directives will also be counted into the duration of "parent" directive.

• Default BO method execution duration (in case it's not overridden by a BaseProcessing direction)is not counted as part of BO Customization duration.

• Since tracing engine allows the user to switch on some tracing functionality for a particular BOcalls, or specific method invocations, it applies to BPM tracing out of the box.

You can evaluate the server log using the Performance and Diagnostic Tool. For more information on how totest the performance of your system, review the Performance Diagnostic Guide.

Disable BPM

You can use the customizationSettings section found in the web.config located in the server folder of yourEpicor ERP installation to control the application's customization engine.

Example

<customizationSettings disabled="false" intermediateFolder="C:\Inetpub\wwwroot\EpicorERP10\Server\BPM"> <customizationStorage provider="FileSystem" settings="C:\Inetpub\wwwroot\EpicorERP10\Server\Customization" /> <externalsStorage provider="FileSystem" settings="C:\Inetpub\wwwroot\EpicorERP10\Server\Customization\Externals" /> <types> <add name="BPM.BO" folder="BO" cacheName="Epicor_Ice_BPM_BO" /> <add name="Posting" folder="PE" cacheName="Epicor_Ice_PE" /> <add name="ElectronicInterface" folder="EI" cacheName="Epicor_Erp_EI" /> <add name="Expressions" folder="ECF" cacheName="Epicor_Erp_Expressions" /> <add name="ProductConfigurator" folder="PC" cacheName="Epicor_Ice_PC" /> <add name="BPM.DT" folder="DT" cacheName="Epicor_Ice_BPM_BO" /> <add name="BPM.Ubaq" folder="Ubaq" cacheName="Epicor_Ice_BPM_BO" /> </types> </customizationSettings>

When you set customizationSettings disabled = "true", you turn the customization engine off. This meansMethod Directives, Data Directives and uBAQ Method Directives processed via BPM are not executed. However,you can still edit, add and remove BPMs but these changes are saved to the database only and no binaries arebeing recompiled or deleted.

When customization engine is turned back on (customizationSettings disabled = "false"), old binaries areapplied. To get the binaries up to date:

• Recompile all Method and Data Directives using the Directive Update program.

Menu Path: System Management > Business Process Management > Directive Update

Important This program is not available in the Epicor Web Access.

• Recompile and refresh BPM binaries related to selected updatable queries using the Updatable QueryMaintenance program.

Menu Path: System Management > Upgrade/Mass Regeneration > Updatable BAQ Maintenance

57Epicor ERP | 10.0.700

BPM UtilitiesBusiness Process Management Course

Page 58: Business Process Management Course 10.0.700

Tip

If an incorrectly configured BPM directive prevents the system from operating or the user from logging in,removing incorrect directives with disabled BPM is not enough. The user should remove affected binariesfrom the Server > Customization folder, for example, fromC:\inetpub\wwwroot\EpicorERP10\Server\Customization and then remove or disable incorrect directives.

Important The customizationSettings disabled = "true" setting also turns off other customization engineclient besides BPM that are defined in the web.config, such as Posting or Product Configurator.

Epicor ERP | 10.0.70058

Business Process Management CourseBPM Utilities

Page 59: Business Process Management Course 10.0.700

Conclusion

Congratulations! You have completed the Business Process Management course.

59Epicor ERP | 10.0.700

ConclusionBusiness Process Management Course

Page 60: Business Process Management Course 10.0.700

Additional information is available at the Education andDocumentation areas of the EPICweb Customer Portal. To access

this site, you need a Site ID and an EPICweb account. To create anaccount, go to http://support.epicor.com.