Sie sind auf Seite 1von 46

Integrata - Floor-Plan-Manager - Grundlagen - Seite

1. Zeigen Sie nur die von Ihnen belegten Prozesse durch die
Definition einer Wertbergabe innerhalb 2-er Schritte an
Definieren Sie eine WebDnpro-Component als wiederverwendbare Einheit als Datenlager

Ttigkeit

: ZWD_SHARED_DATA_XXX anlegen

Ttigkeit

: Knoten als Interfaceknoten bekannt machen

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: IF_FPM_SHARED_DATA einbetten

Anwendungen mit dem Floorplan Manager umfassen in der Regel eine Anzahl von UlBBs.
die untereinander Daten austauschen. Um diese Daten auf Basis einer zentralen Instanz
auszutauschen. kann das FloorpIan-Manager-lnterface 1F_FPM_SHARED_DATA
verwendet werden. Eine Web-Dynpro-Component. die dieses Interface einfgt,
wird auch Shared-Data-Component genannt.
Das Interface IF_FPM_SHARED_DATA beinhaltet selbst keine zu implementierenden
Methoden. Jede Component der Anwendung. die den Zugriff auf die Shared-Data-Component
bentigt. muss diese Component als verwendete Web-Dynpro-Component registrieren. Dafr
muss in der ABAP Workbench die entsprechende Component in der Sektion VERWENDETE
WEB-DYNPRO-COMPONENTS hinterlegt werden
Der Floorplan Manager sorgt zur Laufzeit der Anwendung dafr dass eine Component. die
das Interface IF_FPM_SHARED_DATA implementiert. anwendungsweit nur einmalig
instanziert wird. Somit greifen alle Components der Anwendung. die eine Verwendung auf
eine bestimmte Shared-Data-Component vermerkt haben. auf ein und dieselbe Instanz dieser
Web-Dynpro-Component zu. Dadurch kann die Shared-Data-Component als zentrale
Komponente von allen Verwendern fr den Austausch von Daten auf folgende Weise
eingesetzt werden:
- Mapping auf Basis von Web-Dynpro-Contexten
- Zugriff auf ffentliche Attribute
- Aufruf von ffentlichen Methoden der Shared-Data-Component

Integrata - Floor-Plan-Manager - Grundlagen - Seite


Anpassung im 1.WebDynpro

Ttigkeit

: Component-Verwendung eintragen ZWD_SHARED_DATA_XXX

Ttigkeit

: Component-Verwendung anklicken

Ttigkeit

: Ergebnis kontrollieren

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Interfaceknoten mappen und markieren

Ttigkeit

: Definieren Sie einen Interface-Knoten zur bergabe der Userkennung

Integrata - Floor-Plan-Manager - Grundlagen - Seite

- Global Object definieren

Ttigkeit

: Zentrale Instanz des FPM holen

===================================================
* get fpm instance
wd_this->go_fpm = cl_fpm_factory=>get_instance( ).
data lo_cmp_usage type ref to if_wd_component_usage.

lo_cmp_usage =
wd_this->wd_cpuse_zwd_shared_data_xxx( ).
if lo_cmp_usage->has_active_component( ) is initial.
lo_cmp_usage->create_component( ).
endif.
call method wd_this->go_fpm->attach_component_to_usage
exporting
iv_component_name = 'ZWD_SHARED_DATA_XXX'
io_component_usage = lo_cmp_usage.
=========================================================
*
*
*

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Aufruf der Datenbeschaffung umlagern


Holen des Attributwertes USER.. beim 1.Mal
Setzen des Interfacewertes beim 1.Mal

Die Methode PROCESS_8EFORE_OUT PUT wird immer dann prozessiert wenn der
jeweilige UIBB infolge des soeben prozessierten Event Loops letztlich sichtbar wird; das
heit. wenn der View dieses UlBBs schlielich Bestandteil des Web-Dynpro-Renderings ist.
Ausschlaggebend fr den Aufruf von PROCESS_BEFORE_0UTPUT ist somit immer
die Sichtbarkeit eines UlBBs im Ergebnis der Web-Dynpro-Rendering-Phase.

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Mapping des neuen Knoten


Definiton einer Action uebergabe_user

Ttigkeit

: Lesen des Users gem Lead-Selection in der Action-Phase


Legen Sie eine eigene Methode get_user_from_lead zum Setzen des
Interface-Wertes
Nutzen Sie den Code-Wizzard
Aktivieren und Test

Anpassung im 2.WebDynpro

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Component-Verwendung eintragen ZWD_SHARED_DATA_XXX

Ttigkeit

: Controller-Verwendung des InterfaceControllers einstellen


und Mapping

Ergebnis

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Zentrale Instanz des FPM holen

================================================================
* get fpm instance
wd_this->go_fpm = cl_fpm_factory=>get_instance( ).
data lo_cmp_usage type ref to if_wd_component_usage.
*
*
*

