Functional Description
Purpose
The purpose of F4826 Update Based on WO Activity Rules is to update work order information based on 
the Work Order Activity Rules.  This includes updating the work order status in the Status History file 
(F1307), updating the maintenance status for the PM associated with the work order, updating the 
status for the piece of equipment on the work order in the Status History file (F1307), and updating the 
Subledger inactive field.
Setup Notes and Prerequisites
Special Logic
Technical Specification
Read  F4801 by Work Order Number  (DOCO).
Read  F4826 for the WO Type (DCTO), Order Type (DOCO), and Status (SRST).
 Write the WO Status History using the Business Function (B1300030),
 Update the Equipment Status History using the Business Function (B1300020), if EQST is not equal to 
'**'.  Pass in the children flag to optionally Update Equipment Status for children.
 Read second record in the F1307 
 If status in the current F1307 record is less than Input status
 - Update the Subledger Inactive on the WO Header (F4801).
 - Update the Maintenance Status for the Preventive Maintenance associated with the WO status.
Write a new PM schedule (status 01) if the cycle is finished and the schedule is NOT a multiple 
cycle.
Processing Details
FetchKeyed (Chain) to F4801 by Work Order Number, WADOCO = Input DOCO.
FetchKeyed (Chain) to F4826 by GEDCTO = Input DCTO, GETYPS = Input TYPS, and GESRST = Input SRST.
Write the WO Status History using the Business Function (B1300030).
Input SRST'e0 SRST
Input EFTB'e0 EFTB
Input BEGT'e0 BEGT
'2''e0 TREC
'1''e0 Suppress Error Msg
Input ProgramID'e0 PID
'1''e0 Suppress Status Fetch
 Update the Equipment Status History using the Business Function (B1300020).
 WANUMB from F4801'e0 NUMB
 Input EQST'e0 EQST
 Input EFTB'e0 EFTB
 Input BEGT'e0 BEGT
 Input Children Flag'e0 Update Children
 '1''e0 TREC
 Input PID'e0 PID
 '1''e0 Suppress Status Fetch
End If
// Update Subledger Inactive Code
If F4826 SBLI != F4801 SBLI then
 Update F4801 for input DOCO:  WASBLI = F4826 SBLI
End If
If F4826 MSTS != blank
 Select F1207 records using FWWONA = Input DOCO
 While Fetch successful
 If FWMSTS != 99
 Variable Date = blank
 Variable Date = B9800100 Date
 Else
 Variable Date = Input Date
 End if
 End if
 Update F1207: FWMSTS = F4826 MSTS
 FWCPLD = Variable Date
 FWCPLF = Calculate Completed Hours (FUTURE)
 FWCPLH = Calculate Completed Fuel (FUTURE)
 FWCPLM = Calculate Completed Miles (FUTURE)
 FWUSER = B9800100 User
 FWUPMJ = B9800100 Date
 FWPID = EX4826
 FWJOBN = B9800100 Workstation
 FWUPMT = B9800100 Time
 // Write new Maintenance Schedule
 Call B1300070 to retrieve Next Unique ID
 Call N1300090 to calculate schedule date passing:F1207 TDT
 F1207 FRIN
 F1207 SRVD
 F1207 LCPD
 FWLCPD = F1207 CPLD
 FWTDT = N1300090 PNST
 FWUKID = B1300070 UKID
 FWCPLD = blank
 FWCPLF = blank
 FWCPLH = blank
 FWCPLM = blank
 FWORGF = blank
 FWORGM = blank
 FWORGH = blank
 FWANP = blank
 FWWONA = 0
 FWMPC = 0
 FWPNST = 0
 FWUSER = B9800100 User
 FWUPMJ = B9800100 Date
 FWPID = EX4826
 FWJOBN = B9800100 Workstation
 FWUPMT = B9800100 Time
 End if
 End if
 End while
End if
DX4826 - F4826 Update Based on WO Activity Rules
| Parameter Name | Data Item | Data Type | Req/Opt | I/O/Both | 
|---|---|---|---|---|
| mnWorkOrderNumber | DOCO | MATH_NUMERIC | NONE | INPUT | 
A number that identifies an original document. This document can be a voucher, a sales order, an invoice, unapplied cash, a journal entry, 
  | ||||
| szWorkOrderType | DCTO | char | NONE | INPUT | 
A user defined code (00/DT) that identifies the type of document. This code also indicates the origin of the transaction. J.D. Edwards has 
  | ||||
| cTypeWO | TYPS | char | NONE | INPUT | 
A user defined code (00/TY) that indicates the classification of a work order or engineering change order.
You can use work order type as a 
  | ||||
| szWorkOrderStatus | SRST | char | NONE | INPUT | 
A user defined code (00/SS) that describes the status of a work order, rate schedule, or engineering change order. Any status change from 
  | ||||
| jdEffectiveDate | EFTB | JDEDATE | NONE | INPUT | 
The date that an address, item, transaction, or table record becomes active.  The meaning of this field differs, depending on the program.  
  | ||||
| mnBeginningTime | BEGT | MATH_NUMERIC | NONE | INPUT | 
The time at which the status of a piece of equipment or a work order changes. Use the HH:MM format (for example, 12:35).  | ||||
| szEquipmentStatus | EQST | char | NONE | INPUT | 
A user defined code (12/ES) that identifies the equipment or disposal status of an asset, such as available, down, or disposed.  | ||||
| cUpdateChildrenFlag | EV01 | char | NONE | INPUT | 
1 = Update Children Status
  | ||||
| cSubledgerInactive | SBLI | char | NONE | BOTH | 
An option that indicates whether a specific subledger is inactive. Examples of inactive subledgers are jobs that are closed, employees 
  | ||||
| cErrorCode | EV02 | char | NONE | INPUT | 
0=No Error
  | ||||
| szProgramID | PID | char | NONE | INPUT | 
The number that identifies the batch or interactive program (batch or interactive object). For example, the number of the Sales Order Entry 
  | ||||
| mnAssetItemNumber | NUMB | MATH_NUMERIC | OPT | INPUT | 
An 8-digit number that uniquely identifies an asset.  | ||||
| szNameRemark | RMK | char | OPT | INPUT | 
A generic field that you use for a remark, description, name, or address.  | ||||
| jdDateCompletion | STRX | JDEDATE | OPT | BOTH | 
The date that the work order or engineering change order is completed or canceled.  | ||||
| cCalledByPMAssociations_EV01 | EV01 | char | OPT | NONE | 
If this flag is set to a '1', when the work order status is being updated as a result of PM Associations. This will then 
  | ||||
| B1300020 F1307 Update Asset Status | ||||
| B1300030 F1307 Update Work Order Status | ||||
| B3000450 Get MFG Constants Data | ||||
| B4000260 Line Type - Activity Rules | ||||
| B9800100 Get Audit Information | ||||
| N3103110 F41021 Work Order Commitments | 
| F3111 Work Order Parts List | ||||
| F40205 Line Type Control Constants File | ||||
| F4102 Item Branch File | ||||
| F41021 Item Location File | ||||
| F4801 Work Order Master File | ||||
| F4826 W.O. Status Action Table |