Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 45

Listing of ER for Application : Inventory Adjustments (P4114)

=======================================================================
FORM: Inventory Adjustments [HEADERLESS DETAIL] (W4114A)
=======================================================================
CONTROL: FORM
EVENT: Dialog is Initialized
----------------------------------------------------------------------evt_EnhancementExistance_MEOW
OPT: Using Defaults
0001 //
REVISION LOG
0002 //
0003 // Date
Programmer
SAR
Description
0004 // 11/02/00 EF5613421 4590116 Pinnacle - Dual UoM
0005 // 03/07/02 NS6859983 SAR 5848051 Don't autocall P4605, just set 053A
0006 // 05/20/02 NS6859983 SAR 5796511 Reverse Adustmts and Dual incorrect
0007 // 06/11/02 MR7026369 SAR 5613949- Config Item in Adjustments
0008 // 12/12/03 CA6859852 SAR 6880205 - F41021WF and Post Commit
0009 // 07/28/04 TT5459806 SAR 7247719 - Process Allowed Lot Status
0010 // 07/29/04 CA6859852 SAR 7257546 - License Plate Enhancement (LPN)
0011 // 02/23/05 IC9024640 SAR 7523277 Lot No. not returned
0012 // 05/11/05 AM5731857 SAR 7635199 Dup Doc Number
0013 // 12/14/05 IC8996050 7919950 Existing line g/l date wrong d
0014 // 08/08/06 JV7445740 8069897 'N' Batch in use if HTML
0015 // 12/18/06 IC8996050 8241319 ZBA after full reversal
0016 // 01/16/07 AP9050291 8249695 Zero Quantity Adjustments
0017 // 08/29/07 RN9050944 8506313 Inventory issue and Deleting R
0018 // 10/23/07
AP9050291 8599417 P4114 Matrix Parent
0019 // 08/19/08 RK9050936
8849121
TRDJ updated as blank at F4111
0020 // 03/19/09 GR9051146
8918848 P4114 - Multiple transactions
0021 // 04/26/11 RV9056609
11905201 PMPN Enhancements
0022 //
0023 Disable Control(HC &Journal Entries)
0024 //
0025 // ---------------------------------------------------------------------------0026 // Load form interconnects
0027 // ---------------------------------------------------------------------------0028 //
0029 FC Batch Number = FI Batchnumber
0030 // ---------------------------------------------------------------------------0031 // Initialize fields
0032 // ---------------------------------------------------------------------------0033 //
0034 FC ev01-BgnDocOnce(wf) = "0"
0035 FC dicj - Batch Date (wf) = date_today()
0036 Get Local Computer ID
FC CTID -Computer ID (wf) <> BF szMachineKey
0037 // SAR# 7919950 - Initialize the MaxGridRows to 1
0038 VA frm_MaxGridRows_MATH01 = "1"
0039 //
0040 // ---------------------------------------------------------------------------0041 // If Batch control is on, call Open Batch
0042 // Begin batch processing by calling OpenBatch for the F0911
0043 // ------------------------------------------------------------------------

----0044 //
0045 F4009 Get Distribution Constants
"41" <> BF szSystemCode
FC icri - Batch Control (wf) <> BF cBatchControl
0046 If FC icri - Batch Control (wf) is equal to "Y"
0047
FC ev08 - Cancel Batch Control (wf) = "0"
0048 Else
0049
FC ev08 - Cancel Batch Control (wf) = "1"
0050 End If
0051 //
0052 VA frm_EV01_DoNotCloseBatch = "0"
0053 If FI Batchnumber is not equal to <Zero> Or FC icri - Batch Control (wf) is
equal to "Y"
0054 !
F0011 Open Batch
!
FC EV01 - Batch stat (wf) <> BF cPrevBatchstatus
!
"N" -> BF szBatchtype
!
FC Batch Number -> BF mnBatchnumber
!
FC dicj - Batch Date (wf) <> BF jdBatchDate
!
FC ev08 - Cancel Batch Control (wf) <> BF cCancelBatchControl
0055
F0011 Write Batch Header
"N" -> BF szBatchType
FC Batch Number <> BF mnBatchNumber
FC EV01 - Batch stat (wf) <> BF cPreviousBatchStatus
FC dicj - Batch Date (wf) <> BF jdBatchDate
FC ev08 - Cancel Batch Control (wf) <> BF cBatchControlCancelFlag
0056
If SV Error_Status is not equal to CO SUCCESS
0057
VA frm_EV01_DoNotCloseBatch = "1"
0058
End If
0059 Else
0060
Hide Control(FC Batch Number)
0061
Hide Control(FC Group Box 49)
0062 End If
0063 // ---------------------------------------------------------------------------0064 //
Only display on a change.
0065 // ---------------------------------------------------------------------------0066 //
0067 Hide Control(FC Prev Doc Type)
0068 Hide Control(FC Prev Doc No)
0069 // ---------------------------------------------------------------------------0070 //
0071 // Begin SAR 4590116 - Dual UoM
0072 //
0073 Vertical Feature
"01" -> BF szVerticalEnhancement
VA evt_EnhancementExistance_MEOW <- BF cEnhancementExistance
0074 //
0075 If VA evt_EnhancementExistance_MEOW is not equal to "1"
0076
Hide Grid Column(FC Grid, GC Secondary Quantity)
0077
Hide Grid Column(FC Grid, GC Sec UoM)
0078 End If
0079 // End SAR 4590116
0080 //
0081 // Begin SAR 4980190
0082 Vertical Feature
"03" -> BF szVerticalEnhancement
VA frm_cVFS_MEOW <- BF cEnhancementExistance

0083 If VA frm_cVFS_MEOW is not equal to "1"


0084
Hide Grid Column(FC Grid, GC Lot Effectivity Date)
0085
Disable Control(HC Lo&t Dates)
0086 Else
0087
// Disable the Lot Dates exit. It will be enabled when a row is entered
if the
0088
// item number, branch/plant, lot number and transaction date are not bl
ank.
0089
Disable Control(HC Lo&t Dates)
0090 End If
0091 // End SAR 4980190
0092 //
0093 // Check the evnironment values to determine if Apparel is activated. If
0094 // Apparel is activated, set on a flag to be used by related processing
0095 //
0096 Get Environment Value
"SY41F" -> BF szDataItem
VA frm_cApparelActive_EV01 <- BF cModuleExistance
0097 //
0098 // If Apparel is active and the version of PCW10 has not been setup in the
0099 // proessing options, setup the default of 'ZJDE0001'.
0100 //
0101 If VA frm_cApparelActive_EV01 is equal to "1" And PO szMatrixEntryVersion_V
ERS is equal to or empty <Blank>
0102
PO szMatrixEntryVersion_VERS = "ZJDE0001"
0103 End If
0104 //
0105 // Disable CoO Description
0106 Disable Grid(FC Grid, <All Rows>, GC Country of Origin Description)
0107 //
0108 // BUG# 11905201 PMPN Enhancements - Begin
0109 // Check for PMPN Module Existance
0110 Get Environment Value
"SY31MP" -> BF szDataItem
VA frm_cPMPNInstalled_EV01 <- BF cModuleExistance
0111 // Hide PMPN Fields if PMPN is not installed
0112 If VA frm_cPMPNInstalled_EV01 is not equal to "1"
0113
Hide Grid Column(FC Grid, GC Production Number)
0114
Disable Control(HC Prod No. Consumption)
0115 End If
0116 // BUG# 11905201 PMPN Enhancements - End
0117 //
----------------------------------------------------------------------EVENT: Clear Screen Before Add
----------------------------------------------------------------------evt_cDisplayAssignItemstoLPN
OPT: Using Defaults
0001 // ---------------------------------------------------------------------------0002 // Initialize fields
0003 // ---------------------------------------------------------------------------0004 //
0005 // ---------------------------------------------------------------------------0006 // Hide the previous document number information if none previously existed
.
0007 // ----------------------------------------------------------------------------

0008 //
0009 If FC Prev Doc No is equal to <Zero>
0010
Hide Control(FC Prev Doc Type)
0011
Hide Control(FC Prev Doc No)
0012 Else
0013
Show Control(FC Prev Doc Type)
0014
Show Control(FC Prev Doc No)
0015 End If
0016 // -------------------------------------------------------------------------0017 // SAR 7362688 - Fix License Plate Transaction Processing Issue
0018 // Fetch the LPN Header Cache
0019 If PO cLicensePlateWindow is equal to "1" And VA frm_JobnumberA_JOBS is not
equal to <Zero>
0020
Cache License Plate Transaction Header
"1" -> BF szCacheActionCode
"1" -> BF mnNumberKeys
"1" -> BF nIndex
"1" -> BF cSuppressErrorMessage
VA frm_JobnumberA_JOBS -> BF mnJobNumber
VA evt_cDisplayAssignItemstoLPN <- BF cDisplayAssignItemFlag
0021
If VA evt_cDisplayAssignItemstoLPN is equal to "1"
0022
Call( App:P46L30 , Form:W46L30B , Ver: ZJDE0001 )
"1" -> FI cLoadCache
VA frm_JobnumberA_JOBS <> FI mnJobNumber
0023
End If
0024
// Terminate the LPN Cache
0025
Cache License Plate Transaction Header
"8" -> BF szCacheActionCode
"1" -> BF mnNumberKeys
"1" -> BF nIndex
"1" -> BF cSuppressErrorMessage
VA frm_JobnumberA_JOBS -> BF mnJobNumber
0026 End If
----------------------------------------------------------------------EVENT: Post Dialog is Initialized
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 If SV Form_ Mode is equal to CO ADD_MODE
0003
// ---------------------------------------------------------------------------0004
// If in add mode, retrieve the default branch
0005
// ---------------------------------------------------------------------------0006
//
0007
F40095 Get Default Branch
FC Business Unit <> BF szBranch
0008
FC Doc Type = PO szDocumenttype
0009
Enable Control(FC Order Date)
0010
Enable Control(FC Explanation)
0011
Enable Control(FC Business Unit)
0012
Enable Control(FC Doc Type)
0013
Enable Control(FC Document Number)
0014
//
0015
VA frm_EV09_ValidateF4111DocNo = "1"
0016
// SAR 6093818 - Move this function call so it is done regardless of for
m
0017
// mode.

0018 !
Get GL MBF Version From JE Version
!
VA frm_GLMBFVersion_VER <- BF szGLMBFVersion
!
PO szJournalEntriesVersion -> BF szJEVersion
0019 Else
0020
// ---------------------------------------------------------------------------0021
// Show the Reverse button only in update mode
0022
// ---------------------------------------------------------------------------0023
//
0024
Disable Control(FC Document Number)
0025
Disable Control(FC Doc Type)
0026
Disable Control(FC Explanation)
0027
Disable Control(FC Business Unit)
0028
// SAR 4514076 - Do not disable the G/L Date.
0029 !
Disable Control(FC G/L Date)
0030
//
0031
FC Explanation = FI Explanationtransaction
0032
FC Prev Doc Type = FC Doc Type
0033
// SAR# 6484392, Blank out the GL date to default it to today's date in
0034
// begin doc.
0035 !
FC G/L Date = FI Dtforglandvouch1
0036
FC G/L Date = ""
0037
//
0038
// SAR 7576301 - Defaults todays date to validate in the header.
0039
FC G/L Date = date_today()
0040 End If
0041 // ----- ENDIF ADD_MODE ----0042 //
0043 // SAR 6093818 - Retrieve the GL MBF version whether in add mode or not.
0044 Get GL MBF Version From JE Version
VA frm_GLMBFVersion_VER <- BF szGLMBFVersion
PO szJournalEntriesVersion -> BF szJEVersion
0045 //
0046 // ---------------------------------------------------------------------------0047 //
Protect cost fields if processing option set
0048 //
1. If PO-ProtectCost = '1', disable grids Unit and Extended Cost
s
0049 //
2. If PO-ProtectCost = '2', do not display grid for Unit and Ext
ended
0050 // Costs.
0051 // ---------------------------------------------------------------------------0052 //
0053 If PO cProtectCosts is equal to "1"
0054
Disable Grid(FC Grid, <All Rows>, GC Unit Cost)
0055
Disable Grid(FC Grid, <All Rows>, GC Extended Amount)
0056
Disable Control(HC &Zero Cost)
0057
Disable Control(HC Canc&el Zero Cost)
0058 Else
0059
//
0060
If PO cProtectCosts is equal to "2"
0061
Hide Grid Column(FC Grid, GC Unit Cost)
0062
Hide Grid Column(FC Grid, GC Extended Amount)
0063
Disable Control(HC &Zero Cost)
0064
Disable Control(HC Canc&el Zero Cost)
0065
End If
0066
//
0067 End If

0068 // ----- ENDIF Protect Mode = '1' ----0069 //


0070 // ---------------------------------------------------------------------------0071 // If lot layering processing option set, display grade, potency, status an
d
0072 // lot description fields
0073 // ---------------------------------------------------------------------------0074 //
0075 If PO cLotLayering is equal to <Blank>
0076
Hide Grid Column(FC Grid, GC Lot Grade)
0077
Hide Grid Column(FC Grid, GC Lot Potency)
0078
Hide Grid Column(FC Grid, GC Lot Status)
0079
Hide Grid Column(FC Grid, GC Lot Description)
0080 Else
0081
If PO cLotLayering is equal to "2"
0082
Disable Grid(FC Grid, <All Rows>, GC Lot/Serial)
0083
Disable Grid(FC Grid, <All Rows>, GC Lot Expiration Date)
0084
Disable Grid(FC Grid, <All Rows>, GC Lot Status)
0085
End If
0086 End If
0087 // ---------------------------------------------------------------------------0088 // Do not allow entry of a G/L date - should default from header
0089 // ---------------------------------------------------------------------------0090 //
0091 Disable Grid(FC Grid, <All Rows>, GC G/L Date)
0092 //
0093 Disable Control(FC Prev Doc No)
0094 Disable Control(FC Prev Doc Type)
0095 Disable Control(FC Batch Number)
0096 FC JOBS - Inv Job Number (wf) = "0"
0097 //
0098 // ---------------------------------------------------------------------------0099 //
SAR #2770527
02/22/1999
0100 //
0101 //
If the Batch is already opened by another application, all the
0102 //
transactions must be disabled. This include all row and form exit
;
0103 //
except for Item Ledger (P4111) since it's a display only.
0104 // ---------------------------------------------------------------------------0105 If VA frm_EV01_DoNotCloseBatch is equal to "1"
0106
//
0107
Disable Grid(FC Grid, <All Rows>, <All Columns>)
0108
Disable Control(FC Order Date)
0109
Disable Control(FC G/L Date)
0110
//
0111
Hide Control(HC &Select from histor)
0112
Hide Control(HC &Display Config)
0113
Hide Control(HC &Location Search)
0114
Hide Control(HC Wareho &Loc Detail)
0115
Hide Control(HC Re&verse)
0116
Hide Control(HC &Delete)
0117
Hide Control(HC Canc&el Zero Cost)
0118
Hide Control(HC &Zero Cost)
0119
Hide Control(HC &Journal Entries)

