1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 | |
28 | |
29 |
30 |
31 |
32 | FORM system. |
33 |
34 | PERFORM system_component. |
35 |
36 | PERFORM system_kernel. |
37 |
38 | PERFORM system_status. |
39 | |
40 | ENDFORM. "system |
41 | |
42 | |
43 |
44 |
45 |
46 | FORM system_component. |
47 | |
48 | DATA: |
49 | lt_component TYPE it_component, |
50 | ls_component TYPE st_component, |
51 | lt_cvers TYPE STANDARD TABLE OF cvers, |
52 | lt_html TYPE it_string. |
53 | |
54 | FIELD-SYMBOLS: |
55 | <ls_cvers> TYPE cvers. |
56 | |
57 | SELECT * FROM cvers INTO TABLE lt_cvers. |
58 | LOOP AT lt_cvers ASSIGNING <ls_cvers>. |
59 | CLEAR ls_component. |
60 | ls_component-component = <ls_cvers>-component. |
61 | ls_component-release = <ls_cvers>-release. |
62 | CALL FUNCTION 'OCS_GET_COMPONENT_STATE' |
63 | EXPORTING |
64 | iv_component = <ls_cvers>-component |
65 | IMPORTING |
66 | ev_comp_level = ls_component-level |
67 | ev_last_patch = ls_component-high_package |
68 | EXCEPTIONS |
69 | OTHERS = 1. |
70 | SELECT SINGLE desc_text FROM cvers_ref INTO ls_component-desc_text |
71 | WHERE component = <ls_cvers>-component |
72 | AND langu = sy-langu. |
73 | APPEND ls_component TO lt_component. |
74 | ENDLOOP. |
75 | |
76 |
77 | PERFORM html_main_popupheader |
78 | USING |
79 | txt_component_information |
80 | CHANGING |
81 | lt_html. |
82 |
83 | PERFORM html_add_tablenodiv |
84 | USING |
85 | 'MENU_COMPO' |
86 | lt_component |
87 | lt_component |
88 | CHANGING |
89 | lt_html. |
90 |
91 | PERFORM html_main_popupfooter |
92 | CHANGING lt_html. |
93 |
94 | PERFORM download |
95 | USING |
96 | lt_html |
97 | 'MENU' |
98 | 'SYSTEM' |
99 | 'COMPONENT' |
100 | gc_extension_htm |
101 | abap_false. |
102 | |
103 | ENDFORM. "system_component |
104 | |
105 | |
106 |
107 |
108 |
109 | FORM system_kernel. |
110 | |
111 | DATA: |
112 | ls_textinput TYPE st_textinput, |
113 | lt_kernel TYPE it_textinput, |
114 | lt_database TYPE it_textinput, |
115 | lt_system TYPE it_textinput, |
116 | lt_html TYPE it_string, |
117 | ls_dbinfo TYPE dbrelinfo. |
118 | |
119 | FIELD-SYMBOLS: |
120 | <l_patchlevel> TYPE ANY. |
121 | |
122 | CALL FUNCTION 'DB_DBRELINFO' |
123 | IMPORTING |
124 | dbinfo = ls_dbinfo. |
125 | |
126 |
127 |
128 | CLEAR ls_textinput. |
129 | ls_textinput-name = txt_kernel_release. |
130 | ls_textinput-input = abap_true. |
131 | PERFORM get_version_info |
132 | USING 'kernel release' |
133 | CHANGING ls_textinput-value. |
134 | APPEND ls_textinput TO lt_kernel. |
135 |
136 | CLEAR ls_textinput. |
137 | ls_textinput-name = txt_compilation. |
138 | ls_textinput-input = abap_true. |
139 | PERFORM get_version_info |
140 | USING 'kernel compiled' |
141 | CHANGING ls_textinput-value. |
142 | APPEND ls_textinput TO lt_kernel. |
143 |
144 | CLEAR ls_textinput. |
145 | ls_textinput-name = txt_sup_pkg_lvl. |
146 | ls_textinput-input = abap_true. |
147 | PERFORM get_version_info |
148 | USING 'kernel patch level' |
149 | CHANGING ls_textinput-value. |
150 | APPEND ls_textinput TO lt_kernel. |
151 |
152 | CLEAR ls_textinput. |
153 | ls_textinput-name = txt_abap_load. |
154 | ls_textinput-input = abap_true. |
155 | PERFORM get_version_info |
156 | USING 'ABAP load version' |
157 | CHANGING ls_textinput-value. |
158 | APPEND ls_textinput TO lt_kernel. |
159 |
160 | CLEAR ls_textinput. |
161 | ls_textinput-name = txt_cua_load. |
162 | ls_textinput-input = abap_true. |
163 | PERFORM get_version_info |
164 | USING 'CUA load version' |
165 | CHANGING ls_textinput-value. |
166 | APPEND ls_textinput TO lt_kernel. |
167 |
168 | CLEAR ls_textinput. |
169 | ls_textinput-name = txt_mode. |
170 | ls_textinput-input = abap_true. |
171 | PERFORM get_version_info |
172 | USING 'kernel kind' |
173 | CHANGING ls_textinput-value. |
174 | APPEND ls_textinput TO lt_kernel. |
175 |
176 | CLEAR ls_textinput. |
177 | ls_textinput-name = txt_rsyn_file. |
178 | ls_textinput-input = abap_true. |
179 | PERFORM get_version_info |
180 | USING 'rsyn' |
181 | CHANGING ls_textinput-value. |
182 | APPEND ls_textinput TO lt_kernel. |
183 | |
184 |
185 |
186 | CLEAR ls_textinput. |
187 | ls_textinput-name = txt_db_client_lib. |
188 | ls_textinput-input = abap_true. |
189 | ls_textinput-value = ls_dbinfo-clirel. |
190 | APPEND ls_textinput TO lt_database. |
191 |
192 | CLEAR ls_textinput. |
193 | ls_textinput-name = txt_db_releases. |
194 | ls_textinput-input = abap_true. |
195 | ls_textinput-value = ls_dbinfo-releases. |
196 | APPEND ls_textinput TO lt_database. |
197 |
198 | CLEAR ls_textinput. |
199 | ls_textinput-name = txt_dbsl_version. |
200 | ls_textinput-input = abap_true. |
201 | ls_textinput-value = ls_dbinfo-dbsl_vers. |
202 | APPEND ls_textinput TO lt_database. |
203 |
204 | ASSIGN COMPONENT 'PATCHLEVEL' OF STRUCTURE ls_dbinfo |
205 | TO <l_patchlevel>. |
206 | IF <l_patchlevel> IS ASSIGNED. |
207 | CLEAR ls_textinput. |
208 | ls_textinput-name = txt_dbsl_patch_level. |
209 | ls_textinput-input = abap_true. |
210 | ls_textinput-value = <l_patchlevel>. |
211 | APPEND ls_textinput TO lt_database. |
212 | ENDIF. |
213 | |
214 |
215 |
216 | CLEAR ls_textinput. |
217 | ls_textinput-name = txt_ip_address. |
218 | ls_textinput-input = abap_true. |
219 | PERFORM get_version_info |
220 | USING 'IP address' |
221 | CHANGING ls_textinput-value. |
222 | APPEND ls_textinput TO lt_system. |
223 |
224 | CLEAR ls_textinput. |
225 | ls_textinput-name = txt_sap_versions. |
226 | ls_textinput-input = abap_true. |
227 | PERFORM get_version_info |
228 | USING 'supported SAP vers.' |
229 | CHANGING ls_textinput-value. |
230 | APPEND ls_textinput TO lt_system. |
231 |
232 | CLEAR ls_textinput. |
233 | ls_textinput-name = txt_operating_system. |
234 | ls_textinput-input = abap_true. |
235 | PERFORM get_version_info |
236 | USING 'valid OP system' |
237 | CHANGING ls_textinput-value. |
238 | APPEND ls_textinput TO lt_system. |
239 |
240 | CLEAR ls_textinput. |
241 | ls_textinput-name = txt_op_release. |
242 | ls_textinput-input = abap_true. |
243 | PERFORM get_version_info |
244 | USING 'OP system release' |
245 | CHANGING ls_textinput-value. |
246 | APPEND ls_textinput TO lt_system. |
247 | |
248 |
249 | PERFORM html_main_popupheader |
250 | USING |
251 | txt_component_information |
252 | CHANGING |
253 | lt_html. |
254 |
255 | PERFORM html_add_box1ti_2tivernodiv |
256 | USING |
257 | txt_kernel_information___2 |
258 | lt_kernel |
259 | txt_database_information |
260 | lt_database |
261 | txt_system_information |
262 | lt_system |
263 | CHANGING |
264 | lt_html. |
265 |
266 | PERFORM html_main_popupfooter |
267 | CHANGING lt_html. |
268 |
269 | PERFORM download |
270 | USING |
271 | lt_html |
272 | 'MENU' |
273 | 'SYSTEM' |
274 | 'KERNEL' |
275 | gc_extension_htm |
276 | abap_false. |
277 | |
278 | ENDFORM. "system_kernel |
279 | |
280 | |
281 |
282 |
283 |
284 | FORM system_status. |
285 | |
286 | DATA: |
287 | ls_textinput TYPE st_textinput, |
288 | lt_usage_data_r TYPE it_textinput, |
289 | lt_usage_data_l TYPE it_textinput, |
290 | lt_repository_data TYPE it_textinput, |
291 | lt_sap_system_data TYPE it_textinput, |
292 | lt_host_data TYPE it_textinput, |
293 | lt_database_data TYPE it_textinput, |
294 | lt_html TYPE it_string, |
295 | ls_last_logon TYPE st_last_logon, |
296 | l_name TYPE ad_namtext, |
297 | l_laiso TYPE laiso, |
298 | l_sptxt TYPE sptxt, |
299 | l_title TYPE rs38m-repti, |
300 | l_date TYPE sydatum, |
301 | l_db_release(10) TYPE c, |
302 | l_servername(40) TYPE c, |
303 | l_unicode TYPE c, |
304 | l_exists TYPE flag, |
305 | l_ttext TYPE ttext_stct, |
306 | l_stext(40) TYPE c, |
307 | l_repid TYPE syrepid, |
308 | lt_list TYPE STANDARD TABLE OF msxxlist. |
309 | |
310 | FIELD-SYMBOLS: |
311 | <ls_list> TYPE msxxlist. |
312 | |
313 |
314 | GET PARAMETER ID 'US2' FIELD ls_last_logon. |
315 | |
316 |
317 |
318 | CLEAR ls_textinput. |
319 | ls_textinput-name = txt_client. |
320 | ls_textinput-input = abap_true. |
321 | ls_textinput-value = sy-mandt. |
322 | APPEND ls_textinput TO lt_usage_data_l. |
323 |
324 | CLEAR ls_textinput. |
325 | ls_textinput-name = txt_user. |
326 | ls_textinput-input = abap_true. |
327 | ls_textinput-value = sy-uname. |
328 | PERFORM get_user |
329 | USING sy-uname |
330 | CHANGING l_name. |
331 | ls_textinput-value_text = l_name. |
332 | APPEND ls_textinput TO lt_usage_data_l. |
333 |
334 | CLEAR ls_textinput. |
335 | ls_textinput-name = txt_language. |
336 | ls_textinput-input = abap_true. |
337 | PERFORM get_spras |
338 | USING sy-langu |
339 | CHANGING l_laiso l_sptxt. |
340 | ls_textinput-value = l_laiso. |
341 | ls_textinput-value_text = l_sptxt. |
342 | APPEND ls_textinput TO lt_usage_data_l. |
343 |
344 | CLEAR ls_textinput. |
345 | ls_textinput-name = txt_previous_logon. |
346 | ls_textinput-input = abap_true. |
347 | ls_textinput-has_value_ext = abap_true. |
348 | PERFORM get_date |
349 | USING ls_last_logon-date |
350 | CHANGING ls_textinput-value. |
351 | PERFORM get_time |
352 | USING ls_last_logon-time |
353 | CHANGING ls_textinput-value_ext. |
354 | APPEND ls_textinput TO lt_usage_data_r. |
355 |
356 | CLEAR ls_textinput. |
357 | ls_textinput-name = txt_logon. |
358 | ls_textinput-input = abap_true. |
359 | ls_textinput-has_value_ext = abap_true. |
360 | PERFORM get_date |
361 | USING ls_last_logon-date_now |
362 | CHANGING ls_textinput-value. |
363 | PERFORM get_time |
364 | USING ls_last_logon-time_now |
365 | CHANGING ls_textinput-value_ext. |
366 | APPEND ls_textinput TO lt_usage_data_r. |
367 |
368 | CLEAR ls_textinput. |
369 | ls_textinput-name = txt_system_time. |
370 | ls_textinput-input = abap_true. |
371 | ls_textinput-has_value_ext = abap_true. |
372 | PERFORM get_date |
373 | USING sy-datum |
374 | CHANGING ls_textinput-value. |
375 | PERFORM get_time |
376 | USING sy-uzeit |
377 | CHANGING ls_textinput-value_ext. |
378 | APPEND ls_textinput TO lt_usage_data_r. |
379 | |
380 |
381 | l_repid = sy-repid. |
382 |
383 | CLEAR ls_textinput. |
384 | ls_textinput-name = txt_transaction. |
385 | ls_textinput-input = abap_true. |
386 | ls_textinput-value = sy-tcode. |
387 | SELECT SINGLE ttext FROM tstct INTO l_ttext |
388 | WHERE sprsl = sy-langu |
389 | AND tcode = sy-tcode. |
390 | ls_textinput-value_text = l_ttext. |
391 | APPEND ls_textinput TO lt_repository_data. |
392 |
393 | CLEAR ls_textinput. |
394 | ls_textinput-name = txt_program_screen. |
395 | ls_textinput-input = abap_true. |
396 | ls_textinput-value = l_repid. |
397 | CALL FUNCTION 'PROGRAM_TITLE' |
398 | EXPORTING |
399 | program = l_repid |
400 | language = sy-langu |
401 | IMPORTING |
402 | title = l_title. |
403 | ls_textinput-value_text = l_title. |
404 | APPEND ls_textinput TO lt_repository_data. |
405 |
406 | CLEAR ls_textinput. |
407 | ls_textinput-name = txt_screen_number. |
408 | ls_textinput-input = abap_true. |
409 | ls_textinput-value = sy-dynnr. |
410 | APPEND ls_textinput TO lt_repository_data. |
411 |
412 | CLEAR ls_textinput. |
413 | ls_textinput-name = txt_program_gui. |
414 | ls_textinput-input = abap_true. |
415 | ls_textinput-value = l_repid. |
416 | CALL FUNCTION 'PROGRAM_TITLE' |
417 | EXPORTING |
418 | program = l_repid |
419 | language = sy-langu |
420 | IMPORTING |
421 | title = l_title. |
422 | ls_textinput-value_text = l_title. |
423 | APPEND ls_textinput TO lt_repository_data. |
424 |
425 | CLEAR ls_textinput. |
426 | ls_textinput-name = txt_gui_status. |
427 | ls_textinput-input = abap_true. |
428 | ls_textinput-value = sy-pfkey. |
429 | APPEND ls_textinput TO lt_repository_data. |
430 | |
431 |
432 |
433 | CLEAR ls_textinput. |
434 | ls_textinput-name = txt_component_version. |
435 | ls_textinput-input = abap_true. |
436 | SELECT SINGLE stext FROM cvers_txt INTO l_stext |
437 | WHERE langu = sy-langu. |
438 | IF sy-subrc <> 0. |
439 | SELECT SINGLE stext FROM cvers_txt INTO l_stext |
440 | WHERE langu = 'EN'. |
441 | ENDIF. |
442 | ls_textinput-value = l_stext. |
443 | APPEND ls_textinput TO lt_sap_system_data. |
444 |
445 | CLEAR ls_textinput. |
446 | ls_textinput-space = abap_true. |
447 | APPEND ls_textinput TO lt_sap_system_data. |
448 |
449 | CLEAR ls_textinput. |
450 | ls_textinput-name = txt_installation_number. |
451 | ls_textinput-input = abap_true. |
452 | CALL FUNCTION 'SLIC_GET_LICENCE_NUMBER' |
453 | IMPORTING |
454 | license_number = ls_textinput-value. |
455 | APPEND ls_textinput TO lt_sap_system_data. |
456 |
457 | CLEAR ls_textinput. |
458 | ls_textinput-name = txt_license_expiration. |
459 | ls_textinput-input = abap_true. |
460 | CALL FUNCTION 'SLIC_GET_LICENCE_DATE' |
461 | IMPORTING |
462 | licence_date = l_date. |
463 | PERFORM get_date |
464 | USING l_date |
465 | CHANGING ls_textinput-value. |
466 | APPEND ls_textinput TO lt_sap_system_data. |
467 |
468 | PERFORM get_fuba_exists |
469 | USING 'SLDAG_CHECK_FOR_UNICODE' |
470 | CHANGING l_exists. |
471 | IF l_exists = abap_true. |
472 | CLEAR ls_textinput. |
473 | ls_textinput-name = txt_unicode_system. |
474 | ls_textinput-input = abap_true. |
475 | CALL FUNCTION 'SLDAG_CHECK_FOR_UNICODE' |
476 | IMPORTING |
477 | unicode = l_unicode. |
478 | IF l_unicode = 1. |
479 | ls_textinput-value = txt_yes. |
480 | ELSE. |
481 | ls_textinput-value = txt_no. |
482 | ENDIF. |
483 | APPEND ls_textinput TO lt_sap_system_data. |
484 | ENDIF. |
485 | |
486 |
487 |
488 | CLEAR ls_textinput. |
489 | ls_textinput-name = txt_operating_system. |
490 | ls_textinput-input = abap_true. |
491 | ls_textinput-value = sy-opsys. |
492 | APPEND ls_textinput TO lt_host_data. |
493 |
494 | CLEAR ls_textinput. |
495 | ls_textinput-name = txt_machine_type. |
496 | ls_textinput-input = abap_true. |
497 | PERFORM get_version_info |
498 | USING 'machine type' |
499 | CHANGING ls_textinput-value. |
500 | APPEND ls_textinput TO lt_host_data. |
501 |
502 | CLEAR ls_textinput. |
503 | ls_textinput-name = txt_server_name. |
504 | ls_textinput-input = abap_true. |
505 |
506 | CALL FUNCTION 'TH_SERVER_LIST' |
507 | TABLES |
508 | list = lt_list |
509 | EXCEPTIONS |
510 | OTHERS = 1. |
511 | READ TABLE lt_list ASSIGNING <ls_list> INDEX 1. |
512 | IF <ls_list> IS ASSIGNED. |
513 | l_servername = <ls_list>-name. |
514 | ELSE. |
515 |
516 |
517 |
518 |
519 | CLEAR l_servername. |
520 | ENDIF. |
521 | ls_textinput-value = l_servername. |
522 | APPEND ls_textinput TO lt_host_data. |
523 |
524 | CLEAR ls_textinput. |
525 | ls_textinput-name = txt_platform_id. |
526 | ls_textinput-input = abap_true. |
527 | PERFORM get_version_info |
528 | USING 'SAP system id' |
529 | CHANGING ls_textinput-value. |
530 | APPEND ls_textinput TO lt_host_data. |
531 | |
532 |
533 |
534 | CLEAR ls_textinput. |
535 | ls_textinput-name = txt_database_system. |
536 | ls_textinput-input = abap_true. |
537 | PERFORM get_version_info |
538 | USING 'database system' |
539 | CHANGING ls_textinput-value. |
540 | APPEND ls_textinput TO lt_database_data. |
541 |
542 | CLEAR ls_textinput. |
543 | ls_textinput-name = txt_release. |
544 | ls_textinput-input = abap_true. |
545 | CALL FUNCTION 'DB_GET_RELEASE' |
546 | IMPORTING |
547 | release = l_db_release. |
548 | ls_textinput-value = l_db_release. |
549 | APPEND ls_textinput TO lt_database_data. |
550 |
551 | CLEAR ls_textinput. |
552 | ls_textinput-name = txt_name. |
553 | ls_textinput-input = abap_true. |
554 | PERFORM get_version_info |
555 | USING 'database name' |
556 | CHANGING ls_textinput-value. |
557 | APPEND ls_textinput TO lt_database_data. |
558 |
559 | CLEAR ls_textinput. |
560 | ls_textinput-name = txt_host. |
561 | ls_textinput-input = abap_true. |
562 | PERFORM get_version_info |
563 | USING 'database host' |
564 | CHANGING ls_textinput-value. |
565 | ls_textinput-value = sy-host. |
566 | TRANSLATE ls_textinput-value TO UPPER CASE. |
567 | APPEND ls_textinput TO lt_database_data. |
568 |
569 | CLEAR ls_textinput. |
570 | ls_textinput-name = txt_owner. |
571 | ls_textinput-input = abap_true. |
572 | PERFORM get_version_info |
573 | USING 'database owner' |
574 | CHANGING ls_textinput-value. |
575 | APPEND ls_textinput TO lt_database_data. |
576 | |
577 |
578 | PERFORM html_main_popupheader |
579 | USING |
580 | txt_status |
581 | CHANGING |
582 | lt_html. |
583 |
584 | PERFORM html_add_box1tidbl_box2ti_2tix |
585 | USING |
586 | txt_usage_data |
587 | lt_usage_data_l |
588 | lt_usage_data_r |
589 | txt_sap_data |
590 | txt_repository_data |
591 | txt_sap_system_data |
592 | lt_repository_data |
593 | lt_sap_system_data |
594 | txt_host_data |
595 | txt_database_data |
596 | lt_host_data |
597 | lt_database_data |
598 | CHANGING |
599 | lt_html. |
600 |
601 | PERFORM html_main_popupfooter |
602 | CHANGING lt_html. |
603 |
604 | PERFORM download |
605 | USING |
606 | lt_html |
607 | 'MENU' |
608 | 'SYSTEM' |
609 | 'STATUS' |
610 | gc_extension_htm |
611 | abap_false. |
612 | |
613 | ENDFORM. "system_status |