diff --git a/README.md b/README.md index 337072a6..83e436e5 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,7 @@ * Want to help out? see the contribution guidelines [(abap2UI5/contribution)](https://github.com/abap2UI5/abap2UI5/blob/main/CONTRIBUTING.md) #### Apps & Extensions -* Integrate your apps to the on-premise fiori laúnchpad [(abap2UI5/integration_fiori_launchpad)](https://github.com/abap2UI5/ext-integration_fiori_launchpad) +* Integrate your apps in launchpads and other services [(abap2UI5/ext-service_integration)](https://github.com/abap2UI5/ext-service_integration) * Try out abap2UI5-tools, a useful collection of tools & apps [(abap2UI5/tools)](https://github.com/abap2UI5/app-tools) * Check out other projects using abap2UI5 [(abap2UI5/links)](https://github.com/abap2UI5/abap2UI5/blob/main/docs/links.md) * And finally: Don't forget to explore the [Demo Repository 🧭](https://github.com/abap2UI5/abap2UI5-demos) @@ -79,6 +79,6 @@ METHOD if_http_service_extension~handle_request. ENDMETHOD. ``` #### FAQ -* check out this [documentation](https://blogs.sap.com/2023/04/14/abap2ui5-6-7-installation-configuration-debugging/) for detailed installation guidelines
-* want to configure the theme, bootstrapping, language and title? see [configuration & debugging](https://blogs.sap.com/2023/04/14/abap2ui5-6-7-installation-configuration-debugging/) +* check out the [documentation](https://blogs.sap.com/2023/04/14/abap2ui5-6-7-installation-configuration-debugging/) for installation & configuration guidelines +* still open questions? find an answer here [FAQ](https://github.com/abap2UI5/abap2UI5/blob/main/docs/faq.md) * as always - your comments, questions, wishes and bugs are welcome, please create an [issue](https://github.com/abap2UI5/abap2UI5/issues) diff --git a/docs/faq.md b/docs/faq.md index 9739b1a8..bf4d199e 100644 --- a/docs/faq.md +++ b/docs/faq.md @@ -7,20 +7,22 @@ DATA(lv_search) = client->get( )-s_config-search. DATA(lv_param) = z2ui5_cl_xml_view=>factory( client )->hlp_get_url_param( `myparam` ). ``` #### **2. How to format numbers, times and dates?** -Take a look to the following example: +Take a look to the following example:
https://github.com/abap2UI5/demo-demos/blob/main/src/z2ui5_cl_app_demo_47.clas.abap image #### **3. How to format the output of currencies?** -Take a look to the following example: +Take a look to the following example:
https://github.com/abap2UI5/demo-demos/blob/main/src/z2ui5_cl_app_demo_67.clas.abap image ## Productive Usage #### **1. Can abap2UI5 used in a productive system?** -abap2UI5 is technically a HTTP handler and can be used like any other HTTP Service also in a productive system. -#### **1. Are any preparations needed before using abap2UI5 in productiv scenario? - -abap2UI5 is technically a HTTP handler and can be used like any other HTTP Service also in a productive system. +Yes, the project is technically just an implementation of an HTTP handler and can be used like any other HTTP Service in a productive scenario. +#### **2. Are there any dependencies or preparations needed before using abap2UI5 in a productiv scenario?** +No, but it is recommended to follow these steps before using abap2UI5 apps in a productive scenario: +1. Transport the abap2UI5 HTTP service and the framework first. +2. Sometimes an extra activation of the HTTP service is needed, along with an adjustment of the UI5 bootstrapping. +3. Test the "hello world" app to ensure that abap2UI5 works correctly. #### **3. Does a stable version of abap2UI5 exist?** -The project will be continously further devleoped. Therefore there is now "stable" version, but adjustments to the public APIs will be reduced to a minimum to avoid refactoring of apps. Use the tags and only update from time to time when you use your apps also in production and want to reduce refactoring efforts. +The project will be continuously further developed. Therefore, there is no specific "stable" version. However, adjustments to the public APIs will be kept to a minimum to avoid frequent refactoring of apps. You can use [releases](https://github.com/abap2ui5/abap2ui5/releases/) instead of the main branch and only update from time to time when you want to reduce refactoring efforts. diff --git a/docs/installation/zcl_my_handler_cloud.abap b/docs/installation/zcl_my_handler_cloud.abap index df49ce54..5aed86a8 100644 --- a/docs/installation/zcl_my_handler_cloud.abap +++ b/docs/installation/zcl_my_handler_cloud.abap @@ -15,17 +15,14 @@ CLASS zcl_my_handler_cloud IMPLEMENTATION. METHOD if_http_service_extension~handle_request. - DATA(lt_tab) = request->get_header_fields( ). + DATA(lv_resp) = SWITCH #( server->request->get_method( ) + WHEN 'GET' THEN z2ui5_cl_http_handler=>http_get( ) + WHEN 'POST' THEN z2ui5_cl_http_handler=>http_post( server->request->get_cdata( ) ) ). - DATA(lv_resp) = SWITCH #( request->get_method( ) - WHEN 'GET' THEN z2ui5_cl_http_handler=>http_get( ) - WHEN 'POST' THEN z2ui5_cl_http_handler=>http_post( - body = request->get_text( ) - path_info = lt_tab[ name = `~path_info` ]-value ) ). - - response->set_header_field( i_name = 'cache-control' i_value = 'no-cache' ). - response->set_status( 200 )->set_text( lv_resp ). + server->response->set_header_field( name = `cache-control` value = `no-cache` ). + server->response->set_cdata( lv_resp ). + server->response->set_status( code = 200 reason = `success` ). ENDMETHOD. -ENDCLASS. \ No newline at end of file +ENDCLASS. diff --git a/docs/installation/zcl_my_handler_onprem.abap b/docs/installation/zcl_my_handler_onprem.abap index 913ac5d3..45275103 100644 --- a/docs/installation/zcl_my_handler_onprem.abap +++ b/docs/installation/zcl_my_handler_onprem.abap @@ -14,18 +14,12 @@ CLASS zcl_my_handler_onprem IMPLEMENTATION. METHOD if_http_extension~handle_request. - DATA lt_header TYPE tihttpnvp. - server->request->get_header_fields( CHANGING fields = lt_header ). - - DATA(lv_resp) = SWITCH #( server->request->get_method( ) + DATA(lv_resp) = SWITCH #( request->get_method( ) WHEN 'GET' THEN z2ui5_cl_http_handler=>http_get( ) - WHEN 'POST' THEN z2ui5_cl_http_handler=>http_post( - body = server->request->get_cdata( ) - path_info = lt_header[ name = `~path_info` ]-value ) ). + WHEN 'POST' THEN z2ui5_cl_http_handler=>http_post( request->get_text( ) ) ). - server->response->set_header_field( name = `cache-control` value = `no-cache` ). - server->response->set_cdata( lv_resp ). - server->response->set_status( code = 200 reason = `success` ). + response->set_status( 200 )->set_text( lv_resp + )->set_header_field( i_name = `cache-control` i_value = `no-cache` ). ENDMETHOD.