Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/badges/abap2ui5.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"schemaVersion": 1,
"label": "abap2UI5",
"message": "147 apps · 170 views · 2,195 controls",
"message": "148 apps · 171 views · 2,202 controls",
"color": "007ec6",
"labelColor": "555",
"cacheSeconds": 3600
Expand Down
7 changes: 4 additions & 3 deletions SAMPLES.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@

# The sample catalogue

Every app in this repository — 149 of them — with what it shows and a link
Every app in this repository — 150 of them — with what it shows and a link
to its source. This is the [overview app](src/z2ui5_cl_smp_app_000.clas.abap)
as a page you can read here, before installing anything.

**109 of them ship on every branch** — the portable set the README counts:
`src/01` plus this overview app. The other 40 are under `src/00` and are
`src/01` plus this overview app. The other 41 are under `src/00` and are
stripped from `702`. 2 further classes carry the sample name and are
data objects the samples share rather than apps; they are listed too, so nothing
in the tree is invisible.
Expand Down Expand Up @@ -316,7 +316,7 @@ is absent there.

## Helper apps

12 classes that are only ever *called* by another sample — a
13 classes that are only ever *called* by another sample — a
sub-app, a data object, the other half of a navigation demo. Their short text
starts with `ZZZ`, which is how the generator knows to give them no tile.
Listed here so nothing in the tree is invisible; there is no point starting
Expand All @@ -330,6 +330,7 @@ one on its own.
| **ZZZ** — called by Nested Views - Sub-App (104), the form | [`Z2UI5_CL_SMP_APP_105`](src/01/z2ui5_cl_smp_app_105.clas.abap) |
| **ZZZ** — called by Nested Views - Sub-App (104), the list | [`Z2UI5_CL_SMP_APP_112`](src/01/z2ui5_cl_smp_app_112.clas.abap) |
| **ZZZ** — called by popup | [`Z2UI5_CL_SMP_APP_020`](src/01/z2ui5_cl_smp_app_020.clas.abap) |
| **ZZZ** — called by 085 | [`Z2UI5_CL_SMP_APP_086`](src/00/98/z2ui5_cl_smp_app_086.clas.abap) |
| **ZZZ** — called by Nested Apps I | [`Z2UI5_CL_SMP_APP_126`](src/00/98/z2ui5_cl_smp_app_126.clas.abap) |
| **ZZZ** — called by Nested Apps II | [`Z2UI5_CL_SMP_APP_132`](src/00/98/z2ui5_cl_smp_app_132.clas.abap) |
| **ZZZ** — called by Nested Apps III | [`Z2UI5_CL_SMP_APP_184`](src/00/98/z2ui5_cl_smp_app_184.clas.abap) |
Expand Down
2 changes: 2 additions & 0 deletions src/00/97/package.devc.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<asx:values>
<DEVC>
<CTEXT>experimental</CTEXT>
<LANGUAGE>E</LANGUAGE>
<MASTERLANG>E</MASTERLANG>
<SRV_CHECK>X</SRV_CHECK>
</DEVC>
</asx:values>
Expand Down
2 changes: 2 additions & 0 deletions src/00/98/package.devc.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<asx:values>
<DEVC>
<CTEXT>testing</CTEXT>
<LANGUAGE>E</LANGUAGE>
<MASTERLANG>E</MASTERLANG>
</DEVC>
</asx:values>
</asx:abap>
Expand Down
58 changes: 58 additions & 0 deletions src/00/98/z2ui5_cl_smp_app_086.clas.abap
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
CLASS z2ui5_cl_smp_app_086 DEFINITION PUBLIC.

PUBLIC SECTION.
INTERFACES z2ui5_if_app.

TYPES:
BEGIN OF ty_s_tab_supplier,
suppliername TYPE string,
email TYPE string,
phone TYPE string,
zipcode TYPE string,
city TYPE string,
street TYPE string,
country TYPE string,
END OF ty_s_tab_supplier.
DATA ls_detail_supplier TYPE ty_s_tab_supplier.

PROTECTED SECTION.
PRIVATE SECTION.
ENDCLASS.


CLASS z2ui5_cl_smp_app_086 IMPLEMENTATION.

METHOD z2ui5_if_app~main.

DATA(view) = z2ui5_cl_ui5_view_builder=>factory(
)->ele( n = `View` ns = `mvc`
)->a( n = `displayBlock` v = `true`
)->a( n = `height` v = `100%`
)->a( n = `xmlns` v = `sap.m`
)->a( n = `xmlns:mvc` v = `sap.ui.core.mvc`
)->a( n = `xmlns:core` v = `sap.ui.core`
)->a( n = `xmlns:form` v = `sap.ui.layout.form`
)->a( n = `xmlns:layout` v = `sap.ui.layout` ).
DATA(page) = view->ele( `Shell`
)->ele( `Page`
)->a( n = `title` v = `abap2UI5 - Flow Logic - APP 85`
)->a( n = `showNavButton` b = client->check_app_prev_stack( )
)->a( n = `navButtonPress` v = client->_event_nav_app_leave( ) ).

