Skip to content

Commit

Permalink
Update z2ui5_cl_demo_app_315.clas.abap (#456)
Browse files Browse the repository at this point in the history
  • Loading branch information
oblomov-dev authored Dec 8, 2024
1 parent c01f73d commit 224eff9
Showing 1 changed file with 55 additions and 65 deletions.
120 changes: 55 additions & 65 deletions src/z2ui5_cl_demo_app_315.clas.abap
Original file line number Diff line number Diff line change
Expand Up @@ -24,71 +24,61 @@ CLASS z2ui5_cl_demo_app_315 IMPLEMENTATION.

data(tab) = page->table(
items = `{TRAVEL>/BookingSupplement}`
growing = abap_true
).

tab->header_toolbar(
)->toolbar(
)->title( 'table with odata model' ).

tab->columns(
)->column( )->text( 'TravelID' )->get_parent(
)->column( )->text( 'BookingID' )->get_parent(
)->column( )->text( 'BookingSupplementID' )->get_parent(
)->column( )->text( 'SupplementID' )->get_parent(
)->column( )->text( 'SupplementText' )->get_parent(
)->column( )->text( 'Price' )->get_parent(
)->column( )->text( 'CurrencyCode' )->get_parent(
).

tab->items( )->column_list_item( )->cells(
)->text( '{TRAVEL>TravelID}'
)->text( '{TRAVEL>BookingID}'
)->text( '{TRAVEL>BookingSupplementID}'
)->text( '{TRAVEL>SupplementID}'
)->text( '{TRAVEL>SupplementText}'
)->text( '{TRAVEL>Price}'
)->text( '{TRAVEL>CurrencyCode}'
).

tab = page->table(
items = `{FLIGHT>/Airport}`
growing = abap_true
).

tab->header_toolbar(
)->toolbar(
)->title( 'table with odata model' ).

tab->columns(
)->column( )->text( 'AirportID' )->get_parent(
)->column( )->text( 'Name' )->get_parent(
)->column( )->text( 'City' )->get_parent(
)->column( )->text( 'CountryCode' )->get_parent(
).

tab->items( )->column_list_item( )->cells(
)->text( '{FLIGHT>AirportID}'
)->text( '{FLIGHT>Name}'
)->text( '{FLIGHT>City}'
)->text( '{FLIGHT>CountryCode}'
).

client->view_display( val = view->stringify( ) switchdefaultmodel = `` ).

client->follow_up_action( client->_event_client(
val = z2ui5_if_client=>cs_event-set_odata_model
t_arg = value #(
( `/sap/opu/odata/DMO/API_TRAVEL_U_V2/` )
( `TRAVEL` )
) ) ).

client->follow_up_action( client->_event_client(
val = z2ui5_if_client=>cs_event-set_odata_model
t_arg = value #(
( `/sap/opu/odata/DMO/ui_flight_r_v2/` )
( `FLIGHT` )
) ) ).
growing = abap_true ).

tab->header_toolbar( )->toolbar(
)->title( 'table with odata model' ).

tab->columns(
)->column( )->text( 'TravelID' )->get_parent(
)->column( )->text( 'BookingID' )->get_parent(
)->column( )->text( 'BookingSupplementID' )->get_parent(
)->column( )->text( 'SupplementID' )->get_parent(
)->column( )->text( 'SupplementText' )->get_parent(
)->column( )->text( 'Price' )->get_parent(
)->column( )->text( 'CurrencyCode' )->get_parent( ).

tab->items( )->column_list_item( )->cells(
)->text( '{TRAVEL>TravelID}'
)->text( '{TRAVEL>BookingID}'
)->text( '{TRAVEL>BookingSupplementID}'
)->text( '{TRAVEL>SupplementID}'
)->text( '{TRAVEL>SupplementText}'
)->text( '{TRAVEL>Price}'
)->text( '{TRAVEL>CurrencyCode}' ).

tab = page->table(
items = `{FLIGHT>/Airport}`
growing = abap_true ).

tab->header_toolbar( )->toolbar(
)->title( 'table with odata model' ).

tab->columns(
)->column( )->text( 'AirportID' )->get_parent(
)->column( )->text( 'Name' )->get_parent(
)->column( )->text( 'City' )->get_parent(
)->column( )->text( 'CountryCode' )->get_parent( ).

tab->items( )->column_list_item( )->cells(
)->text( '{FLIGHT>AirportID}'
)->text( '{FLIGHT>Name}'
)->text( '{FLIGHT>City}'
)->text( '{FLIGHT>CountryCode}' ).

client->view_display( val = view->stringify( ) switchdefaultmodel = `` ).

client->follow_up_action( client->_event_client(
val = z2ui5_if_client=>cs_event-set_odata_model
t_arg = value #(
( `/sap/opu/odata/DMO/API_TRAVEL_U_V2/` )
( `TRAVEL` ) ) ) ).

client->follow_up_action( client->_event_client(
val = z2ui5_if_client=>cs_event-set_odata_model
t_arg = value #(
( `/sap/opu/odata/DMO/ui_flight_r_v2/` )
( `FLIGHT` ) ) ) ).

ENDIF.

Expand Down

0 comments on commit 224eff9

Please sign in to comment.