694 lines
18 KiB
Plaintext
Executable File
694 lines
18 KiB
Plaintext
Executable File
*---*
|
|
*PGM NAME: CMSD.CONTROL
|
|
*PURPOSE: CONTROL PROGRAM FOR INQUIRY / MAIL PROCESSING
|
|
*AUTHOR: CONNERS
|
|
*CREATED: ??
|
|
*---*
|
|
$INCLUDE GEN.COMMON
|
|
$INCLUDE PM
|
|
$INCLUDE BA
|
|
$INCLUDE CMSD.IVD
|
|
$INCLUDE PM.TRANS
|
|
*
|
|
10 *---initialize array variables (passed through GEN.COMMON)---
|
|
HOME=''
|
|
TRNS=''
|
|
NEW.TRANS=''
|
|
PLG.ARRAY=''
|
|
PL.DATA=''
|
|
INV.ARRAY=''
|
|
INDEXES=''
|
|
MAT ORDERS=''
|
|
MAT SUBSCRIPTIONS=''
|
|
PM.AUX=''
|
|
TOVERFLOW=''
|
|
PASSAREA='' ;* CLEARED FOR OREA PROGRAM 'CMSD.TRANS.OREA'
|
|
DISPCD=''
|
|
SEARCH.KEY=PT.DATA<1>:"*":@TTY
|
|
*
|
|
*---check for user access to this account---
|
|
LOCATE("VIP",PM.DATA,PM$STATUS;FND) THEN
|
|
CALL R8.SECURITY.CHECK("55",RTVALUE)
|
|
IF RTVALUE THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Access to this Account is restricted - <return>":ERV:BEEP:
|
|
ANY=''; INPUT ANY
|
|
RETURN.CODE=1
|
|
GOSUB 7000
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):CL:RV:"Access limited to this account - <return> to continue!":ERV:BEEP:
|
|
ANY=''; INPUT ANY
|
|
END
|
|
END
|
|
*
|
|
*---check for security to see financial data---
|
|
CALL R8.SECURITY.CHECK("29",RTVALUE)
|
|
IF RTVALUE THEN
|
|
FINANCIAL.INQUIRY.OK=0
|
|
END ELSE
|
|
FINANCIAL.INQUIRY.OK=1
|
|
END
|
|
*
|
|
*---define prompt lines---
|
|
IF PROCESS='DBM010' THEN ;* PCC
|
|
IF MTEK800INFO # '' THEN GO 70000 ;* PCC
|
|
END ;* PCC
|
|
*
|
|
MTEK800INFO='' ;* PCC
|
|
*
|
|
IF PROCESS='INQ010' THEN
|
|
BA.DATA=''
|
|
POS=0
|
|
LNA21=@(0,21):'Enter #, ' ; POS=POS+9
|
|
LNA21=LNA21:@(POS,21):RV:'/':ERV:'esc, ' ; POS=POS+6
|
|
LNA21=LNA21:@(POS,21):RV:'E':ERV:'nd, ' ; POS=POS+5
|
|
LNA21=LNA21:@(POS,21):RV:'L':ERV:'abel, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'N':ERV:'otes, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'D':ERV:'emog, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'EM':ERV:'ploy, ' ; POS=POS+8
|
|
LNA21=LNA21:@(POS,21):RV:'F':ERV:'amily, ' ; POS=POS+8
|
|
LNA21=LNA21:@(POS,21):RV:'PR':ERV:'int' ; POS=POS+5
|
|
IF SYSTEM.SETUP<5>='Y' THEN
|
|
LNA21=LNA21:', ' ; POS=POS+2
|
|
LNA21=LNA21:@(POS,21):RV:'S':ERV:'ubs' ; POS=POS+4
|
|
END
|
|
LNA21=LNA21:', ' ; POS=POS+2
|
|
LNA21=LNA21:@(POS,21):RV:'T':ERV:'rans, ' ; POS=POS+7
|
|
POS=0
|
|
LNA22=''
|
|
LNA22=LNA22:@(POS,22):RV:'B':ERV:'oth, ' ; POS=POS+6
|
|
LNA22=LNA22:@(POS,22):RV:'H':ERV:'ist, ' ; POS=POS+6
|
|
LNA22=LNA22:@(POS,22):RV:'ST':ERV:'snt, ' ; POS=POS+7
|
|
LNA22=LNA22:@(POS,22):RV:'LT':ERV:'rs, ' ; POS=POS+6
|
|
LNA22=LNA22:@(POS,22):RV:'SG':ERV:'seg, ' ; POS=POS+7
|
|
LNA22=LNA22:@(POS,22):RV:'Y':ERV:'rly$, ' ; POS=POS+7
|
|
LNA22=LNA22:@(POS,22):RV:'CR':ERV:'dt' ; POS=POS+4
|
|
IF SYSTEM.SETUP<6>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'P':ERV:'lg ' ; POS=POS+4
|
|
END
|
|
IF SYSTEM.SETUP<15>='2' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'AT':ERV:'tnd' ; POS=POS+5
|
|
END
|
|
IF SYSTEM.SETUP<18>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'J':ERV:'rnl, ' ; POS=POS+6
|
|
END
|
|
LNA22=LNA22:@(POS,22):RV:'TP':ERV:' ' ; POS=POS+3
|
|
IF SYSTEM.SETUP<28>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'SN':ERV:'ssn' ; POS=POS+5
|
|
END
|
|
IF SYSTEM.SETUP<29>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'EV':ERV:'env' ; POS=POS+5
|
|
END
|
|
END ELSE ;*---within a batch
|
|
POS=0
|
|
LNA21=''
|
|
LNA21=@(0,21):'Enter #, ' ; POS=POS+9
|
|
LNA21=LNA21:@(POS,21):RV:'L':ERV:'abel, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'N':ERV:'otes, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'D':ERV:'emog, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'EM':ERV:'ploy, ' ; POS=POS+8
|
|
LNA21=LNA21:@(POS,21):RV:'F':ERV:'amily, ' ; POS=POS+8
|
|
LNA21=LNA21:@(POS,21):RV:'PR':ERV:'int, ' ; POS=POS+7
|
|
LNA21=LNA21:@(POS,21):RV:'ST':ERV:'sent' ; POS=POS+6
|
|
IF SYSTEM.SETUP<5>='Y' THEN
|
|
LNA21=LNA21:", " ; POS=POS+2
|
|
LNA21=LNA21:@(POS,21):RV:'S':ERV:'ubs' ; POS=POS+4
|
|
END
|
|
LNA21=LNA21:', ' ; POS=POS+2
|
|
LNA21=LNA21:@(POS,21):RV:'LT':ERV:'rs, ' ; POS=POS+6
|
|
POS=0
|
|
LNA22=''
|
|
LNA22=LNA22:@(POS,22):RV:'SG':ERV:'segs, ' ; POS=POS+8
|
|
LNA22=LNA22:@(POS,22):RV:'Y':ERV:'rly$' ; POS=POS+5
|
|
IF SYSTEM.SETUP<15>='2' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'AT':ERV:'tend' ; POS=POS+6
|
|
END
|
|
IF SYSTEM.SETUP<18>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'J':ERV:'rnl' ; POS=POS+4
|
|
END
|
|
IF SYSTEM.SETUP<28>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'SN':ERV:'ssn' ; POS=POS+5
|
|
END
|
|
IF SYSTEM.SETUP<29>='Y' THEN
|
|
LNA22=LNA22:', ' ; POS=POS+2
|
|
LNA22=LNA22:@(POS,22):RV:'EV':ERV:'env' ; POS=POS+5
|
|
END
|
|
LNA22=LNA22:" or <return> to continue"
|
|
END
|
|
*
|
|
RETURN.CODE=''
|
|
MTEK800SW='' ;* PCC
|
|
IF NOT(UPDATE) THEN ;*---adding a new account---
|
|
FUNCT='NEW'
|
|
JNLSW=''
|
|
CALL MSD.DBM.RED
|
|
GOSUB 7000
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
CALL MSD.INQ010
|
|
IF RETURN.CODE='N' THEN INDEXES<25>=PART.KEY ; ENTER MSD.LOOKUP
|
|
IF RETURN.CODE=2 THEN ADD.SW=0 ELSE ADD.SW=1
|
|
GOSUB 7000
|
|
IF ADD.SW THEN INDEXES<4>='ADD'
|
|
IF PART.KEY#'' THEN GO 1298
|
|
* NEW STANDARD ROUTINE FOR NEXT.PARTNER
|
|
CALL CMSD.NEXT.PARTNER("CMSD.CONTROL")
|
|
*
|
|
1298 *
|
|
PRINT @(9,1):PART.KEY:' '
|
|
PM.DATA<PM$SEGMENT> = 'M0'
|
|
PM.DATA<PM$ENTRY.OPERATOR>=PT.DATA<1> ;* MTC/RBC - REMOVED CHKDIGIT
|
|
IF PROCESS='DBM010' THEN PM.DATA<PM$SEG.DATE> = BA.DATA<BA$BANK.DATE> ELSE
|
|
PM.DATA<PM$SEG.DATE>=DATE()
|
|
END
|
|
IF PM.DATA<PM$SEG.DATE>='' THEN PM.DATA<PM$SEG.DATE>=DATE() ;* CMSD
|
|
IF PM.DATA<PM$ORIGIN>='' THEN
|
|
IF BA.DATA<BA$DEFAULT.ORIGIN>#"" THEN
|
|
PM.DATA<PM$ORIGIN>=BA.DATA<BA$DEFAULT.ORIGIN>
|
|
END ELSE
|
|
PM.DATA<PM$ORIGIN>=DF.DATA<1>
|
|
END
|
|
END
|
|
IF MTEK800SW THEN RETURN ;* PCC
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
IF PROCESS='DBM010' THEN GO 81000 ELSE GO 60000
|
|
END ELSE
|
|
JNLSW=1
|
|
IF PROCESS='INQ010' THEN
|
|
CALL MSD.DBM.RED
|
|
GOSUB 7000
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
GO 60000 ;*---update if inquiry process---
|
|
END ELSE
|
|
GO 80000 ;*---update if batch process---
|
|
END
|
|
END
|
|
*
|
|
60000 *---update routine for inquiry---
|
|
FUNCT='OLD'
|
|
UPDATE=1
|
|
CRT @(0,21):CR:LNA21
|
|
CRT @(0,22):LNA22:
|
|
DATA.IO=''; INPUT DATA.IO
|
|
60001 *
|
|
BEGIN CASE
|
|
CASE DATA.IO=''
|
|
CASE DATA.IO='/' OR DATA.IO=PF3 OR DATA.IO="TOP"
|
|
RETURN.CODE=1
|
|
IF ORDERS(1)#"" THEN
|
|
CRT @(0,22):CL:RV:"Orders have been created/changed - are you sure (Y/N): ":ERV:BEEP:
|
|
INPUT RSP
|
|
IF RSP#"Y" THEN
|
|
RETURN.CODE=''
|
|
END
|
|
END
|
|
GOSUB 7000
|
|
CASE DATA.IO='E' OR DATA.IO=0
|
|
DELETE SEARCH.SAVE,SEARCH.KEY
|
|
IF PURGE.INQ<1> THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Purged accounts may not be updated":ERV:BEEP:
|
|
RQM
|
|
END ELSE
|
|
PREEDITVALUE=''
|
|
CALL CMSD.PRECLOSE.EDIT(PREEDITVALUE)
|
|
CALL R8.SECURITY.CHECK("30",RTVALUE)
|
|
IF RTVALUE THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security to Update Account":ERV:BEEP:
|
|
RQM
|
|
END ELSE
|
|
IF NOT(PREEDITVALUE) THEN
|
|
ENTER CMSD.CLOSE
|
|
END
|
|
END
|
|
END
|
|
CASE DATA.IO='DELETE' AND NOT(PURGE.INQ<1>)
|
|
CALL DELETE.PM
|
|
CASE DATA.IO='CR'
|
|
FUNCTION=''
|
|
CALL CMSD.CREDITS(FUNCTION)
|
|
CALL MSD.DBM.RED
|
|
CASE DATA.IO='LT'
|
|
CALL MSD.LETTERS
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='PR'
|
|
CALL MSD.PRINT.ACCOUNT
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO ='LOG'
|
|
MED.ANS=''
|
|
READ CHK.REC FROM PM,PART.KEY ELSE
|
|
CRT @(0,21):CL
|
|
CRT @(0,22):CL:RV:" WOULD YOU LIKE TO SAVE CHANGES? (Y/N) :":ERV:
|
|
INPUT MED.ANS,5
|
|
END
|
|
CALL CMS.MEDIA.LOG
|
|
*== if no changes then dump out else send through MSD.CLOSE ==
|
|
IF MED.ANS="Y" THEN DATA.IO="E" ; GO 60001 ELSE CHAIN "MSD.INQ000"
|
|
CASE DATA.IO='SG'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL MSD.SEGMENT.DISPLAY
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE DATA.IO='Y'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL MSD.YEAR.DISPLAY
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE DATA.IO='M' AND PURGE.INQ<1>=1
|
|
CALL CMSD.PM.REACTIVATE
|
|
RETURN.CODE=1
|
|
GOSUB 7000
|
|
CASE DATA.IO='B'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL CMS.DISP.TRANS.PLEDGES
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE DATA.IO='TP'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL CMS.DISP.TRANS.PRODUCTS
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE DATA.IO='ST'
|
|
CALL MSD.SENT.DISP
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='SN' AND SYSTEM.SETUP<29>='Y'
|
|
CALL CMSD.SSN.UPDATE
|
|
CASE DATA.IO='EV' AND SYSTEM.SETUP<28>='Y'
|
|
CALL CMSD.ENVELOPE.UPDATE
|
|
CASE DATA.IO='T'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL MSD.DISP.TRANS
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE DATA.IO MATCHES "0N"
|
|
IF PURGE.INQ<1> THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Account is purged - no updates permitted":ERV:BEEP:
|
|
RQM
|
|
END ELSE
|
|
BEGIN CASE
|
|
CASE DATA.IO > 0 AND DATA.IO < 5
|
|
CRT @(0,21):CR
|
|
UPDATE=1
|
|
PASS=''
|
|
PASS<1> = DATA.IO
|
|
CALL MSD.INQ010
|
|
GOSUB 7000
|
|
IF DATA.IO=4 THEN CALL MSD.DBM2.RED
|
|
CASE DATA.IO > 19 AND DATA.IO < 29
|
|
CRT @(0,21):CR
|
|
UPDATE=1
|
|
PASS=''
|
|
PASS<1>=DATA.IO
|
|
CALL MSD.INQ200
|
|
GOSUB 7000
|
|
END CASE
|
|
END
|
|
CASE DATA.IO='L'
|
|
CALL MSD.DISP.LBL
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='EM' AND NOT(PURGE.INQ<1>)
|
|
CALL MSD.EM001
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='D'
|
|
CALL CMSD.DEMOG
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='N' AND NOT(PURGE.INQ<1>)
|
|
RT.COD=''
|
|
CALL MSD.TEL31.FULL
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='S' AND SYSTEM.SETUP<5>='Y' AND NOT(PURGE.INQ<1>)
|
|
FUNCTION=''
|
|
CALL CMSD.SUB001(FUNCTION)
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='J'
|
|
CALL MSD.JOURNAL
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
* CASE DATA.IO='X'
|
|
* CALL CMSD.AUX.SETUP
|
|
* CALL MSD.DBM.RED
|
|
* CALL MSD.DBM2.RED
|
|
CASE DATA.IO='P' AND SYSTEM.SETUP<6>='Y'
|
|
CALL MSD.INQ050
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='F'
|
|
CALL MSD.FAMILY
|
|
IF RTCOD#'' THEN
|
|
IF PURGE.INQ<1> THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Account is not active - cannot transfer to another account":ERV:BEEP:
|
|
RQM
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
END
|
|
INDEXES<25>=RTCOD
|
|
PREEDITVALUE=''
|
|
CALL CMSD.PRECLOSE.EDIT(PREEDITVALUE)
|
|
IF NOT(PREEDITVALUE) THEN
|
|
ENTER CMSD.CLOSE
|
|
END
|
|
END
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='CC' AND NOT(PURGE.INQ<1>)
|
|
CALL CMS.INV.INIT
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='H'
|
|
ORDER.FUNC='MOD'
|
|
CALL CMSD.ORDER.HIST
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE DATA.IO='AT' AND NOT(PURGE.INQ<1>)
|
|
CALL MSD.ATTND
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE 1
|
|
CALL CMSD.CONTROL.SPECIAL(DATA.IO)
|
|
END CASE
|
|
GO 60000
|
|
*
|
|
20000 *---delete a partner record if 0 balance and no invoices---
|
|
CALL R8.SECURITY.CHECK("56",RTVALUE)
|
|
IF RTVALUE THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security to Delete Account":ERV:BEEP:
|
|
RQM
|
|
END ELSE
|
|
READ TREC FROM PM.TRANS,PART.KEY ELSE TREC=''
|
|
READ PGREC FROM PM.PLEDGES,PART.KEY ELSE PGREC=''
|
|
IF PM.DATA<PM$ORDER.NUMBERS>#'' OR PM.DATA<PM$STATUS,1>#'' OR PM.DATA<PM$INVOICE.NUMBERS,1>#'' OR TREC#'' OR PGREC#'' THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Cannot delete due to transactions or orders or statuses":ERV:BEEP:
|
|
RQM
|
|
END ELSE
|
|
READ TREC FROM PM.TRANS,PART.KEY ELSE TREC=""
|
|
READ PLGREC FROM PM.PLEDGES,PART.KEY ELSE PLGREC=""
|
|
IF TREC<1,1>#"" OR PLGREC<1,1>#"" THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Cannot delete due to transactions or pledges - <return>":ERV:BEEP:
|
|
INPUT ANY
|
|
END ELSE
|
|
FUNCTION='DELETE'
|
|
CALL MSD.INDEX("D","","",RTCOD)
|
|
CALL CMSD.DELETE.ALIAS(PART.KEY)
|
|
DELETE PM,PART.KEY
|
|
DELETE PM.JOURNAL,PART.KEY
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Account has been deleted!!!!!":ERV:BEEP:
|
|
RQM
|
|
CHAIN 'MSD.INQ000'
|
|
END
|
|
END
|
|
END
|
|
RETURN
|
|
*
|
|
7000 *---error checking routine---
|
|
IF RETURN.CODE = 1 THEN
|
|
GOSUB 7500
|
|
IF PROCESS = 'INQ010' AND NOT(PURGE.INQ<1>) THEN
|
|
CHAIN "MSD.INQ000"
|
|
END ELSE
|
|
ENTER MSD.LOOKUP
|
|
END
|
|
END
|
|
RETURN
|
|
*
|
|
7500 *---release records---
|
|
RELEASE PM,PART.KEY
|
|
RELEASE PM.TRANS,PART.KEY
|
|
RELEASE PM.PLEDGES,PART.KEY
|
|
RETURN
|
|
*
|
|
80000 *---batch processing---
|
|
IF NEW.TRANS='' AND SYSTEM.SETUP<26>='Y' AND BA.DATA<BA$BATCH.TYPE>='FT' THEN
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.FAST.TRANS(RETURN.VALUE)
|
|
IF RETURN.VALUE='/' THEN
|
|
CRT @(0,22):RV:"YOUR CHANGES WILL BE LOST!!! - IS THIS WHAT YOU WANT? (Y or N) :":ERV:
|
|
INPUT ANYANS
|
|
IF ANYANS="Y" THEN
|
|
RETURN.CODE=1 ; GOSUB 7000
|
|
END
|
|
END
|
|
IF RETURN.VALUE='C' THEN
|
|
CALL MSD.DBM2.RED
|
|
GO 81000
|
|
END
|
|
IF RETURN.VALUE='D' THEN GO 81003
|
|
IF RETURN.VALUE='E' AND NOT(PURGE.INQ<1>) THEN
|
|
CALL CMSD.TRANS
|
|
END
|
|
END ELSE
|
|
81003 *
|
|
CALL MSD.BAT.DISPLAY
|
|
CALL CMSD.TRANS
|
|
END
|
|
BEGIN CASE
|
|
CASE RETURN.CODE='P' AND SYSTEM.SETUP<6>='Y'
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.INQ050
|
|
CASE RETURN.CODE="O"
|
|
ORDER.FUNC='ADD'
|
|
CALL CMSD.ORDER.XFER
|
|
CASE RETURN.CODE='H'
|
|
ORDER.FUNC='MOD'
|
|
CALL CMSD.ORDER.HIST
|
|
CASE RETURN.CODE='N'
|
|
CALL MSD.TEL31.FULL
|
|
CASE RETURN.CODE='T'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DISP.TRANS
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE RETURN.CODE='E'
|
|
DELETE SEARCH.SAVE,SEARCH.KEY
|
|
IF PURGE.INQ<1> THEN
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):CL:RV:"Purged accounts may not be updated - use '/' to escape - return: ":ERV:BEEP:
|
|
INPUT DUMMY
|
|
END ELSE
|
|
PREEDITVALUE=''
|
|
CALL CMSD.PRECLOSE.EDIT(PREEDITVALUE)
|
|
IF NOT(PREEDITVALUE) THEN
|
|
ENTER CMSD.CLOSE
|
|
END
|
|
END
|
|
CASE RETURN.CODE='M'
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
GO 81000
|
|
CASE RETURN.CODE=1
|
|
IF ORDERS(1)#"" THEN
|
|
CRT @(0,22):CL:RV:"Orders have been created/changed - are you sure (Y/N): ":ERV:BEEP:
|
|
INPUT RSP
|
|
IF RSP#"Y" THEN
|
|
RETURN.CODE=''
|
|
END
|
|
END
|
|
IF INDEXES<4>="ADD" THEN
|
|
CRT @(0,22):CL:RV:"Warning - New Member data will be lost - are you sure (Y/N): ":ERV:BEEP:
|
|
INPUT ANYANS
|
|
IF ANYANS="Y" ELSE RETURN.CODE=''
|
|
END
|
|
GOSUB 7000
|
|
END CASE
|
|
GO 80000
|
|
*
|
|
81000 *
|
|
CRT @(0,21):CR:LNA21
|
|
CRT @(0,22):LNA22:
|
|
ANS=''; INPUT ANS
|
|
BEGIN CASE
|
|
CASE ANS=''
|
|
GO 80000
|
|
CASE ANS='TOP'
|
|
RETURN.CODE=1
|
|
IF ORDERS(1)#"" THEN
|
|
CRT @(0,22):CL:RV:"Orders have been created/changed - are you sure (Y/N): ":ERV:BEEP:
|
|
INPUT RSP
|
|
IF RSP#"Y" THEN
|
|
RETURN.CODE=''
|
|
END
|
|
END
|
|
GOSUB 7000
|
|
CASE ANS MATCHES "0N"
|
|
IF ANS > 0 AND ANS < 5 THEN
|
|
CRT @(0,21):CR
|
|
UPDATE=1
|
|
PASS=''
|
|
PASS<1>=ANS
|
|
CALL MSD.INQ010
|
|
IF ANS=4 THEN CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
END
|
|
IF ANS > 19 AND ANS < 29 THEN
|
|
CRT @(0,21):CR
|
|
UPDATE=1
|
|
PASS=''
|
|
PASS<1>=ANS
|
|
CALL MSD.INQ200
|
|
GOSUB 7000
|
|
END
|
|
CASE ANS='L'
|
|
CALL MSD.DISP.LBL
|
|
GOSUB 7000
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
CASE ANS='B'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL CMS.DISP.TRANS.PLEDGES
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE ANS='TP'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL CMS.DISP.TRANS.PRODUCTS
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE ANS='J'
|
|
CALL MSD.JOURNAL
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE ANS='F'
|
|
CALL MSD.FAMILY
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE ANS='AT'
|
|
CALL MSD.ATTND
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE ANS='ST'
|
|
CALL MSD.SENT.DISP
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
CASE ANS='SN' AND SYSTEM.SETUP<29>='Y'
|
|
CALL CMSD.SSN.UPDATE
|
|
CASE ANS='EV' AND SYSTEM.SETUP<28>='Y'
|
|
CALL CMSD.ENVELOPE.UPDATE
|
|
CASE ANS='EM'
|
|
CALL MSD.EM001
|
|
GOSUB 7000
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
CASE ANS='D'
|
|
CALL CMSD.DEMOG
|
|
GOSUB 7000
|
|
CALL MSD.DBM.RED
|
|
GOSUB 7000
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
CASE ANS='N'
|
|
RT.COD=''
|
|
CALL MSD.TEL31.FULL
|
|
GOSUB 7000
|
|
CALL MSD.DBM.RED
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
CASE ANS='S' AND SYSTEM.SETUP<5>='Y'
|
|
FUNCTION=''
|
|
CALL CMSD.SUB001(FUNCTION)
|
|
GOSUB 7000
|
|
CALL MSD.DBM.RED
|
|
GOSUB 7000
|
|
CALL MSD.DBM2.RED
|
|
GOSUB 7000
|
|
CASE ANS='LT'
|
|
CALL MSD.LETTERS
|
|
CALL MSD.DBM2.RED
|
|
CASE ANS='SG'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL MSD.SEGMENT.DISPLAY
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE ANS='Y'
|
|
IF FINANCIAL.INQUIRY.OK THEN
|
|
CALL MSD.YEAR.DISPLAY
|
|
CALL MSD.DBM2.RED
|
|
END ELSE
|
|
CRT @(0,21):CR
|
|
CRT @(0,22):RV:"Insufficient Security for Financial Inquiry":ERV:BEEP:
|
|
RQM
|
|
END
|
|
CASE ANS='CR'
|
|
FUNCTION=''
|
|
CALL CMSD.CREDITS(FUNCTION)
|
|
CALL MSD.DBM.RED
|
|
CASE 1
|
|
CALL CMSD.CONTROL.SPECIAL(ANS)
|
|
END CASE
|
|
GO 81000
|
|
|
|
*****
|
|
70000 * 800 # PHONE CENTER LOGIC - PCC (REST OF PROGRAM)
|
|
*
|
|
CALL CMSD.CONTROL.MTEK800(MASTER.RTCOD)
|
|
*
|
|
IF MASTER.RTCOD = '' THEN ;* RECORD GOOD
|
|
ENTER CMSD.CLOSE
|
|
END ELSE
|
|
CHANNEL=OCONV(0, 'U50BB')
|
|
PORT=FIELD(CHANNEL," ",1)
|
|
PT.DATA<100>=MASTER.RTCOD
|
|
OPEN 'PT' TO PT ELSE ABORT
|
|
WRITE PT.DATA ON PT,PORT
|
|
ACCOUNT.NAME='PHONE'
|
|
CHAIN "LOGTO ":ACCOUNT.NAME
|
|
END
|
|
*
|