Fonction SAP BAPI_TRIP_REPORT_INIT - Tables Needed for REPORT_CREATE (Local Workspace)

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
CHECK_OVERLAP BAPITRVXXX-BOOLEAN C 1 SPACE X Check Overlaps with Existing Trips (X/SPACE)
DATE BAPITRVXXX-DATE D 8 SY-DATUM X Date of Authorization and Overlap Check
EMPLOYEENUMBER BAPIEMPL-PERNR N 8 Employee's personnel number
LANGUAGE BAPITRVXXX-LANGU C 1 SY-LANGU X Language of Rel. Table Entries
SEL_COUN BAPITRVXXX-BOOLEAN C 1 SPACE X Fill Table T706O_DAT (X/SPACE)
SEL_CURR BAPITRVXXX-BOOLEAN C 1 SPACE X Fill Table TCURR_DAT /X/SPACE)

Paramètre Reférence Type Long. Description
RETURN BAPIRETURN u 452 Return Value (Instead of Exceptions)

Paramètre Reférence Long. Facultatif Description
DEFAULTS BAPITRVDEF 26 Default Values for Travel Expenses (PR04)
EMP_INFO BAPITRVEMP 201 X Infos for Personnel Number
T706B_DAT BAPITR706B 87 Table of Expense Types
T706O_DAT BAPITR706O 33 X Table of Countries
TCURR_DAT BAPITRCURR 71 X Table of Currencies

Functionality
Using the method EmployeeTrip.GetOptionsWeekly you can obtainall tables and default values needed to create a simple weekly report(transaction PR04).
The import parameter EmployeeNumber determines the personnelnumber for which the lokal workspace is to be created, Dateindicates a date within the weekly report to be created,Language indicates the language of the table entries.
The parameter Check_Overlap is used to switch verification on
(='X') or off (=Space) as to whether, for the date transferred, aweekly report already exists or not.
Using Sel_Coun andSel_Curr, the additional tablesT706O_DAT, or TCURR_DAT can be filled, if needed.
The export table Emp_Info contains information on the specifiedpersonnel number, table Defaults contains the parameters

  • Firstday (refers to first day of weekly report, determined from
  • feature TRVPA, entry FDW as date, referring to the week specified byDATE).
    • CCCParam (TRVPA, switch CCC; see documentation on feature TRVPA
    • ),
      • Rec_F_PD (TRVCT, F line, position 1; see docu. on feature
      • TRVCT),
        • Rec_U_PD (TRVCT, U line, position 1; see above)

        • Rec_V_PD (TRVCT, V line, position 1; see above.)

        • MWAUS (table T706D, MWAUS) and

        • Mileage_PD (reimbursement amount per mile/km traveled for first
        • mile/km driven in the week in employee's local currency; if miles/kmsaccumulation is not active, this rate is valid for the whole week,otherwise it can differ!)
          Table T706B_DAT contains the trip expense types valid for thispersonnel number. This is a section of table T706B with the respectivefields required for the receipt entry check. The SC***fields in thisstructure represent a link to the entry fields in the "Additionalreceipt info" dialog in trip costs recording available for thisreceipt. These fields can have the following characteristics:
          • "+" : mandatory field

          • "-" : invisible field, therefore not active

          • "." : ready for entries

          • SPACE: field displayed only

          • Table T706O_DAT contains the values in table T706O (countries andregions) for this employee.
            T706O_DAT contains all currencies stored in the system (tablesTCURC and TCURT), together with the entries from the conversion tablefor currencies (TCURR) and the decimal points for currencies (TCURX).
            The export parameter RETURN, finally, supplies information concerningthe results of the method called.

            Description
            Personnel number