0120
0121
0122
0123
0124
0125
0126
0127

Hide Control(HC &Item Search)


Hide Control(HC &OK)
End If
// SAR 4410921Begin: Initialize variable
// SAR# 6201823, Replaced with grid variables.
! VA frm_cReversalOn_EV01 = " "
! VA frm_mnRevQuantity_MATH01 = 0
// SAR 4410921End

----------------------------------------------------------------------EVENT: Grid Record is Fetched


----------------------------------------------------------------------evt_TFLA_UOMFlag
OPT: Using Defaults
0001 //
0002 // ---------------------------------------------------------------------------0003 //
SAR #1914074
1/23/1998
0004 //
Hide grid Row if the F4111 Record has the following description
0005 //
1.
"Standard Cost Change"
0006 //
2.
"Zero Balance Adjustment"
0007 // ---------------------------------------------------------------------------0008 FC lnid - Prev Line No (wf) = BC Line Number (F4111)(LNID)
0009 // SAR# 7919950 - incriment the MaxGrid rows to find the initial number of
0010 // rows
0011 VA frm_MaxGridRows_MATH01 = [VA frm_MaxGridRows_MATH01]+1
0012 //
0013 If BC Explanation - Transaction (F4111)(TREX) is equal to "Standard Cost Ch
ange" Or BC Explanation - Transaction (F4111)(TREX) is equal to "Zero Balance Ad
justment"
0014
Suppress Grid Line(FC Grid)
0015 Else
0016
//
0017
// ---------------------------------------------------------------------------0018
//
Return the primary item nubmer for display in the grid
0019
// ---------------------------------------------------------------------------0020
//
0021
F4101 Select Primary Item Number
BC Item Number - Short (F4111)(ITM) -> BF mnShortItemNumber
BC 2nd Item Number (F4111)(LITM) -> BF sz2ndItemNumber
BC 3rd Item Number (F4111)(AITM) -> BF sz3rdItemNumber
BC Business Unit (F4111)(MCU) -> BF szBranchPlant
GC Item Number <- BF szPrimaryItemNumber
"1" -> BF cSuppressErrorMsg
0022
//
0023
// ---------------------------------------------------------------------------0024
//
Format the location for the grid row
0025
// ---------------------------------------------------------------------------0026
//
0027
F4100 Format Location
BC Business Unit (F4111)(MCU) -> BF szCostCenter
GC Location <- BF szDisplayFormatLocation
BC Location (F4111)(LOCN) -> BF szFileFormatLocation
"1" -> BF cMode
0028
// ---------------------------------------------------------------------

-------0029
//
0030
//
-------0031
//
0032
If
0033
0034
n instead
0035
0036

Load information from the lot master


--------------------------------------------------------------------BC Lot/Serial Number (F4111)(LOTN) is not equal to <Blank>
// BUG 11836680 - Get the Country of Origin
// Bug# 14737812 Begin - Retrieved Country of Origin in correct colum

// of GC Production Number
F4108 Get Lot Master Information
GC Lot Description <- BF szLotDescription
GC Lot Expiration Date <- BF jdExpirationDate
BC Item Number - Short (F4111)(ITM) -> BF mnShortItemNumber
BC Business Unit (F4111)(MCU) -> BF szBranchPlant
BC Lot/Serial Number (F4111)(LOTN) -> BF szLotNumber
GC Memo Lot 1 <- BF szMemoLot1
GC Memo Lot 2 <- BF szMemoLot2
VA grd_BasedOnDate_BODJ <- BF jdBasedOnDate
VA grd_OnHandDate_OHDJ <- BF jdOnHandDate
GC Lot Effectivity Date <- BF jdLotEffectivityDate
VA grd_SellByDate_SBDJ <- BF jdSellByDate
VA grd_BestBeforeDate_BBDJ <- BF jdBestBeforeDate
VA grd_UserLotDate1_U1DJ <- BF jdUserLotDate1
VA grd_UserLotDate2_U2DJ <- BF jdUserLotDate2
VA grd_UserLotDate3_U3DJ <- BF jdUserLotDate3
VA grd_UserLotDate4_U4DJ <- BF jdUserLotDate4
VA grd_UserLotDate5_U5DJ <- BF jdUserLotDate5
GC Country of Origin <- BF szCountryOfOrigin
0037
// Bug# 14737812 End
0038
End If
0039
//
0040
If FC kco- DocKeyComp (wf) is equal to or empty <Blank>
0041
FC kco- DocKeyComp (wf) = BC Document Company (F4111)(KCO)
0042
End If
0043 End If
0044 //
0045 // If media objects exist - display paperclip
0046 //
0047 Media Object Structures(GT4111, <Default Media Object>, <Exist>, VA frm_Med
ia_Objects_Status, BC Document (Voucher, Invoice, etc.) (F4111)(DOC), BC Documen
t Type (F4111)(DCT), BC Document Company (F4111)(KCO), ...)
0048 If VA frm_Media_Objects_Status is equal to "1"
0049
Set Grid Text Indicator(FC Grid, <Current Row>, <Yes>)
0050 Else
0051
Set Grid Text Indicator(FC Grid, <Current Row>, <No>)
0052 End If
0053 // SAR 2490955 Begin
0054 // Business Function B4001040 is used to input Item Description into the Gr
id.
0055 F4101 Get Item Master Information
BC Item Number - Short (F4111)(ITM) -> BF mnShortItemNumber
GC Item Description <- BF szDescription
0056 // SAR 2490955 End
----------------------------------------------------------------------EVENT: Write Grid Line-Before
----------------------------------------------------------------------OPT: Using Defaults
0001 // ------------------------------------------------------------------------

----0002 // Disable all grid records that are written. No records can be changed.
0003 // Only a Reversal can occur to an already existing record.
0004 // ---------------------------------------------------------------------------0005 //
0006 Disable Grid(FC Grid, <Current Row>, <All Columns>)
0007 // ---------------------------------------------------------------------------0008 // Load a '1' to the Reversal OK field. This will indicate that the record
0009 // already existed and is eligible for a reversal.
0010 // ---------------------------------------------------------------------------0011 //
0012 GC ev01 - F4111 Record Exist (wf) = "1"
0013 GC lnid - Line Number (wf) = BC Line Number (F4111)(LNID)
0014 FC lnid - Prev Line No (wf) = BC Line Number (F4111)(LNID)
----------------------------------------------------------------------EVENT: Last Grid Record Has Been Read
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 // ---------------------------------------------------------------------------0003 //
SAR #2770527
CDL
02/22/1999
0004 //
Prevent a new line to be added by hiding the blank line.
0005 // ---------------------------------------------------------------------------0006 If VA frm_EV01_DoNotCloseBatch is equal to "1"
0007
Hide Grid Row(FC Grid, <Current Row>)
0008 End If
----------------------------------------------------------------------EVENT: End Dialog
----------------------------------------------------------------------evt_cDisplayAssignItemstoLPN
OPT: Using Defaults
0001 // BUG 15842653 - Display the P46l30 screen in update mode also.
0002 // Fetch the LPN Header Cache
0003 If PO cLicensePlateWindow is equal to "1" And VA frm_JobnumberA_JOBS is not
equal to <Zero> And SV Form_ Mode is equal to CO UPDATE_MODE
0004
Cache License Plate Transaction Header
"1" -> BF szCacheActionCode
"1" -> BF mnNumberKeys
"1" -> BF nIndex
"1" -> BF cSuppressErrorMessage
VA frm_JobnumberA_JOBS -> BF mnJobNumber
VA evt_cDisplayAssignItemstoLPN <- BF cDisplayAssignItemFlag
0005
If VA evt_cDisplayAssignItemstoLPN is equal to "1"
0006
Call( App:P46L30 , Form:W46L30B , Ver: ZJDE0001 )
"1" -> FI cLoadCache
VA frm_JobnumberA_JOBS <> FI mnJobNumber
0007
End If
0008
// Terminate the LPN Cache
0009
Cache License Plate Transaction Header
"8" -> BF szCacheActionCode
"1" -> BF mnNumberKeys
"1" -> BF nIndex
"1" -> BF cSuppressErrorMessage

VA frm_JobnumberA_JOBS -> BF mnJobNumber


0010 End If
----------------------------------------------------------------------EVENT: Post Commit
----------------------------------------------------------------------evt_cDisplayLicensePlateWindow
OPT: Using Defaults
0001 // SAR 6612745
0002 If SV TP_Commit_Status is equal to CO TP_ACTION_FAIL
0003
Process F41021WF Records
FC CTID -Computer ID (wf) -> BF szComputerID
VA frm_JobnumberA_JOBS -> BF mnJobnumberA
VA frm_mnUniqueKeyIDF41021WF_UKID -> BF mnUniqueKeyIDInternal
0004 End If
----------------------------------------------------------------------EVENT: Variables
----------------------------------------------------------------------frm_UITM_ItemNumber
frm_UOM1_PrimaryUOM
frm_TFLA_StandardUOMFlag
frm_UNCS_UnitCost
frm_MaxGridRows_MATH01
frm_Index_MATH01
frm_CacheCursor_GENLNG
frm_CacheCursorConfig_GENLNG
frm_CostChanged_EV01
frm_QtyChanged_EV01
frm_EV05_ExtendedCostEntered
frm_PAID_PrevExtendedCost
frm_EV01_DoNotCloseBatch
frm_EV09_ValidateF4111DocNo
frm_Media_Objects_Status
frm_FromTo
frm_HoldGLDate_DGL
frm_cProcessCloseBatch_EV11
grd_Old_UnitCost
grd_Old_ItemNumber
frm_LotNumber
frm_GLMBFVersion_VER
frm_mnRevQuantity_MATH01
frm_cReversalOn_EV01
frm_cVFS_MEOW
grd_BasedOnDate_BODJ
grd_OnHandDate_OHDJ
grd_SellByDate_SBDJ
grd_BestBeforeDate_BBDJ
grd_UserLotDate1_U1DJ
grd_UserLotDate2_U2DJ
grd_UserLotDate3_U3DJ
grd_UserLotDate4_U4DJ
grd_UserLotDate5_U5DJ
frm_SecondaryQty
grd_cEditLineCalled_EV01
frm_cP4605WindowCanceled_EV01
grd_cReversalOn_EV01
grd_SecondaryQty_SQOR
grd_mnRevQuantity_MATH01
frm_JobnumberA_JOBS

frm_mnUniqueKeyIDF41021WF_UKID
frm_cLPNMasterSwitch_LPNM
frm_cDisableGlDate_EV01
frm_cApparelActive_EV01
frm_cPMPNInstalled_EV01
frm_szProdNoJobNumber_JOB
frm_cProdNumInvCancelled_EV01
grd_szInitialLotStsCode_LOTS
grd_mnLotStsOverridden_INT01
=======================================================================
CONTROL: HYPITEM &OK
EVENT: Button Clicked
----------------------------------------------------------------------evt_GridRowMax
evt_CurrentGridRow
evt_NumberOfRows_INT01
evt_LotStatusCodefromF41021
evt_rowindex_INT01
OPT: Using Defaults
0001 //
0002 // ****** Begin SAR 7635199 ******
0003 // ---------------------------------------------------------------------------0004 //
Retrieving Document Number If Document Number is zero
0005 // 1) Get or validate document number from F4111 Item Ledger
0006 // 2) Call F0911 Get Next Document Number for interoperability
0007 // ---------------------------------------------------------------------------0008 //
0009 If FC ev01-BgnDocOnce(wf) is equal to "1"
0010
//
0011
//
0012
If SV Form_ Mode is equal to CO ADD_MODE
0013
// SAR 7635199 Call F0002 Get Item Ledger next number to get the next
number
0014
// in add mode or validate it if the user entered a number.
0015
F0002 Get Item Ledger Next Number
FC Document Number <> BF mnDocumentNumber
FC Doc Type -> BF szDocumentType
FC kco- DocKeyComp (wf) -> BF szKeyCompany
"2" -> BF mnNextNumberingIndexNo
"41" -> BF szSystemCode
FC G/L Date -> BF jdGLDate
0016
//
0017
If FC jobs - JobNoF0911 (wf) is not equal to <Zero> And FC jobs - Job
NoF0911 (wf) is not equal to <Null>
0018
// SAR 7635199 Call F0911 Get Next Document Number, even though th
e Doc Number
0019
// has been retieved, so the interoperability code is hit.
0020
//
0021
// SAR 8363640 - Document Number is just passed to F0911 Get Next
Document
0022
// Number, but is not retreived.
0023
F0911 Get Next Document Number
FC jobs - JobNoF0911 (wf) -> BF mnJobNumber
"2.00" -> BF mnNextNumberIndex
"41" -> BF szNextNumberSystemCode
FC Document Number -> BF mnDocNumber
0024
//

0025
// End SAR 8363640
0026
// ****** How the code looked before SAR 7635199 ******
0027 !
If FC Document Number is equal to <Zero> Or FC Document Number i
s equal to or empty <Null>
0028 !
F0911 Get Next Document Number
!
FC jobs - JobNoF0911 (wf) -> BF mnJobNumber
!
"2.00" -> BF mnNextNumberIndex
!
"41" -> BF szNextNumberSystemCode
!
FC Document Number <> BF mnDocNumber
0029 !
VA frm_EV09_ValidateF4111DocNo = "0"
0030 !
End If
0031
End If
0032 !
If VA frm_EV09_ValidateF4111DocNo is equal to "1"
0033 !
F0002 Get Item Ledger Next Number
!
FC Document Number <> BF mnDocumentNumber
!
FC Doc Type -> BF szDocumentType
!
FC kco- DocKeyComp (wf) -> BF szKeyCompany
!
"2" -> BF mnNextNumberingIndexNo
!
"41" -> BF szSystemCode
!
FC G/L Date -> BF jdGLDate
0034 !
End If
0035
// ****** End SAR 7635199 ******
0036
//
0037
End If
0038
//
0039
If SV Error_Status is equal to CO SUCCESS
0040
Show Control(FC Group Box 49)
0041
FC Prev Doc Type = FC Doc Type
0042
FC Prev Doc No = FC Document Number
0043
Show Control(FC Prev Doc No)
0044
Show Control(FC Prev Doc Type)
0045
End If
0046 End If
0047 // ---------------------------------------------------------------------------0048 //
Need this Work Field ICU for "END-DIALOG"
0049 //
Currently, FC-Batch Number goes back to "0" at "END-DIALOG".
0050 // ---------------------------------------------------------------------------0051 //
0052 FC ICU - BatchNo (wf) = FC Batch Number
0053 //
0054 // Begin BUG - 14049888 - Throw an warning if the Lot staus code in F41021
is
0055 // different from the one present in the grid. If the user is manually
0056 // entering the Lot staus code, skip the warning,
0057 //
0058 Get Max Grid Rows(FC Grid, VA evt_NumberOfRows_INT01)
0059 VA evt_rowindex_INT01 = "1"
0060 VA evt_NumberOfRows_INT01 = [VA evt_NumberOfRows_INT01]-1
0061 While VA evt_NumberOfRows_INT01 is greater than <Zero>
0062
Get Grid Row(FC Grid, VA evt_rowindex_INT01)
0063
F41021.Fetch Single
GC itm - Short Item No (wf) = TK Item Number - Short
GC Branch/ Plant = TK Business Unit
GC Location - File (wf) = TK Location
GC Lot/Serial = TK Lot/Serial Number
VA evt_LotStatusCodefromF41021 <- TK Lot Status Code
0064
If SV File_IO_Status is equal to CO SUCCESS And GC Lot Status is not eq
ual to VA evt_LotStatusCodefromF41021 And VA grd_mnLotStsOverridden_INT01 is not