page->ele( n = `Grid` ns = `layout`
)->a( n = `defaultSpan` v = `L6 M12 S12`
)->ele( n = `content` ns = `layout`
)->ele( n = `SimpleForm` ns = `form`
)->a( n = `title` v = `Supplier`
)->ele( n = `content` ns = `form`
)->tag( `Label`
)->a( n = `text` v = `Value set by previous app`
)->tag( `Input`
)->a( n = `editable` v = `false`
)->a( n = `value` v = ls_detail_supplier-suppliername ).

client->view_display( view->stringify( ) ).

ENDMETHOD.

ENDCLASS.
16 changes: 16 additions & 0 deletions src/00/98/z2ui5_cl_smp_app_086.clas.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<abapGit version="v1.0.0" serializer="LCL_OBJECT_CLAS" serializer_version="v1.0.0">
<asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
<asx:values>
<VSEOCLASS>
<CLSNAME>Z2UI5_CL_SMP_APP_086</CLSNAME>
<LANGU>E</LANGU>
<DESCRIPT>ZZZ - called by 085</DESCRIPT>
<STATE>1</STATE>
<CLSCCINCL>X</CLSCCINCL>
<FIXPT>X</FIXPT>
<UNICODE>X</UNICODE>
</VSEOCLASS>
</asx:values>
</asx:abap>
</abapGit>
7 changes: 2 additions & 5 deletions src/00/98/z2ui5_cl_smp_app_343.clas.abap
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ CLASS z2ui5_cl_smp_app_343 DEFINITION PUBLIC.
ENDCLASS.


CLASS z2ui5_cl_smp_app_343 IMPLEMENTATION.
CLASS Z2UI5_CL_SMP_APP_343 IMPLEMENTATION.


METHOD get_comp.

TRY.
TRY.

cl_abap_typedescr=>describe_by_name( EXPORTING p_name = `Z2UI5_T_01`
RECEIVING p_descr_ref = DATA(typedesc)
Expand All @@ -48,8 +48,6 @@ CLASS z2ui5_cl_smp_app_343 IMPLEMENTATION.
CATCH cx_root.
ENDTRY.

CATCH cx_root.
ENDTRY.

ENDMETHOD.

Expand Down Expand Up @@ -129,5 +127,4 @@ CLASS z2ui5_cl_smp_app_343 IMPLEMENTATION.
ENDIF.

ENDMETHOD.

ENDCLASS.
7 changes: 2 additions & 5 deletions src/00/98/z2ui5_cl_smp_app_345.clas.abap
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ CLASS z2ui5_cl_smp_app_345 DEFINITION PUBLIC.
ENDCLASS.


CLASS z2ui5_cl_smp_app_345 IMPLEMENTATION.
CLASS Z2UI5_CL_SMP_APP_345 IMPLEMENTATION.


METHOD get_comp.

TRY.
TRY.

cl_abap_typedescr=>describe_by_name( EXPORTING p_name = `Z2UI5_T_01`
RECEIVING p_descr_ref = DATA(typedesc)
Expand All @@ -57,8 +57,6 @@ CLASS z2ui5_cl_smp_app_345 IMPLEMENTATION.
CATCH cx_root.
ENDTRY.

CATCH cx_root.
ENDTRY.

ENDMETHOD.

Expand Down Expand Up @@ -191,5 +189,4 @@ CLASS z2ui5_cl_smp_app_345 IMPLEMENTATION.
ENDIF.

ENDMETHOD.

ENDCLASS.
2 changes: 2 additions & 0 deletions src/00/package.devc.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<asx:values>
<DEVC>
<CTEXT>system</CTEXT>
<LANGUAGE>E</LANGUAGE>
<MASTERLANG>E</MASTERLANG>
<SRV_CHECK>X</SRV_CHECK>
</DEVC>
</asx:values>
Expand Down
2 changes: 2 additions & 0 deletions src/01/package.devc.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<asx:values>
<DEVC>
<CTEXT>samples</CTEXT>
<LANGUAGE>E</LANGUAGE>
<MASTERLANG>E</MASTERLANG>
</DEVC>
</asx:values>
</asx:abap>
Expand Down
6 changes: 2 additions & 4 deletions src/01/z2ui5_cl_smp_app_144.clas.abap
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ CLASS z2ui5_cl_smp_app_144 DEFINITION PUBLIC.
ENDCLASS.


CLASS z2ui5_cl_smp_app_144 IMPLEMENTATION.
CLASS Z2UI5_CL_SMP_APP_144 IMPLEMENTATION.


METHOD set_view.

Expand Down Expand Up @@ -100,16 +101,13 @@ CLASS z2ui5_cl_smp_app_144 IMPLEMENTATION.

IF client->check_on_init( ).

DO 1 TIMES.
t_tab = VALUE #( BASE t_tab
( title = `entry 01` value = `red` )
( title = `entry 02` value = `blue` ) ).
ENDDO.
set_view( ).
ELSEIF client->check_on_navigated( ).
set_view( ).
ENDIF.

ENDMETHOD.

ENDCLASS.
2 changes: 2 additions & 0 deletions src/package.devc.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<asx:values>
<DEVC>
<CTEXT>abap2UI5 - samples</CTEXT>
<LANGUAGE>E</LANGUAGE>
<MASTERLANG>E</MASTERLANG>
</DEVC>
</asx:values>
</asx:abap>
Expand Down