Enhancing Mobile Development Kit Projects with Joule¶
This guide will walk you through the steps to effectively leverage Joule to enhance your new/existing Mobile Development Kit projects. This feature allows you to automate the generation of essential app definitions—such as pages and actions — thereby streamlining the creation of metadata and improving efficiency and consistency throughout your development process.
Additionally, Joule can automate the creation of translation files in multiple languages directly from a source file (i18n.properties) that contains key-value string pairs. This functionality ensures that your applications are not only efficient but also easily adaptable to diverse linguistic requirements.
By integrating Joule into your Mobile Development Kit projects, you can focus more on innovation while reducing the manual effort involved in repetitive tasks.
Note
To access the Mobile Development Kit genie commands for Joule you must open the base project from the root folder.
Generating Mobile Development Kit Page¶
- In SAP Business Application Studio, open the AI assistant, Joule, from the activity bar. If you do not see the icon, click Additional Views and select Joule from the list.
- Select the
/mdk-gen-page Generate MDK Page
command. - Choose a
MDK Service File
from the list. - You can either compose a prompt based on your requirements or use the sample prompt provided by Joule.
- Click the send icon to send the prompt to Joule.
- Code for the prompted Mobile Development Kit page, and the corresponding rules are generated and displayed below your prompt.
- Review the code snippets and click Accept to save the code under the Pages and Rules folders, respectively.
Note
Only the following section types are supported in Mobile Development Kit pages:
Contact Cell
KeyValue
ObjectHeader
ObjectTable
SimpleProperty Collection
Form Cell
CardCollection
Generating Mobile Development Kit Action¶
- In SAP Business Application Studio, open the AI assistant, Joule, from the activity bar. If you do not see the icon, click Additional Views and select Joule from the list.
- Select the
/mdk-gen-action Generate MDK Action
command. - Choose a
MDK Service File
from the list. - You can either compose a prompt based on your requirements or use the sample prompt provided by Joule.
- Click the send icon to send the prompt to Joule.
- Code for the prompted Mobile Development Kit action is generated and displayed below your prompt.
- Review the code snippets and click Accept to save the code under the Action folder.
Note
Only the following action types are supported:
OData:
CreateODataEntity
CreateODataMedia
UploadODataMedia
CreateODataService
DeleteODataEntity
DeleteODataMedia
DownloadMediaOData
DownloadOfflineOData
DownloadStreamOData
InitializeOData
UndoPendingChanges
UpdateODataEntity
UploadStreamOData
UploadOfflineOData
CancelUploadOfflineOData
CancelDownloadOfflineOData
ReadODataService
CreateODataRelatedEntity
CreateODataRelatedMedia
RemoveDefiningRequest
ClearOfflineOData
Close Offline OData
Initialize Offline OData
Open OData Service
Logging:
LogMessage
Upload
SetState
SetLevel
Messaging:
Message
ProgressBanner
ToastMessage
Navigation:
Navigation
Push:
PushNotificationRegister
PushNotificationUnregister
Rest:
SendRequest
Generating Translation Files¶
- In SAP Business Application Studio, open the AI assistant, Joule, from the activity bar. If you do not see the icon, click Additional Views and select Joule from the list.
- Select the
/mdk-gen-i18n Generate MDK i18n File
command. - Choose the default i18n file to proceed.
- You can either compose a prompt based on your requirements or use the sample prompt provided by Joule.
- Click the send icon to send the prompt to Joule.
- Translation files are generated and displayed below your prompt.
- Review the files and click Accept to save the files under the i18n folder.
- You can either choose the Merge file option to append any new changes to existing files, or select Overwrite file to completely replace an existing file with the new changes.