equal to "1"
0065
Set Grid Cell Error(FC Grid, <Currently Selected Row>, GC Lot Status
, "41100")
0066
End If
0067
VA evt_NumberOfRows_INT01 = [VA evt_NumberOfRows_INT01]-1
0068
VA evt_rowindex_INT01 = [VA evt_rowindex_INT01]-1
0069 End While
0070 //
0071 // End BUG
14049888
----------------------------------------------------------------------EVENT: Post Button Clicked
----------------------------------------------------------------------evt_cEndDocDone_EV01
evt_cDisplayAssignItemtoLPN
evt_cLicensePlateBranchPlant
evt_cCloseBatch_EV01
OPT: Using Defaults
0001 VA evt_cEndDocDone_EV01 = "0"
0002 //
0003 // Get a UKID fort he F41021WF and write it to the cache to be used at End
0004 // Doc.
0005 Get Next Unique Key ID
"F41021WF" -> BF szObjectName
VA frm_mnUniqueKeyIDF41021WF_UKID <- BF mnUniqueKeyID
0006 Cache Process Unique F41021WF
FC JOBS - Inv Job Number (wf) -> BF mnJobnumber
FC CTID -Computer ID (wf) -> BF szComputerID
VA frm_mnUniqueKeyIDF41021WF_UKID -> BF mnUniqueKeyIDInternal
"2" -> BF szCacheActionCode
"3" -> BF mnNumberKeys
"1" -> BF cSuppressErrorMessage
0007 //
0008 Get F46L001 Records
FC Business Unit <> BF szCostCenter
VA evt_cLicensePlateBranchPlant <- BF cLPNMasterSwitch
0009 // LPN Enhancement - Write the LPN Header Cache
0010 Cache License Plate Transaction Header
"2" -> BF szCacheActionCode
"1" -> BF mnNumberKeys
"1" -> BF nIndex
"1" -> BF cSuppressErrorMessage
FC JOBS - Inv Job Number (wf) -> BF mnJobNumber
PO szLPNGenerationMethod -> BF szPO_LPNGenerationMethod
PO cLicensePlateWindow -> BF cPO_DisplayAssignItemWindow
PO cBuildStructure -> BF cPO_BuildDefaultStructure
"N" -> BF cPartialsAllowedYN
"EP4114" -> BF szProgramId
"IA" -> BF szLicensePlateTransactionT
0011 //
0012 If PO cLicensePlateWindow is equal to "1"
0013
If FC ev01-BgnDocOnce(wf) is equal to "1"
0014
F4114 End Document
"EP4114" -> BF szProgramID
FC Document Number -> BF mnDocumentNumber
FC CTID -Computer ID (wf) -> BF szComputerID
"1" -> BF cWriteCardex
FC Doc Type -> BF szDocumentType
"2.00" -> BF mnTransactionProcessType
FC jobs - JobNoF0911 (wf) -> BF mnF0911Jobnumber

FC Batch Number -> BF mnBatchNumber


FC EV01 - Batch stat (wf) -> BF cBatchStatus
PO cSummaryMode -> BF cSummarizeF0911
FC JOBS - Inv Job Number (wf) -> BF mnInvJobNumber
PO OutInteroperabilityType <> BF szEDITransactionType
0015
VA evt_cEndDocDone_EV01 = "1"
0016
End If
0017 End If
0018 //
0019 If FC ev01-BgnDocOnce(wf) is equal to "1" And VA evt_cEndDocDone_EV01 is no
t equal to "1"
0020
//
0021
// SAR 8069897 - The Batch is not released in the End Document. In an
0022
// Add mode, the user has to always cancel out of the screen after
0023
// every inventory transaction to release the batch. It is released on
ly if
0024
// the user presses the Cancel button in the Clear Detail Stack. The b
atch
0025
// has to be released in Add mode as well. Hence if it is not Update
0026
// Mode, pass the CloseBatch Value as 1. In Update mode, the batch is
0027
// released in the Clear Detail Stack below.
0028
//
0029
If SV Form_ Mode is not equal to CO UPDATE_MODE
0030
VA evt_cCloseBatch_EV01 = "1"
0031
Else
0032
VA evt_cCloseBatch_EV01 = "0"
0033
End If
0034
//
0035
F4114 End Document
"EP4114" -> BF szProgramID
FC Document Number -> BF mnDocumentNumber
FC CTID -Computer ID (wf) -> BF szComputerID
"1" -> BF cWriteCardex
FC Doc Type -> BF szDocumentType
"2.00" -> BF mnTransactionProcessType
FC jobs - JobNoF0911 (wf) -> BF mnF0911Jobnumber
FC Batch Number -> BF mnBatchNumber
FC EV01 - Batch stat (wf) -> BF cBatchStatus
VA evt_cCloseBatch_EV01 <> BF cProcessCloseBatch
PO cSummaryMode -> BF cSummarizeF0911
FC JOBS - Inv Job Number (wf) -> BF mnInvJobNumber
PO OutInteroperabilityType <> BF szEDITransactionType
0036 End If
0037 //
0038 If SV Form_ Mode is equal to CO UPDATE_MODE And VA frm_EV01_DoNotCloseBatch
is not equal to "1"
0039
// ---------------------------------------------------------------------------0040
//
Clear Work File
0041
// ---------------------------------------------------------------------------0042
F4114 Clear Detail Stack
FC CTID -Computer ID (wf) -> BF szComputerID
FC Prev Doc Type -> BF szDocumentType
"1" -> BF cProcessCloseBatch
FC ICU - BatchNo (wf) -> BF mnBatchNumber
FC EV01 - Batch stat (wf) -> BF cBatchStatus
FC jobs - JobNoF0911 (wf) -> BF mnF0911Jobnumber
FC JOBS - Inv Job Number (wf) -> BF mnInvJobNumber
0043 End If

0044
0045
0046
0047
0048
0049
0050

//
//
VA
//
FC
FC
//

Added for SAR 6612745,


frm_JobnumberA_JOBS = FC JOBS - Inv Job Number (wf)
End of SAR 6612745
jobs - JobNoF0911 (wf) = "0"
JOBS - Inv Job Number (wf) = "0"

=======================================================================
CONTROL: HYPITEM &Cancel
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 // ---------------------------------------------------------------------------0002 //
Load FC-Batch to ICU-Batch Work Field for "END-DIALOG".
0003 //
At "END-DIALOG", the BC are being cleared.
0004 // ---------------------------------------------------------------------------0005 FC ICU - BatchNo (wf) = FC Batch Number
0006 FC Prev Doc Type = FC Doc Type
----------------------------------------------------------------------EVENT: Post Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 // ---------------------------------------------------------------------------0002 //
Clear Work File
0003 //
0004 //
If the Batch had been opened by other application,
0005 //
Do not close the batch. If the batch is closed and
0006 //
it was opened by someone else, it will close their batch.
0007 // ---------------------------------------------------------------------------0008 If VA frm_EV01_DoNotCloseBatch is not equal to "1"
0009
If FI Batchnumber is not equal to <Zero>
0010
VA frm_cProcessCloseBatch_EV11 = "2"
0011
Else
0012
VA frm_cProcessCloseBatch_EV11 = "1"
0013
End If
0014
F4114 Clear Detail Stack
FC CTID -Computer ID (wf) -> BF szComputerID
FC Prev Doc Type -> BF szDocumentType
VA frm_cProcessCloseBatch_EV11 -> BF cProcessCloseBatch
FC ICU - BatchNo (wf) -> BF mnBatchNumber
FC EV01 - Batch stat (wf) -> BF cBatchStatus
FC jobs - JobNoF0911 (wf) -> BF mnF0911Jobnumber
FC JOBS - Inv Job Number (wf) -> BF mnInvJobNumber
0015 End If
=======================================================================
CONTROL: HYPITEM &Zero Cost
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Repeat ER for Event
0001 If GC ev01 - F4111 Record Exist (wf) is not equal to "1"
0002
//
0003
GC ev09CostEntered(wf) = "1"
0004
//

0005
GC Unit Cost = "0"
0006
Set Grid Color(FC Grid, <Current Row>, GC Unit Cost, <Gray>)
0007
Disable Grid(FC Grid, <Current Row>, GC Unit Cost)
0008
//
0009
GC Extended Amount = "0"
0010
Set Grid Color(FC Grid, <Current Row>, GC Extended Amount, <Gray>)
0011
Disable Grid(FC Grid, <Current Row>, GC Extended Amount)
0012
//
0013 End If
=======================================================================
CONTROL: HYPITEM Canc&el Zero Cost
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Repeat ER for Event
0001 If GC ev01 - F4111 Record Exist (wf) is not equal to "1"
0002
If GC ev09CostEntered(wf) is equal to "1"
0003
//
0004
GC ev09CostEntered(wf) = "0"
0005
Set Grid Color(FC Grid, <Current Row>, GC Extended Amount, <Default>)
0006
Enable Grid(FC Grid, <Current Row>, GC Unit Cost)
0007
//
0008
Set Grid Color(FC Grid, <Current Row>, GC Unit Cost, <Default>)
0009
Enable Grid(FC Grid, <Current Row>, GC Extended Amount)
0010
//
0011
End If
0012 End If
=======================================================================
CONTROL: HYPITEM &Delete
EVENT: Button Clicked
----------------------------------------------------------------------evt_Num_of_Rows
OPT: Repeat ER for Event
0001 // ---------------------------------------------------------------------------0002 //
Delete is not allowed if record exists in F4111 (Update Mode).
0003 // ---------------------------------------------------------------------------0004 If GC ev01 - F4111 Record Exist (wf) is equal to "1" And GC REVL_Reversal D
one (wf) is not equal to "1"
0005
// SAR#8241319- If a record wasn't written, then re-enable the OK button
.
0006
If GC ev06 - Rcd Written (wf) is not equal to "1"
0007
Enable Control(HC &OK)
0008
End If
0009
Stop Processing
0010 Else
0011
// ---------------------------------------------------------------------------0012
// Clear the detail stack records
0013
// ---------------------------------------------------------------------------0014
//
0015
If GC ev06 - Rcd Written (wf) is equal to "1"
0016
F4114 Clear Detail Stack
FC CTID -Computer ID (wf) -> BF szComputerID
GC lnid - Line Number (wf) -> BF mnFromLineNumber
GC lnid - Line Number (wf) -> BF mnThruLineNumber
"1" -> BF cDeleteDetail

FC Doc Type -> BF szDocumentType


FC jobs - JobNoF0911 (wf) -> BF mnF0911Jobnumber
FC JOBS - Inv Job Number (wf) <> BF mnInvJobNumber
0017
End If
0018
//
0019
If GC REVL_Reversal Done (wf) is equal to "1" And GC ev01 - F4111 Recor
d Exist (wf) is equal to "1"
0020
GC Extended Amount = [GC Extended Amount]*-1
0021
GC Quantity = [GC Quantity]*-1
0022
GC ev06 - Rcd Written (wf) = "0"
0023
GC REVL_Reversal Done (wf) = "0"
0024
Set Grid Row Bitmap(FC Grid, <Current Row>, <Check Mark>)
0025
If SL CurrencyProcessing is equal to "Y,Z"
0026
Copy Currency Information(GC Extended Amount, FC ECST - Hold Curre
ncy Info (wf))
0027
End If
0028
Else
0029
Delete Grid Row(FC Grid, <Current Row>)
0030
End If
0031 End If
0032 //
ENDIF F4111 Record Exists
0033 //
0034 // If all rows were deleted, add 1 for entry
0035 //
0036 // SAR# 6584481, Insert grid row is replaced with insert grid buffer row as
0037 // nsert grid row is obseleted. But in the case of input capable grid new l
ine
0038 // is automatically added, so no need to replace and disable code to inser
t
0039 // row.
0040 ! Get Max Grid Rows(FC Grid, VA evt_Num_of_Rows)
0041 ! If VA evt_Num_of_Rows is equal to <Zero>
0042 !
Insert Grid Row(FC Grid, <Current Row>)
0043 ! End If
=======================================================================
CONTROL: HYPITEM Re&verse
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Repeat ER for Event
0001 // SAR 4410921: Calculat and save reversal quantity
0002 // SAR 5796511 - Reversal of Adjust. with Dual incorrect
0003 //
0004 // SAR# 6201823 Begin Use Grid Variable for reversal.
0005 ! VA frm_mnRevQuantity_MATH01 = [GC Quantity]*-1
0006 VA grd_mnRevQuantity_MATH01 = [GC Quantity]*-1
0007 ! VA frm_cReversalOn_EV01 = "1"
0008 VA grd_cReversalOn_EV01 = "1"
0009 //
0010 // SAR 7576301
0011 Clear Control Error(FC G/L Date)
0012 //
0013 // SAR 4410921 End
0014 If GC ev01 - F4111 Record Exist (wf) is not equal to "1"
0015
Disable Control(HC Wareho &Loc Detail)
0016
Set Grid Cell Error(FC Grid, <Current Row>, GC Item Number, "4189")
0017
Stop Processing
0018 Else
0019
// ----------------------------------------------------------------------------

0020
//
d the
0021
//
he Work
0022
//
0023
//
-------0024
If
0025
0026

If the reversal has already been performed on this line previously an


reversal is performed again, this will go out and delete record off t
File (F41UI001) and the GL Work File (F09UI002 and F09UI003).
---------------------------------------------------------------------

GC REVL_Reversal Done (wf) is equal to "1"


