Creating an SAP Fiori Smart Template Application
Recently I attended the openSAP course Build You Own Fiori App in the Cloud (2016) where Smart Templates was part of it. With this blog post I want to share my experiences and show you a demo how to build a Smart Template app with SAP Web IDE.
Smart Templates strictly follow SAPs Fiori design guidelines. Without any coding you describe the application screens and behavior using Floorpans and annotations. Annotations provided by the OData service in the SAP backend help the app to understand the data model and its semantics.
Let’s start by creating a new project from template in SAP Web IDE. At the time of writing, only one Smart Template application template is available.
This completes my demo.
Smart Templates are an easy and quick way to visualize and mobilize data from an SAP backend system. To setup the demo app, it took me about four hours, and I only did the exercises from the openSAP course before and had no other training on Smart Templates. If you understand the principles of Smart Templates, you can build the app really fast. And if SAP provides other Floorplans as Smart Templates (what I am sure they’ll do) in the future, Smart Templates will become an even more productive way of implementing Fiori apps.
Some findings and personal opinions about restrictions I see compared to programmed Fiori-based apps. I know this is by design because Smart Templates are supposed to be coding-free and therefore it’s obvious that apps developed in SAPUI5 are more powerful. Nevertheless I want to point out my findings to help you decide whether Smart Templates are the better choice for your app. Btw, the list contains my findings and is neither complete nor 100 % validated. Maybe there is a solution that I didn’t find.
- The OData service needs to be very powerful and, eventually, tailored to your Smart Template app or at least to your business case. For example, what I already mentioned, you cannot bind controls to complex types’ properties. In SAPUI5 you could implement that via the controller if necessary.
- Obviously, the OData service must support annotations to be used in Smart Template apps (in contrast to general SAPUI5 apps where this is not mandatory).
- There is no way to format a date, like in the sales order items list where the delivery date is displayed as timestamp and not as date.
- There is no way to format anything, for example remove the leading zeros at IDs (business partner ID, sales order ID, item position). Solution would be that the OData service delivers the IDs without leading zeros already but this puts another restriction on the OData service.
I would appreciate very much any feedback in the comments section.