Presentation is loading. Please wait.

Presentation is loading. Please wait.

Workflow Tips & Tricks Ulrich Mende Mende EDV Beratung Session Code: 3206.

Similar presentations


Presentation on theme: "Workflow Tips & Tricks Ulrich Mende Mende EDV Beratung Session Code: 3206."— Presentation transcript:

1 Workflow Tips & Tricks Ulrich Mende Mende EDV Beratung Session Code: 3206

2 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Deadline Calculation with SAP Calendar Functions Deadline calculation should be based on the active factory calendar in the SAP system. Working time should be used as the Offsets in deadline calculation. Weekends and holidays have to be omitted. Example: In case an Approver did not complete his/her workitem after 2 working days deadline processing will send a mail to a responsible person. Workitem arrives:Monday, 4:00 p.m. Mail should arrive:Wednsday, 4:00 p.m. Workitem arrives:Friday, 4:00 p.m. Mail should arrive:Tuesday, 4:00 p.m. (not Sunday 4:00 p.m.)

3 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Setup deadline calculation in activity dynpro  LatestEnd

4 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Use radio box „Expression“ for your own calculation of deadline date and time Expression for deadline date Expression for deadline time

5 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Notes for the solution -An agent can execute the workitem only after it arrived in his inbox  a calculation regarding workitem creation time is of interest -Workitem creation time is not known at workflow creation time  deadlines can not be calculated before starting the workflow -Deadline calculation must be carried out in the workflow at runtime  ABAP coding in an BOR object type (method or virtual property) is needed -Deadlines should be set for tasks of several BOR object types (FIPP, MARA...), but these types should not be changed or subtyped -Consequence: Special object type for deadline calculation

6 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Special BOR object type ZDEADLINE Numerical offset relating to workitem creation time Time unit for offset (minutes, hours, days) Factory calendar for calculation (table TFACD) Calculates date for deadline using factory calendar ( FM END_TIME_DETERMINE) Calculates time for deadline using factory calendar ( FM END_TIME_DETERMINE)

7 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Definition of ZDEADLINE-elements in the workflow container

8 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de F4 Set up key values for ZDEADLINE object by „Triggering events“ or by „Initial values“

9 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Use virtual properties of ZDEADLINE object as deadline expressions

10 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Text file ABAP code of object type ZDEADLINE

11 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Filter Report for Workitem Selection

12 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Workitem Selection in a Development System

13 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Workitem Selection in a productive system Workitems are sorted by ID Lots of workflow- and object instances in the list

14 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de F 13007 STARTED E 13008 STARTED W 13009 COMPLETED F 13234 STARTED W 13236 COMPLETED B 13413 COMPLETED W 13414 READY WI_CHCKID = 13007 WI_CHCKID = 13234 Multi step items (Subworkflows) Single step Items Workitem hierarchy, modelled in table SWWWIHEAD Find a toplevel WI to a given WI going up the hierarchy by field WI_CHECKID Find a toplevel WI to a given BOR object instance In table SWW_CONTOB Find all WIs, related to a toplevel WI going down the hierarchy recursively

15 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de A n y WI-ID, if not toplevel, toplevel is found STARTED, COMPLETED, CANCELLED, ERROR Task of Type WS or WF BOR object type Key of BOR object instance wildcards are allowed Date and time of workflow creation Selection screen of report Z_FILTER_WF

16 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Type is always „F“ Basic list of report Z_FILTER_WF (ALV-list of toplevel workflows) Task and object type are corresponding Full key of object instance Count of WIs in the workflow Toplevel IDs

17 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de 6 days between creation of workflow and last WI 22.000 WI-IDs between workflow and last WI Workitem Selection for the result of report Z_FILTER_WF

18 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Text file ABAP code of filter report Z_FILTER_WF for workitem selection

19 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de Thank you for attending! Please remember to complete and return your evaluation form following this session (session code = 3206).

20 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de The solution: Special object type ZDEADLINE  virtual properties for deadline date and time  no reference to database table  separates calculation of deadlines from business properties  no changes to business objects necessary  one deadline object type for several business object types  good performance (no RFCs)  import parameters by key values  alter parameters of deadline calculation at runtime

21 Workflow Tips & Tricks : 3206 info@mende-edv-beratung.de 5 steps to use the suggested solution: 1.Create a BOR object type ZDEADLINE 3 keys, frames for 2 virtual properties 2.Copy ABAP code for virtual properties Set state to implemented, generate object type, test properties 3.In the workflow that contains the activity with deadline processing define one or more ZDEADLINE container elements 4.Set up initial values for the container element 5.Use virtual properties of the object as deadline expressions in activity dynpro


Download ppt "Workflow Tips & Tricks Ulrich Mende Mende EDV Beratung Session Code: 3206."

Similar presentations


Ads by Google