Namensraum anlegen
Tcode: SE03

Editierbarkeit von Objekten eines Namensraumes zulassen
Tcode: SE03

Ggf. muss in der SE80 noch der Modifikationsassistant ausgeschaltet werden.
SE80 -> Bearbeitten -> Modifikationsoperationen -> Assistant ausschalten
SAP
Namensraum anlegen
Tcode: SE03

Editierbarkeit von Objekten eines Namensraumes zulassen
Tcode: SE03

Ggf. muss in der SE80 noch der Modifikationsassistant ausgeschaltet werden.
SE80 -> Bearbeitten -> Modifikationsoperationen -> Assistant ausschalten
There are several different types of buttons you can add to the Shell Header: https://sapui5.hana.ondemand.com/sdk/#/api/sap.ushell.renderers.fiori2.Renderer%23methods/Summary
For my test I choose the “addHeaderEndItem” Button. Add the fowlloing logic in the Component.js file to create the button and the logic for switching the theme:
_addHeaderButton: function () {
const oRenderer = sap.ushell.Container.getRenderer("fiori2");
oRenderer.addHeaderEndItem("sap.ushell.ui.shell.ShellHeadItem", {
id: "toogleTheme",
icon: "sap-icon://circle-task-2",
visible: "{device>/orientation/landscape}",
tooltip: "Switch Theme",
press: (oEvent) => {
const toogleButton = oEvent.getSource();
if (toogleButton.getIcon() === "sap-icon://circle-task-2") {
sap.ui.getCore().applyTheme("sap_fiori_3_dark");
toogleButton.setIcon("sap-icon://circle-task");
} else {
sap.ui.getCore().applyTheme("sap_fiori_3");
toogleButton.setIcon("sap-icon://circle-task-2");
}
}
}, true);
},
Afterwars you need call the method in the init() function of the component. No reload the app and you will find the new button in the top right corner. Pressing will switch the theme to dark or back to light theme.


# install SQLite
npm i sqlite3 -D
# create db, save configuration in package.json, stores mock data into db
cds deploy --to sqlite:db/my-app.db
# test cds deploy command with --dry. Displays ever table and view it creates
cds deploy --to sqlite:db/my-app.db --dry
# get and overview of your tables with .tables
sqlite3 db/my-app.db .tables
# open and view newly created db
sqlite3 db/my-app.db -cmd .dump
# and select single field with
SELECT field FROM mytable WHERE mykeyfield= "00505601194D1EE9B7BFC518B85";
# update a field with
UPDATE mytable SET field = "test" WHERE mykeyfield= "00505601194D1EE9B7BFC518B85";
OAC0 – Content Repository pflege (extern oder lokale DB, dafür die Tabelle SDOKCONT1 als Vorlage nehmen)
OAC2 – Dokumentenarten
OAC3 – Verknüpfung der Dokumentenart zum Content Repository. Zuordnung Objektyp.
PARAMETER p_test TYPE c OBLIGATORY AS LISTBOX VISIBLE LENGTH 32 DEFAULT 1.
INITIALIZATION.
cl_reca_ddic_doma=>get_values( EXPORTING id_name = 'Z_MYDOMAIN'
IMPORTING et_values = DATA(lt_rsdomaval) ).
CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = 'P_TEST'
values = VALUE vrm_values( FOR dvalue IN lt_rsdomaval ( key = dvalue-domvalue_l
text = dvalue-ddtext ) ).
" Check if class exists and is activated
IF cl_esh_ca_check=>is_active_class( 'ZCL_MYCLASS' ) = abap_true.
WRITE: 'Class exists'.
ENDIF.
Via Infotype
TRY.
DATA(lo_employee_api) = cl_hcmfab_employee_api=>get_instance( ).
DATA(lv_pernr) = lo_employee_api->get_employeenumber_from_user( sy-uname ).
DATA(lv_ename) = lo_employee_api->get_name( lv_pernr ).
CATCH cx_hcmfab_common.
ENDTRY.
or via SU01
DATA(lv_ename) = NEW cl_hreic_appl_utilities( )->get_user_name( sy-uname ).
DATA p0001 TYPE p0001.
cl_hcmfab_utilities=>read_infotype_record( EXPORTING iv_pernr = pernr
iv_infty = '0001'
IMPORTING es_pnnnn = p0001 ).
DATA(personnel_area_id) = p0001-werks.
DATA(personnel_area_text) = cl_hr_t500p=>read( p0001-werks )-name1.
Or using the class CL_HCMFAB_EMPLOYEE_API.
DATA(lv_employee_details) = cl_hcmfab_employee_api=>get_instance( )->get_employee_details( iv_pernr = pernr
iv_application_id = if_hcmfab_constants=>gc_application_id-mypersonaldata ).
DATA(personnel_area_id) = lv_employee_details-personnel_area_id.
DATA(personnel_area_text) = lv_employee_details-personnel_area_text.
REPORT ztest.
TABLES pa0002.
*-----------------------------------------------------------------------
* Selection screen
*-----------------------------------------------------------------------
PARAMETERS: p_radio1 RADIOBUTTON GROUP rad1 DEFAULT 'X' USER-COMMAND rad. "set s_pernr visible
PARAMETERS: p_radio2 RADIOBUTTON GROUP rad1. "set s_pernr invisible
SELECT-OPTIONS : s_pernr FOR pa0002-pernr MODIF ID 100.
*----------------------------------------------------------------------
* AT SELECTION-SCREEN
*----------------------------------------------------------------------
AT SELECTION-SCREEN OUTPUT. " PBO
LOOP AT SCREEN.
CASE screen-group1.
WHEN '100'.
screen-invisible = COND #( WHEN p_radio1 = abap_true THEN 0 ELSE 1 ).
MODIFY SCREEN.
ENDCASE.
ENDLOOP.