lo_cmp_usage =
wd_this->wd_cpuse_zwd_shared_data_xxx( ).
if lo_cmp_usage->has_active_component( ) is initial.
lo_cmp_usage->create_component( ).
endif.
call method wd_this->go_fpm->attach_component_to_usage
exporting
iv_component_name = 'ZWD_SHARED_DATA_XXX'
io_component_usage = lo_cmp_usage.

=========================================================

Ttigkeit

: Umlagerung der Datenbeschaffung

Integrata - Floor-Plan-Manager - Grundlagen - Seite

10

Anpassungsquellcode im Service-Funktionsbaustein
* ===================================================
data lo_nd_if_user type ref to if_wd_context_node.
data lo_el_if_user type ref to if_wd_context_element.
data ls_if_user type wd_this->element_if_user.
data lv_bname type wd_this->element_if_user-bname.
* navigate from <CONTEXT> to <IF_USER> via lead selection
lo_nd_if_user = wd_context->get_child_node( name = wd_this->wdctx_if_user
).
* @TODO handle non existant child
* IF lo_nd_if_user IS INITIAL.
* ENDIF.
* get element via lead selection
lo_el_if_user = lo_nd_if_user->get_element( ).
* @TODO handle not set lead selection
if lo_el_if_user is initial.
endif.
* get single attribute
lo_el_if_user->get_attribute(
exporting
name = `BNAME`
importing
value = lv_bname ).
sort lt_c_wplist by wp_bname ascending.
delete lt_c_wplist where wp_bname ne lv_bname.
* ====================================================

Ttigkeit

: Aktivieren und Test der Konfiguration

2. Hilfe Funktion "Quickinfo" aktivieren

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Konfiguration starten

Ttigkeit
Testen

: Erluterung Untersicht 1 + 2 hinzufgen

Ttigkeit
Testen

: Erluterungsobjekt Untersicht 1 hinzufgen

Ttigkeit

: Doku-Objekt einfgen

Ttigkeit

: Doku-Objekt zdokuobjekt_1anlegen

11

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

12

: Testen

3. Legen Sie einen Guided Activity Floorplan an


Der Guided Activity Floorplan besteht im Wesentlichen aus einer Abfolge von
Hauptschritten und unterschritten. die in einer Roadmap und entsprechenden Sub-Roadmaps
abgebildet werden. Jedem Hauptschritt und jedem Unterschritt ist eine eigene Toolbar
zugewiesen. Ein Guided Activity Floorplan kann auerdem ein Einstiegsbiid oder ein
Besttigungsbild haben

Ttigkeit

: Application anlegen, GAF-Component zuordnen und sichern

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Konfiguration anlegen

Ttigkeit

: Konfiguration-ID eingeben und Anlegen

Ttigkeit

: Paket zuordnen und sichern

13

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Auftrag zuordnen und sichern

Ttigkeit

: Konfiguration benennen, zur Konfiguration springen und anlegen

Ttigkeit

: Component und Window benennen

Ttigkeit

: Hauptschritt hinzufgen

14

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit
testen

: Component und Window benennen

4. Legen Sie einen Substep der die Daten zur letzen


Kennwortnderung PWDLGNDATE und Anmeldung
PWDCHGDATE anzeigt (USR02)
Webdynpro-Erweiterung im 1.WebDynpro

Ttigkeit
: Knoten USR02 im Component-Controller Context anlegen , im ViewController Context mappen und Layout dazu definieren

Ttigkeit

: Knoten USR02 anlegen und Layout dazu definieren


Datenbeschaffung aus USR02 ber separate Methode im CC die in der
Methode processevent aufgerufen wird definieren

15

Integrata - Floor-Plan-Manager - Grundlagen - Seite

16

=============== get user details ======================================


data lo_nd_if_bname type ref to if_wd_context_node.

data lo_el_if_bname type ref to if_wd_context_element.


data ls_if_bname type wd_this->element_if_bname.
data lv_bname type wd_this->element_if_bname-bname.
* navigate from <CONTEXT> to <IF_BNAME> via lead selection
lo_nd_if_bname = wd_context->get_child_node( name = wd_this>wdctx_if_bname ).
* @TODO handle non existant child
* IF lo_nd_if_bname IS INITIAL.
* ENDIF.
* get element via lead selection
lo_el_if_bname = lo_nd_if_bname->get_element( ).
* @TODO handle not set lead selection
if lo_el_if_bname is initial.
endif.
* get single attribute
lo_el_if_bname->get_attribute(
exporting
name = `BNAME`
importing
value = lv_bname ).
data lo_nd_usr02 type ref to if_wd_context_node.
data lo_el_usr02 type ref to if_wd_context_element.
data ls_usr02 type wd_this->element_usr02.
*
*
*
*

