-
Notifications
You must be signed in to change notification settings - Fork 2
Installation Guide
Step 1: It's necessary to create a SAP Gateway service as picture bellow:
Step 2: Generate Runtime objects.
Follow Runtime Artifacts are expected (names could be slightly different):
It's necessary to "install" ABAP code in the class ending _DPC_EXT
, in the case showed above, ZCL_ZABAP_ACTIVE_RE_01_DPC_EXT
.
Step 3: Redefine following methods in ZCL_ZABAP_ACTIVE_RE_01_DPC_EXT
:
/IWBEP/IF_MGW_CORE_SRV_RUNTIME~CHANGESET_BEGIN
/IWBEP/IF_MGW_CORE_SRV_RUNTIME~CHANGESET_END
REQUESTSET_CREATE_ENTITY
REQUESTSET_UPDATE_ENTITY
RESULTSET_CREATE_ENTITY
RESULTSET_DELETE_ENTITY
RESULTSET_GET_ENTITY
RESULTSET_GET_ENTITYSET
RESULTSET_UPDATE_ENTITY
And create follow methods bellow:
-
GET_FIELDS_LIST
- Returning parameter:
RE_FIELDS_LIST TYPE TY_T_PARSE_PARAMETER
- Returning parameter:
-
GET_WHERE_CONDITIONS
- Returning parameter:
RE_WHERE_LIST TYPE TY_T_PARSE_PARAMETER
- Returning parameter:
-
ITAB_FACTORY
- Returning parameter:
RE_REF_TABLE TYPE REF TO DATA
- Returning parameter:
-
GET_FILLED_WORKAREA
- Returning parameter:
RE_WA_FILLED TYPE REF TO DATA
- Returning parameter:
Copy the content of files at ./abap into correspondent method.
In the PROTECTED SESSION.
include types from file ./abap/types.abap.
Activate whole class.
Step : 4 Download Files
You can clone the Github repository or download ZIP file.
Step : 5 Change file ./abapActiveRecord/abapar.json to point to your service URI.
To test your service, just open index.html file in your browser, enter your user/password for your service and you should get a screen like that:
Click on button "New Flight" and reload the page. A new flight should be created as bellow:
Click on button "Read" and follow value should be retrieved in the "Price" field:
Enter a new numeric value into "New Price" fiel, for example 350 and click on button "Change". Reload the page and new price should be changed in the table:
To delete the entity created, click in the button "Delete Flight" and the flight created above will be deleted. Don't forget to reload the page.
For questions/comments/bugs/feature requests/wishes please create an issue.