mirror of
https://github.com/abap2UI5/abap2UI5.git
synced 2025-04-29 02:58:20 +08:00
parent
91fe7aac29
commit
9fe77d9555
|
@ -3,7 +3,7 @@
|
|||
<asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
|
||||
<asx:values>
|
||||
<DEVC>
|
||||
<CTEXT>abap2UI5 - apps and demos</CTEXT>
|
||||
<CTEXT>abap2UI5 - demos and view helper</CTEXT>
|
||||
</DEVC>
|
||||
</asx:values>
|
||||
</asx:abap>
|
||||
|
|
|
@ -91,10 +91,10 @@ CLASS z2ui5_cl_app_demo_00 IMPLEMENTATION.
|
|||
)->button( text = 'Import UI5-XML-View' press = client->_event( 'z2ui5_cl_app_demo_31' )
|
||||
)->button( text = 'HTML, JS, CSS' press = client->_event( 'z2ui5_cl_app_demo_29' )
|
||||
).
|
||||
*
|
||||
* grid->simple_form( title = 'HowTo - Messages' layout = 'ResponsiveGridLayout' )->content( 'f'
|
||||
* )->button( text = 'Messages (Toast, Box, Strip)' press = client->_event( 'z2ui5_cl_app_demo_08' )
|
||||
* ).
|
||||
|
||||
grid->simple_form( title = 'HowTo - Messages' layout = 'ResponsiveGridLayout' )->content( 'form'
|
||||
)->button( text = 'Messages (Toast, Box, Strip)' press = client->_event( 'z2ui5_cl_app_demo_08' )
|
||||
).
|
||||
|
||||
DATA(form) = page->grid( 'L9 M12 S12'
|
||||
)->content( 'l'
|
||||
|
|
|
@ -41,6 +41,7 @@ CLASS z2ui5_cl_app_demo_01 IMPLEMENTATION.
|
|||
)->link(
|
||||
text = 'Source_Code'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
target = '_blank'
|
||||
)->get_parent(
|
||||
)->simple_form( title = 'Form Title' editable = abap_true
|
||||
)->content( 'form'
|
||||
|
|
|
@ -115,8 +115,8 @@ CLASS Z2UI5_CL_APP_DEMO_02 IMPLEMENTATION.
|
|||
navbuttonpress = client->_event( 'BACK' )
|
||||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link( text = 'Demo' href = `https://twitter.com/OblomovDev/status/1628701535222865922`
|
||||
)->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( text = 'Demo' target = '_blank' href = `https://twitter.com/OblomovDev/status/1628701535222865922`
|
||||
)->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
DATA(grid) = page->grid( 'L6 M12 S12'
|
||||
|
|
|
@ -54,7 +54,7 @@ CLASS Z2UI5_CL_APP_DEMO_03 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -98,7 +98,7 @@ CLASS Z2UI5_CL_APP_DEMO_05 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -80,7 +80,7 @@ CLASS Z2UI5_CL_APP_DEMO_06 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -168,8 +168,8 @@ CLASS z2ui5_cl_app_demo_07 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content( ns = 'm'
|
||||
)->toolbar_spacer( ns = 'm'
|
||||
)->link( ns = 'm' text = 'Demo' href = 'https://twitter.com/OblomovDev/status/1638487600930357248'
|
||||
)->link( ns = 'm' text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( ns = 'm' text = 'Demo' target = '_blank' href = 'https://twitter.com/OblomovDev/status/1638487600930357248'
|
||||
)->link( ns = 'm' target = '_blank' text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
page->text( ns = 'm' text = 'Custom Control for File Upload is now loaded.'
|
||||
|
|
|
@ -59,7 +59,7 @@ CLASS Z2UI5_CL_APP_DEMO_08 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -214,10 +214,10 @@ CLASS Z2UI5_CL_APP_DEMO_09 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Demo'
|
||||
text = 'Demo' target = '_blank'
|
||||
href = 'https://twitter.com/OblomovDev/status/1637470531136921600'
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -31,10 +31,10 @@ CLASS Z2UI5_CL_APP_DEMO_10 IMPLEMENTATION.
|
|||
)->button( text = 'button'
|
||||
)->text( 'text'
|
||||
)->link(
|
||||
text = 'link'
|
||||
text = 'link' target = '_blank'
|
||||
href = 'https://twitter.com/OblomovDev'
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
).
|
||||
|
||||
|
|
|
@ -67,10 +67,10 @@ CLASS Z2UI5_CL_APP_DEMO_11 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Demo'
|
||||
text = 'Demo' target = '_blank'
|
||||
href = 'https://twitter.com/OblomovDev/status/1630240894581608448'
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -89,7 +89,7 @@ CLASS Z2UI5_CL_APP_DEMO_12 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -166,10 +166,10 @@ CLASS Z2UI5_CL_APP_DEMO_13 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Demo'
|
||||
text = 'Demo' target = '_blank'
|
||||
href = `https://twitter.com/OblomovDev/status/1634206964291911682`
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->sub_header(
|
||||
|
|
|
@ -56,8 +56,8 @@ CLASS Z2UI5_CL_APP_DEMO_14 IMPLEMENTATION.
|
|||
navbuttonpress = client->_event( 'BACK' )
|
||||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link( text = 'Demo' href = 'https://twitter.com/OblomovDev/status/1631562906570575875'
|
||||
)->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( text = 'Demo' target = '_blank' href = 'https://twitter.com/OblomovDev/status/1631562906570575875'
|
||||
)->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
DATA(grid) = page->grid( 'L7 M12 S12' )->content( 'l' ).
|
||||
|
|
|
@ -41,7 +41,7 @@ CLASS Z2UI5_CL_APP_DEMO_15 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->toolbar_spacer(
|
||||
)->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->vbox( 'sapUiSmallMargin'
|
||||
)->link(
|
||||
|
|
|
@ -66,7 +66,7 @@ CLASS Z2UI5_CL_APP_DEMO_16 IMPLEMENTATION.
|
|||
)->grid( 'XL6 L6 M6 S12' ).
|
||||
|
||||
grid->link(
|
||||
text = 'Go to the SAP Demos for Interactive bar Charts here...'
|
||||
text = 'Go to the SAP Demos for Interactive bar Charts here...' target = '_blank'
|
||||
href = 'https://sapui5.hana.ondemand.com/#/entity/sap.suite.ui.microchart.InteractiveBarChart/sample/sap.suite.ui.microchart.sample.InteractiveBarChart'
|
||||
)->text(
|
||||
text = 'Absolute and Percentage value'
|
||||
|
@ -131,7 +131,7 @@ CLASS Z2UI5_CL_APP_DEMO_16 IMPLEMENTATION.
|
|||
)->grid( 'XL6 L6 M6 S12' ).
|
||||
|
||||
grid->link(
|
||||
text = 'Go to the SAP Demos for Interactive Donut Charts here...'
|
||||
text = 'Go to the SAP Demos for Interactive Donut Charts here...' target = '_blank'
|
||||
href = 'https://sapui5.hana.ondemand.com/#/entity/sap.suite.ui.microchart.InteractiveDonutChart/sample/sap.suite.ui.microchart.sample.InteractiveDonutChart'
|
||||
)->text(
|
||||
text = 'Three segments'
|
||||
|
@ -203,7 +203,7 @@ CLASS Z2UI5_CL_APP_DEMO_16 IMPLEMENTATION.
|
|||
DATA(grid) = tab->grid( 'XL6 L6 M6 S12' ).
|
||||
|
||||
grid->link(
|
||||
text = 'Go to the SAP Demos for Interactive Line Charts here...'
|
||||
text = 'Go to the SAP Demos for Interactive Line Charts here...' target = '_blank'
|
||||
href = 'https://sapui5.hana.ondemand.com/#/entity/sap.suite.ui.microchart.InteractiveLineChart/sample/sap.suite.ui.microchart.sample.InteractiveLineChart' ).
|
||||
|
||||
grid->text(
|
||||
|
@ -283,7 +283,7 @@ CLASS Z2UI5_CL_APP_DEMO_16 IMPLEMENTATION.
|
|||
)->grid( 'XL12 L12 M12 S12' ).
|
||||
|
||||
grid->link(
|
||||
text = 'Go to the SAP Demos for Radial Charts here...'
|
||||
text = 'Go to the SAP Demos for Radial Charts here...' target = '_blank'
|
||||
href = 'https://sapui5.hana.ondemand.com/#/entity/sap.suite.ui.microchart.RadialMicroChart/sample/sap.suite.ui.microchart.sample.RadialMicroChart' ).
|
||||
|
||||
grid->vertical_layout(
|
||||
|
@ -370,8 +370,8 @@ CLASS Z2UI5_CL_APP_DEMO_16 IMPLEMENTATION.
|
|||
navbuttonpress = client->_event( 'BACK' )
|
||||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link( text = 'Demo' href = `https://twitter.com/OblomovDev/status/1639191954285113344`
|
||||
)->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( text = 'Demo' target = '_blank' href = `https://twitter.com/OblomovDev/status/1639191954285113344`
|
||||
)->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->tab_container( ).
|
||||
|
||||
|
|
|
@ -80,7 +80,7 @@ CLASS z2ui5_cl_app_demo_18 IMPLEMENTATION.
|
|||
"set the data for the frontend
|
||||
client->set_next( app-next ).
|
||||
|
||||
"the app is serialized and persisted, we delete all data which is not needed in the future before
|
||||
"the app will be serialized and persisted, we delete all data which is not needed in the future before
|
||||
CLEAR app-get.
|
||||
CLEAR app-next.
|
||||
|
||||
|
@ -131,7 +131,7 @@ CLASS z2ui5_cl_app_demo_18 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->simple_form( title = 'VIEW_MAIN' editable = abap_true
|
||||
|
|
|
@ -61,10 +61,10 @@ CLASS Z2UI5_CL_APP_DEMO_19 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Demo'
|
||||
text = 'Demo' target = '_blank'
|
||||
href = 'https://twitter.com/OblomovDev/status/1637852441671528448'
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
|
|
|
@ -80,10 +80,10 @@ CLASS Z2UI5_CL_APP_DEMO_21 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Demo'
|
||||
text = 'Demo' target = '_blank'
|
||||
href = 'https://twitter.com/OblomovDev/status/1637163852264624139'
|
||||
)->link(
|
||||
text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
DATA(grid) = page->grid( 'L8 M12 S12' )->content( 'l' ).
|
||||
|
|
|
@ -108,7 +108,7 @@ CLASS Z2UI5_CL_APP_DEMO_22 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
).
|
||||
|
||||
page->header_content( )->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) ) ).
|
||||
page->header_content( )->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) ) ).
|
||||
|
||||
|
||||
page->input(
|
||||
|
|
|
@ -56,8 +56,8 @@ CLASS z2ui5_cl_app_demo_24 IMPLEMENTATION.
|
|||
DATA(view) = z2ui5_cl_xml_view_helper=>factory(
|
||||
)->page( title = 'abap2UI5 - flow logic - APP 01' navbuttonpress = client->_event( 'BACK' ) shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link( text = 'Demo' href = `https://twitter.com/OblomovDev/status/1640743794206228480`
|
||||
)->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( text = 'Demo' target = '_blank' href = `https://twitter.com/OblomovDev/status/1640743794206228480`
|
||||
)->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
|
||||
)->grid( 'L6 M12 S12' )->content( 'l'
|
||||
|
|
|
@ -70,8 +70,8 @@ CLASS z2ui5_cl_app_demo_25 IMPLEMENTATION.
|
|||
title = 'abap2UI5 - flow logic - APP 02'
|
||||
navbuttonpress = client->_event( 'BACK' ) shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link( text = 'Demo' href = `https://twitter.com/OblomovDev/status/1640743794206228480`
|
||||
)->link( text = 'Source_Code' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->link( text = 'Demo' target = '_blank' href = `https://twitter.com/OblomovDev/status/1640743794206228480`
|
||||
)->link( text = 'Source_Code' target = '_blank' href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent( ).
|
||||
|
||||
page->grid( 'L6 M12 S12' )->content( 'l'
|
||||
|
|
|
@ -105,7 +105,7 @@ CLASS Z2UI5_CL_APP_DEMO_26 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->simple_form( 'Popover'
|
||||
|
|
|
@ -105,7 +105,7 @@ CLASS Z2UI5_CL_APP_DEMO_27 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->simple_form( title = 'Binding Syntax' editable = abap_true
|
||||
|
|
|
@ -22,8 +22,8 @@ CLASS z2ui5_cl_app_demo_28 DEFINITION PUBLIC.
|
|||
check_initialized TYPE abap_bool,
|
||||
view_main TYPE string,
|
||||
view_popup TYPE string,
|
||||
s_get TYPE z2ui5_if_client=>ty_s_get,
|
||||
s_next TYPE z2ui5_if_client=>ty_s_next,
|
||||
get TYPE z2ui5_if_client=>ty_s_get,
|
||||
next TYPE z2ui5_if_client=>ty_s_next,
|
||||
END OF app.
|
||||
|
||||
METHODS z2ui5_on_init.
|
||||
|
@ -41,7 +41,7 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
METHOD z2ui5_if_app~controller.
|
||||
|
||||
me->client = client.
|
||||
app-s_get = client->get( ).
|
||||
app-get = client->get( ).
|
||||
app-view_popup = ``.
|
||||
|
||||
IF app-check_initialized = abap_false.
|
||||
|
@ -49,22 +49,22 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
z2ui5_on_init( ).
|
||||
ENDIF.
|
||||
|
||||
IF app-s_get-event IS NOT INITIAL.
|
||||
IF app-get-event IS NOT INITIAL.
|
||||
z2ui5_on_event( ).
|
||||
ENDIF.
|
||||
|
||||
z2ui5_on_render( ).
|
||||
|
||||
client->set_next( app-s_next ).
|
||||
CLEAR app-s_get.
|
||||
CLEAR app-s_next.
|
||||
client->set_next( app-next ).
|
||||
CLEAR app-get.
|
||||
CLEAR app-next.
|
||||
|
||||
ENDMETHOD.
|
||||
|
||||
|
||||
METHOD z2ui5_on_event.
|
||||
|
||||
CASE app-s_get-event.
|
||||
CASE app-get-event.
|
||||
|
||||
WHEN 'BUTTON_POST'.
|
||||
* client->popup_message_toast( |{ product } { quantity } - send to the server| ).
|
||||
|
@ -74,12 +74,31 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
client->popup_message_toast( |confirm| ).
|
||||
app-view_popup = ''.
|
||||
|
||||
WHEN 'TIMER_FINISHED'.
|
||||
|
||||
FIELD-SYMBOLS <mt_draft> TYPE STANDARD TABLE.
|
||||
|
||||
" OF z2ui5_t_draft.
|
||||
ASSIGN mt_draft->* TO <mt_draft>.
|
||||
|
||||
SELECT FROM z2ui5_t_draft
|
||||
FIELDS *
|
||||
ORDER BY uuid
|
||||
INTO TABLE @DATA(lt_data)
|
||||
UP TO 2 ROWS
|
||||
.
|
||||
APPEND LINES OF lt_data TO <mt_draft>.
|
||||
"!"mt_draft->* = CORRESPONDING #( lt_data ).
|
||||
"!
|
||||
app-next-s_timer-interval_ms = '2000'.
|
||||
app-next-s_timer-event_finished = 'TIMER_FINISHED'.
|
||||
|
||||
WHEN 'BUTTON_CANCEL'.
|
||||
client->popup_message_toast( |cancel| ).
|
||||
app-view_popup = ''.
|
||||
|
||||
WHEN 'BACK'.
|
||||
client->nav_app_leave( client->get_app( app-s_get-id_prev_app_stack ) ).
|
||||
client->nav_app_leave( client->get_app( app-get-id_prev_app_stack ) ).
|
||||
|
||||
ENDCASE.
|
||||
|
||||
|
@ -105,13 +124,16 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
|
||||
SELECT FROM z2ui5_t_draft
|
||||
FIELDS uuid, uuid_prev
|
||||
order by uuid
|
||||
ORDER BY uuid
|
||||
INTO TABLE @DATA(lt_data)
|
||||
UP TO 10 ROWS
|
||||
.
|
||||
|
||||
mt_draft->* = CORRESPONDING #( lt_data ).
|
||||
|
||||
app-next-s_timer-interval_ms = '2000'.
|
||||
app-next-s_timer-event_finished = 'TIMER_FINISHED'.
|
||||
|
||||
ENDMETHOD.
|
||||
|
||||
|
||||
|
@ -123,7 +145,7 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
shownavbutton = abap_true
|
||||
)->header_content(
|
||||
)->link(
|
||||
text = 'Source_Code'
|
||||
text = 'Source_Code' target = '_blank'
|
||||
href = z2ui5_cl_xml_view_helper=>hlp_get_source_code_url( app = me get = client->get( ) )
|
||||
)->get_parent(
|
||||
)->simple_form( title = 'Form Title' editable = abap_true
|
||||
|
@ -138,10 +160,10 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
press = client->_event( 'BUTTON_POST' )
|
||||
).
|
||||
|
||||
data(tab) = lo_view->get_parent( )->get_parent( )->simple_form( title = 'Table' editable = abap_true
|
||||
)->content( 'form' )->table(
|
||||
items = client->_bind( val = mt_draft->* check_gen_data = abap_true )
|
||||
).
|
||||
DATA(tab) = lo_view->get_parent( )->get_parent( )->simple_form( title = 'Table' editable = abap_true
|
||||
)->content( 'form' )->table(
|
||||
items = client->_bind( val = mt_draft->* check_gen_data = abap_true )
|
||||
).
|
||||
|
||||
tab->columns(
|
||||
)->column(
|
||||
|
@ -155,7 +177,7 @@ CLASS z2ui5_cl_app_demo_28 IMPLEMENTATION.
|
|||
)->input( '{UUID_PREV}'
|
||||
).
|
||||
|
||||
app-s_next-xml_main = lo_view->get_root( )->xml_get( ).
|
||||
app-next-xml_main = lo_view->get_root( )->xml_get( ).
|
||||
|
||||
ENDMETHOD.
|
||||
|
||||
|
|
|
@ -143,6 +143,11 @@ CLASS z2ui5_cl_http_handler IMPLEMENTATION.
|
|||
` sap.ui.core.BusyIndicator.hide();` && |\n| &&
|
||||
` }.bind(this));` && |\n| &&
|
||||
` }` && |\n| &&
|
||||
` if (sap.z2ui5.oResponse.oTimer){ ` && |\n| &&
|
||||
` var oEvent = { 'EVENT' : 'BUTTON_CHECK', 'METHOD' : 'UPDATE' };` && |\n| &&
|
||||
` oEvent.EVENT = sap.z2ui5.oResponse.oTimer.eventFinished;` && |\n| &&
|
||||
` setTimeout( sap.z2ui5.oView.getController().onEvent, sap.z2ui5.oResponse.oTimer.intervalMs, oEvent );` && |\n| &&
|
||||
` }` && |\n| &&
|
||||
` sap.ui.core.BusyIndicator.hide();` && |\n| &&
|
||||
` },` && |\n| &&
|
||||
|\n| &&
|
||||
|
@ -176,7 +181,7 @@ CLASS z2ui5_cl_http_handler IMPLEMENTATION.
|
|||
` }` && |\n| &&
|
||||
` sap.z2ui5.oResponse.oViewPopup.destroy();` && |\n| &&
|
||||
` } else {` && |\n| &&
|
||||
` this.oBody.oUpdate = this.oView.getModel().oData.oUpdate;` && |\n| &&
|
||||
` this.oBody.oUpdate = sap.z2ui5.oView.getModel().oData.oUpdate;` && |\n| &&
|
||||
` }` && |\n| &&
|
||||
|\n| &&
|
||||
` this.oBody.oSystem = sap.z2ui5.oResponse.oSystem;` && |\n| &&
|
||||
|
@ -190,8 +195,9 @@ CLASS z2ui5_cl_http_handler IMPLEMENTATION.
|
|||
|\n| &&
|
||||
` sap.z2ui5.oResponseOld = sap.z2ui5.oResponse;` && |\n| &&
|
||||
` sap.z2ui5.oResponse = {};` && |\n| &&
|
||||
` this.oView.destroy();` && |\n| &&
|
||||
` this.Roundtrip();` && |\n| &&
|
||||
` sap.z2ui5.oBody = this.oBody;` && |\n| &&
|
||||
` sap.z2ui5.oView.getController( ).Roundtrip();` && |\n| &&
|
||||
` sap.z2ui5.oView.destroy();` && |\n| &&
|
||||
` },` && |\n| &&
|
||||
|\n| &&
|
||||
` Roundtrip: function () {` && |\n| &&
|
||||
|
@ -251,7 +257,7 @@ CLASS z2ui5_cl_http_handler IMPLEMENTATION.
|
|||
` });` && |\n| &&
|
||||
` }` && |\n| &&
|
||||
` }.bind(this);` && |\n| &&
|
||||
` xhr.send(JSON.stringify(this.oBody));` && |\n| &&
|
||||
` xhr.send(JSON.stringify(sap.z2ui5.oBody));` && |\n| &&
|
||||
` },` && |\n| &&
|
||||
` });` && |\n| &&
|
||||
|\n| &&
|
||||
|
|
|
@ -1460,6 +1460,12 @@ CLASS z2ui5_lcl_system_runtime IMPLEMENTATION.
|
|||
)->add_attribute( n = `selectionStart` v = ms_next-s_set-s_cursor_pos-selectionstart apos_active = abap_false ).
|
||||
ENDIF.
|
||||
|
||||
IF ms_next-s_set-s_timer IS NOT INITIAL.
|
||||
lo_ui5_model->add_attribute_object( `oTimer`
|
||||
)->add_attribute( n = `eventFinished` v = ms_next-s_set-s_timer-event_finished
|
||||
)->add_attribute( n = `intervalMs` v = ms_next-s_set-s_timer-interval_ms apos_active = abap_false ).
|
||||
ENDIF.
|
||||
|
||||
IF ms_next-s_set-check_set_prev_view = abap_true.
|
||||
lo_ui5_model->add_attribute( n = `SET_PREV_VIEW` v = `true` apos_active = abap_false ).
|
||||
ENDIF.
|
||||
|
@ -1509,7 +1515,7 @@ CLASS z2ui5_lcl_system_runtime IMPLEMENTATION.
|
|||
WHEN cl_abap_datadescr=>kind_elem.
|
||||
CREATE DATA <attribute> TYPE (lr_attri->gen_type).
|
||||
lv_value = lo_model->get_attribute( lr_attri->name )->get_val( ).
|
||||
assign <attribute>->* to FIELD-SYMBOL(<attribute2>).
|
||||
ASSIGN <attribute>->* TO FIELD-SYMBOL(<attribute2>).
|
||||
<attribute2> = lv_value.
|
||||
WHEN cl_abap_datadescr=>kind_table.
|
||||
DATA(lo_struc) = cl_abap_structdescr=>describe_by_name( lr_attri->gen_type ).
|
||||
|
@ -1519,7 +1525,7 @@ CLASS z2ui5_lcl_system_runtime IMPLEMENTATION.
|
|||
p_unique = abap_false
|
||||
).
|
||||
CREATE DATA <attribute> TYPE HANDLE lo_tab.
|
||||
assign <attribute>->* to <attribute2>.
|
||||
ASSIGN <attribute>->* TO <attribute2>.
|
||||
_=>trans_ref_tab_2_tab(
|
||||
EXPORTING ir_tab_from = lo_model->get_attribute( lr_attri->name )->mr_actual
|
||||
CHANGING ct_to = <attribute2> ).
|
||||
|
@ -1633,9 +1639,9 @@ CLASS z2ui5_lcl_system_runtime IMPLEMENTATION.
|
|||
|
||||
IF check_gen_data = abap_true.
|
||||
TRY.
|
||||
" DATA(lo_refdescr) = CAST cl_abap_refdescr( cl_abap_datadescr=>describe_by_data( lr_ref2->* ) ).
|
||||
" DATA lr_ref TYPE REF TO data.
|
||||
data(lr_ref) = cast data( lr_ref2->* ).
|
||||
" DATA(lo_refdescr) = CAST cl_abap_refdescr( cl_abap_datadescr=>describe_by_data( lr_ref2->* ) ).
|
||||
" DATA lr_ref TYPE REF TO data.
|
||||
DATA(lr_ref) = CAST data( lr_ref2->* ).
|
||||
IF lr_attri->gen_type IS INITIAL.
|
||||
DATA(lo_datadescr) = cl_abap_datadescr=>describe_by_data( lr_ref->* ).
|
||||
lr_attri->gen_type_kind = lo_datadescr->type_kind.
|
||||
|
|
|
@ -33,6 +33,10 @@ INTERFACE z2ui5_if_client
|
|||
selectionstart TYPE string,
|
||||
selectionend TYPE string,
|
||||
END OF s_cursor_pos,
|
||||
begin of s_timer,
|
||||
interval_ms type string,
|
||||
event_finished type string,
|
||||
end of s_timer,
|
||||
END OF ty_s_next.
|
||||
|
||||
METHODS set_next
|
||||
|
|
Loading…
Reference in New Issue
Block a user