1.1Purpose
The purpose of this business function is to determine what type of shop floor calendar is being used
and to return that type to the calling program. The calendar type is then used to determine what key
values to use when accessing the Shop Floor Calendar. The following is a list of the valid calendar
types:
'1' = Reserved for future use (B/P, Century, Year, Month, Calendar Name, Shift)
'2' = Branch/Plant, Century, Year, Month, Shift
'3' = Branch/Plant, Century, Year, Month
'4' = Branch/Plant (ALL), Century, Year, Month
'b7'b7
1.2Setup Notes and Prerequisites
If a shift level calendar is setup for one shift then shift level calendars must be setup for all
shifts.
1.3Special Logic
None
2.4Processing
Initialize Calendar Type.
Set Calendar Type = blank
Set Shop Floor Calendar key values based on entry parameters
Check for Branch/Plant Level Calendar.
Get Shop Floor Calendar entry using Branch Plant, Century, Year, Month
If Shop Floor Calendar entry was retrieved
Set Calendar Type = '3'
If Shop Floor Calendar Shift <> blank
Set Calendar Type = '2'
Else (Shop Floor Calendar entry found & shift = blank)
Get next Shop Floor Calendar entry with same key
If Shop Floor Calendar entry was retrieved
AND key hasn't changed
AND Shop Floor Calendar Shift <> blank
Set Calendar Type = '2'
Else (Shop Floor Calendar entry not retrieved)
Set Branch/Plant key = ' ALL'
Get Shop Floor Calendar entry
If Shop Floor Calendar entry was retrieved
Set Calendar Type = '4'
If Calendar Type = blank
Set error '1923' (Calendar Not Setup)
D3101670 - F0007 Get Calendar Type
Required Fields
szBranch/Plant
mnCentury
mnCalendarYear
mnCalendarMonth
cShiftCode
szCalendarName (Future Use - B8)
^
Parameter Name | Data Item | Data Type | Req/Opt | I/O/Both |
---|---|---|---|---|
szBranchPlant | MMCU | char | OPT | NONE |
A code that represents a high-level business unit. Use this code to refer to a branch or plant that might have departments or jobs, which
| ||||
mnCentury | CTRY | MATH_NUMERIC | OPT | NONE |
0 = 20th Century
| ||||
mnCalendarYear | YR | MATH_NUMERIC | OPT | NONE |
The calendar year for this calendar. | ||||
mnCalendarMonth | MT | MATH_NUMERIC | OPT | NONE |
A number that corresponds to the month in a calendar year. | ||||
cShiftCode | SHFT | char | OPT | NONE |
A user defined code (00/SH) that identifies daily work shifts.
In payroll systems, you can use a shift code to add a percentage or amount to
| ||||
szCalendarName | WDCK | char | OPT | NONE |
A code used to classify values within a calendar type. For example, if the calendar type is ROUTE, you can enter a code that specifies a
| ||||
cCalendarType | EV01 | char | OPT | NONE |
Output Parameter
| ||||
cSuppressErrorMessage | SUPPS | char | OPT | NONE |
A flag indicating whether or not runtime error messaging will occur when an error message is issued from a business function.
0 = allow
| ||||
cErrorCode | ERRC | char | OPT | NONE |
This error code indicates if any errors occurred during the creation of the Trip Document Detail (F4914) records by the Delivery Document
| ||||
szErrorMessageID | DTAI | char | OPT | NONE |
A code that identifies and defines a unit of information. It is an alphanumeric code up to 8 characters long that does not allow blanks or
| ||||
szWorkDayCalendarType | WDCT | char | OPT | NONE |
A user defined code (42/WD) that specifies how the calendar is used. For example, the calendar might be specific to an industry such as
|
None |
None |