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

PRCFFUC2.m

Go to the documentation of this file.
  1. PRCFFUC2 ;WISC/SJG-UTILITY ROUTINE FOR HOLD FUNCTIONALITY ;7/24/00 23:13
  1. V ;;5.1;IFCAP;;Oct 20, 2000
  1. ;Per VHA Directive 10-93-142, this routine should not be modified.
  1. ;
  1. ; Edit checking accounting period, obligation processing date, etc.
  1. CHK1 ; Check for earlier accounting periods
  1. N CUR,NEW
  1. S CUR=$P(PRCFA("CURRENT"),U,3),NEW=$P(PRCFA("ACCPD"),U,3)
  1. Q:CUR=NEW Q:CUR<NEW
  1. I CUR>NEW D M1
  1. Q
  1. CHK2 ; Check for accounting period/obligation processing
  1. N APCK,NEW
  1. S APCK=$P(PRCFA("ACCPDCK"),U,3),NEW=$P(PRCFA("ACCPD"),U,3)
  1. Q:APCK=NEW
  1. I APCK>NEW!(APCK<NEW) D M2
  1. Q
  1. M ; Message Processing
  1. M1 D LN K MSG
  1. S MSG(1)="WARNING: The Accounting Period selected is earlier than the current"
  1. S MSG(2)="the Accounting Period! Sending this document to FMS with this Accounting"
  1. S MSG(3)="Period may cause the document to reject with a Closed Accounting Period error!"
  1. D EN^DDIOL(.MSG) K MSG D LN
  1. Q
  1. M2 ;
  1. N YY S YY=$$DATE^PRC0C(PRCFA("OBLDATE"),"I"),YY=$$TRANS^PRCFFUC(YY)
  1. W ! K MSG D LN
  1. S MSG(1)="WARNING: There may be an Obligation Processing Date/Accounting Period"
  1. S MSG(2)="mismatch! The Obligation Processing Date ("_YY_") does not fall into"
  1. S MSG(3)="the selected Accounting Period ("_$P(PRCFA("ACCPD"),U)_") for "_$P(PRCFA("ACCPD"),U,2)_"."
  1. S MSG(4)=" "
  1. S:APCK>NEW MM="precedes" S:APCK<NEW MM="follows"
  1. S MSG(5)="The Accounting Period "_MM_" the Obligation Processing Date."
  1. S MSG(6)=" ",MSG(7)="Please be sure that the appropriate Accounting Period has been"
  1. S MSG(8)="chosen for this transaction before proceeding with this obligation."
  1. D EN^DDIOL(.MSG) K MSG D LN
  1. D TABLE I Y D H2^PRCFFUC1 W !
  1. Q
  1. TABLE ; Set up call to display help table
  1. N DIR S DIR(0)="Y",DIR("B")="NO"
  1. S DIR("A")="the calendar month and its fiscal month"
  1. S DIR("A",1)="Do you wish to display a table showing the relationship between"
  1. W ! D ^DIR K DIR
  1. Q
  1. LN ; Write out a line of asterisks
  1. W ! S $P(LN,"*",80)="" W LN Q