navigate from <CONTEXT> to <USR02> via lead selection


lo_nd_usr02 = wd_context->get_child_node( name = wd_this->wdctx_usr02 ).
@TODO handle non existant child
IF lo_nd_usr02 IS INITIAL.
ENDIF.

get element via lead selection


lo_el_usr02 = lo_nd_usr02->get_element( ).

@TODO handle not set lead selection


if lo_el_usr02 is initial.
endif.

*
*

@TODO fill static attributes


ls_usr02 = xxx->get_yyy( ).
select single * from usr02 into ls_usr02 where bname eq lv_bname.

set all declared attributes


lo_el_usr02->set_static_attributes(
static_attributes = ls_usr02 ).
===========================================================

================= processevent ======================================

Integrata - Floor-Plan-Manager - Grundlagen - Seite

17

data lr_event type ref to cl_fpm_event.


case io_event->mv_event_id.
* --------------------------------- STEP1 -----------------------------------when 'USER_DETAIL'.
lr_event = cl_fpm_event=>create_by_id( cl_fpm_event=>gc_event_change_
step ).
lr_event->mo_event_data->set_value( iv_key = cl_fpm_even
t=>gc_event_param_mainstep_id
iv_value = 'USER_LISTE' ).
lr_event->mo_event_data->set_value( iv_key = cl_fpm_even
t=>gc_event_param_substep_id
iv_value = 'USER_DETAIL' ).
lr_event->mo_event_data->set_value( iv_key = cl_fpm_even
t=>gc_event_param_subvariant_id
iv_value = 'VARIANT_1' ).
wd_this->get_user_details(
).
wd_this->go_fpm->raise_event( io_event = lr_event ).
endcase.
==============================================================

Ttigkeit

: Konfigurator starten

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Unterschritt hinzufgen

Ttigkeit

: Unterschritt hinzufgen

Ttigkeit
Testen

: Component , Window hinzufgen und sichern

18

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Element zur Drucktastenleiste hinzufgen

Ttigkeit

: Drucktastenleiste zum Hauptstep beleben

19

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Ansprung Substep User_Detail definieren und sichern

Ttigkeit

: Ansprung Mainstep definieren

Ttigkeit

: Ansprung Mainstep definieren

20

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Attribute Rcksprung definieren


Testen

5. Statische und dynamische Komponentenkonfiguration

Ttigkeit

: Nutzen Sie ihre OIF Komponente

Ttigkeit

: Konfiguration anlegen

21

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Konfiguration ZWD_USER_LIST_XXX_G1 anlegen

Ttigkeit

: Mandant ausblenden

22

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Sichern

23

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Ttigkeit

: Ergebnis sichten und Konfiguration entfernen

* =============== Dynamische Konfiguration Process Before Output


data lo_api_controller TYPE REF TO if_wd_component.
data lo_pers_manager TYPE REF TO if_wd_personalization.
data ls_konfig_key type wdy_config_key.
lo_api_controller = wd_this->wd_get_api( ).
lo_pers_manager = lo_api_controller->get_personalization_manager( ).
if sy-uname eq 'PWD'.
ls_konfig_key-config_id = 'ZWD_USER_LIST_XXX_G1'.
lo_pers_manager->load_config_by_key( ls_konfig_key ).
endif.
* ========================================

6. Dynamische Titelleisten ausgeben


* ============== Dynamische Titelleiste Process Before Output
data: lo_idr type ref to if_fpm_idr,
lo_fpm type ref to if_fpm.
lo_fpm = cl_fpm_factory=>get_instance( ).
lo_idr ?= lo_fpm->get_service( cl_fpm_service_manager=>gc_key_idr ).
lo_idr->set_application_title( exporting
iv_title
= 'Test dynamic title'
iv_title_tooltip = 'Title'
).
lo_idr->set_ticket( exporting
iv_top
= 'Ticket top dynamic '
iv_bottom
= 'Ticket bottom dynamic'
).

24

Integrata - Floor-Plan-Manager - Grundlagen - Seite

7. Nutzen Sie auch den fpm_cfg_hierarchy_browser

Ttigkeit

: Anwendung testen und ihre Konfiguration


ZWD_USER_WP_LIST_XXX_OIF eingeben

Ttigkeit

: Anwendungsaufbau sichten

25

Integrata - Floor-Plan-Manager - Grundlagen - Seite

26

8. Definieren Sie einen FPM Search Generic User Interface


Building Block
Legen Sie eine ZTabelle ZSCARR_XX abgeleitet aus SCARR an und kopieren Sie den Inhalt

>Aktivieren der Tabelle<


================= Kopier 4-Zeiler ==================
report zscarr_copy.
data: it_scarr type table of scarr.
select * from scarr into table it_scarr package size 1000.
insert zscarr_XX from table it_scarr accepting duplicate keys.
endselect.
====================================================

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Klasse anlegen und lokal sichern

