Skip to Content

If your company is using the “My Leave Requests” SAP Fiori application and also uses Microsoft Outlook then this blog might be for you. Below you see a list of my recently submitted leave request in Fiori. Wouldn’t it be nice to have this information also reflected in the Outlook Calendar?

GWPAM_Fiori1.jpg

Behind the scenes the Fiori application is powered by a SAP NetWeaver Gateway OData service called LEAVEREQUEST. This service can be used for different consumption experience beyond the Fiori UI. In this blog I will briefly discuss how you can utilize this service together with the SAP NetWeaver Gateway productivity accelerator for Microsoft to bring leave requests into your Microsoft Outlook Calendar.

If you are not yet familiar with the Appointment Template of SAP NetWeaver Gateway productivity accelerator for Microsoft, then you should take a look at this blog before you continue.

First I need to find the URL of the OData service. In the SAP NetWeaver Gateway system I navigate to Activate and Maintain Services (transaction /iwfnd/maint_service). In the Service Catalog I look for a service with the technical service name ZLEAVEREQUEST_2 (have not tried version 1 of the service).

Via the Call Browser button I get to the URL, which is required for the next step.

GWPAM_Fiori6.jpg
In my case the URL looks like this: http://<host>:<port>/sap/opu/odata/GBHCM/LEAVEREQUEST;v=2

In Microsoft Visual Studio, I create a new project based on the GWPAM Outlook 2010 Add-in template. The GWPAM wizard launches and here I provide a template name and chose Appointment as the template type.

GWPAM_Fiori7.jpg
Next, on the Service Details tab, I enter the URL and click on the GO button, which prompts me to authenticate against the Gateway system. In the Collection Name dropdown list I select the LeaveRequestCollection entry.

As for the mapping instruction I keep it simple and only map 3 fields (which I will have to enhance later in coding):

Service Properties Outlook Properties
Leave Type Subject
Start date Start
End date End

I am not tweaking the Custom Properties. By default I will get all of them. I also skip over the Associated Properties to keep things simple.

GWPAM_Fiori8.jpg
That’s it. I click on the Finish button to generate the project. Once generated, I set my user id and password in the BusinessConnectivityHelper class. I use Basic Authentication to keep things simple, but GWPAM does also support X.509 and SAML 2.0. Now I give this a try to see the “plain-vanilla” solution that GWPAM generated. From Outlook I click on the GetAll button to retrieve the data through the Fiori OData Service and now I see the leave requests in my Outlook Calendar:GWPAM_Fiori9.jpg

The calendar entries you see correspond to the ones you see in the Fiori application above. Below you see one of the leave requests with the Subject, Start and End populated with data from the SAP HR system:
 
Looking at the auto-generated user property folder, here you see all additional data that the OData service offers:
GWPAM_Fiori3.jpg
I hope you are excited by now. But you might be saying: Pretty cool, but a bit plain. Ok, this is where your work starts to enhance the generated coding to take full advantage of the SAP data and map it into the proper fields and formats of an Outlook Appointment. Example: The HR Leave Status (posted vs. approved) could determine the Appointment Busy Status (tentative vs. out-of-office). In the screenshot below I have done a couple of simple tweaks to the .NET coding:

GWPAM_Fiori5.jpg
Of course this could be taken even further to allow the creation or changes of a leave request from Outlook, which I will not touch on in this blog. The sky is the limit? Almost, more precisely, the OData service, the .NET  framework and your skills are the limits. 😉

SAP Fiori has many other scenarios that fit really well into Outlook. I hope to post a follow-up blog on some other scenarios. Please leave your feedback and comments of scenarios you have tried.

Update: In the meantime I have written another blog on how to bring the SAP Fiori My Contacts to Outlook. I hope you find it helpful.

To report this post you need to login first.

4 Comments

You must be Logged on to comment or reply to a post.

    1. Holger Bruchelt

      Hi Olivier,

      thanks — very nice video! This is really a great example showing the flexibilty that comes when building scenarios on top of SAP Gateway!

      (0) 
  1. Kavitha G

    Hi,

    Is it possible to send the outlook calendar details to a SAP UI5 / Fiori screen? For example, for a selected period of time for which a user is applying for leave, if i want to retrieve the meeting details along with meeting host names and display this information in the Fiori screen. Would that be possible? If yes, how? Also, I would like to provide an option for the user to send leave notifications to the hosts of the meetings (which should be possible if I achieve step 1).

    Thanks!

    (0) 
    1. Holger Bruchelt

      Hi Kavitha,

      sorry for the late reply. Right now SAP Gateway for Microsoft concentrates on the integration of SAP data in Microsoft UIs (e.g. Outlook). What you are asking for is the other way around: integrating Microsoft data in SAP UIs (e.g. Fiori). This is currently not in scope.

      If you have requirements / thoughts in this direction, shoot me an email and I would be happy to discuss this further with you.

      Regards, Holger.

      (0) 

Leave a Reply