Professional Documents
Culture Documents
• Executive Summary
• Short Demo
• Problem:
You want to leverage a new proprietary Fiori App with your SAP system on premise
• Solution:
Create an Fiori App accessing your SAP on IBM z Systems with Eclipse
• How to:
- Learn via sample Fiori App
- Use an IDES Installation because it already contains a SAP Gateway setup
(IDES ECC 6.0 incl. EhP7 Edition 2 (2015))
- Select common scenario: SAP Business Suite ‘Purchase Order Approval’ application
- Implement sample described in two SAP Community Network blogs
• IBM Bluemix
• Modern and fast dev. environment; offers
„MobilFirst Services Starter“ boilerplate*
• For Apps which access both SAP and Cloud
APIs
• Public Cloud deployment
* boilerplate: contains an app and its associated runtime environment and predefined services for a particular domain.
* https://de.wikipedia.org/wiki/HTML5 ** http://scn.sap.com/docs/DOC-53949
Only transactional Fiori Apps run currently on Any DB Option: HANA as a sidecar
• The ModelProviderClass (MPC) is used to define the model, e.g. method ‘Define’ creates entity,
properties, etc.
• The DataProviderClass (DPC) is used to code your CRUD methods as well as function import
methods. All the logic must be coded in redefined methods of DPC extension class.
• The UI is coded in JavaScript and XML
See http://scn.sap.com/docs/DOC-46223
and refer to Generated ABAP Classes and Service Registration - SAP NetWeaver Gateway - SAP Library
SAP Gateway:
Handles communication between client and SAP backend
applications using OData services and processes HTTPS
request for the OData services
Makes your SAP business data and functionality accessible to
any external device
Details
Details
Alternative deployment on SAP HANA Cloud Platform
SAP Mobile Platform Tools, which contains the Ogee OData plugin
SAP UI5 Development Toolkit; SAP UI5 application preview runs on the Jetty web server
Jetty provides Web services in an embedded Java application and it is already a component of the Eclipse IDE (started as open
source project and moved in 2009 to Eclipse); https://en.wikipedia.org/wiki/Jetty_(web_server)
1. Create backend ABAP code (available on Github) via SAPlink report as described in
‚Fiori-like SCN Part I‘
2. Create OData model as Entity Data Model in Eclipse and export it
3. Activate SAP Gateway as described in ‚Gateway SCN step 1‘
4. In mandant with Purchase Order data:
Create a new SAP Gateway project (described in ‚Gateway SCN‘ step 2) and import
OData Model into SAP Gateway via SEGW transaction
5. Adapt Model and create code for the data access (CRUD) methods
6. Activate service in Gateway via SPRO transaction (described in ‚Gateway SCN‘ step 4)
7. Create „Fiori“ UserInterface (UI) App with SAPUI5 Development Toolkit in Eclipse as
described in ‚Fiori-like SCN Part II‘
8. Adapt sample ABAP code to retrieve ‘real pending approval data’ from IDES system
Remark: More details, hints, remarks and recommendations can be found in the backup foils
Hint: Odata model was not correct in our SAP Gateway, see comment:
• Adapt Model and create code for the data access (CRUD) methods
Hint: Code should be already available via SLINK import of frist step
• Create „Fiori“ UserInterface (UI) App with SAPUI5 Development Toolkit in Eclipse as
described in ‚Fiori-like SCN Part II‘
• Adapt in component.js the line
var url = "proxy/http/<host>:<port>/sap/opu/odata/sap/ZPOAPPROVAL_SRV/";
with the real SAP System host, port and service name, if you have used a different one and the line
var oModel = new sap.ui.model.odata.ODataModel(url, true, "<user>", "<pass>");
with a valid SAP System userid and password
Hint: "Target Device" does no longer exist in panel --> select Libray ‘sap.m’
• Remark: Userid and password are hardcoded and anybody knowing the URL can access the backend data!
• Recommendation: In order to get an understanding of the UI fundamentals, do the 10 exercises described in SCN “Building SAP Fiori-like
UIs with SAPUI5 in 10 Exercises” SCN paper link
• Test: Select project, right click and ‘Run As’ ‘Web App Preview’
• Problem of sample ABAP code with IDES system
• In class Z_MM_PO and method GET_PENDING_APPROVAL the value ‘Z1’ defined for:
constants: lc_frggr type frggr value 'Z1'. "Release group from Purchase Orders in your system
did not deliver any Purchase Orders and had to be adapted:
constants: lc_frggr type frggr value 'PO'. "Release group from Purchase Orders in your system
Hint: Check with transaction me28, which combination of Release group (and Release code) is used in your environment.
It may be necessary to adapt also value of constants: lc_released type frggr value 'C'. "Code for "released" in your system
Hint: If your z<eclipse project> name is longer than 15 char, you can copy the project using a name with less than 15 chars
Use transactions /IWBEP/CACHE_CLEANUP and /IWFND/CACHE_CLEANUP to clean services caches and
SMICM (-> Goto -> HTTP-PlugIn -> Server Cache -> Invalidate Globally) to clean ICM cache
• Remark: SAP developer access key is needed
4) In ‚Favourite bar‘ select „VS Fiori Lauchpad“; login into client 800 ...
5) In Firefox: Show your bookmarks -> Recently Bookmarked -> VS Fiori Launchpad ...
Or:
6) Start eclipse with workplace “C:\Users\IBM_ADMIN\workspace “ (old TP "D:\temp\eclipse\workspace\VSFirstBMDemoApp“
7) Select FioriLikePOApproval project (old TP: SAPUI5POApproval) and right click -> Run As -> Web App Preview
Summary
start
Thank you
Volker Schoelles
volker_schoelles@de.ibm.com
• SAP Gateway offers connectivity to SAP applications using any programming language
or model without the need for SAP knowledge by leveraging REST services and OData
protocol.
• Odata (The Open Data Protocol) is an open web protocol for querying and updating
data (CRUD methods). The protocol allows for a consumer to query a data source over
the HTTP protocol and get the result back in formats like Atom, JSON or plain XML.
For a simple overview see http://scn.sap.com/docs/DOC-35472
Skills:
ABAP & in OData Services
OOPs ABAP and BAPI, RFC
Eclipse, HTML5, JavaScript
DevOps
Development, monitoring, deployment and
logging tools allow the developer to run the
entire application
Cloud Integration
Build hybrid environments. Connect to on-
premises systems of record plus other public
and private clouds. Expose your own APIs to
your developers.
All other product and service names mentioned are the trademarks of their respective companies.
Data contained in this document serves informational purposes only. National product specifications may vary.
Notes:
Performance is in Internal Throughput Rate (ITR) ratio based on measurements and projections using standard IBM benchmarks in a controlled environment. The actual throughput that
any user will experience will vary depending upon considerations such as the amount of multiprogramming in the user's job stream, the I/O configuration, the storage configuration, and the
workload processed. Therefore, no assurance can be given that an individual user will achieve throughput improvements equivalent to the performance ratios stated here.
IBM hardware products are manufactured from new parts, or new and serviceable used parts. Regardless, our warranty terms apply.
All customer examples cited or described in this presentation are presented as illustrations of the manner in which some customers have used IBM products and the results they may have
achieved. Actual environmental costs and performance characteristics will vary depending on individual customer configurations and conditions.
All statements regarding IBM's future direction and intent are subject to change or withdrawal without notice, and represent goals and objectives only.
Information about non-IBM products is obtained from the manufacturers of those products or their published announcements. IBM has not tested those products and cannot confirm the
performance, compatibility, or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products.
IBM’s statements regarding its plans, directions, and intent are subject to change or withdrawal without notice at IBM’s sole discretion. Information
regarding potential future products is intended to outline our general product direction and it should not be relied on in making a purchasing decision.
The information mentioned regarding potential future products is not a commitment, promise, or legal obligation to deliver any material, code or
functionality. Information about potential future products may not be incorporated into any contract. The development, release, and timing of any future
features or functionality described for our products remains at our sole discretion.
Performance is based on measurements and projections using standard IBM benchmarks in a controlled environment. The
actual throughput or performance that any user will experience will vary depending upon many factors, including
considerations such as the amount of multiprogramming in the user’s job stream, the I/O configuration, the storage
configuration, and the workload processed. Therefore, no assurance can be given that an individual user will achieve results
similar to those stated here.
Availability. References in this presentation to IBM products, programs, or services do not imply that they will be available in all countries in which IBM
operates.
The workshops, sessions and materials have been prepared by IBM or the session speakers and reflect their own views. They are provided for
informational purposes only, and are neither intended to, nor shall have the effect of being, legal or other guidance or advice to any participant. While
efforts were made to verify the completeness and accuracy of the information contained in this presentation, it is provided AS-IS without warranty of any
kind, express or implied. IBM shall not be responsible for any damages arising out of the use of, or otherwise related to, this presentation or any other
materials. Nothing contained in this presentation is intended to, nor shall have the effect of, creating any warranties or representations from IBM
or its suppliers or licensors, or altering the terms and conditions of the applicable license agreement governing the use of IBM software.
All customer examples described are presented as illustrations of how those customers have used IBM products and the results they may have
achieved. Actual environmental costs and performance characteristics may vary by customer. Nothing contained in these materials is intended to, nor
shall have the effect of, stating or implying that any activities undertaken by you will result in any specific sales, revenue growth or other results.