27

Integrata - Floor-Plan-Manager - Grundlagen - Seite

28

class ZCL_SCARR_SEARCH_UIBB_99 definition


public
final
create public .
public section.
interfaces IF_FPM_GUIBB .
interfaces IF_FPM_GUIBB_SEARCH .
class-data MS_SCARR type SCARR .
class-data:
mt_SCARR type standard table of SCARR .
data MO_CATALOG type ref to CL_ABAP_STRUCTDESCR .
protected section.
private section.
ENDCLASS.

CLASS ZCL_SCARR_SEARCH_UIBB_99 IMPLEMENTATION.


* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB_SEARCH~CHECK_CONFIG
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_LAYOUT_CONFIG
TYPE REF TO IF_FPM_GUIBB_SEARCH_C
ONFIG
* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_SEARCH~CHECK_CONFIG.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB_SEARCH~FLUSH
* +------------------------------------------------------------------------------------------------+
* | [--->] IT_FPM_SEARCH_CRITERIA
TYPE
FPMGB_T_SEARCH_CRITER
IA
* | [--->] IV_MAX_NUM_RESULTS
TYPE
I
* | [--->] IT_SELECTED_LINES_OF_RESULT
TYPE
T_RESULT
* | [--->] IV_RESULT_LEAD_SEL
TYPE
I(optional)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_SEARCH~FLUSH.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB_SEARCH~GET_DATA
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_EVENT
TYPE REF TO CL_FPM_EVENT

Integrata - Floor-Plan-Manager - Grundlagen - Seite

29

* | [--->] IV_RAISED_BY_OWN_UI
TYPE
BOOLE_D
* | [--->] IT_VISIBLE_ATTRIBUTES
TYPE
FPMGB_T_SELECTED_FIEL
DS
* | [--->] IT_SELECTED_COLUMNS_OF_RESULT TYPE
FPMGB_T_SELECTED_FIEL
DS
* | [--->] IT_SELECTED_SEARCH_ATTRIBUTES TYPE
FPMGB_T_SELECTED_FIEL
DS
* | [<---] ET_MESSAGES
TYPE
FPMGB_SEARCH_T_T100_M
ESSAGE
* | [<---] EV_SEARCH_CRITERIA_CHANGED
TYPE
BOOLE_D
* | [<---] ET_RESULT_LIST
TYPE
DATA
* | [<---] EV_RESULT_LIST_TITLE
TYPE
STRING
* | [<-->] CT_FPM_SEARCH_CRITERIA
TYPE
FPMGB_T_SEARCH_CRITER
IA
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_search~get_data.
check io_event->mv_event_id = if_fpm_guibb_search=>fpm_execute_search.
et_result_list = mt_SCARR.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB_SEARCH~GET_DEFAULT_CONFIG
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_LAYOUT_CONFIG
TYPE REF TO IF_FPM_GUIBB_SEARCH_C
ONFIG
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_SEARCH~GET_DEFAULT_CONFIG.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB_SEARCH~GET_DEFINITION
* +------------------------------------------------------------------------------------------------+
* | [<---] EO_FIELD_CATALOG_ATTR
TYPE REF TO CL_ABAP_STRUCTDESCR
* | [<---] ET_FIELD_DESCRIPTION_ATTR
TYPE
FPMGB_T_SEARCHFIELD_D
ESCR
* | [<---] EO_FIELD_CATALOG_RESULT
TYPE REF TO CL_ABAP_TABLEDESCR
* | [<---] ET_FIELD_DESCRIPTION_RESULT
TYPE
FPMGB_T_SEARCHRESULT_
DESCR
* | [<---] EV_RESULT_TABLE_SELECTION_MODE TYPE
WDUI_TSMODE
* | [<---] ES_MESSAGE
TYPE
FPMGB_S_T100_MESSAGE
* | [<---] EV_ADDITIONAL_ERROR_INFO
TYPE
DOKU_OBJ
* | [<---] ES_OPTIONS
TYPE
FPMGB_S_SEARCH_OPTION
S
* | [<---] ET_ACTION_DEFINITION
TYPE
FPMGB_T_ACTIONDEF
* | [<---] ET_SPECIAL_GROUPS
TYPE
FPMGB_T_SPECIAL_GROUP
S
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_SEARCH~GET_DEFINITION.
data : wa_fields
type dfies,
" Work area dicitonary field attribut
es
it_fields
type ddfields, " Internal table Dicitonary field att

Integrata - Floor-Plan-Manager - Grundlagen - Seite

30

ributes
ls_field_desc like line of et_field_description_result.
ea result column description

" Work ar

* Creating the field catalog


eo_field_catalog_attr ?= cl_abap_structdescr=>describe_by_data( ms_SCARR
).

