*&---------------------------------------------------------------------*
*& Module STATUS_0110 OUTPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE STATUS_0110 OUTPUT.
* SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR '110'.
ENDMODULE. " STATUS_0110 OUTPUT
*&---------------------------------------------------------------------*
*& Module USER_COMMAND_0110 INPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE USER_COMMAND_0110 INPUT.
CASE SY-UCOMM.
WHEN 'RESET'.
CLEAR: USER_ID , PASSWORD.
WHEN 'EXIT' .
LEAVE PROGRAM.
WHEN 'DISPLAY'.
SELECT SINGLE EMP_ID FROM ZPROJECT_EMP INTO TEMP_ID
WHERE EMP_ID = USER_ID.
SELECT SINGLE PASSCODE FROM ZPROJECT_EMP INTO TEMP_PASS
WHERE EMP_ID = USER_ID.
IF USER_ID EQ TEMP_ID AND PASSWORD EQ TEMP_PASS .
MESSAGE 'EMPLOYEE LOGIN' TYPE 'S'.
CALL SCREEN 0115.
ELSEIF USER_ID EQ TEMP_ID AND PASSWORD EQ ' '.
MESSAGE I000(zmsg_eas).
ELSEIF USER_ID EQ TEMP_ID AND NOT PASSWORD EQ TEMP_PASS.
CLEAR PASSWORD.
MESSAGE I001(ZMSG_EAS).
ELSE.
CLEAR: USER_ID , PASSWORD.
MESSAGE I002(ZMSG_EAS).
CALL SCREEN 1000.
ENDIF.
WHEN 'BACK'.
CLEAR : USER_ID , PASSWORD.
CALL SCREEN 1000.
ENDCASE.
ENDMODULE. " USER_COMMAND_0110 INPUT
*&---------------------------------------------------------------------*
*& Module STATUS_0115 OUTPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE STATUS_0115 OUTPUT.
* SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR '115'.
ENDMODULE. " STATUS_0115 OUTPUT
*&---------------------------------------------------------------------*
*& Module USER_COMMAND_0115 INPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE USER_COMMAND_0115 INPUT.
CASE SY-UCOMM.
WHEN 'BACK'.
CLEAR : USER_ID , PASSWORD.
CALL SCREEN 110.
WHEN 'EXIT'.
LEAVE PROGRAM.
WHEN 'CANCEL'.
CLEAR : USER_ID , PASSWORD.
CALL SCREEN 1000.
WHEN 'PRINT'.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'ZPROJECT_EAS'
IMPORTING
fm_name = fname.
CALL FUNCTION fname
EXPORTING
user_id = USER_ID.
WHEN 'PROJECT_DETAILS'.
CALL SCREEN 0116.
WHEN 'DEFINE_KPI_&_MARKS'.
CALL SCREEN 0117.
WHEN 'UPDATE_BASIC_DETAILS'.
CALL SCREEN 0118.
WHEN 'VMAAR'.
CALL SCREEN 119.
WHEN 'RGAMR'.
CALL SCREEN 123.
WHEN 'MKOM'.
CALL SCREEN 1115.
WHEN 'VKM'.
SELECT * FROM ZPROJECT_KPI INTO TABLE KPI_DETAILS WHERE EMP_ID = USER_ID.
refresh IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'EMP_ID'.
WA_FIELDCAT-SELTEXT_M = 'EMP_ID'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'DEPT_NAME'.
WA_FIELDCAT-SELTEXT_M = 'DEPT_NAME'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_1'.
WA_FIELDCAT-SELTEXT_M = 'KPI_1'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_1'.
WA_FIELDCAT-SELTEXT_M = 'TIME_1'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_1'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_1'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_2'.
WA_FIELDCAT-SELTEXT_M = 'KPI_2'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_2'.
WA_FIELDCAT-SELTEXT_M = 'TIME_2'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_2'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_2'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_3'.
WA_FIELDCAT-SELTEXT_M = 'KPI_3'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_3'.
WA_FIELDCAT-SELTEXT_M = 'TIME_3'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_3'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_3'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_4'.
WA_FIELDCAT-SELTEXT_M = 'KPI_4'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_4'.
WA_FIELDCAT-SELTEXT_M = 'TIME_4'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_4'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_4'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_5'.
WA_FIELDCAT-SELTEXT_M = 'KPI_5'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_5'.
WA_FIELDCAT-SELTEXT_M = 'TIME_5'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_5'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_5'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
IT_FIELDCAT = IT_FIELDCAT
TABLES
T_OUTTAB = KPI_DETAILS.
WHEN 'VPR'.
SELECT * FROM ZPROJECT_DETAILS INTO TABLE PROJECT_DETAILS
WHERE EMP_ID = USER_ID.
refresh IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'EMP_ID'.
WA_FIELDCAT-SELTEXT_M = 'EMP_ID'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'DEPT_NAME'.
WA_FIELDCAT-SELTEXT_M = 'DEPT_NAME'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'PROJECT_NAME'.
WA_FIELDCAT-SELTEXT_M = 'PROJECT_NAME'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'PROJECT_STATUS'.
WA_FIELDCAT-SELTEXT_M = 'PROJECT_STATUS'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
IT_FIELDCAT = IT_FIELDCAT
TABLES
T_OUTTAB = PROJECT_DETAILS.
ENDCASE.
ENDMODULE. " USER_COMMAND_0115 INPUT
*& Module STATUS_0110 OUTPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE STATUS_0110 OUTPUT.
* SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR '110'.
ENDMODULE. " STATUS_0110 OUTPUT
*&---------------------------------------------------------------------*
*& Module USER_COMMAND_0110 INPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE USER_COMMAND_0110 INPUT.
CASE SY-UCOMM.
WHEN 'RESET'.
CLEAR: USER_ID , PASSWORD.
WHEN 'EXIT' .
LEAVE PROGRAM.
WHEN 'DISPLAY'.
SELECT SINGLE EMP_ID FROM ZPROJECT_EMP INTO TEMP_ID
WHERE EMP_ID = USER_ID.
SELECT SINGLE PASSCODE FROM ZPROJECT_EMP INTO TEMP_PASS
WHERE EMP_ID = USER_ID.
IF USER_ID EQ TEMP_ID AND PASSWORD EQ TEMP_PASS .
MESSAGE 'EMPLOYEE LOGIN' TYPE 'S'.
CALL SCREEN 0115.
ELSEIF USER_ID EQ TEMP_ID AND PASSWORD EQ ' '.
MESSAGE I000(zmsg_eas).
ELSEIF USER_ID EQ TEMP_ID AND NOT PASSWORD EQ TEMP_PASS.
CLEAR PASSWORD.
MESSAGE I001(ZMSG_EAS).
ELSE.
CLEAR: USER_ID , PASSWORD.
MESSAGE I002(ZMSG_EAS).
CALL SCREEN 1000.
ENDIF.
WHEN 'BACK'.
CLEAR : USER_ID , PASSWORD.
CALL SCREEN 1000.
ENDCASE.
ENDMODULE. " USER_COMMAND_0110 INPUT
*&---------------------------------------------------------------------*
*& Module STATUS_0115 OUTPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE STATUS_0115 OUTPUT.
* SET PF-STATUS 'xxxxxxxx'.
SET TITLEBAR '115'.
ENDMODULE. " STATUS_0115 OUTPUT
*&---------------------------------------------------------------------*
*& Module USER_COMMAND_0115 INPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
MODULE USER_COMMAND_0115 INPUT.
CASE SY-UCOMM.
WHEN 'BACK'.
CLEAR : USER_ID , PASSWORD.
CALL SCREEN 110.
WHEN 'EXIT'.
LEAVE PROGRAM.
WHEN 'CANCEL'.
CLEAR : USER_ID , PASSWORD.
CALL SCREEN 1000.
WHEN 'PRINT'.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'ZPROJECT_EAS'
IMPORTING
fm_name = fname.
CALL FUNCTION fname
EXPORTING
user_id = USER_ID.
WHEN 'PROJECT_DETAILS'.
CALL SCREEN 0116.
WHEN 'DEFINE_KPI_&_MARKS'.
CALL SCREEN 0117.
WHEN 'UPDATE_BASIC_DETAILS'.
CALL SCREEN 0118.
WHEN 'VMAAR'.
CALL SCREEN 119.
WHEN 'RGAMR'.
CALL SCREEN 123.
WHEN 'MKOM'.
CALL SCREEN 1115.
WHEN 'VKM'.
SELECT * FROM ZPROJECT_KPI INTO TABLE KPI_DETAILS WHERE EMP_ID = USER_ID.
refresh IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'EMP_ID'.
WA_FIELDCAT-SELTEXT_M = 'EMP_ID'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'DEPT_NAME'.
WA_FIELDCAT-SELTEXT_M = 'DEPT_NAME'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_1'.
WA_FIELDCAT-SELTEXT_M = 'KPI_1'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_1'.
WA_FIELDCAT-SELTEXT_M = 'TIME_1'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_1'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_1'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_2'.
WA_FIELDCAT-SELTEXT_M = 'KPI_2'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_2'.
WA_FIELDCAT-SELTEXT_M = 'TIME_2'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_2'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_2'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_3'.
WA_FIELDCAT-SELTEXT_M = 'KPI_3'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_3'.
WA_FIELDCAT-SELTEXT_M = 'TIME_3'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_3'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_3'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_4'.
WA_FIELDCAT-SELTEXT_M = 'KPI_4'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_4'.
WA_FIELDCAT-SELTEXT_M = 'TIME_4'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_4'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_4'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'KPI_5'.
WA_FIELDCAT-SELTEXT_M = 'KPI_5'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'TIME_5'.
WA_FIELDCAT-SELTEXT_M = 'TIME_5'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'QUALITY_5'.
WA_FIELDCAT-SELTEXT_M = 'QUALITY_5'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
IT_FIELDCAT = IT_FIELDCAT
TABLES
T_OUTTAB = KPI_DETAILS.
WHEN 'VPR'.
SELECT * FROM ZPROJECT_DETAILS INTO TABLE PROJECT_DETAILS
WHERE EMP_ID = USER_ID.
refresh IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'EMP_ID'.
WA_FIELDCAT-SELTEXT_M = 'EMP_ID'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'DEPT_NAME'.
WA_FIELDCAT-SELTEXT_M = 'DEPT_NAME'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'PROJECT_NAME'.
WA_FIELDCAT-SELTEXT_M = 'PROJECT_NAME'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
WA_FIELDCAT-FIELDNAME = 'PROJECT_STATUS'.
WA_FIELDCAT-SELTEXT_M = 'PROJECT_STATUS'.
APPEND WA_FIELDCAT TO IT_FIELDCAT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
IT_FIELDCAT = IT_FIELDCAT
TABLES
T_OUTTAB = PROJECT_DETAILS.
ENDCASE.
ENDMODULE. " USER_COMMAND_0115 INPUT
Output:
Employee Login Page
Employee Navigation page
No comments:
Post a Comment