Meeting Process Automation

Lawson Mid-America User Group Spring 2016
Meeting
Using Infor Process Automation – an End Users
Point of View
Converting Current Process flows to Infor
Process Automation
Do you have existing Process Flows?
• There is a way to automatically convert current Process Flows to
the new Infor Process Flow Automation
• This process will convert most process flows unless the function is
not longer supported or the process has changed (mainly in HR)
• The command is migrateflows
Migrate Flows command
• To convert your process flows where they default to log errors use
migrateflows prod –d C:\SourceDirectory –e –t C:\TargetDirectory –l
-d source directory
-t destination director
-l Log errors
• To convert your process flow where they email errors use
Migrate Flows command
• To convert your process flow where they email errors use
Migrateflows prod –d C:\SourceDirectory –e –t C:\TargetDirectory –n –T
[email protected] –F [email protected]
-d source directory
-t destination director
-n notify on errors
-T To e-mail
-F From e-mail
Java Scripts
• Missing Java Scripts (make sure all Java Script functions are included in file that
are being utilized by IPA)
– MID
– LEFT
– RIGHT
•
•
•
•
Find Java Script format on internet
Load JavaScript into pflow.js file
Running on PC will probably be under \IPDesigner\IPDesigner
On IPA server will probably be under C:\IPADesigner
Java Scripts (Sample)
Functions
IPA Screen
IPA Screen
• Screen sections
– Process Name – can jump to any node used in the process automation
– Properties – shows information about the node selected in process name
– Center – shows pictorial representation of process, this is where most of the work
is completed. Left side has all the different functions available
– Right side – when process automation is run, it will show each step and result of
the process automation
Conventions
• Node ID – this field is used as the beginning of the variable name in
subsequent nodes. This will also appear in the process name
section.
• Node Name – this field is used to identify the node on the screen.
This will appear under the node name in the center of the screen
and also process name section.
Start Function
Start Function
• Define Variables
– Define type of variable
– All variables used must be included
• Define dates – DME and AGS
– DME dates (for data mining)
– AGS dates (for making data updates using Lawson screens)
Manipulating dates
• Today – this returns the current system date. Variable type is date.
• AddDay – this allows you to add or subtract a set number of days from the date used
“AddDay(today,-5)” this will return date 5 days previous to today’s day. Variable type is
date
• getDateAGS – this converts a system date or a AddDay to a date format that can be
used in an AGS call “getDateAGS(today)”. Variable type is String
• getDateDME – this converts a system date or a AddDay to a date format that can be
used in a DME call “getDateDME(today). Variable type is String
Variable set up
Variable Usage
• When using variables within process automation the variable is entered
using <!variable name> format.
• This will be shown throughout the presentation
• Anywhere you see the light bulb you can press Ctrl+Space to see a list of
variables.
• The list of variables is displayed under the main section of the page
Variable Useful Tip
Query Function
Query Function
• This function is used to query date from the Lawson system or other databases.
• Use this function to obtain data to either report (via e-mal or other function) or
to use in a transaction function.
• The best way to create the query is to use the query builder.
• Using add-ins may also help build the query
• Only Lawson existing links between tables can be used. If the tables are not
linked by Lawson then the SQL Query node will need to be used.
Query Example
PROD=PROD&FILE=POLINE&FIELD=COMPANY;PO-NUMBER;PO-RELEASE;PO-CODE;QUANTITY;RECQTY;CXL-QTY;RELEASED-FL;PURCHORDER.PO-DATE;PURCHORDER.PO-NUMBER;PURCHORDER.PORELEASE;PURCHORDER.PO-CODE;PURCHORDER.COMPANY;ITEM-TYPE&SELECT=POCODE=PAYO%26RELEASED-FL=Y%26PURCHORDER.PO-DATE%3E<!Period>%26CLOSEDFL=N%26ITEM-TYPE%21%3DS&OUT=CSV&DELIM=~
•The above query is used to find any PO that has a PO Code of PAYO, with a PO date greater than or
equal to the variable Period (period is set to 180 days before the current date), the PO closed flag is
set to N, and the item type is not equal to S (service)
•All fields that need to be used in the AGS calls, e-mail, branches, etc. will need to be included in the
field selected.
•This query is used to identify any Pay only PO’s that have not been received.
Query Builder Function
Query Builder Function
Query Builder Function
Transaction Function
Transaction Function
• This function is used to create a transaction in Lawson. This can include
changes, adds, releases, etc.
• This function works similarly to add-ins update. However process
automation has more functionality.
• You can use add-ins to help create the AGS calls.
• You can also use the build function to create the appropriate information
for the call.
AGS Call
_PDL=PROD&_TKN=PO30.1&_EVT=CHG&_RTN=DATA&_LFN=ALL&_T
DS=IGNORE&FC=V&POR-COMPANY=<!GETPO_COMPANY>&POR-PONUMBER=<!GETPO_PO_NUMBER>&POR-PORELEASE=<!GETPO_PO_RELEASE>&POR-POCODE=<!GETPO_PO_CODE>&_DELIM=%09&_OUT=XML&_EOT=TRUE
•The above AGS call will create receiver all using the program PO
Receipt (PO30) using the variables from the previous DME call.
Company, PO Number, PO Release, and PO code.
Transaction Builder Function
Branch Function
Branch Function
• Use the branch function to create if statements to change the flow depending on the
parameters of the if statement.
• In the above the first statement will check to see if there is still quantity open on the line, if
there is open quantity then it goes to the transaction node, if there is not any quantity open
then it goes to the next record of the query.
• The order of the statements is critical since this is the order that the statement will be run
so once it reaches a true statement then it will follow that command. So ensure the steps
are in the correct order.
• Always make sure that the if statement is fulfilled with a true answer otherwise the
automation will stop with an error. To ensure this you can use branch name of else with the
condition of true.
Message Builder Function
Message Builder Function
• The message builder allows for the building of an e-mail for the entire
process. This will allow a line or multiple lines of data each time this
mode is enacted.
• This will allow only one e-mail to be sent with many records listed in the
e-mail as opposed to one e-mail for each record.
• Build the records by using variable names of the fields that should be
included in the e-mail.
E-Mail Function
E-Mail Function
• Use the e-mail function to send e-mails to specific users using process
automation.
• Be sure to put this process outside the query otherwise an e-mail will be
sent for each record of the query. Use the message builder to create a
consolidated e-mail
• Use the variable for the message builder in the body of the e-mail in this
case <!RECLOG>. Also you can include other variables in the e-mail like
<!RECQUERY_REC_DATE> that will show the receive date in the e-mail
E-Mail Function
• If an attachment needs to be included in the e-mail then the attachment has
to reside on the landmark server in the directory
d:\lmrk\system\LPS\emailattachments if the process is being run on the
server.
• To get the attachment to the correct directory the FTP node can be used.
Data Iteration Function
Data Iteration Function
• Use the data iteration function to read data from an outside file like a csv file.
• This functionality is perfect for loading data from an outside system into Lawson if the
outside system can provide a flat file.
• Process Automation has more capabilities than add-ins because it has the ability to have
logic include like branches and message builders.
• The other thing is you can nest data iteration nodes to first read a csv file line (1st iteration)
then use a 2nd iteration to then put each data element in the row into a separate variable.
• This is used to take a CSV file from our capital management software and create a PO from
that data.
Data Iteration Function
Data Iteration Using Variables from 2nd
Connectors Function
Connectors Function
• The connectors are used to link nodes together.
• Every node (except for start and stop) has to have at least 2
connectors. One going into the node and one going out of the
node.
• Some nodes can have multiple connectors like a branch statement.
This can be seen in the following example
Demo
Explanation
• Releases buyer messages with a message type of C and a reason
code of 07.
• Used to release multiple messages from an Add-Ins function for
buyer messages on contracts
• This shows a process where you can combine both add-ins and
process automation
Special Thanks
• Many of these Process Automations would not have been created
without the help of our IT department including:
– Chris Davis
– Natalie Heinen
– Jerome Sison
– Matt Whatley
Questions
Thank you for attending
Contact Information:
Karl Danielson
E-Mail: [email protected]
Phone: 502-629-7216