mo_catalog = eo_field_catalog_attr.
* Assigning the result catalog
eo_field_catalog_result ?= cl_abap_tabledescr=>describe_by_data( mt_SCARR

).

* Assigning field description


it_fields = eo_field_catalog_attr->get_ddic_field_list( ).
loop at it_fields into wa_fields.
ls_field_desc-name = wa_fields-fieldname.
ls_field_desc-text = wa_fields-fieldtext.
append ls_field_desc to et_field_description_result.
clear ls_field_desc.
endloop.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB_SEARCH~PROCESS_EVENT
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_EVENT
TYPE REF TO CL_FPM_EVENT
* | [--->] IT_FPM_SEARCH_CRITERIA
TYPE
FPMGB_T_SEARCH_CRITER
IA
* | [--->] IV_RAISED_BY_OWN_UI
TYPE
BOOLE_D
* | [--->] IV_MAX_NUM_RESULTS
TYPE
I
* | [--->] IO_SEARCH_CONVERSION
TYPE REF TO IF_FPM_GUIBB_SEARCH_C
ONVERSION(optional)
* | [<---] ET_MESSAGES
TYPE
FPMGB_SEARCH_T_T100_M
ESSAGE
* | [<---] EV_RESULT
TYPE
FPM_EVENT_RESULT
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_search~process_event.
data : lt_where_string type rsds_where_tab.
data : lo_exe type ref to cx_fpmgb.
check io_event->mv_event_id = if_fpm_guibb_search=>fpm_execute_search.
* Convert the search query into sql string
try.
cl_fpm_guibb_search_conversion=>to_abap_select_where_tab(
exporting
it_fpm_search_criteria = it_fpm_search_criteria
" search criteria
for GUIBB Search

Integrata - Floor-Plan-Manager - Grundlagen - Seite


iv_table_name
= 'SCARR'
io_field_catalog
= mo_catalog
Type Services
importing
et_abap_select_table
= lt_where_string
).
catch cx_fpmgb into lo_exe.
" GUIBB Exceptions
*

31
" Table Name
" Runtime

Exception part handled here


endtry.

* Fetching the result


select *
from SCARR into table mt_SCARR up to iv_max_num_results rows
where (lt_where_string).
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB~GET_PARAMETER_LIST
* +------------------------------------------------------------------------------------------------+
* | [<-()] RT_PARAMETER_DESCR
TYPE
FPMGB_T_PARAM_DESCR
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB~GET_PARAMETER_LIST.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_SCARR_SEARCH_UIBB_99>IF_FPM_GUIBB~INITIALIZE
* +------------------------------------------------------------------------------------------------+
* | [--->] IT_PARAMETER
TYPE
FPMGB_T_PARAM_VALUE
* | [--->] IO_APP_PARAMETER
TYPE REF TO IF_FPM_PARAMETER(opti
onal)
* | [--->] IV_COMPONENT_NAME
TYPE
FPM_COMPONENT_NAME(op
tional)
* | [--->] IS_CONFIG_KEY
TYPE
WDY_CONFIG_KEY(option
al)
* | [--->] IV_INSTANCE_ID
TYPE
FPM_INSTANCE_ID(optio
nal)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB~INITIALIZE.
endmethod.
ENDCLASS.

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Applikation + Konfiguration anlegen

>Sichern + Konfiguration starten<

Suchkomponente definieren

32

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Feeder Klasse zuordnen + >Parameter bearbeiten< + >ok<

>Suchkriterien<

Block auswhlen + ok

33

Integrata - Floor-Plan-Manager - Grundlagen - Seite

34

Spalten der Ergebnisliste + ok


>Sichern und Debugging<
==================================================================
>Testen der Einstellung<
>Testen gesicherte Suche<
>Operatoren ausschliessen<

Integrata - Floor-Plan-Manager - Grundlagen - Seite

35

9. Definieren Sie einen FPM LIST Generic User Interface


Building Block

Klasse ZCL_ZSCARR_LIST anlegen und lokal sichern


class ZCL_ZSCARR_LIST_99 definition
public
final
create public .
public section.
interfaces IF_FPM_GUIBB .
interfaces IF_FPM_GUIBB_LIST .
data:
MT_SCARR type standard table of SCARR .
class-data MS_SCARR type SCARR .
protected section.
private section.
ENDCLASS.

CLASS ZCL_ZSCARR_LIST_99 IMPLEMENTATION.


* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99>IF_FPM_GUIBB_LIST~CHECK_CONFIG
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_LAYOUT_CONFIG
TYPE REF TO IF_FPM_GUIBB_LIST_CON
FIG

Integrata - Floor-Plan-Manager - Grundlagen - Seite

36

* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_LIST~CHECK_CONFIG.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99->IF_FPM_GUIBB_LIST~FLUSH
* +------------------------------------------------------------------------------------------------+
* | [--->] IT_CHANGE_LOG
TYPE
FPMGB_T_CHANGELOG
* | [--->] IT_DATA
TYPE REF TO DATA
* | [--->] IV_OLD_LEAD_SEL
TYPE
I(optional)
* | [--->] IV_NEW_LEAD_SEL
TYPE
I(optional)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_LIST~FLUSH.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99->IF_FPM_GUIBB_LIST~GET_DATA
* +------------------------------------------------------------------------------------------------+
* | [--->] IV_EVENTID
TYPE REF TO CL_FPM_EVENT
* | [--->] IT_SELECTED_FIELDS
TYPE
FPMGB_T_SELECTED_FIEL
DS(optional)
* | [--->] IV_RAISED_BY_OWN_UI
TYPE
BOOLE_D(optional)
* | [--->] IV_VISIBLE_ROWS
TYPE
I(optional)
* | [--->] IV_EDIT_MODE
TYPE
FPM_EDIT_MODE(optiona
l)
* | [--->] IO_EXTENDED_CTRL
TYPE REF TO IF_FPM_LIST_ATS_EXT_C
TRL(optional)
* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* | [<---] EV_DATA_CHANGED
TYPE
BOOLE_D
* | [<---] EV_FIELD_USAGE_CHANGED
TYPE
BOOLE_D
* | [<---] EV_ACTION_USAGE_CHANGED
TYPE
BOOLE_D
* | [<---] EV_SELECTED_LINES_CHANGED
TYPE
BOOLE_D
* | [<---] EV_DND_ATTR_CHANGED
TYPE
BOOLE_D
* | [<---] EO_ITAB_CHANGE_LOG
TYPE REF TO IF_SALV_ITAB_CHANGE_L
OG
* | [<-->] CT_DATA
TYPE
DATA
* | [<-->] CT_FIELD_USAGE
TYPE
FPMGB_T_FIELDUSAGE
* | [<-->] CT_ACTION_USAGE
TYPE
FPMGB_T_ACTIONUSAGE
* | [<-->] CT_SELECTED_LINES
TYPE
RSTABIXTAB
* | [<-->] CV_LEAD_INDEX
TYPE
SYTABIX
* | [<-->] CV_FIRST_VISIBLE_ROW
TYPE
I
* | [<-->] CS_ADDITIONAL_INFO
TYPE
FPMGB_S_ADDITIONAL_IN
FO(optional)
* | [<-->] CT_DND_ATTRIBUTES
TYPE
FPMGB_T_DND_DEFINITIO
N(optional)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_LIST~GET_DATA.
* if iv_eventid->mv_event_id = 'FPM_START'.
*
*
ev_data_changed = abap_true.
*
*
ct_data = mt_SCARR.

Integrata - Floor-Plan-Manager - Grundlagen - Seite


*
*

37

endif.
if iv_eventid->mv_event_id = 'FPM_EXECUTE_SEARCH'.
ct_data = ZCL_SCARR_SEARCH_UIBB_XX=>mt_SCARR.

ct_data = mt_SCARR.
ev_data_changed = abap_true.

endif.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99>IF_FPM_GUIBB_LIST~GET_DEFAULT_CONFIG
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_LAYOUT_CONFIG
TYPE REF TO IF_FPM_GUIBB_LIST_CON
FIG
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_LIST~GET_DEFAULT_CONFIG.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99>IF_FPM_GUIBB_LIST~GET_DEFINITION
* +------------------------------------------------------------------------------------------------+
* | [<---] EO_FIELD_CATALOG
TYPE REF TO CL_ABAP_TABLEDESCR
* | [<---] ET_FIELD_DESCRIPTION
TYPE
FPMGB_T_LISTFIELD_DES
CR
* | [<---] ET_ACTION_DEFINITION
TYPE
FPMGB_T_ACTIONDEF
* | [<---] ET_SPECIAL_GROUPS
TYPE
FPMGB_T_SPECIAL_GROUP
S
* | [<---] ES_MESSAGE
TYPE
FPMGB_S_T100_MESSAGE
* | [<---] EV_ADDITIONAL_ERROR_INFO
TYPE
DOKU_OBJ
* | [<---] ET_DND_DEFINITION
TYPE
FPMGB_T_DND_DEFINITIO
N
* | [<---] ET_ROW_ACTIONS
TYPE
FPMGB_T_ROW_ACTION
* | [<---] ES_OPTIONS
TYPE
FPMGB_S_LIST_OPTIONS
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_LIST~GET_DEFINITION.
* field catalog - Table columns
eo_field_catalog ?= cl_abap_tabledescr=>describe_by_data( mt_SCARR ).
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99>IF_FPM_GUIBB_LIST~PROCESS_EVENT
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_EVENT
TYPE REF TO CL_FPM_EVENT

Integrata - Floor-Plan-Manager - Grundlagen - Seite