//
F4114 Clear Detail Stack
FC CTID -Computer ID (wf) -> BF szComputerID
GC lnid - Line Number (wf) -> BF mnFromLineNumber
GC lnid - Line Number (wf) -> BF mnThruLineNumber
"1" -> BF cDeleteDetail
FC Doc Type -> BF szDocumentType
FC jobs - JobNoF0911 (wf) -> BF mnF0911Jobnumber
FC JOBS - Inv Job Number (wf) -> BF mnInvJobNumber
0027
GC Quantity = [GC Quantity]*-1
0028
GC Extended Amount = [GC Extended Amount]*-1
0029
//
0030
If SL GLInterfaceFlagAR is equal to "Y,Z"
0031
Copy Currency Information(GC Extended Amount, FC ECST - Hold Curre
ncy Info (wf))
0032
End If
0033
//
0034
Set Grid Row Bitmap(FC Grid, <Currently Selected Row>, <Blank/Clear>)
0035
GC REVL_Reversal Done (wf) = "0"
0036
GC ev06 - Rcd Written (wf) = "0"
0037
Stop Processing
0038
Else
0039
//
0040
// ---------------------------------------------------------------------------0041
// If Begin Doc master business functions have not been executed, exe
cute them
0042
//
0043
// now.
0044
// ---------------------------------------------------------------------------0045
If FC ev01-BgnDocOnce(wf) is not equal to "1"
0046
FC ev01-BgnDocOnce(wf) = "0"
0047
F4114 Begin Document
FC CTID -Computer ID (wf) <> BF szComputerID
FC Business Unit -> BF szBranchPlant
FC Batch Number -> BF mnBatchNumber
FC dicj - Batch Date (wf) <> BF jdBatchDate
FC JELN -Last JE Line (wf) <- BF mnLastJELineNumber
FC kco- DocKeyComp (wf) <> BF szDocumentKeyCompany
FC Doc Type -> BF szDocumentType
FC Document Number <> BF mnDocumentNumber
FC G/L Date <> BF jdGLDate
FC Order Date <> BF jdTransactionDate
FC Explanation <> BF szGLExplanation
0048
If SV Error_Status is equal to CO SUCCESS
0049
Disable Control(FC G/L Date)
0050
// SAR 8849121 - Disabling transaction date also.
0051
Disable Control(FC Order Date)
0052
FC ev01-BgnDocOnce(wf) = "1"
0053
// ----------------------------------------------------------------------------

0054
//
0055
//
----------------0056
If
0057

Retrieving the Currency Code and Decimal.


-----------------------------------------------------------SL CurrencyProcessing is equal to "Y,Z"
Decimal Trigger Get By Company
FC kco- DocKeyComp (wf) -> BF szCompany
FC ECST - Hold Currency Info (wf) <> BF mnDomesticAmount0

1
0058
End If
0059
End If
0060
End If
0061
// ------------ENDIF BegDocOnce----------------0062
//
0063
If FC ev01-BgnDocOnce(wf) is equal to "1"
0064
If SL CurrencyProcessing is equal to "Y,Z"
0065
Copy Currency Information(GC Extended Amount, FC ECST - Hold Cu
rrency Info (wf))
0066
End If
0067
//
0068
// SAR 6093818 - Pass the G/L MBF Version to Edit Line.
0069
// SAR 6484392, Pass in header level GL date to Editline
0070
// inorder to write GL entries with current date on the reversal
0071
// entries. Previously GC GLdate was being passed in.
0072
// BUG# 11905201 - PMPN Enhancements - Pass PMPN Fields to EditLin
e
0073
F4114 Edit Line
"3" -> BF cLineAction
FC CTID -Computer ID (wf) -> BF szComputerID
GC ev06 - Rcd Written (wf) <> BF cRecordWrittenToWorkFile
GC lnid - Line Number (wf) <> BF mnLineNumber
FC G/L Date -> BF jdGLDate
FC Explanation -> BF szGLExplanation
"1" -> BF cUpdateQuantityOnHand
PO cAllowQtyOverAvailable <> BF cAllowQtyOverAvailable
FC lnid - Prev Line No (wf) <> BF mnPreviousLinenumber
FC JELN -Last JE Line (wf) <> BF mnLastJELine
PO cEntera1todefaultfromprimary -> BF cDefaultFromPrimaryLocati
on
PO cAllowHeldLots -> BF cAllowHeldLots
FC Order Date -> BF jdTransactionDate
FC Doc Type -> BF szDocumentType
FC dicj - Batch Date (wf) -> BF jdBatchDate
FC Batch Number <> BF mnBatchNumber
FC EV01 - Batch stat (wf) <> BF cBatchStatus
GC Branch/ Plant -> BF szBranchPlant
GC Item Number -> BF szItemNumber
GC Location <> BF szDisplayedLocation
GC Location - File (wf) -> BF szLocation
GC Lot/Serial -> BF szLotNumber
GC UM -> BF szTransactionUOM
GC Quantity <> BF mnTransactionQty
GC Unit Cost -> BF mnTransactionUnitCost
GC Extended Amount <> BF mnExtendedAmount
"2.00" -> BF mnTransactionProcessType
GC Lot Potency <> BF mnLotPotency
GC Lot Grade <> BF szLotGrade
GC Lot Status <> BF cLotStatusCode
GC Lot Expiration Date <> BF jdLotExpirationDate
FC Document Number -> BF mnDocumentNumber
GC Lot Description -> BF szLotDescription

GC Reason Code -> BF szReasonCode


FC jobs - JobNoF0911 (wf) <> BF mnF0911JobNumber
FC kco- DocKeyComp (wf) <> BF szKeyCompany
GC STKT - Stocking Type (wf) <- BF cStockingType
FC JOBS - Inv Job Number (wf) <> BF mnInvJobNumber
GC Memo Lot 1 <> BF szMemoLot1
GC Memo Lot 2 <> BF szMemoLot2
GC WMS Line (wf) <> BF mnWMSLineNumber
"1" -> BF cProcessJE
VA frm_GLMBFVersion_VER -> BF szGLMBFVersion
GC Secondary Quantity <> BF mnSecondaryQty
GC Sec UoM -> BF szSecondaryUOM
<Blank> -> BF cDualCycleCountGLOffset
VA grd_BasedOnDate_BODJ <> BF jdBasedOnDate
VA grd_OnHandDate_OHDJ <> BF jdOnHandDate
GC Lot Effectivity Date <> BF jdLotEffectivityDate
VA grd_SellByDate_SBDJ <> BF jdSellByDate
VA grd_BestBeforeDate_BBDJ <> BF jdBestBeforeDate
VA grd_UserLotDate1_U1DJ <> BF jdUserLotDate1
VA grd_UserLotDate2_U2DJ <> BF jdUserLotDate2
VA grd_UserLotDate3_U3DJ <> BF jdUserLotDate3
VA grd_UserLotDate4_U4DJ <> BF jdUserLotDate4
VA grd_UserLotDate5_U5DJ <> BF jdUserLotDate5
PO szLotGroup -> BF szLotGroup
GC Country of Origin <> BF szCountryOfOrigin
GC Production Number -> BF szProjectManufacturingProd
GC Production Number Short -> BF mnProductionNumberShort
GC ProductionNumber ProcessFlag <> BF cProcessFlag
PO cProductionNoConsumption -> BF cProdNoConsumption
0074
//
0075
If SV Error_Status is equal to CO SUCCESS
0076
GC REVL_Reversal Done (wf) = "1"
0077
Set Grid Row Bitmap(FC Grid, <Current Row>, <X Mark>)
0078
// SAR 5796511 05/20/02-Enable OK button b/c F4114 Edit Line ra
n properly
0079
Enable Control(HC &OK)
0080
Else
0081
// SAR 5796511 05/20/02 -Disable OK button until F4114 Edit Lin
e runs
0082
// successfully (Dual would have halted processing if errrors)
0083
Disable Control(HC &OK)
0084
End If
0085
End If
0086
End If
0087
//
ENDIF Reversal Done
0088 End If
0089 //
ENDIF F4111 Record Exists
=======================================================================
CONTROL: HYPITEM Wareho &Loc Detail
EVENT: Button Clicked
----------------------------------------------------------------------evt_cDualUOMItem_DUAL
evt_szErrorMsgID_DTAI
OPT: Repeat ER for Event
0001 // -------------------------------------------------------0002 // SAR 4336177 Adjusments w/ lots writing 2 F4602's
0003 // Check error status before continuing
0004 // SAR 4410921: Disable error checking per request by WMS
0005 // SAR 5796511 Reverse Adjust. incorrect with Dual item

0006 //
0007 // -------------------------------------------------------0008 If GC WMS Line (wf) is equal to <Blank> Or GC WMS Line (wf) is equal to <Nu
ll> Or GC WMS Line (wf) is equal to <Zero>
0009
GC WMS Line (wf) = GC lnid - Line Number (wf)
0010 End If
0011 //
0012 // SAR 5848051 NS6859983 03/07/02 - Determine if Item is Dual
0013 F4101.Fetch Single
GC itm - Short Item No (wf) = TK Item Number - Short
VA evt_cDualUOMItem_DUAL <- TK Dual Unit Of Measure Item
0014 // If Dual, verify the UOMs entered are valid
0015 If VA evt_cDualUOMItem_DUAL is equal to "1,2"
0016
Verify Dual Unit of Measure
<Blank> -> BF cRelatedToSecondaryUoM
GC UM -> BF szUnitOfMeasureAsInput
GC Sec UoM -> BF szUnitOfMeasureSecondary
"1" -> BF cSuppressErrorMessage
VA evt_szErrorMsgID_DTAI <- BF szErrorMessageID
0017 End If
0018 // SAR 4410921Begin: Passin negative qty if reversal
0019 // SAR# 6201823, Mdified if condition to check grid variables for checking
0020 // reversal and secondary quantity.
0021 If VA grd_cReversalOn_EV01 is equal to "1"
0022
// Begin SAR 5848051 NS6859983 -- If there's no error from "Verify Dual
"
0023
// call, call the P4605 window
0024
If VA evt_szErrorMsgID_DTAI is equal to <Blank> Or VA evt_szErrorMsgID_D
TAI is equal to <Null>
0025
VA grd_SecondaryQty_SQOR = GC Secondary Quantity
0026
Call( App:P4605 , Form:W4605A )
GC itm - Short Item No (wf) -> FI mnShortItemNumber
GC Branch/ Plant -> FI szBranchPlant
GC Location - File (wf) -> FI szLocation
GC Lot/Serial -> FI szLot
FC Doc Type -> FI szOrderType
FC kco- DocKeyComp (wf) -> FI szKeyCompany
VA grd_mnRevQuantity_MATH01 -> FI mnTransactionQuantity
GC UM -> FI szTransactionUnitOfMeasure
FC JOBS - Inv Job Number (wf) -> FI mnJobnumberA
"1" -> FI cQuantityValidation
PO cAllowQtyOverAvailable -> FI cAllowNegativeAvailability
"1" -> FI cAllowNegativeOnHand
GC WMS Line (wf) <> FI mnWMSLineNumber
VA frm_cP4605WindowCanceled_EV01 <- FI cCancelled
GC ev06 - Rcd Written (wf) -> FI cAsynchProcessCompleted
VA grd_SecondaryQty_SQOR <> FI mnDualQuantity
GC Sec UoM -> FI szDualUnitOfMeasure
"EP4114" -> FI szProgramID
0027
End If
0028 Else
0029
If VA evt_szErrorMsgID_DTAI is equal to <Blank> Or VA evt_szErrorMsgID_D
TAI is equal to <Null>
0030
VA grd_SecondaryQty_SQOR = GC Secondary Quantity
0031
// SAR# 6201823, Not passing order number into P4605
0032
Call( App:P4605 , Form:W4605A )
GC itm - Short Item No (wf) -> FI mnShortItemNumber
GC Branch/ Plant -> FI szBranchPlant
GC Location - File (wf) -> FI szLocation
GC Lot/Serial -> FI szLot

FC Doc Type -> FI szOrderType


FC kco- DocKeyComp (wf) -> FI szKeyCompany
GC Quantity -> FI mnTransactionQuantity
GC UM -> FI szTransactionUnitOfMeasure
FC JOBS - Inv Job Number (wf) -> FI mnJobnumberA
"1" -> FI cQuantityValidation
PO cAllowQtyOverAvailable -> FI cAllowNegativeAvailability
"1" -> FI cAllowNegativeOnHand
GC WMS Line (wf) <> FI mnWMSLineNumber
VA frm_cP4605WindowCanceled_EV01 <- FI cCancelled
GC ev06 - Rcd Written (wf) -> FI cAsynchProcessCompleted
VA grd_SecondaryQty_SQOR <> FI mnDualQuantity
GC Sec UoM -> FI szDualUnitOfMeasure
"EP4114" -> FI szProgramID
0033
0034
0035
0036
0037

End If
End If
// End SAR# 6201823
// SAR 4410921End
//

=======================================================================
CONTROL: HYPITEM &Display Config
EVENT: Button Clicked
----------------------------------------------------------------------evt_DTAI_ErrorMsgID
OPT: Using Defaults
0001 //
0002 If GC STKT - Stocking Type (wf) is equal to or empty <Blank> Or GC STKT Stocking Type (wf) is equal to or empty <Null>
0003
F4102.Open
0004
F4102.Fetch Single
GC itm - Short Item No (wf) = TK Item Number - Short
GC Branch/ Plant = TK Business Unit
GC STKT - Stocking Type (wf) = TK Stocking Type
0005
F4102.Close
0006 End If
0007 //
0008 If GC STKT - Stocking Type (wf) is equal to "C" Or GC STKT - Stocking Typ
e (wf) is equal to "c"
0009
//
0010
If GC CFGSID - Unique Configuration ID (wf) is equal to <Null>
0011
F41021.Open
0012
F41021.Fetch Single
GC itm - Short Item No (wf) = TK Item Number - Short
GC Branch/ Plant = TK Business Unit
GC Location - File (wf) = TK Location
GC Lot/Serial = TK Lot/Serial Number
0013
F41021.Close
0014
End If
0015
//
0016
If GC CFGSID - Unique Configuration ID (wf) is not equal to <Null> And G
C CFGSID - Unique Configuration ID (wf) is greater than <Blank>
0017
//
0018
VA evt_DTAI_ErrorMsgID = " "
0019 !
** Business Function NOT FOUND (F32942GetConfiguredStringDetail) **
!
VA evt_DTAI_ErrorMsgID <> BF szErrorMessageId
0020
Call( App:P32983 , Form:W32983B )
GC itm - Short Item No (wf) -> FI mnItemNumberShortKit
GC CFGSID - Unique Configuration ID (wf) -> FI szUniqueConfigurati
onID

