Ignore:
Timestamp:
Jul 9, 2012, 7:43:46 PM (12 years ago)
Author:
Sam Habiel
Message:

Added/fixed the following:

  • Unit Tests for running everything through PIMS
  • Checks for end of message for error handling ((31))
  • All routines previously using transactions use locks now
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Scheduling/trunk/m/BSDXAPI.m

    r1472 r1479  
    1 BSDXAPI ; IHS/LJF,HMW,MAW & VEN/SMH - SCHEDULING APIs ; 7/6/12 10:24am
     1BSDXAPI ; IHS/LJF,HMW,MAW & VEN/SMH - SCHEDULING APIs ; 7/9/12 4:00pm
    22        ;;1.7T1;BSDX;;Jul 06, 2012;Build 18
    33        ; Licensed under LGPL 
     
    155155        ; If previous data exists, which caused an error, it's destroyed.
    156156        ; NB: ^DIK stops for nobody
     157        ; TODO: If Patient Appointment previously existed as cancelled, it's removed.
     158        ; How can I tell if one previously existed when data is in an intermediate
     159        ; State? Can I restore it if the other file failed? Restoration can cause
     160        ; another error. If I restore the global, there will be cross-references
     161        ; missing (ASDCN specifically).
     162        ;
    157163        ; Input: Same array as $$MAKE
    158164        ; Output: Always 0
     
    422428        Q $S(X=3:"SCHED",X=4:"WALK-IN",1:"??")
    423429        ;
    424 UPDATENT(PAT,CLINIC,DATE,NOTE)  ; PEP; Update Note in ^SC for patient's appointment @ DATE
    425         ; PAT = DFN
    426         ; CLINIC = SC IEN
    427         ; DATE = FM Date/Time of Appointment
    428         ;
    429         ; Returns:
    430         ; 0 if okay
    431         ; -1 if failure
    432         ;
    433         ; ERROR SIMULATION
    434         I $G(BSDXSIMERR1) QUIT "-1~Simulated Error"
    435         ;
    436         N SCIEN S SCIEN=$$SCIEN(PAT,CLINIC,DATE) ; ien of appt in ^SC
    437         I SCIEN<1 QUIT 0    ; Appt cancelled; cancelled appts rm'ed from file 44
    438         N BSDXIENS S BSDXIENS=SCIEN_","_DATE_","_CLINIC_","
    439         N BSDXFDA S BSDXFDA(44.003,BSDXIENS,3)=$E(NOTE,1,150)
    440         N BSDXERR
    441         D FILE^DIE("","BSDXFDA","BSDXERR")
    442         I $D(BSDXERR) QUIT "-1~Can't file for Pat "_PAT_" in Clinic "_CLINIC_" at "_DATE_". Fileman reported an error: "_BSDXERR("DIERR",1,"TEXT",1)
    443         QUIT 0
Note: See TracChangeset for help on using the changeset viewer.