38

* | [--->] IV_RAISED_BY_OWN_UI
TYPE
BOOLE_D(optional)
* | [--->] IV_LEAD_INDEX
TYPE
SYTABIX
* | [--->] IV_EVENT_INDEX
TYPE
SYTABIX
* | [--->] IT_SELECTED_LINES
TYPE
RSTABIXTAB
* | [--->] IO_UI_INFO
TYPE REF TO IF_FPM_LIST_ATS_UI_IN
FO(optional)
* | [<---] EV_RESULT
TYPE
FPM_EVENT_RESULT
* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB_LIST~PROCESS_EVENT.
data ls_makt type makt.
if io_event->mv_event_id = 'FPM_GUIBB_LIST_ON_LEAD_SELECTI'.
read table mt_scarr into ms_scarr index iv_lead_index.
endif.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99>IF_FPM_GUIBB~GET_PARAMETER_LIST
* +------------------------------------------------------------------------------------------------+
* | [<-()] RT_PARAMETER_DESCR
TYPE
FPMGB_T_PARAM_DESCR
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB~GET_PARAMETER_LIST.
endmethod.
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_LIST_99->IF_FPM_GUIBB~INITIALIZE
* +------------------------------------------------------------------------------------------------+
* | [--->] IT_PARAMETER
TYPE
FPMGB_T_PARAM_VALUE
* | [--->] IO_APP_PARAMETER
TYPE REF TO IF_FPM_PARAMETER(opti
onal)
* | [--->] IV_COMPONENT_NAME
TYPE
FPM_COMPONENT_NAME(op
tional)
* | [--->] IS_CONFIG_KEY
TYPE
WDY_CONFIG_KEY(option
al)
* | [--->] IV_INSTANCE_ID
TYPE
FPM_INSTANCE_ID(optio
nal)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method IF_FPM_GUIBB~INITIALIZE.
select * from SCARR into table mt_SCARR up to 10 rows.
endmethod.
ENDCLASS.

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Zur Anwendung die Konfiguration anlegen

application configuration name eingeben ZCL_LIST_GUIBB_XXX.

Konfigurations-ID

: ZCL_LIST_GUIBB_XXX_ID anlegen

39

Integrata - Floor-Plan-Manager - Grundlagen - Seite

40

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Aktion

: UIBB Konfigurieren

Aktion

: anlagen

41

Integrata - Floor-Plan-Manager - Grundlagen - Seite

Aktion

: Parameter bearbeiten

Aktion

: OK

Aktion

: Spalten konfigurieren + Testen

Aktion

: Alles auswhlen + Spalten hinzufgen

Sichern und testen

10. Definieren Sie einen FPM FORM Generic User Interface


Building Block
Rufen Sie SE24 auf
Name der Klasse
: ZCL_UIBB_FORM als lokales Objekt anlegen
====================================================================================

class zcl_zscarr_form_99 definition


public
final
create public .
public section.

42

Integrata - Floor-Plan-Manager - Grundlagen - Seite

43

interfaces if_fpm_guibb .
interfaces if_fpm_guibb_form .
data mo_search type ref to zcl_zscarr_list_99 .
protected section.
private section.
ENDCLASS.

CLASS ZCL_ZSCARR_FORM_99 IMPLEMENTATION.


* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99>IF_FPM_GUIBB_FORM~CHECK_CONFIG
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_LAYOUT_CONFIG
TYPE REF TO IF_FPM_GUIBB_FORM_CON
FIG
* | [--->] IO_LAYOUT_CONFIG_GL2
TYPE REF TO IF_FPM_GUIBB_FORM_CFG
_GL2(optional)
* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_form~check_config.
endmethod.
"IF_FPM_GUIBB_FORM~CHECK_CONFIG
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99->IF_FPM_GUIBB_FORM~FLUSH
* +------------------------------------------------------------------------------------------------+
* | [--->] IT_CHANGE_LOG
TYPE
FPMGB_T_CHANGELOG
* | [--->] IS_DATA
TYPE REF TO DATA
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_form~flush.
endmethod.
"IF_FPM_GUIBB_FORM~FLUSH
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99->IF_FPM_GUIBB_FORM~GET_DATA
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_EVENT
TYPE REF TO CL_FPM_EVENT
* | [--->] IT_SELECTED_FIELDS
TYPE
FPMGB_T_SELECTED_FIEL
DS(optional)
* | [--->] IV_RAISED_BY_OWN_UI
TYPE
BOOLE_D(optional)
* | [--->] IV_EDIT_MODE
TYPE
FPM_EDIT_MODE(optiona
l)
* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* | [<---] EV_DATA_CHANGED
TYPE
BOOLE_D
* | [<---] EV_FIELD_USAGE_CHANGED
TYPE
BOOLE_D
* | [<---] EV_ACTION_USAGE_CHANGED
TYPE
BOOLE_D
* | [<-->] CS_DATA
TYPE
DATA
* | [<-->] CT_FIELD_USAGE
TYPE
FPMGB_T_FIELDUSAGE
* | [<-->] CT_ACTION_USAGE
TYPE
FPMGB_T_ACTIONUSAGE