0021
//
0022
If VA evt_DTAI_ErrorMsgID is equal to or empty <Blank> Or VA evt_DTAI
_ErrorMsgID is equal to or empty <Null>
0023 !
Call( App:P3298 , Form:W3298C )
!
***MISSING_NAME*** -> DS:W3298C:1
!
GC itm - Short Item No (wf) -> DS:W3298C:2
!
GC itm - Short Item No (wf) -> DS:W3298C:5
!
GC Branch/ Plant -> DS:W3298C:6
!
"5" -> DS:W3298C:7
0024
Else
0025 !
Call( App:P32981 , Form:W32981B )
!
***MISSING_NAME*** -> DS:W32981B:2
!
GC itm - Short Item No (wf) -> DS:W32981B:3
!
GC itm - Short Item No (wf) -> DS:W32981B:4
!
GC Branch/ Plant -> DS:W32981B:6
!
"5" -> DS:W32981B:7
0026
End If
0027
//
0028
End If
0029
//
0030 End If
=======================================================================
CONTROL: HYPITEM &Location Search
EVENT: Button Clicked
----------------------------------------------------------------------evt_EV01_FirstTimeLoadDone
evt_TRQT_PrimaryQty
evt_EV02_PositiveQty
OPT: Using Defaults
0001 // ---------------------------------------------------------------------------0002 //
If the record is already exist in F4111 and the Row exist did not
get
0003 //
performed, retrieve the Stocking Type.
0004 // ---------------------------------------------------------------------------0005 If GC STKT - Stocking Type (wf) is equal to or empty <Blank> Or GC STKT Stocking Type (wf) is equal to or empty <Null>
0006
If GC ev01 - F4111 Record Exist (wf) is equal to "1"
0007
End If
0008 End If
0009 //
0010 If GC ev01 - F4111 Record Exist (wf) is equal to "1"
0011
VA evt_EV01_FirstTimeLoadDone = "1"
0012
VA frm_UNCS_UnitCost = "0"
0013 Else
0014
VA evt_EV01_FirstTimeLoadDone = "0"
0015
VA frm_UNCS_UnitCost = GC Unit Cost
0016 End If
0017 //
0018 F4101 Get Item Master Information
GC itm - Short Item No (wf) -> BF mnShortItemNumber
VA frm_UOM1_PrimaryUOM <> BF szPrimaryUOM
"1" -> BF cSuppressErrorMessage
GC Branch/ Plant -> BF szBranchPlant
VA frm_TFLA_StandardUOMFlag <> BF szStandardUOMConversion
0019 F41002 Get Item UoM Conversion
GC Branch/ Plant -> BF szBranchPlant
GC UM -> BF szFromUnitOfMeasure

VA frm_UOM1_PrimaryUOM -> BF szToUnitOfMeasure


GC Quantity -> BF mnQuantityToConvert
VA evt_TRQT_PrimaryQty <> BF mnQuantityConvertedToPrimary
GC Lot/Serial -> BF szLotNumber
"1" -> BF cSuppressErrorMsg
GC itm - Short Item No (wf) -> BF mnShortItemNumber
VA frm_UOM1_PrimaryUOM -> BF szUOMToPrimary
VA frm_TFLA_StandardUOMFlag -> BF szStandardUOMConversion
0020 //
0021 If GC Quantity is less than <Zero>
0022
VA evt_EV02_PositiveQty = "0"
0023 Else
0024
VA evt_EV02_PositiveQty = "1"
0025 End If
0026 //
0027 VA evt_TRQT_PrimaryQty = abs([VA evt_TRQT_PrimaryQty])
0028 VA frm_UITM_ItemNumber = GC Item Number
0029 //
0030 If GC STKT - Stocking Type (wf) is equal to "C" Or GC STKT - Stocking Typ
e (wf) is equal to "c"
0031
//
0032
// Disabled to disscuss if form W32053A/ W32053B has to be called
SAR :
0033
// 5613949
0034 !
Call( App:P32053 , Form:W32053B )
!
GC itm - Short Item No (wf) -> FI IdentifierShortItem
!
GC Branch/ Plant -> FI CostCenter
!
VA evt_TRQT_PrimaryQty -> FI Unitsquantityshipped
!
VA frm_UOM1_PrimaryUOM -> FI UnitOfMeasure
!
PO cAllowHeldLots -> FI AllowIssuesFromHeldLots
!
PO cAllowQtyOverAvailable -> FI AllowOverIssues
!
VA evt_EV02_PositiveQty -> FI AddToInventoryFlag
!
GC CFGSID - Unique Configuration ID (wf) <- FI szUniqueConfigID
0035
//
0036
FC EV05-Done Unloading Cache (wf) = "0"
0037
VA frm_CacheCursorConfig_GENLNG = "0"
0038
//
0039
While FC EV05-Done Unloading Cache (wf) is not equal to "1"
0040
//
0041
Clear Grid Buffer(FC Grid)
0042
Cache, Get Memory
GB Item Number <- BF szItemNumber
GB Branch/ Plant <- BF szBranchPlant
GB Location <- BF szLocation
GB Lot/Serial <- BF szLotNumber
FC EV05-Done Unloading Cache (wf) <> BF cLastRecordReadFlag
GB Quantity <- BF mnQuantity
GC Memo Lot 1 <- BF szMemoLot1
GC Memo Lot 2 <- BF szMemoLot2
VA frm_CacheCursorConfig_GENLNG <> BF idCacheCursor
0043
//
0044
If FC EV05-Done Unloading Cache (wf) is not equal to "1"
0045
//
0046
If VA evt_EV02_PositiveQty is not equal to "1"
0047
GB Quantity = [GB Quantity]*-1
0048
End If
0049
//
0050
GB UM = VA frm_UOM1_PrimaryUOM
0051
GB Item Number = VA frm_UITM_ItemNumber
0052
GB Unit Cost = VA frm_UNCS_UnitCost

0053
//
0054
If VA evt_EV01_FirstTimeLoadDone is not equal to "1"
0055
GC Branch/ Plant = GB Branch/ Plant
0056
GC Location = GB Location
0057
GC Lot/Serial = GB Lot/Serial
0058
GC Item Number = GB Item Number
0059
GC UM = GB UM
0060
GC Quantity = GB Quantity
0061
GC Unit Cost = GB Unit Cost
0062
GC Extended Amount = "0"
0063
VA evt_EV01_FirstTimeLoadDone = "1"
0064
Else
0065
Insert Grid Buffer Row(FC Grid, <After Current Row>, <Yes>, <No
>, <Yes>, <Yes>, <Yes>)
0066
End If
0067
//
0068
End If
0069
//
0070
End While
0071
//
0072 End If
=======================================================================
CONTROL: HYPITEM &Select from histor
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 // ---------------------------------------------------------------------------0002 //
Retrieve CSID (Configured String ID) only the new line is being ad
ded
0003 //
and the stocking type of 'C'.
0004 // ---------------------------------------------------------------------------0005 If GC ev01 - F4111 Record Exist (wf) is not equal to "1"
0006
//
0007
If GC STKT - Stocking Type (wf) is equal to "C" Or GC STKT - Stocking
Type (wf) is equal to "c"
0008
// Disabled for B9 DB Change, Phase II until DSTR and fxns are modifi
ed
0009
Call( App:P3296 , Form:W3296D )
<Blank> X FI szProduct_Code_F3201
GC Branch/ Plant -> FI szBusiness_Unit_F3215
GC itm - Short Item No (wf) -> FI mnItem_Number__Short_F3215
GC CFGSID - Unique Configuration ID (wf) <- FI szUniqueConfigurati
onID
0010
End If
0011
//
0012 End If
=======================================================================
CONTROL: HYPITEM C&onfig Search
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 Call( App:P32202 , Form:W32202C )
GC itm - Short Item No (wf) -> FI ItemNumberShortKit
GC Branch/ Plant -> FI CostCenter
GC CFGSID - Unique Configuration ID (wf) <- FI szUniqueConfigurationID

=======================================================================
CONTROL: HYPITEM Lo&t Dates
EVENT: Button Clicked
----------------------------------------------------------------------evt_cOKPressed_EV01
OPT: Using Defaults
0001 If GC Item Number is not equal to <Blank> And GC Branch/ Plant is not equal
to <Blank> And GC Branch/ Plant is not equal to <Null> And GC Item Number is no
t equal to <Null> And GC Lot/Serial is not equal to <Blank> And GC Lot/Serial is
not equal to <Null> And FC Order Date is not equal to <Null Date>
0002
Call( App:P4108 , Form:W4108G )
GC Lot/Serial -> FI szLot
GC itm - Short Item No (wf) -> FI mnIdentifierShortItem
GC Branch/ Plant -> FI szCostCenter
VA grd_BasedOnDate_BODJ <> FI jdBasedOnDate
VA grd_OnHandDate_OHDJ <> FI jdOnHandDate
GC Lot Effectivity Date <> FI jdLotEffectivityDate
VA grd_SellByDate_SBDJ <> FI jdSellByDate
VA grd_BestBeforeDate_BBDJ <> FI jdBestBeforeDate
VA grd_UserLotDate1_U1DJ <> FI jdUserLotDate1
VA grd_UserLotDate2_U2DJ <> FI jdUserLotDate2
VA grd_UserLotDate3_U3DJ <> FI jdUserLotDate3
VA grd_UserLotDate4_U4DJ <> FI jdUserLotDate4
VA grd_UserLotDate5_U5DJ <> FI jdUserLotDate5
GC Lot Expiration Date <> FI jdDate - Lot Expiration
VA evt_cOKPressed_EV01 <- FI cOKPressed
0003
If VA evt_cOKPressed_EV01 is equal to "1"
0004
F41UI001 Update Expiration Date
FC CTID -Computer ID (wf) -> BF szComputerID
FC JOBS - Inv Job Number (wf) -> BF mnJobNumber
GC lnid - Line Number (wf) -> BF mnLineNumber
GC Lot Expiration Date -> BF jdDaterExpiration
VA grd_BasedOnDate_BODJ -> BF jdBasedOnDate
VA grd_OnHandDate_OHDJ -> BF jdOnHandDate
GC Lot Effectivity Date -> BF jdLotEffectivityDate
VA grd_SellByDate_SBDJ -> BF jdSellByDate
VA grd_BestBeforeDate_BBDJ -> BF jdBestBeforeDate
VA grd_UserLotDate1_U1DJ -> BF jdUserLotDate1
VA grd_UserLotDate2_U2DJ -> BF jdUserLotDate2
VA grd_UserLotDate3_U3DJ -> BF jdUserLotDate3
VA grd_UserLotDate4_U4DJ -> BF jdUserLotDate4
VA grd_UserLotDate5_U5DJ -> BF jdUserLotDate5
0005
End If
0006 End If
=======================================================================
CONTROL: HYPITEM &Attachments
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 // If the document doesn't exist - error
0003 //
0004 If GC doc - Document Number (wf) is equal to <Zero> Or GC doc - Document Nu
mber (wf) is equal to <Null> Or GC lnid - Line Number (wf) is equal to <Zero> Or
GC lnid - Line Number (wf) is equal to <Null>
0005
Set Grid Cell Error(FC Grid, <Current Row>, <All Columns>, "2832")
0006 Else
0007
Media Object Structures(GT4111, <Edit>, VA frm_Media_Objects_Status, GC
doc - Document Number (wf), GC dct - Doc Ty (wf), GC kco - Doc Co (wf), GC lnid

- Line Number (wf))


0008
If VA frm_Media_Objects_Status is equal to "1"
0009
Set Grid Text Indicator(FC Grid, <Current Row>, <Yes>)
0010
Else
0011
Set Grid Text Indicator(FC Grid, <Current Row>, <No>)
0012
End If
0013 End If
=======================================================================
CONTROL: HYPITEM Prod No. Consumption
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 // BUG# 11904715 - PMPN Enhancements - Begin
0002 // Inventory Tag file Integrity - Call P42054 for PN Consumption
0003 If GC ProductionNumber ProcessFlag is equal to "1,3"
0004 !
If GC ProdNoConsumption Cancelled is equal to "1"
0005
Math Numeric to String, Convert
FC JOBS - Inv Job Number (wf) -> BF mnMathNumeric01
VA frm_szProdNoJobNumber_JOB <- BF szVideoConstant30A
0006
Call( App:P42054 , Form:W42054A )
GC itm - Short Item No (wf) -> FI mnIdentifierShortItem
GC Branch/ Plant -> FI szCostCenter
GC Location - File (wf) -> FI szLocation
GC Lot/Serial -> FI szLot
GC Production Number -> FI szProductionNumber
GC Quantity -> FI mnQuantityTransaction
VA frm_szProdNoJobNumber_JOB <> FI szJobNumber
VA frm_cProdNumInvCancelled_EV01 <- FI cCancelButtonclicked
GC lnid - Line Number (wf) -> FI mnLineNumber
GC UM -> FI szTransUnitOfMeasure
0007
If GC ProdNoConsumption Cancelled is equal to "1"
0008
If VA frm_cProdNumInvCancelled_EV01 is equal to "1"
0009
Set Grid Cell Error(FC Grid, <Currently Selected Row>, GC Quant
ity, "34401R")
0010
Stop Processing
0011
Else
0012
GC ProdNoConsumption Cancelled = "0"
0013
Clear Grid Cell Error(FC Grid, <Currently Selected Row>, GC Qua
ntity)
0014
End If
0015
End If
0016 !
End If
0017 End If
0018 // BUG# 11904715 - PMPN Enhancements - End
=======================================================================
CONTROL: HYPITEM &Item Search
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 // Initialize fields for the multiple return
0003 //
Call Multiple Item Search
0004 //
0005 Call( App:P40ITM2 , Form:W40ITM2F , Ver: ZJDE0001 )
FC Business Unit -> FI szCostCenter
0006 //
0007 FC EV05-Done Unloading Cache (wf) = "0"
0008 VA frm_CacheCursor_GENLNG = "0"

0009 Get Selected Grid Row Number(FC Grid, FC MATH01-Item Search Grid Number (wf
))
0010 //
0011 If GC Item Number is not equal to <Blank> And GC Item Number is not equal t
o <Null>
0012
If FC MATH01-Item Search Grid Number (wf) is less than or equal to "1.00
"
0013
FC MATH01-Item Search Grid Number (wf) = [FC MATH01-Item Search Grid
Number (wf)]+1
0014
End If
0015 End If
0016 //
0017 While FC EV05-Done Unloading Cache (wf) is not equal to "1"
0018
//
0019
Clear Grid Buffer(FC Grid)
0020
// BUG 11836680 - Retrieve the Country of Origin also.
0021
Cache, Get Memory
GB Item Number <- BF szItemNumber
GB Branch/ Plant <- BF szBranchPlant
GB Location <- BF szLocation
GB Lot/Serial <- BF szLotNumber
FC EV05-Done Unloading Cache (wf) <- BF cLastRecordReadFlag
GB Quantity <- BF mnQuantity
GB UM <- BF szUnitOfMeasure
GB Memo Lot 1 <- BF szMemoLot1
GB Memo Lot 2 <- BF szMemoLot2
VA frm_CacheCursor_GENLNG <> BF idCacheCursor
GB Lot Expiration Date <- BF jdDateLayerExpiration
GB Lot Status <- BF cLotStatusCode
GC itm - Short Item No (wf) <- BF mnIdentifierShortItem
GB Lot Potency <- BF mnLotPotency
GB Lot Grade <- BF szLotGrade
GC Country of Origin <- BF szCountryOfOrigin
0022
//
0023
//
Only do an Isert Grid line if the Last Record Read is not '1'
0024
//
Otherwise, it will write a blank row
0025
//
0026
If FC EV05-Done Unloading Cache (wf) is not equal to "1"
0027
If FC MATH01-Item Search Grid Number (wf) is equal to "1.00"
0028
Update Grid Buffer Row(FC Grid, FC MATH01-Item Search Grid Number
(wf), <Yes>, <No>, <Yes>, <Yes>, <Yes>)
0029
Else
0030
Insert Grid Buffer Row(FC Grid, FC MATH01-Item Search Grid Number
(wf), <Yes>, <No>, <Yes>, <Yes>, <Yes>)
0031
End If
0032
FC MATH01-Item Search Grid Number (wf) = [FC MATH01-Item Search Grid
Number (wf)]+1
0033
End If
0034 End While
0035 Set Control Focus(FC G/L Date)
0036 //
=======================================================================
CONTROL: HYPITEM Item &Ledger
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 Call( App:P4111 , Form:W4111A , Ver: PO szItemLedgerVersion )
FC Business Unit -> FI Costcenter

