File tree Expand file tree Collapse file tree 3 files changed +23
-0
lines changed Expand file tree Collapse file tree 3 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -153,6 +153,14 @@ CLASS y_code_pal_service IMPLEMENTATION.
153
153
RETURN .
154
154
ENDIF .
155
155
156
+ TRY .
157
+ y_profile_manager=>create( )->delete_profiles( ).
158
+ CATCH ycx_failed_to_remove_a_line.
159
+ raise_internal_server_error( ).
160
+ response->set_cdata( 'Profiles were not disabled' ).
161
+ RETURN .
162
+ ENDTRY .
163
+
156
164
DATA (atc ) = NEW cl_satc_api_factory( ).
157
165
158
166
TRY .
Original file line number Diff line number Diff line change @@ -82,6 +82,9 @@ INTERFACE y_if_profile_manager
82
82
!profile TYPE ytab_profiles
83
83
RAISING
84
84
ycx_failed_to_remove_a_line .
85
+ METHODS delete_profiles
86
+ RAISING
87
+ ycx_failed_to_remove_a_line .
85
88
METHODS delete_check
86
89
IMPORTING
87
90
!check TYPE ytab_checks
Original file line number Diff line number Diff line change @@ -151,6 +151,18 @@ CLASS y_profile_manager IMPLEMENTATION.
151
151
ENDMETHOD .
152
152
153
153
154
+ METHOD y_if_profile_manager ~delete_profiles .
155
+ TRY .
156
+ DATA (profiles ) = y_if_profile_manager~select_profiles( sy -uname ).
157
+ CATCH ycx_entry_not_found.
158
+ RETURN .
159
+ ENDTRY .
160
+
161
+ LOOP AT profiles ASSIGNING FIELD-SYMBOL (<profile> ).
162
+ y_if_profile_manager~delete_profile( <profile> ).
163
+ ENDLOOP .
164
+ ENDMETHOD .
165
+
154
166
METHOD y_if_profile_manager ~get_checks_type_name .
155
167
result = checks_type.
156
168
ENDMETHOD .
You can’t perform that action at this time.
0 commit comments