38 lines
1.2 KiB
Plaintext
38 lines
1.2 KiB
Plaintext
compile subroutine quote_num_valid(ConvType, DataIo, Branch, ReturnedValue)
|
|
begin condition
|
|
pre:
|
|
post:
|
|
end condition
|
|
|
|
$insert logical
|
|
$insert quote_equ
|
|
$insert msg_equates
|
|
declare function msg, get_property, set_property
|
|
equ valid$ to 0 ;* successful
|
|
equ invalid_msg$ to 1 ;* bad data - print error message window
|
|
equ invalid_conv$ to 2 ;* bad conversion - " "
|
|
equ invalid_nomsg$ to 3 ;* bad but do not print the error message window
|
|
equ CrLf$ to char(13):char(10)
|
|
|
|
ReturnedValue = DataIo
|
|
status() = Valid$
|
|
ValidTables = xlate( 'CONFIG', 'TABLENAMES', '', 'X' )
|
|
*
|
|
begin case
|
|
case ConvType = 'ICONV'
|
|
if xlate( 'QUOTE', DataIo, quote_status$, 'X' ) = 'O' else
|
|
MsgInfo = ''
|
|
MsgInfo<mtext$> = DataIo:' is not an OPEN Quote...':CrLf$:'Press [SF2] to view OPEN quotes for this customer.'
|
|
MsgInfo<micon$> = 'H'
|
|
Void = msg( '', MsgInfo )
|
|
status() = invalid_nomsg$
|
|
end
|
|
case ConvType = 'OCONV'
|
|
* no output
|
|
ReturnedValue = DataIo
|
|
case otherwise$
|
|
ReturnedValue = ''
|
|
status() = invalid_conv$
|
|
end case
|
|
return
|