=======================================================================
CONTROL: HYPITEM &Journal Entries
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 // Call Journal Entries
0003 //
0004 Call( App:P0911 , Form:W0911I , Ver: PO szJournalEntriesVersion )
"N" -> FI Batchtype
FC Batch Number -> FI Batchnumber
FC Doc Type -> FI Documenttype
FC Document Number -> FI Docvoucherinvoicee
FC kco- DocKeyComp (wf) -> FI Companykey
=======================================================================
CONTROL: EDIT G/L Date
EVENT: Control Exited/Changed-Asynch
----------------------------------------------------------------------evt_CurrencyCode_CRCD
evt_cDocActionCode_ACTN
evt_MaxGridRows_MATH01
OPT: Using Defaults
0001 //
0002 // SAR 8918848- Initializing the evt_CurrencyCode_CRCD variable so that it
0003 // does not retain its previous value.
0004 VA evt_CurrencyCode_CRCD = " "
0005 // Call F0911 Begin Doc when the G/L date changes
0006 //
0007 // SAR 6484392, Check the DocActionCode and pass it into F0911 Begin Doc.
0008 If SV Form_ Mode is equal to CO ADD_MODE
0009
VA evt_cDocActionCode_ACTN = "1"
0010 Else
0011
VA evt_cDocActionCode_ACTN = "2"
0012 End If
0013 If FC jobs - JobNoF0911 (wf) is not equal to <Zero>
0014
// SAR 8918848 - Checking for null value of evt_CurrencyCode_CRCD also.
0015
//
0016
If VA evt_CurrencyCode_CRCD is equal to or empty <Blank> Or VA evt_Curre
ncyCode_CRCD is equal to <Null>
0017
F0010 Get Company Currency Code
FC kco- DocKeyComp (wf) -> BF szCompany
VA evt_CurrencyCode_CRCD <- BF szCurrencyCode
0018
End If
0019
F0911 Begin Document
FC jobs - JobNoF0911 (wf) <> BF mnJobNumber
VA evt_cDocActionCode_ACTN -> BF cDocAction
"1" <> BF cEditInstructionFlag
FC JELN -Last JE Line (wf) <> BF mnLastLineNumber
FC kco- DocKeyComp (wf) <> BF szCompanyKey
FC Doc Type <> BF szDocumentType
FC Document Number <> BF mnDocNumber
FC G/L Date <> BF jdGLDate
FC Batch Number <> BF mnBatchNumber
"N" <> BF szBatchType
FC dicj - Batch Date (wf) <> BF jdBatchDate
FC dicj - Batch Date (wf) <> BF jdBatchSystemDate
VA evt_CurrencyCode_CRCD <> BF szTransactionCurrency
FC Explanation <> BF szExplanation
VA evt_CurrencyCode_CRCD <> BF szBaseCoCurrency

0020
0021
0022
0023
0024
0025
usly
0026
0027
0028
0029
0030
0031
0032
0033
TH01
0034
0035
0036
0037
0038
0039
0040
0041
0042
0043
0044
0045
0046
0047
0048

VA frm_GLMBFVersion_VER -> BF szJEVersion


End If
//
// Change the G/L Date in all existing lines
//
If FC G/L Date is not equal to VA frm_HoldGLDate_DGL
// SAR# 7919950 - Changed the code to retain all the G/L dates of previo
!
!
!

// enterd rows and update all newly entered rows with new G/L date
Get Max Grid Rows(FC Grid, VA frm_MaxGridRows_MATH01)
VA frm_MaxGridRows_MATH01 = [VA frm_MaxGridRows_MATH01]-1
VA frm_Index_MATH01 = "1"
Get Max Grid Rows(FC Grid, VA evt_MaxGridRows_MATH01)
VA evt_MaxGridRows_MATH01 = [VA evt_MaxGridRows_MATH01]-1
VA frm_Index_MATH01 = VA frm_MaxGridRows_MATH01
While VA frm_Index_MATH01 is less than or equal to VA evt_MaxGridRows_MA

// SAR# 7919950 End


Get Grid Row(FC Grid, VA frm_Index_MATH01)
GC G/L Date = FC G/L Date
VA frm_Index_MATH01 = [VA frm_Index_MATH01]+1
End While
End If
VA frm_HoldGLDate_DGL = FC G/L Date
// SAR# 7919950
! VA frm_MaxGridRows_MATH01 = "0"
Clear Edit Control Error(FC G/L Date)
//
// SAR 7576301 - Validate G/L Date once value has changed.
If SV Form_ Mode is equal to CO UPDATE_MODE
VA frm_cDisableGlDate_EV01 = "1"
F0008 Edit Date
FC kco- DocKeyComp (wf) -> BF szCompany
FC G/L Date -> BF jdDate
FC Doc Type -> BF szDocumentType
"09" -> BF szSystem
"1" -> BF cFYPNFlag
0049 End If
=======================================================================
CONTROL: EDIT Business Unit
EVENT: Control Exited/Changed-Inline
----------------------------------------------------------------------OPT: Using Defaults
0001 Clear Edit Control Error(FC Business Unit)
0002 Press Button(FC DisableWMSOverride)
=======================================================================
CONTROL: GRID Grid
EVENT: Add Grid Rec to DB - Before
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 // Suppress the Add of the record through OneWorld. The Master Business
0003 // Functions handle the writing of records to the database.
0004 //
0005 Suppress Add
----------------------------------------------------------------------EVENT: Update Grid Rec to DB-Before

----------------------------------------------------------------------OPT: Using Defaults


0001 //
0002 // Suppress the update of records through OneWorld. The Master Business
0003 // Functions will handle the updating of records to the database.
0004 //
0005 Suppress Update
----------------------------------------------------------------------EVENT: Delete Grid Rec Verify-Before
----------------------------------------------------------------------OPT: Using Defaults
0001 Suppress Delete
----------------------------------------------------------------------EVENT: Row is Entered
----------------------------------------------------------------------OPT: Using Defaults
0001 // SAR 4980190
0002 If VA frm_cVFS_MEOW is equal to "1"
0003
If GC Item Number is not equal to <Blank> And GC Branch/ Plant is not eq
ual to <Blank> And GC Branch/ Plant is not equal to <Null> And GC Item Number is
not equal to <Null> And GC Lot/Serial is not equal to <Blank> And GC Lot/Serial
is not equal to <Null> And FC Order Date is not equal to <Null Date>
0004
// SAR 5329956 - If Edit Line was called but there is not Expiration
Date,
0005
// disable the Lot Date Override row exit.
0006
If VA grd_cEditLineCalled_EV01 is equal to "1" And GC Lot Expiration
Date is equal to <Null Date>
0007
Disable Control(HC Lo&t Dates)
0008
Else
0009
Enable Control(HC Lo&t Dates)
0010
End If
0011
Else
0012
Disable Control(HC Lo&t Dates)
0013
End If
0014 End If
0015 //
----------------------------------------------------------------------EVENT: Row is Selected (Web Only)
----------------------------------------------------------------------OPT: Using Defaults
0001 Press Button(FC DisableWMSOverride)
----------------------------------------------------------------------EVENT: Row Exit & Changed - Inline
----------------------------------------------------------------------evt_IdentifierShortItem
evt_BranchPlant
evt_MatrixControlled_EV01
OPT: Using Defaults
0001 //
0002 //
SAR 7999187 - If the line has exited without a quantity, set an error
.
0003 // Normally we would rely on the MBF to catch this but when adding a new li
ne
0004 // to a transaction, if the user doesn't enter a quantity, then Begin Doc a
nd
0005 // therefore Edit Line are not called. When the G/L Date field is changed t

