Firstly let me apologise in advance for the long and rambling post. I’m not even sure that this is the best discussion group to ask and if so feel free to shoo me elsewhere…
My client has a workforce of 1,500 field workers using Windows 7 Laptops to run a bespoke application that I wrote using .NET C# WPF and the MVVM pattern. The client now wants to move to SAPUI5 for ALL bespoke applications. I therefore need to get into SAPUI5 and as a place to start I thought I would look at recreating this app in SAPUI5.
To do this I need to address the following issues:
- Local Working. The users have no LAN or wireless access to the network. Each Laptop contains a SIM card which connects to the corporate network via an APN. The users are in a rural area and have no network access most of the time. It is typical for users to be offline for days on end. Data that users capture are saved locally to a MS SQL compact database on the hard disk and the data are copied to the network when they get a network connection. So I need to create a web app that works without a web server. I think this can be addressed by simply copying the SAPUI resources folder locally to each laptop ?
- Access to local hard disk. Copying the SAPUI resources folder locally should let users fire up SAPUI5 web pages without a web server, but traditionally web
applications are not allowed to access local resources like the hard disk. The application needs to be able to save data to a local database until it can be
copied up to the network. I could use Chrome as the web browser and start it with the --allow-file-access and -disable-web-security, but although that might
be OK for development it hardly feels suitable for production. What can I do ? - Access the Laptop built in camera. The laptop manufacturer supplies an SDK to provide access to the camera from applications. The SDK contains c++, .NET and JAVA versions of the code. I guess, given that SAPUI5 is javascript based that I need to be able to call one of them from JavaScript ? This doesn’t seem possible. I have seen references to Rhino JavaScript accessing JAVA packages, but I don’t think that will help here because whatever the browser is (we currently use IE, but I could use whatever we want), it won’t have Rhino as its script engine.
- Access .NET dlls. All of the business logic in the existing app is written in .NET, compiled into dlls. It would be great to be able to call these dlls from my client side code. Is this possible ? In effect I would like to just replace the WPF GUI in the current app with a SAPUI5 GUI. What the client wants
is to see SAPGUI. They don’t actually care what is under the hood. In fact could I stick with my .NET app and just “plug in” the SAPUI5 controls, so the
application remains a native .NET app but looks like SAPUI5 ? If it is possible to access my .NET dlls from SAPUI5 this would address issue 3 too – since I could access the .NET dll provided by the Laptop manufacturer for camera functionality. - Cordova. It has been suggested that all the above issues go away if I simply create a SAPUI5 web application, use Cordova to wrapper it and deploy the cordova app to the laptops. Is this true ? It seems unlikely and I’m not even sure if cordova works for “real” Windows 7, as opposed to Windows Phone. Most sites I have seen don’t mention Windows as a target. Although the current environment is Windows 7, the laptops are scheduled for upgrade to windows 8.x soon, if this helps.
As you can see from the above I really have no idea what I am talking about – all this stuff is totally outside my sphere of knowledge which is .NET apps. I do think that the correct answer to all the above is that SAPUI5 is not the right choice to address these business requirements and a native desktop app is the best approach. Unfortunately I don’t have a say in that (unless some sort of SAPUI5 solution is actually physically not possible).
Comments anyone ?
Martin