CLASS zcl_abapgit_gui_page_tutorial DEFINITION
PUBLIC
FINAL
INHERITING FROM zcl_abapgit_gui_component
CREATE PUBLIC.
PUBLIC SECTION.
INTERFACES zif_abapgit_gui_renderable.
CLASS-METHODS create
RETURNING
VALUE(ri_page) TYPE REF TO zif_abapgit_gui_renderable
RAISING
zcx_abapgit_exception.
PROTECTED SECTION.
PRIVATE SECTION.
CLASS-METHODS build_main_menu
RETURNING
VALUE(ro_menu) TYPE REF TO zcl_abapgit_html_toolbar.
ENDCLASS.
CLASS ZCL_ABAPGIT_GUI_PAGE_TUTORIAL IMPLEMENTATION.
METHOD build_main_menu.
CREATE OBJECT ro_menu EXPORTING iv_id = 'toolbar-main'.
ro_menu->add(
iv_txt = zcl_abapgit_gui_buttons=>repo_list( )
iv_act = zif_abapgit_definitions=>c_action-abapgit_home
)->add(
iv_txt = zcl_abapgit_gui_buttons=>new_online( )
iv_act = zif_abapgit_definitions=>c_action-repo_newonline
)->add(
iv_txt = zcl_abapgit_gui_buttons=>new_offline( )
iv_act = zif_abapgit_definitions=>c_action-repo_newoffline
)->add(
iv_txt = zcl_abapgit_gui_buttons=>settings( )
iv_act = zif_abapgit_definitions=>c_action-go_settings
)->add(
iv_txt = zcl_abapgit_gui_buttons=>advanced( )
iv_title = 'Utilities'
io_sub = zcl_abapgit_gui_chunk_lib=>advanced_submenu( )
)->add(
iv_txt = zcl_abapgit_gui_buttons=>help( )
iv_title = 'Help'
io_sub = zcl_abapgit_gui_chunk_lib=>help_submenu( ) ).
ENDMETHOD.
METHOD create.
DATA lo_component TYPE REF TO zcl_abapgit_gui_page_tutorial.
CREATE OBJECT lo_component.
ri_page = zcl_abapgit_gui_page_hoc=>create(
iv_page_title = 'Tutorial'
io_page_menu = build_main_menu( )
ii_child_component = lo_component ).
ENDMETHOD.
METHOD zif_abapgit_gui_renderable~render.
CREATE OBJECT ri_html TYPE zcl_abapgit_html.
ri_html->add( '
' ).
ri_html->add( '
Tutorial
' ).
ri_html->add( '
' ).
ri_html->add( '
Online repositories
' ).
ri_html->add( '
' ).
ri_html->add( `- To clone a remote repository (e.g. from github) click ` ).
ri_html->add_a( iv_txt = zcl_abapgit_gui_buttons=>new_online( )
iv_act = zif_abapgit_definitions=>c_action-repo_newonline ).
ri_html->add( ' from the top menu. This will link a remote repository with a package on your system.
' ).
ri_html->add( '- Use the pull button to retrieve and activate the remote objects.
' ).
ri_html->add( '- If the remote repository is updated,' ).
ri_html->add( ' you will see the changes and can pull to apply the updates.
' ).
ri_html->add( '
' ).
ri_html->add( '
Offline repositories
' ).
ri_html->add( '
' ).
ri_html->add( `- To add a package as an offline repository, click ` ).
ri_html->add_a( iv_txt = zcl_abapgit_gui_buttons=>new_offline( )
iv_act = zif_abapgit_definitions=>c_action-repo_newoffline ).
ri_html->add( ' from the top menu.' ).
ri_html->add( '
- abapGit will start tracking changes for the package ' ).
ri_html->add( 'without linking it to an online git repository.
' ).
ri_html->add( '- You can link the package later or just export the package content as a ZIP file.
' ).
ri_html->add( '
' ).
ri_html->add( '' ).
ri_html->add( '
Repository list and favorites
' ).
ri_html->add( '
' ).
ri_html->add( |- To favorite a repository, use the {
ri_html->icon( 'star/darkgrey' ) } icon in the repository list.
| ).
ri_html->add( |- To go to a repository, click on the repository name.
| ).
ri_html->add( |- To go back to your favorites, use the| ).
ri_html->add_a(
iv_txt = zcl_abapgit_gui_buttons=>repo_list( )
iv_act = zif_abapgit_definitions=>c_action-abapgit_home ).
ri_html->add( |
| ).
ri_html->add( `- ` ).
ri_html->add_a( iv_txt = 'Explore'
iv_act = zif_abapgit_definitions=>c_action-go_explore ).
ri_html->add( ' to find projects using abapGit
' ).
ri_html->add( '
' ).
ri_html->add( '
' ).
ENDMETHOD.
ENDCLASS.