he
0006 // ER sets the cDisableGlDate variable to 1 and when a quantity is entered
0007 // then that variable is set back to 0. If it is left at 1 then Begin Doc i
s
0008 // not called, and Edit Line is not called.
0009 //
0010 // SAR 8249695 - The user can enter a zero quantity but they must enter an
0011 // extended cost if they do.
0012 If GC Quantity is equal to <Zero> And GC Extended Amount is equal to <Zero>
0013
Set Grid Cell Error(FC Grid, <Currently Selected Row>, GC Quantity, "000
3")
0014 Else
0015
Clear Grid Cell Error(FC Grid, <Currently Selected Row>, GC Quantity)
0016 End If
0017 //
0018 If FC Business Unit is equal to or empty <Blank> And GC Branch/ Plant is eq
ual to or empty <Blank>
0019
Set Grid Cell Error(FC Grid, <Current Row>, GC Branch/ Plant, "0003")
0020
Set Edit Control Error(FC Business Unit, "0003")
0021 End If
0022 //
0023 If GC Branch/ Plant is not equal to <Blank>
0024
Clear Grid Cell Error(FC Grid, <Current Row>, GC Branch/ Plant)
0025 End If
0026 If GC Branch/ Plant is not equal to <Blank> And FC Business Unit is equal t
o or empty <Blank>
0027
FC Business Unit = GC Branch/ Plant
0028 End If
0029 //
0030 If FC Business Unit is not equal to <Blank> And FC Business Unit is not equ
al to <Null>
0031
//
0032
Clear Edit Control Error(FC Business Unit)
0033
//
0034
If GC Branch/ Plant is equal to or empty <Blank>
0035
GC Branch/ Plant = FC Business Unit
0036
End If
0037
//
0038
// SAR 6167573 - Move this if statement to after the check for GC Branch
Plant
0039
// being blank instead of before.
0040
// SAR 7576301 - Disable this condition.
0041 !
If FC ev01-BgnDocOnce(wf) is not equal to "1"
0042
// SAR 7576301 - New condition added to allow user to change G/L Date
before
0043
// disabling it once Qty in grid is changed.
0044
If FC ev01-BgnDocOnce(wf) is not equal to "1" And VA frm_cDisableGlDa
te_EV01 is not equal to "1"
0045
//
0046
F4114 Begin Document
FC CTID -Computer ID (wf) -> BF szComputerID
GC Branch/ Plant -> BF szBranchPlant
FC Batch Number <> BF mnBatchNumber
FC dicj - Batch Date (wf) <> BF jdBatchDate
FC JELN -Last JE Line (wf) <> BF mnLastJELineNumber
FC kco- DocKeyComp (wf) <> BF szDocumentKeyCompany
FC Doc Type <> BF szDocumentType
FC Document Number <> BF mnDocumentNumber
FC G/L Date <> BF jdGLDate
FC Order Date <> BF jdTransactionDate

FC Explanation <> BF szGLExplanation


0047
If SV Error_Status is equal to CO SUCCESS
0048
FC ev01-BgnDocOnce(wf) = "1"
0049
VA frm_HoldGLDate_DGL = FC G/L Date
0050
Disable Control(FC Order Date)
0051
Disable Control(FC Explanation)
0052
Disable Control(FC Doc Type)
0053
Disable Control(FC Document Number)
0054
Disable Control(FC Business Unit)
0055
End If
0056
// ---------------------------------------------------------------------------0057
//
If Currency Processing Flag = Y or Z, retrieve the curr
ency code and
0058
//
decimal value for extended amount..
0059
// ---------------------------------------------------------------------------0060
If SL CurrencyProcessing is equal to "Y,Z"
0061
FC ECST - Hold Currency Info (wf) = "1"
0062
Decimal Trigger Get By Company
FC kco- DocKeyComp (wf) -> BF szCompany
FC ECST - Hold Currency Info (wf) <> BF mnDomesticAmount01
0063
End If
0064
End If
0065 !
End If
0066
//
0067 End If
0068 //
0069 // SAR 3670376
0070 // description will be popluated when the row is exited so that the correct
0071 // branch item relation can be validated
0072 //
0073 // 8599417 - Retrieve the matrix controlled Item information from F4101 tab
le
0074 F4101 Get Item Master Information
VA evt_IdentifierShortItem <- BF mnShortItemNumber
GC Item Number -> BF szPrimaryItemNumber
GC Item Description <- BF szDescription
GC Branch/ Plant -> BF szBranchPlant
VA evt_MatrixControlled_EV01 <- BF cMatrixControlled
0075 //
0076 // 8599417 - If the Item is parent matrix item or hierarchy level matrix it
em
0077 // then issue an error.
0078 If VA evt_MatrixControlled_EV01 is equal to "1" Or VA evt_MatrixControlled_
EV01 is equal to "3"
0079
Set Grid Cell Error(FC Grid, <Currently Selected Row>, GC Item Number, "
4101E")
0080 Else
0081
Clear Grid Cell Error(FC Grid, <Currently Selected Row>, GC Item Number)
0082 End If
----------------------------------------------------------------------EVENT: Row is Exited
----------------------------------------------------------------------OPT: Using Defaults
0001 Disable Control(HC Lo&t Dates)
----------------------------------------------------------------------EVENT: Row Exit & Changed - Asynch

----------------------------------------------------------------------evt_cP4605Cancelled
OPT: Using Defaults
0001 If GC ev01 - F4111 Record Exist (wf) is not equal to "1" And FC ev01-BgnDoc
Once(wf) is equal to "1"
0002
// ---------------------------------------------------------------------------0003
// Save entered lot fields. If returned from the master business funct
ions,
0004
// protect fields.
0005
// ---------------------------------------------------------------------------0006
//
0007
FC mmej - Ent Lot Exp Date (wf) = GC Lot Expiration Date
0008
FC lotp - Ent Lot Potency (wf) = GC Lot Potency
0009
FC lotg - EntLotGrade(wf) = GC Lot Grade
0010
FC ldsc - Ent Lot Desc (wf) = GC Lot Description
0011
// ---------------------------------------------------------------------------0012
// If the Reversal flag is not set, process the Row is Exited event.
0013
// ---------------------------------------------------------------------------0014
//
0015
// ---------------------------------------------------------------------------0016
//
PO-ProtectCost = 1 : Disable Cost
0017
//
PO-ProtectCost = 2 : Hide Cost
0018
//
0019
//
If UnitCostEnter flag is set to '1' , then ExtendedCost must be
0020
//
recalculated. This is because if the quantities changes, the
0021
//
ExtendedCost was never recalculated in the Inventory Transaction
Program
0022
//
Edit Line (F4111EditLine); and it will give an error.
0023
// ---------------------------------------------------------------------------0024
//
0025
If PO cProtectCosts is equal to "1,2"
0026
GC Unit Cost = "0"
0027
GC Extended Amount = "0"
0028
Else
0029
If VA grd_Old_ItemNumber is not equal to GC Item Number And VA grd_Ol
d_UnitCost is equal to GC Unit Cost And VA grd_Old_ItemNumber is greater than <B
lank>
0030
GC Unit Cost = "0"
0031
GC Extended Amount = "0"
0032
End If
0033
End If
0034
//
0035
If SL CurrencyProcessing is equal to "Y,Z"
0036
Copy Currency Information(GC Extended Amount, FC ECST - Hold Currency
Info (wf))
0037
End If
0038
//
0039
If GC Branch/ Plant is equal to or empty <Blank>
0040
GC Branch/ Plant = FC Business Unit
0041
End If
0042
//
0043
If GC G/L Date is equal to ""
0044
GC G/L Date = FC G/L Date
0045
End If

0046
0047
the
0048
the
0049
0050
0051
0052
0053
0054
0055
0056
0057
0058
0059
054
0060
0061

//
// If the quantity is greater than zero, the amount is being added 'To'
// location. If it is less than zero, the amount is being taken 'From'
// location
//
If GC Quantity is greater than <Zero>
VA frm_FromTo = "T"
Else
VA frm_FromTo = "F"
End If
//
// BUG 11836680 - Pass the Country of Origin
// BUG# 11905201 - PMPN Enhancements
// Added PMPN Fields in Edit Line Call. Retrieve ProcessFlag to call P42
// for Inventory Tag update
F4114 Edit Line
FC CTID -Computer ID (wf) -> BF szComputerID
GC ev06 - Rcd Written (wf) <> BF cRecordWrittenToWorkFile
GC lnid - Line Number (wf) <> BF mnLineNumber
GC G/L Date -> BF jdGLDate
FC Explanation -> BF szGLExplanation
"1" -> BF cUpdateQuantityOnHand
PO cAllowQtyOverAvailable <> BF cAllowQtyOverAvailable
FC lnid - Prev Line No (wf) <> BF mnPreviousLinenumber
VA frm_FromTo -> BF cFromTo
FC JELN -Last JE Line (wf) <> BF mnLastJELine
PO cEntera1todefaultfromprimary -> BF cDefaultFromPrimaryLocation
PO cAllowHeldLots -> BF cAllowHeldLots
FC Order Date -> BF jdTransactionDate
FC Doc Type -> BF szDocumentType
FC dicj - Batch Date (wf) -> BF jdBatchDate
FC Batch Number <> BF mnBatchNumber
FC EV01 - Batch stat (wf) <> BF cBatchStatus
GC Branch/ Plant -> BF szBranchPlant
GC Item Number -> BF szItemNumber
GC itm - Short Item No (wf) <- BF mnShortItemNumber
GC Location <> BF szDisplayedLocation
GC Location - File (wf) <- BF szLocation
GC Lot/Serial <> BF szLotNumber
GC UM <> BF szTransactionUOM
GC Quantity -> BF mnTransactionQty
GC Unit Cost <> BF mnTransactionUnitCost
GC Extended Amount <> BF mnExtendedAmount
"2" -> BF mnTransactionProcessType
GC Lot Potency <> BF mnLotPotency
GC Lot Grade <> BF szLotGrade
GC Lot Status <> BF cLotStatusCode
GC Lot Expiration Date <> BF jdLotExpirationDate
FC Document Number <> BF mnDocumentNumber
GC Lot Description <> BF szLotDescription
GC Reason Code -> BF szReasonCode
FC jobs - JobNoF0911 (wf) <> BF mnF0911JobNumber
FC kco- DocKeyComp (wf) <> BF szKeyCompany
GC STKT - Stocking Type (wf) <- BF cStockingType
FC JOBS - Inv Job Number (wf) <> BF mnInvJobNumber
GC Memo Lot 1 <> BF szMemoLot1
GC Memo Lot 2 <> BF szMemoLot2

GC ev09CostEntered(wf) -> BF cCostEntered


GC WMS Line (wf) <> BF mnWMSLineNumber
"1" -> BF cProcessJE
VA frm_GLMBFVersion_VER -> BF szGLMBFVersion
GC Secondary Quantity -> BF mnSecondaryQty
GC Sec UoM <> BF szSecondaryUOM
<Blank> -> BF cDualCycleCountGLOffset
VA grd_BasedOnDate_BODJ <> BF jdBasedOnDate
VA grd_OnHandDate_OHDJ <> BF jdOnHandDate
GC Lot Effectivity Date <> BF jdLotEffectivityDate
VA grd_SellByDate_SBDJ <> BF jdSellByDate
VA grd_BestBeforeDate_BBDJ <> BF jdBestBeforeDate
VA grd_UserLotDate1_U1DJ <> BF jdUserLotDate1
VA grd_UserLotDate2_U2DJ <> BF jdUserLotDate2
VA grd_UserLotDate3_U3DJ <> BF jdUserLotDate3
VA grd_UserLotDate4_U4DJ <> BF jdUserLotDate4
VA grd_UserLotDate5_U5DJ <> BF jdUserLotDate5
GC CFGSID - Unique Configuration ID (wf) <> BF szUniqueConfigurationI
D
PO
GC
GC
GC
GC
PO

szLotGroup -> BF szLotGroup


Country of Origin <> BF szCountryOfOrigin
Production Number -> BF szProjectManufacturingProd
Production Number Short -> BF mnProductionNumberShort
ProductionNumber ProcessFlag <> BF cProcessFlag
cProductionNoConsumption -> BF cProdNoConsumption

0062
//
0063
// SAR 5329956 - Mark that edit line was called.
0064
VA grd_cEditLineCalled_EV01 = "1"
0065
// End SAR 5329956
0066
//
0067 !
If GC STKT - Stocking Type (wf) is equal to "C" Or GC STKT - Stocking
Type (wf) is equal to "c"
0068 !
If GC CFGSID - Unique Configuration ID (wf) is equal to <Null>
0069 !
Set Grid Row Bitmap(FC Grid, <Current Row>, <Action Msg>)
0070 !
Else
0071 !
Set Grid Row Bitmap(FC Grid, <Current Row>, <Blank>)
0072 !
End If
0073 !
Else
0074 !
Set Grid Row Bitmap(FC Grid, <Current Row>, <Blank>)
0075 !
End If
0076
//
0077
// ---------------------------------------------------------------------------0078
//
If lot information returned and is different than the entered fi
elds,
0079
//
protect the columns
0080
// ---------------------------------------------------------------------------0081
//
0082 !
If FC mmej - Ent Lot Exp Date (wf) is not equal to GC Lot Expiration
Date
0083 !
Disable Grid(FC Grid, <Current Row>, GC Lot Expiration Date)
0084 !
End If
0085 !
//
0086 !
If FC lotp - Ent Lot Potency (wf) is not equal to GC Lot Potency
0087 !
Disable Grid(FC Grid, <Current Row>, GC Lot Potency)
0088 !
End If
0089 !
//
0090 !
If FC lotg - EntLotGrade(wf) is not equal to GC Lot Grade
0091 !
Disable Grid(FC Grid, <Current Row>, GC Lot Grade)

0092 !
End If
0093 !
//
0094 !
If FC ldsc - Ent Lot Desc (wf) is not equal to GC Lot Description
0095 !
Disable Grid(FC Grid, <Current Row>, GC Lot Description)
0096 !
End If
0097
// ---------------------------------------------------------------------------0098
//
Display Batch Group Box
0099
// ---------------------------------------------------------------------------0100
If FC Batch Number is not equal to <Zero>
0101
FC ICU - BatchNo (wf) = FC Batch Number
0102
Show Control(FC Batch Number)
0103
Show Control(FC Group Box 49)
0104
Disable Control(FC Batch Number)
0105
End If
0106
//
0107
// Begin SAR 7333203 - Initialize F0911 Job no. & BeginDoc Flag if JELN
is
0108
// blank/null/Zero.
0109
// SAR 7576301 - Disable all this code.
0110 !
If FC JELN -Last JE Line (wf) is equal to <Blank> Or FC JELN -Last JE
Line (wf) is equal to <Null> Or FC JELN -Last JE Line (wf) is equal to <Zero>
0111 !
FC jobs - JobNoF0911 (wf) = 0
0112
// SAR 7576301 - If the G/L Interface flag is not on in branch plant
constants
0113
// no J/E line numbers will be created. That does not mean processing
should
0114
// not continue.
0115 !
FC ev01-BgnDocOnce(wf) = "0"
0116 !
End If
0117
// End SAR 7333203
0118 End If
0119 // ----- ENDIF Reversal not equal to '1' ----0120 //
0121 VA grd_Old_ItemNumber = GC Item Number
0122 VA grd_Old_UnitCost = GC Unit Cost
0123 //
0124 // BUG - 14049888 - Copy the initial lot status code in the variable
0125 // nitialLotStatus
0126 VA grd_szInitialLotStsCode_LOTS = GC Lot Status
0127 // BUG# 11904715 - PMPN Enhancements - Begin
0128 // Inventory Tag file Integrity - Call P42054 for PN Consumption
0129 If VA frm_cPMPNInstalled_EV01 is equal to "1"
0130
If GC ProductionNumber ProcessFlag is equal to "1"
0131
If GC Production Number is not equal to <Blank> And GC Production Num
ber is not equal to <Null>
0132
Disable Control(HC Prod No. Consumption)
0133 !
Set Grid Cell Error(FC Grid, <Currently Selected Row>, GC Quanti
ty, "41OHT")
0134
Else
0135
Enable Control(HC Prod No. Consumption)
0136
Math Numeric to String, Convert
FC JOBS - Inv Job Number (wf) -> BF mnMathNumeric01
VA frm_szProdNoJobNumber_JOB <- BF szVideoConstant30A
0137
Call( App:P42054 , Form:W42054A )
GC itm - Short Item No (wf) -> FI mnIdentifierShortItem
GC Branch/ Plant -> FI szCostCenter
GC Location - File (wf) -> FI szLocation
GC Lot/Serial -> FI szLot

GC Production Number -> FI szProductionNumber


GC Quantity -> FI mnQuantityTransaction
VA frm_szProdNoJobNumber_JOB <> FI szJobNumber
GC ProdNoConsumption Cancelled <- FI cCancelButtonclicked
GC lnid - Line Number (wf) -> FI mnLineNumber
GC UM -> FI szTransUnitOfMeasure
If GC ProdNoConsumption Cancelled is equal to "1"
Set Grid Cell Error(FC Grid, <Currently Selected Row>, GC Quant

0138
0139
ity, "34401R")
0140
Else
0141
Clear Grid Cell Error(FC Grid, <Currently Selected Row>, GC Qua
ntity)
0142
End If
0143
End If
0144
Else
0145
If GC ProductionNumber ProcessFlag is equal to "3"
0146
Enable Control(HC Prod No. Consumption)
0147
Else
0148
Disable Control(HC Prod No. Consumption)
0149
End If
0150
End If
0151 End If
0152 // BUG# 11904715 - PMPN Enhancements - End
=======================================================================
CONTROL: GRIDCOL Item Number
EVENT: Visual Assist Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 If PO cItemSearchAndSelect_EV01 is equal to "1" And VA frm_cApparelActive_E
V01 is equal to "1"
0002
Suppress Default Visual Assist Form
0003
Call( App:PCW41011 , Form:WCW41011A )
GC Item Number <- FI szIdentifier2ndItem
0004 End If
----------------------------------------------------------------------EVENT: Col Exited & Changed - Inline
----------------------------------------------------------------------evt_cMatrixErrorCode_ERRC
evt_mnMatrixJobNumber_JOBS
evt_szMatrixUser_USER
evt_szMatrixLevelName_C9LVNM
evt_cMatrixItem_C9MXLN
evt_mnMatrixLevelNumber_C9LVNO
evt_szMatrixStructure_C9STRC
evt_szMatrixErrorID_DTAI
evt_mnQuantityControl_TRQT
evt_mnMatrixMaxGrid_MATH01
evt_idMatricCacheCursor_GENLNG
evt_mnIdentifierShortItem_ITM
evt_szTransactionUOM_UOM
evt_cSKULevelItem_EV11
evt_cStyleITEM_YN_EV01
OPT: Using Defaults
0001 //
0002 GC CFGSID - Unique Configuration ID (wf) = ""
0003 //
0004 // perform matrix item processing only if Apparel is active
0005 //

0006 If VA frm_cApparelActive_EV01 is equal to "1" And GC Item Number is not equ


al to <Blank>
0007
// SAR 8970768 - Apparel
0008
If SV Form_ Mode is equal to CO UPDATE_MODE
0009
VA frm_cDisableGlDate_EV01 = "0"
0010
Clear Control Error(FC G/L Date)
0011
Disable Control(FC G/L Date)
0012
End If
0013
// Retrieve the short item required for Apparel processing.
0014
F4101 Get Item Master Information
VA evt_mnIdentifierShortItem_ITM <- BF mnShortItemNumber
GC Item Number -> BF szPrimaryItemNumber
VA evt_szMatrixErrorID_DTAI <- BF szErrorMessageID
0015
If VA evt_szMatrixErrorID_DTAI is equal to or empty <Blank>
0016
// Check whether the item is style item or a standard item
0017
Determine SKU Level Item
VA evt_mnIdentifierShortItem_ITM -> BF mnItemNumberShort_Apparel
VA evt_cSKULevelItem_EV11 <- BF cSKULevelItem
VA evt_cStyleITEM_YN_EV01 <- BF cStyleItemYN
0018
If VA evt_cStyleITEM_YN_EV01 is equal to "Y"
0019
Determine Inventory Matrix Item
VA evt_mnMatrixJobNumber_JOBS <- BF mnMatrixJobNumber
VA evt_szMatrixUser_USER <- BF szMatrixUser
VA evt_szMatrixLevelName_C9LVNM <- BF szMatrixLevelName
VA evt_cMatrixItem_C9MXLN <- BF cMatrixItem
VA evt_mnMatrixLevelNumber_C9LVNO <- BF mnMatrixLevelNumber
VA evt_szMatrixStructure_C9STRC <- BF szMatrixStructure
VA evt_szMatrixErrorID_DTAI <- BF szErrorID
VA evt_mnIdentifierShortItem_ITM -> BF mnIdentifierShortItem_IT
M
0020
If VA evt_cMatrixItem_C9MXLN is equal to "Y" And VA evt_szMatrixEr
rorID_DTAI is equal to or empty <Blank>
0021
VA evt_mnQuantityControl_TRQT = GC Quantity
0022
VA evt_szTransactionUOM_UOM = GC UM
0023
Delete Grid Row(FC Grid, <Currently Selected Row>)
0024
Call( App:PCW10 , Form:WCW10B , Ver: PO szMatrixEntryVersion_VE
RS )
VA evt_mnMatrixJobNumber_JOBS -> FI mnJobnumberA
VA evt_szMatrixUser_USER -> FI szUserId
VA evt_szMatrixLevelName_C9LVNM -> FI szC9LVL0-Level 0
"1" -> FI MatrixType
VA evt_szMatrixStructure_C9STRC -> FI szC9STRC-Structure
VA evt_mnMatrixLevelNumber_C9LVNO -> FI mnC9LVNO-Level No
VA evt_cMatrixItem_C9MXLN -> FI cC9MXLN_MatrixLine_YN
VA evt_mnQuantityControl_TRQT -> FI QtyControle
FC Business Unit -> FI szCostCenter
"P4114" -> FI szCallingAPPLProgramId
VA evt_szTransactionUOM_UOM -> FI szTransactionUOM
0025
FCW20.Delete
VA evt_mnMatrixJobNumber_JOBS = TK Job Number
VA evt_szMatrixUser_USER = TK User ID
0026
Get Max Grid Rows(FC Grid, VA evt_mnMatrixMaxGrid_MATH01)
0027
Delete Grid Row(FC Grid, VA evt_mnMatrixMaxGrid_MATH01)
0028
While VA evt_cMatrixErrorCode_ERRC is not equal to "1"
0029
// Country of Origin Enhancement 11836680
0030
// Bug# 14737812 Begin - Retrieved Country of Origin in corr
ect column
0031
// instead of GB Production Number
0032
Cache, Get Memory
GB Item Number <- BF szItemNumber

GB Branch/ Plant <- BF szBranchPlant


GB Location <- BF szLocation
GB Lot/Serial <- BF szLotNumber
VA evt_cMatrixErrorCode_ERRC <> BF cLastRecordReadFlag
GB Quantity <- BF mnQuantity
VA evt_idMatricCacheCursor_GENLNG <> BF idCacheCursor
GB Country of Origin <- BF szCountryOfOrigin
0033
// Bug# 14737812 End
0034
Insert Grid Buffer Row(FC Grid, <After Last Row>, <Yes>, <No
>, <Yes>, <Yes>, <Yes>)
0035
End While
0036
If VA evt_idMatricCacheCursor_GENLNG is not equal to <Zero> And
VA evt_idMatricCacheCursor_GENLNG is not equal to <Null>
0037
Memory, Free Ptr To Data Structure
VA evt_idMatricCacheCursor_GENLNG <> BF idGenericLong
0038
End If
0039
Else
0040
// Do not throw the error for SKU item. We just need to prevent
the calling of
0041
// PCW10 for SKU item
0042
If VA evt_cSKULevelItem_EV11 is not equal to "Y"
0043
Set Control Error(FC Grid, "CW0077")
0044
End If
0045
End If
0046
End If
0047
End If
0048 End If
=======================================================================
CONTROL: GRIDCOL Quantity
EVENT: Col Exited & Changed - Inline
----------------------------------------------------------------------OPT: Using Defaults
0001 // SAR 7576301 - G/L Date is disabled in order to avoid commitment fail err
ors
0002 // in F0911, this is the less intrusive fix, please do not enable it again
0003 // otherwise a big enhancement will have to be made in order to avoid
0004 // commitment failures.
0005 If SV Form_ Mode is equal to CO UPDATE_MODE
0006
VA frm_cDisableGlDate_EV01 = "0"
0007
Clear Control Error(FC G/L Date)
0008
Disable Control(FC G/L Date)
0009 End If
=======================================================================
CONTROL: GRIDCOL Location
EVENT: Visual Assist Button Clicked
----------------------------------------------------------------------evt_szOrigLocation_LOCN
OPT: Using Defaults
0001 Suppress Default Visual Assist Form
0002 // SAR 7523277 - Store the lot and location before the window.
0003 VA evt_szOrigLocation_LOCN = GC Location - File (wf)
0004 VA frm_LotNumber = GC Lot/Serial
0005 //
0006 Call( App:P41LOCN , Form:W41LOCNB , Ver: ZJDE0001 )
GC Location <> FI Location
GC itm - Short Item No (wf) -> FI mnIdentifierShortItem
FC Business Unit -> FI szCostCenter
VA frm_LotNumber <> FI szLot

0007
0008
0009
0010
0011
0012
so
0013
0014
0015
(wf)
0016
0017
0018
0019
0020
0021

GC Location - File (wf) <- FI szLocationFileFormat


GC Item Number -> FI szItemNoUnknownFormat
PO szLotGroup -> FI szLotGroup
FC Doc Type -> FI szOrderType
GC Country of Origin <- FI szCountryOfOrigin
// SAR 7523277 - Disable this code.
! If PO cLotLayering is not equal to "2"
!
GC Lot/Serial = VA frm_LotNumber
! End If
// SAR 7523277 - If the user is unable to enter lot information but the
// location/lot changed due to the visual assist, blank out the lot status
// that it defaulted to the correct lot status.
If PO cLotLayering is equal to "2"
If GC Lot/Serial is not equal to VA frm_LotNumber Or GC Location - File
is not equal to VA evt_szOrigLocation_LOCN
GC Lot Status = ""
End If
End If
// SAR 7523277 - Even if the processing option is set to protect lot
// information, still return the lot number to the grid.
GC Lot/Serial = VA frm_LotNumber

----------------------------------------------------------------------EVENT: Col Exited & Changed - Inline


----------------------------------------------------------------------OPT: Using Defaults
0001 // SAR 7523277 - Disable this line otherwise the value entered by the user
0002 // will not be kept.
0003 ! GC Lot Status = ""
=======================================================================
CONTROL: GRIDCOL Branch/ Plant
EVENT: Col Exited & Changed - Inline
----------------------------------------------------------------------OPT: Using Defaults
0001 Press Button(FC DisableWMSOverride)
=======================================================================
CONTROL: GRIDCOL Lot Status
EVENT: Col Exited & Changed - Inline
----------------------------------------------------------------------OPT: Using Defaults
0001 If VA grd_szInitialLotStsCode_LOTS is not equal to GC Lot Status
0002
VA grd_mnLotStsOverridden_INT01 = "1"
0003 End If
=======================================================================
CONTROL: BUTTON ClearWarehouseErrors [HIDDEN]
EVENT: Button Clicked
----------------------------------------------------------------------evt_cRelatedToSecondaryError
OPT: Using Defaults
0001 Verify Dual Unit of Measure
<Blank> -> BF cRelatedToSecondaryUoM
GC UM -> BF szUnitOfMeasureAsInput
GC Sec UoM -> BF szUnitOfMeasureSecondary
"1" -> BF cSuppressErrorMessage
VA evt_cRelatedToSecondaryError <- BF cErrorCode
0002 // Only Clear errors if the error is a Location Window required error 053A

0003 If VA evt_cRelatedToSecondaryError is not equal to "1"


0004
Clear Grid Cell Error(FC Grid, <Currently Selected Row>, GC Quantity)
0005
Clear Grid Cell Error(FC Grid, <Currently Selected Row>, GC Secondary Qu
antity)
0006 End If
=======================================================================
CONTROL: BUTTON DisableWMSOverride [HIDDEN]
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 // LPN enhancement
0002 VA frm_cLPNMasterSwitch_LPNM = "0"
0003 Get F46L001 Records
FC Business Unit <> BF szCostCenter
VA frm_cLPNMasterSwitch_LPNM <- BF cLPNMasterSwitch
0004 If VA frm_cLPNMasterSwitch_LPNM is equal to "1"
0005
Disable Control(HC Wareho &Loc Detail)
0006 Else
0007
Enable Control(HC Wareho &Loc Detail)
0008 End If
=======================================================================
FORM: Work With Inventory Adjustments [FIND BROWSE] (W4114B)
=======================================================================
CONTROL: FORM
EVENT: Dialog is Initialized
----------------------------------------------------------------------OPT: Using Defaults
0001 // -------------------------------------------------------------------------0002 // Date
Programmer SAR
Description
0003 // -------------------------------------------------------------------------0004 // 10/21/05 IC8996050 7841662 Replicate batches and NN
0005 // -------------------------------------------------------------------------0006 //
0007 // Set default document type to processing option value
0008 //
0009 FC DCT- Dflt Doc Type (wf) = PO szDocumenttype
0010 // ---------------------------------------------------------------------------0011 //
Defaulting processing options Versions with ZJDE0001
0012 // ---------------------------------------------------------------------------0013 If PO szJournalEntriesVersion is equal to or empty <Blank>
0014
PO szJournalEntriesVersion = "ZJDE0001"
0015 End If
0016 If PO szItemLedgerVersion is equal to or empty <Blank>
0017
PO szItemLedgerVersion = "ZJDE0001"
0018 End If
0019 If PO szWarehouseVersion is equal to or empty <Blank>
0020
PO szWarehouseVersion = "ZJDE0001"
0021 End If
----------------------------------------------------------------------EVENT: Grid Record is Fetched
----------------------------------------------------------------------OPT: Using Defaults

0001 //
0002 // If the document number, type and company are the same as the previous or
der,
0003 // suppress the grid line. Otherwise, save the current document number, ty
pe an
0004 // company for the next comparison.
0005 //
0006 // ---------------------------------------------------------------------------0007 //
SAR #1914071
1/23/1998
0008 //
Suppress Grid If Zero Balance Adjustment or Standard
0009 //
Cost Change Line
0010 // ---------------------------------------------------------------------------0011 //
0012 If BC Explanation - Transaction (F4111)(TREX) is equal to "Standard Cost Ch
ange" Or BC Explanation - Transaction (F4111)(TREX) is equal to "Zero Balance Ad
justment"
0013
Suppress Grid Line(FC Grid)
0014 Else
0015
If BC Document (Voucher, Invoice, etc.) (F4111)(DOC) is equal to FC DOC
- Doc No (wf) And BC Document Type (F4111)(DCT) is equal to FC DCT - Doc Type (
wf) And BC Document Company (F4111)(KCO) is equal to FC KCO - Doc Comp (wf) And
BC Batch Number (F4111)(ICU) is equal to VA frm_ICU_BatchNumber
0016
Suppress Grid Line(FC Grid)
0017
End If
0018
//
0019
//
0020
VA frm_ICU_BatchNumber = BC Batch Number (F4111)(ICU)
0021
GC Batch Number = BC Batch Number (F4111)(ICU)
0022
FC KCO - Doc Comp (wf) = BC Document Company (F4111)(KCO)
0023
FC DCT - Doc Type (wf) = BC Document Type (F4111)(DCT)
0024
FC DOC - Doc No (wf) = BC Document (Voucher, Invoice, etc.) (F4111)(DOC
)
0025 End If
----------------------------------------------------------------------EVENT: Variables
----------------------------------------------------------------------frm_ICU_BatchNumber
frm_ICUT_BatchType
frm_IST_BatchStatus
=======================================================================
CONTROL: HYPITEM &Select
EVENT: Button Clicked
----------------------------------------------------------------------evt_GLInterfaceOn
OPT: Repeat ER for Event
0001 Call( App:P4114 , Form:W4114A )
GC Document Number -> FI Docvoucherinvoicee
GC Do Ty -> FI Documenttype
GC Doc Co -> FI Companykey
GC G/L Date -> FI Dtforglandvouch1
GC Branch/ Plant -> FI Costcenter
GC Transaction Date -> FI Datetransactionjulian
GC Transaction Explanation -> FI Explanationtransaction
GC Batch Number -> FI Batchnumber
=======================================================================

CONTROL: HYPITEM F&ind


EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 FC KCO - Doc Comp (wf) = " "
0002 FC DCT - Doc Type (wf) = " "
0003 FC DOC - Doc No (wf) = "0"
0004 FC DCT- Dflt Doc Type (wf) = "*"
0005 If PO szDocumenttype is not equal to <Blank> And PO szDocumenttype is not e
qual to <Null>
0006
FC DCT- Dflt Doc Type (wf) = PO szDocumenttype
0007 End If
0008 If QC Do Ty is not equal to <Blank> And QC Do Ty is not equal to <Null>
0009
FC DCT- Dflt Doc Type (wf) = QC Do Ty
0010 End If
=======================================================================
CONTROL: HYPITEM &Add
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 //
0002 // Call Inventory Adjustments in Add mode
0003 //
0004 Call( App:P4114 , Form:W4114A )
=======================================================================
CONTROL: HYPITEM Adju&stment
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Repeat ER for Event
0001 Press Button(***MISSING_NAME***)
=======================================================================
CONTROL: HYPITEM Item &Ledger
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 Call( App:P4111 , Form:W4111A , Ver: PO szItemLedgerVersion )
GC Branch/ Plant -> FI Costcenter
=======================================================================
CONTROL: HYPITEM &Journal Entries
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Using Defaults
0001 If GC Batch Number is not equal to <Zero>
0002
F0911 Get Account Information
GC Do Ty -> BF szDocumentType
GC Document Number -> BF mnDocumentNumber
GC Doc Co -> BF szDocumentCompany
"1" -> BF mnJournalEntryLineNo
GC G/L Date -> BF jdGLDate
"1" -> BF cSuppressErrorMsg
FC LT-F0911 Ledger Type (wf) <> BF szLedgerType
FC EXA-F0911 Explanation (wf) <> BF szExplanation
FC CRCD-F0911 Currency Code (wf) <> BF szCurrencyCode
FC CRR-F0911 Exchange Rate (wf) <> BF mnCurrencyConversionRate
0003 End If
0004 // Begin SAR 5563030

0005 Call( App:P0911 , Form:W0911A , Ver: PO szJournalEntriesVersion )


GC Do Ty -> FI Documenttype
GC Document Number -> FI Docvoucherinvoicee
GC Doc Co -> FI Companykey
FC EXA-F0911 Explanation (wf) -> FI Namealphaexplanation
GC Batch Number -> FI Batchnumber
FC CRCD-F0911 Currency Code (wf) -> FI Currencycodefrom
FC CRR-F0911 Exchange Rate (wf) -> FI Currencyconverrateov
GC G/L Date -> FI Dateforglandvoucherjulia
"N" -> FI Batchtype
FC LT-F0911 Ledger Type (wf) -> FI LedgerType
"Y" -> FI InquiryOnlyFlag
0006 // End SAR 5563030
=======================================================================
CONTROL: HYPITEM &Batches
EVENT: Button Clicked
----------------------------------------------------------------------OPT: Repeat ER for Event
0001 Call( App:P0011 , Form:W0011A )
"N" <> FI BatchType
GC Batch Number <> FI BatchNumber
Sunday January 22, 2017 21:12

You might also like