Integrata - Floor-Plan-Manager - Grundlagen - Seite

44

* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_form~get_data.
data wa type zscarr_00.
ev_data_changed = abap_true.
if io_event->mv_event_id = 'FPM_EXECUTE_SEARCH'.
cs_data = zcl_zscarr_list_99=>ms_scarr.
*

ct_data = mt_SCARR.
ev_data_changed = abap_true.
else.
select single * from zscarr_00 into wa where carrid = 'AA'.
cs_data = wa.
endif.
endmethod.
"if_fpm_guibb_form~get_data

* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99>IF_FPM_GUIBB_FORM~GET_DEFAULT_CONFIG
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_LAYOUT_CONFIG
TYPE REF TO IF_FPM_GUIBB_FORM_CON
FIG
* | [--->] IO_LAYOUT_CONFIG_GL2
TYPE REF TO IF_FPM_GUIBB_FORM_CFG
_GL2(optional)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_form~get_default_config.
endmethod.
"IF_FPM_GUIBB_FORM~GET_DEFAULT_CONFIG
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99>IF_FPM_GUIBB_FORM~GET_DEFINITION
* +------------------------------------------------------------------------------------------------+
* | [<---] ES_MESSAGE
TYPE
FPMGB_S_T100_MESSAGE
* | [<---] EO_FIELD_CATALOG
TYPE REF TO CL_ABAP_STRUCTDESCR
* | [<---] ET_FIELD_DESCRIPTION
TYPE
FPMGB_T_FORMFIELD_DES
CR
* | [<---] ET_ACTION_DEFINITION
TYPE
FPMGB_T_ACTIONDEF
* | [<---] ET_SPECIAL_GROUPS
TYPE
FPMGB_T_SPECIAL_GROUP
S
* | [<---] EV_ADDITIONAL_ERROR_INFO
TYPE
DOKU_OBJ
* | [<---] ET_DND_DEFINITION
TYPE
FPMGB_T_DND_DEFINITIO
N
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_form~get_definition.
data: li_action_line
type fpmgb_s_actiondef.
eo_field_catalog ?= cl_abap_tabledescr=>describe_by_name( 'SCARR' ).
endmethod.

"IF_FPM_GUIBB_FORM~GET_DEFINITION

* <SIGNATURE>--------------------------------------------------------------

Integrata - Floor-Plan-Manager - Grundlagen - Seite

45

-------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99>IF_FPM_GUIBB_FORM~PROCESS_EVENT
* +------------------------------------------------------------------------------------------------+
* | [--->] IO_EVENT
TYPE REF TO CL_FPM_EVENT
* | [--->] IV_RAISED_BY_OWN_UI
TYPE
BOOLE_D(optional)
* | [<---] EV_RESULT
TYPE
FPM_EVENT_RESULT
* | [<---] ET_MESSAGES
TYPE
FPMGB_T_MESSAGES
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb_form~process_event.
endmethod.
"IF_FPM_GUIBB_FORM~PROCESS_EVENT
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99>IF_FPM_GUIBB~GET_PARAMETER_LIST
* +------------------------------------------------------------------------------------------------+
* | [<-()] RT_PARAMETER_DESCR
TYPE
FPMGB_T_PARAM_DESCR
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb~get_parameter_list.
endmethod.
"IF_FPM_GUIBB~GET_PARAMETER_LIST
* <SIGNATURE>--------------------------------------------------------------------------------------+
* | Instance Public Method ZCL_ZSCARR_FORM_99->IF_FPM_GUIBB~INITIALIZE
* +------------------------------------------------------------------------------------------------+
* | [--->] IT_PARAMETER
TYPE
FPMGB_T_PARAM_VALUE
* | [--->] IO_APP_PARAMETER
TYPE REF TO IF_FPM_PARAMETER(opti
onal)
* | [--->] IV_COMPONENT_NAME
TYPE
FPM_COMPONENT_NAME(op
tional)
* | [--->] IS_CONFIG_KEY
TYPE
WDY_CONFIG_KEY(option
al)
* | [--->] IV_INSTANCE_ID
TYPE
FPM_INSTANCE_ID(optio
nal)
* +-------------------------------------------------------------------------------------</SIGNATURE>
method if_fpm_guibb~initialize.
endmethod.
"IF_FPM_GUIBB~INITIALIZE
ENDCLASS.
==================================================================
Konfiguration zur Komponent : FPM_FORM_UIBB anlegen

Integrata - Floor-Plan-Manager - Grundlagen - Seite

46