Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: PRCHMOP

PRCHMOP.m

Go to the documentation of this file.
PRCHMOP ;ISC2/RWS-ORDER NUMBER ACK (ONA) TRANSMITTER ;8-20-92/09:55
V ;;5.1;IFCAP;;Oct 20, 2000
 ;Per VHA Directive 10-93-142, this routine should not be modified.
READ ; READ SYSID AND LINE COUNT SEGMENTS
 S X=$Q(@TRANSIN),SYSEG=@X
 S X=$Q(@X),LCSEG=@X I $P(LCSEG,U,1)'="LC" S ERR="SEGMENT TYPE SHOULD BE LC" Q
 S LCNT=$P(LCSEG,U,2),ISNO=$P(SYSEG,U,7),IFNO=$P(LCSEG,U,3),IFNO=$E(IFNO,1,3)_"-"_$E(IFNO,4,99)
 F  Q:$A($E(ISNO,$L(ISNO)))'=32  S ISNO=$E(ISNO,1,$L(ISNO)-1)
 S ^XMB(3.9,XMZ,2,1,0)="      IFCAP Requisition Number "_IFNO_" has been assigned # "_ISNO_" in ISMS."
 S ^XMB(3.9,XMZ,2,2,0)=""
 S ^XMB(3.9,XMZ,2,3,0)=""
 S ^XMB(3.9,XMZ,2,4,0)=""
 S ^XMB(3.9,XMZ,2,5,0)=""
 S LIN=5 I $Q(@X)=""!(+LCNT'=0) S ERR="LINE COUNT ERROR" Q
 D ACK
EXIT Q
ACK ;TRANSMIT ISMS PO # TO IFCAP PO
 S DA=$O(^PRC(442,"B",IFNO,0)) I DA="" S ERR="REQUISITION NUMBER NOT FOUND" Q
 S DIE="^PRC(442,",DR="110///^S X=ISNO",DR(2,442.17)="1///" D ^DIE
 K DA,DIE,DR Q