Description of Issue
Different payments are being assigned the same payment number.
Description of Cause
The following describes the process flow when a payment group is written:
1. Payment group is highlighted (in P04571, W04571A) and ‘Write’ selected from the exit bar
a. This calls P04572, W04572A (see step 2)
2. Details of the payment group are loaded into the grid
a. As the details are loaded (‘Grid Record is Fetched’ event), the next payment number is fetched from F0030 (using BSFN ‘F0030 Get Bank Account Information’). Only an inquire is performed to fetch the number – the payment number is not incremented at this stage as the user can still cancel the ‘Write’ at this stage.
b. After the details are loaded, the user has the option of changing the details on this screen. It is possible for the user to specify a different payment number, which is particularly applicable if pre-printed cheques are being used. The user can then either choose ‘OK’ or ‘Cancel’.
[No updates are performed if ‘Cancel’ is pressed].
3. User presses ‘OK’ to confirm ‘Write’
a. As the ‘OK’ button is pressed (‘Button Clicked’ event), the next payment number is updated (action code = 1) in F0030 (using BSFN ‘F0030 Get Bank Account Information’) to match the payment number in the grid. This will either be the F0030 payment number just fetched (2a) or the payment number specified by the user (2b).
4. User presses ‘OK’ to confirm submission of R04571
a. As part of this UBE, BSFN ‘F04572 Update Print Driver’ is called which again fetches the F0030 payment number, increments it by the number of payments within the group and then updates F0030 with the incremented value.
Problems can occur when 2 payment groups are being written at similar times, in particular, when step 2 for a payment group is performed between steps 3 and 4 for another payment group.
e.g. next payment number in F0030 = 1
1st Payment Group / 2nd Payment Group1. User clicks ‘Write’
- no F0030 updates occur
2. Details loaded into P04572
- payment number 1 is fetched
- no F0030 updates occur
3. User presses ‘OK’ to confirm ‘Write’
- F0030 payment number updated to ‘1’ fetched in step 2.
1. User clicks ‘Write’
- no F0030 updates occur
2. Details loaded into P04572
- payment number 1 is fetched
- no F0030 updates occur
4. User presses ‘OK’ to confirm submission of R04571
- pymt group has 1 pymt, is allocated payment number 1
- payment number incremented by 1
- F0030 payment number updated to incremented value ‘2’
3. User presses ‘OK’ to confirm ‘Write’
- F0030 payment number updated to ‘1’ fetched in step 2.
4. User presses ‘OK’ to confirm submission of R04571
- pymt group has 1 pymt, is allocated payment number 1
- payment number incremented by 1
- F0030 payment number updated to incremented value ‘2’
Both payments get allocated payment number ‘1’.
This is because after the payment number has been correctly incremented to 2 by 1st payment group’s step 4, it gets reset back to 1 by 2nd payment group’s step 3.
Solution
[PN = payment number]
The following solution is proposed:
When user presses ‘OK’ to confirm ‘Write’ the following could occur (step 3):
If grid PN = fetched F0030 PN (fetched in step 2) (i.e. user is happy with fetched F0030 PN)
Do not perform an update to F0030
Else (i.e. user wants to specify a different PN)
Perform another fetch from F0030 to get PN
If this fetched PN = original fetched PN (i.e. F0030 hasn’t been updated in the meantime)
Update F0030 with the user specified PN in grid
Else (i.e. another process has updated F0030 in the meantime)
Issue pop up message to user:
Message Title: “Action Cancelled”
Message Description: “To avoid duplicate payments this action has been cancelled. Click ‘OK’ to return to the previous screen to re-write this group”
There will be a single ‘OK’ button on the form that will cancel the ‘Write Payments’ screen. User will be returned to the ‘Work With Payment Groups’ screen, where they will need to press ‘Write’ again.
Endif
Endif
Technical Spec
P5804572 – Write Auto Payments
P04572 has been copied to P5804572
A new form in this new app has been created: W5804572C:
Form: P5804572, W5804572A
Control: Form
Event: ‘Grid Record is Fetched’
The PN fetched from F0030 when this screen loads up is saved in a new variable:
0022 //
0023 // & M1748 KPERRY 26/08/05 BEGIN
0024 //
0025 // Save original PN fetched from F0030
0026 VA frm_mnOriginalF0030PN_NXTC = GC NextPayment
0027 //
0028 // & M1748 KPERRY 26/08/05 END
Form: P5804572, W5804572A
Control: ‘OK’ button
Event: ‘Button is Pressed’
0044 //
0045 // & M1748 KPERRY 26/08/05 BEGIN
0046 //
0047 // Check if user has amended payment number
0048 If GC NextPayment is equal to VA frm_mnOriginalF0030PN_NXTC
0049 //
0050 // If not amended, do nothing, do not update F0030 next payment number
0051 //
0052 Else
0053 //
0054 // If user has specified another number,
0055 // check if F0030 PN has been updated in the meantime by another process
0056 F0030 Get Bank Account Information
GC GLBA [HIDDEN] -> szAccountid
GC Business Unit -> szCostcenter
VA evt_mnCurrentF0030PN_NXTC <- mnNextchecknumber
UNDEFINED X mnDetaillinesperappayments
UNDEFINED X mnNumberofalignmentchecks
UNDEFINED X szBanktransitnumber
UNDEFINED X szCustbankacctnumber
UNDEFINED X szDescription001
UNDEFINED X cPrenoteoptioncode
UNDEFINED X szCheckprintqueue
UNDEFINED X szCheckattachmentsprint
UNDEFINED X szDebitmemoprintqueue
UNDEFINED X szControldigit
UNDEFINED X mnFloatdaysforcheckspayabl
UNDEFINED X cCheckingorsavingsaccount
UNDEFINED X mnBacsusernumber
UNDEFINED X szBacsreferencename
UNDEFINED X szReferencerollnumber
UNDEFINED X szSwiftcode
UNDEFINED X mnAddressnumber
"<Blank>" X cProcessingMode
UNDEFINED X szErrorCode
0057 //
0058 If VA evt_mnCurrentF0030PN_NXTC is equal to VA frm_mnOriginalF0030PN_NXTC
0059 //
0060 // If it has not been updated, update with user amended value
0061 F0030 Get Bank Account Information
GC GLBA [HIDDEN] -> szAccountid
GC Business Unit -> szCostcenter
GC Next Payment -> mnNextchecknumber
UNDEFINED X mnDetaillinesperappayments
UNDEFINED X mnNumberofalignmentchecks
UNDEFINED X szBanktransitnumber
UNDEFINED X szCustbankacctnumber
UNDEFINED X szDescription001
UNDEFINED X cPrenoteoptioncode
UNDEFINED X szCheckprintqueue
UNDEFINED X szCheckattachmentsprint
UNDEFINED X szDebitmemoprintqueue
UNDEFINED X szControldigit
UNDEFINED X mnFloatdaysforcheckspayabl
UNDEFINED X cCheckingorsavingsaccount
UNDEFINED X mnBacsusernumber
UNDEFINED X szBacsreferencename
UNDEFINED X szReferencerollnumber
UNDEFINED X szSwiftcode
UNDEFINED X mnAddressnumber
"1" -> cProcessingMode
UNDEFINED X szErrorCode
0062 //
0063 Else
0064 //
0065 // If it has been updated, issue error to user and cancel screen
0066 Call( App:P5804572 , Form: W5804572C )
"<Blank>" X Version
0067 Press Button(HC &Cancel)
0068 Stop Processing
0069 //
0070 End If
0071 End If
0072 //
0073 // & M1748 KPERRY 26/08/05 END
0074 //
P5804571 – Work with Payment Groups
To allow the new application (P5804572) to be called when writing payment groups, P04571 has been copied to P5804571.
On pressing the ‘Write’ exit bar, the FC Multiple Writes is pressed.
Form: P5804571, W5804571A
Control: FC Multiple Write
Event: Post Button Clicked
0011 //
0012 // & M1748 KPERRY 26/08/05 BEGIN
0013 //
0014 // Amend to call new application which prevent duplicate payments
0015 ! Call( App:P04572 , Form: W04572A )
! VA frm_mnPrintSelection_PSEL -> APCheckPrintSelection
! UNDEFINED X GlBankAccount
! UNDEFINED X CostCenter
! VA frm_cBusinessUnitFlag_EV02 -> BusinessUnitFlag
! "1" -> GroupOrPaymentFlag
! VA frm_cCancelFlag_EV07 <- CancelFlag
! PO cPCGOutput -> OutputMode
! PO szPrintProgramVersion -> Version
! PO jdEffectiveDate -> CurrencyEffectiveDate
! PO cUseVoucherRate -> UseVoucherRate
! PO cInteractiveProcess -> ProcessInteractive
! PO cBACSProcessing -> BACSProcessing
! "<Blank>" X Version
0016 Call( App:P5804572 , Form: W5804572A )
VA frm_mnPrintSelection_PSEL -> APCheckPrintSelection
UNDEFINED X GlBankAccount
UNDEFINED X CostCenter
VA frm_cBusinessUnitFlag_EV02 -> BusinessUnitFlag
"1" -> GroupOrPaymentFlag
VA frm_cCancelFlag_EV07 <- CancelFlag
PO cPCGOutput -> OutputMode
PO szPrintProgramVersion -> Version
PO jdEffectiveDate -> CurrencyEffectiveDate
PO cUseVoucherRate -> UseVoucherRate
PO cInteractiveProcess -> ProcessInteractive
PO cBACSProcessing -> BACSProcessing
"<Blank>" X Version
0017 //
0018 // & M1748 KPERRY 26/08/05 END
0019 //
It has also been modified to call the below application when select is used to view individual payments.
Form: P5804571, W5804571A
Control: Select/OK
Event: Button Clicked
0006 //
0007 // & M1748 KPERRY 26/08/05 BEGIN
0008 //
0009 // Amend to call copied object for writing individual pymts
0010 ! Call( App:P04572W , Form: W04572WA )
! GC Payment Group Control Number -> PaymentGroupControlNbr
! UNDEFINED X CkControlNoAPCh
! GC GLBA [HIDDEN] -> Glbankaccount
! GC Version -> Version
! GC Curr Code -> Currencycodefrom
! GC Business Unit -> Costcenter
! GC Payment Print Queue -> Checkprintqueue
! VA frm_cVoidFlag_EV01 -> Voidflag
! GC Group Total -> Paymntamount
! GC Number of Payments -> Numberofpaymentsprocesse
! VA frm_cBusinessUnitFlag_EV02 -> BusinessUnitFlag
! VA frm_cPCGChangedFlag_EV06 <- PCGChangedFlag
! PO cPCGOutput -> OutputMode
! PO szPrintProgramVersion -> PrintProgramVersion
! PO jdEffectiveDate -> CurrencyEffectiveDate
! PO cUseVoucherRate -> UseVoucherRate
! PO cInteractiveProcess -> InteractiveOrBatch
! PO cBACSProcessing -> BACSProcessing
! VA frm_F0450Exists -> F0450Exists
! "<Blank>" X Version
0011 Call( App:P584572W , Form: W584572WA )
GC Payment Group Control Number -> PaymentGroupControlNbr
UNDEFINED X CkControlNoAPCh
GC GLBA [HIDDEN] -> Glbankaccount
GC Version -> Version
GC Curr Code -> Currencycodefrom
GC Business Unit -> Costcenter
GC Payment Print Queue -> Checkprintqueue
VA frm_cVoidFlag_EV01 -> Voidflag
GC Group Total -> Paymntamount
GC Number of Payments -> Numberofpaymentsprocesse
VA frm_cBusinessUnitFlag_EV02 -> BusinessUnitFlag
VA frm_cPCGChangedFlag_EV06 <- PCGChangedFlag
PO cPCGOutput -> OutputMode
PO szPrintProgramVersion -> PrintProgramVersion
PO jdEffectiveDate -> CurrencyEffectiveDate
PO cUseVoucherRate -> UseVoucherRate
PO cInteractiveProcess -> InteractiveOrBatch
PO cBACSProcessing -> BACSProcessing
VA frm_F0450Exists -> F0450Exists
"<Blank>" X Version
0012 //
0013 // & M1748 KPERRY 26/08/05 END
0014 //
P584572W – P584572WA
To allow the new application (P5804572) to be called when writing individual payments within a payment group, P04572W has been copied to P584572W.
On pressing the ‘Write’ exit bar, the FC Multiple Writes is pressed.
Form: P584572W, W584572WA
Control: FC Multiple Write
Event: Post Button Clicked
0007 //
0008 // & M1748 KPERRY 26/08/05 BEGIN
0009 //
0010 // Amend to call new application which prevent duplicate payments
0011 Call( App:P5804572 , Form: W5804572A )
FC PSEL [HIDDEN] -> APCheckPrintSelection
UNDEFINED X GlBankAccount
UNDEFINED X CostCenter
FC Business Unit Flag [HIDDEN] -> BusinessUnitFlag
UNDEFINED X GroupOrPaymentFlag
FC Cancel Flag [HIDDEN] <- CancelFlag
FI OutputMode -> OutputMode
FC Print Program Version [HIDDEN] -> Version
FC Currency Effective Date [HIDDEN] -> CurrencyEffectiveDate
FC Use Voucher Rate [HIDDEN] -> UseVoucherRate
FI InteractiveOrBatch -> ProcessInteractive
FI BACSProcessing -> BACSProcessing
"<Blank>" X Version
0012 ! Call( App:P04572 , Form: W04572A )
! FC PSEL [HIDDEN] -> APCheckPrintSelection
! UNDEFINED X GlBankAccount
! UNDEFINED X CostCenter
! FC Business Unit Flag [HIDDEN] -> BusinessUnitFlag
! UNDEFINED X GroupOrPaymentFlag
! FC Cancel Flag [HIDDEN] <- CancelFlag
! FI OutputMode -> OutputMode
! FC Print Program Version [HIDDEN] -> Version
! FC Currency Effective Date [HIDDEN] -> CurrencyEffectiveDate
! FC Use Voucher Rate [HIDDEN] -> UseVoucherRate
! FI InteractiveOrBatch -> ProcessInteractive
! FI BACSProcessing -> BACSProcessing
! "<Blank>" X Version
0013 //
0014 // & M1748 KPERRY 26/08/05 END
0015 //
Kate Perry Page 6 of 6 20/12/2007
H:\My Documents\Defects\M1748 Tech Spec.doc