This how-to guide is meant to make you acquainted with main peculiarities of Action Cards (Intelligent Decision Dimensions) implementation and show how simple it is to send a notification email from the SAP system for the Goods Movement document using our SAP certified solution.
Let us consider an example of using background service of notifications when detecting a focus situation in the process of Goods Movement documents background monitoring.
The Purchasing Department of some company creates a document on Goods Movement. As soon as the document is saved, the department manager is sent a mail with a notification about creating such a document.
So, you are going to see now how easy, fast and convenient it is to create such an email for SAP notifications using Action Cards (Intelligent Decision Dimensions).
ABAP Classes Development Simplicity
The process of ABAP class development for notifications scenario consists of 2 main blocks.
1) Reading the document data (business objects).
2) Creating an HTML mail.
Here sending an HTML mail is a standardized algorithm step. It is referred either to custom implementation or implemented just once in the class of Mail_Bone
Now let us follow all the implementation steps in detail.
- ABAP class of /SKYBFR/CL_YCA1_ERP_MAIL_BONE
First, you are to inherit the class of /SKYBFR/CL_YCA1_ERP_MAIL_BONE into your own class – this is going to be the common core for all tasks on creating mails for simple notifications emailing on documents. In this class you are to redefine 4 separate methods on creating common corporate mail style.
- Let’s choose the email template (get_template) and determine the template name. Alternatively, you can organize reading this template from any source
- Header (get_header) – here we determine the mail subject and the company’s letterhead, that is, the name and the information string
- Addressing the receiver (get_sections) – here we create the salutation and the text addressed to the receiver.
- Signature (get_footer). Here we create any template phrase for the footer
- This class is created just once for all the documents types in the system.
- ABAP class of /SKYBFR/CL_YCA1_ERP_MAIL_MM_GR
In order to create a mail on a particular kind of document (Goods Movement in our case), we are to copy a demonstrational code of /SKYBFR/CL_YCA1_ERP_MAIL_MM_GR delivered with Action Cards (Intelligent Decision Dimensions), specify the core class created in the previous step as its parent class and redetermine the following methods.
- The method of filling the mail with the contents (get_sections) It effects reading the document and filling the mail with the data.
- Creating buttons (get_buttons). This method stipulates each button’s actions, words written, other additional information. In this article we have a sample mail without buttons.
This is going to be enough for simple notifications to be emailed according to documents without binding to the workflow.
All these classes use text elements. Also, our Add-On has an implemented method of switching to the language of a particular receiver which provides multilingual support when creating mails directly out-of-the-box.
As we can see from this example, this programming code is not too big, it can take from 1 to 3 hrs to program a code to create such a mail.
All you have to do in order to boost the implementation is to copy or inherit supplementary classes.
In case you need to implement a separate option, you are to redetermine the respected class method.
I would like to emphasize that the volume of a developed code is not too big as the main part of the functionality is already implemented in the Add-On.
SAP GUI example
Now we are going to open some backend system. Here we are opening the document on Goods Movement for which our notification mail has been created. To make it easier and more convenient for a person responsible for the Goods Movement approval, to spare him from the necessity to log in to the SAP system, our mail has the main elements of the document
- Details on the positions
As the result of calling the class method delivered in the Action Cards (Intelligent Decision Dimensions), we see the following mail created.
As we can see, this mail contains exactly the same details of the Goods Movement document as those shown in the previous step.
So, implementation of Skybuffer Action Cards (Intelligent Decision Dimensions) can significantly speed up development of SAP applications and utilities necessary to form, send and process incoming emails.