MBAAMRP1 ;OIT-PD/CKU - APPOINTMENT RPC ;02/10/2016
;;1.0;Scheduling Calendar View;**1**;Jun 23, 2015;Build 85
;
Q
GETCLN(RV,SC) ; gets the clinic details
; MBAA RPC: MBAA GET CLINIC DETAILS
N STATUS,RESULT ;S STATUS=$$DETAILS(.RESULT,SC)
D DETAILS(.RESULT,SC)
;I 'STATUS S RV=-1
D MERGE^MBAAMRPC(.RV,.RESULT)
Q
DETAILS(ARRAY,SC) ; Get clinic details
S FILE=44,FIELDS=".01;1;2;7;8;9;9.5;10;24;1912;1914;1917;1918;2500;2503",FLAG="IE"
K ARRAY D GETS^DIQ(44,SC_",",FIELDS,FLAG,"ARRAY")
I $G(ARRAY(44,SC_",",1914,"E"))="" S ARRAY(44,SC_",",1914,"E")=8
I $G(ARRAY(44,SC_",",1914,"I"))="" S ARRAY(44,SC_",",1914,"I")=8
K FILE,FIELDS,FLAG
Q
;GETCLN(RV,CLINIC) ; SD GET CLINIC DETAILS
; N STATUS,RESULT S STATUS=$$GETCLN^MBAAMAP1(.RESULT,CLINIC)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; I 'STATUS S RV=-1
; Q
;LSTCLNS(RV,SEARCH,START,NUMBER) ; SD GET CLINICS BY NAME
; N STATUS,RESULT S STATUS=$$LSTCLNS^MBAAMAP1(.RESULT,SEARCH,.START,NUMBER)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; I 'STATUS S RV=-1
; Q
;FRSTAVBL(RV,SC) ; SD GET FIRST AVAILABLE APPT
; N STATUS,RESULT S STATUS=$$FRSTAVBL^MBAAMAP1(.RESULT,SC)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; I 'STATUS S RV=-1
; Q
;CLNCK(RV,CLN) ; SD VALID CLINIC STOP CODE
; N STATUS,RESULT S STATUS=$$CLNCK^MBAAMAP1(.RESULT,CLN)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
CLNRGHT(RV,CLN) ; MBAA RPC: MBAA VERIFY CLINIC ACCESS
N STATUS,RESULT S STATUS=$$CLNRGHT^MBAAMAP1(.RESULT,CLN)
;D MERGE^MBAAMRPC(.RV,.RESULT)
S RV(0)=0
I $G(STATUS)=1 S RV(0)=1
Q
;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
;CLNVSC(RV,SC) ; SD VALID STOP CODE
; N STATUS,RESULT S STATUS=$$CLNVSC^MBAAMAP1(.RESULT,SC)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
SLOTS(RV,SC) ; MBAA RPC: MBAA GET CLINIC AVAILABILITY
N STATUS,RESULT S STATUS=$$SLOTS^MBAAMAP1(.RESULT,SC)
I 'STATUS S RV=-1
D MERGE^MBAAMRPC(.RV,.RESULT)
;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
;GETPEND(RV,PAT,DT) ; SD GET PATIENT PENDING APPTS
; N STATUS,RESULT S STATUS=$$GETPEND^MBAAMAP1(.RESULT,PAT,DT)
; I 'STATUS S RV=-1
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;GETAPTS(RV,DFN,SD) ; SD GET PATIENT APPOINTMENTS
; N STATUS,RESULT S STATUS=$$GETAPTS^MBAAMAP1(.RESULT,DFN,.SD)
; I 'STATUS S RV=-1
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;HASPEND(RV,PAT,DT) ; SD HAS PATIENT PENDING APPTS
; N STATUS,RESULT S STATUS=$$HASPEND^MBAAMAP1(.RESULT,PAT,DT)
; I 'STATUS S RV=-1
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
LSTCRSNS(RV,SEARCH,START,NUMBER) ; MBAA RPC: MBAA LIST CANCELLATION REASONS
N STATUS,RESULT S STATUS=$$LSTCRSNS^MBAAMAP1(.RESULT,SEARCH,START,NUMBER)
I 'STATUS S RV=-1
D MERGE^MBAAMRPC(.RV,.RESULT)
Q
;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
;LISTEWL(RV,DFN,STATUS,BEGIN,END) ; SD EWL LIST
; N STATUS,RESULT S STATUS=$$LIST^MBAAWLAP(.RESULT,DFN,STATUS,BEGIN,END)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;DETALEWL(RV,IEN) ; SD EWL DETAIL
; N STATUS,RESULT S STATUS=$$DETAIL^MBAAWLAP(.RESULT,IEN)
; I 'STATUS S RV=-1
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;NEWEWL(RV,SDWLD) ; MBAA RPC: MBAA EWL NEW
;N STATUS,RESULT S STATUS=$$NEW^MBAAWLAP(.RESULT,SDWLD)
;I 'STATUS S RV=-1
;D MERGE^MBAAMRPC(.RV,.RESULT)
;Q
;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
;UPDTEWL(RV,SDWLIEN,SDWLD) ; SD EWL UPDATE
; N STATUS,RESULT S STATUS=$$UPDATE^MBAAWLAP(.RESULT,SDWLIEN,.SDWLD)
; I 'STATUS S RV=-1
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;DISPEWL(RV,SDWLDFN,SDWLIEN,SDWLDISP,SDWLAPPT) ; SD EWL DISPOSITION
; N STATUS,RESULT S STATUS=$$DISP^MBAAWLAP(.RESULT,SDWLDFN,SDWLIEN,SDWLDISP,.SDWLAPPT)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;DELEWL(RV,SDWLIEN) ; SD EWL DELETE
; N STATUS,RESULT S STATUS=$$DELETE^MBAAWLAP(.RESULT,SDWLIEN)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;ISEWL(RV,DFN) ; SD EWL IS PATIENT ON LIST
; N STATUS,RESULT S STATUS=$$HASENTRY^MBAAWLAP(.RESULT,DFN)
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
;LSTSRT(RV) ; SD GET REQUEST TYPES
; N STATUS,RESULT S STATUS=$$LSTSRT^MBAAMAP1(.RESULT)
; I 'STATUS S RV=-1
; D MERGE^MBAAMRPC(.RV,.RESULT)
; Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HMBAAMRP1 4411 printed Dec 13, 2024@02:14:57 Page 2
MBAAMRP1 ;OIT-PD/CKU - APPOINTMENT RPC ;02/10/2016
+1 ;;1.0;Scheduling Calendar View;**1**;Jun 23, 2015;Build 85
+2 ;
+3 QUIT
GETCLN(RV,SC) ; gets the clinic details
+1 ; MBAA RPC: MBAA GET CLINIC DETAILS
+2 ;S STATUS=$$DETAILS(.RESULT,SC)
NEW STATUS,RESULT
+3 DO DETAILS(.RESULT,SC)
+4 ;I 'STATUS S RV=-1
+5 DO MERGE^MBAAMRPC(.RV,.RESULT)
+6 QUIT
DETAILS(ARRAY,SC) ; Get clinic details
+1 SET FILE=44
SET FIELDS=".01;1;2;7;8;9;9.5;10;24;1912;1914;1917;1918;2500;2503"
SET FLAG="IE"
+2 KILL ARRAY
DO GETS^DIQ(44,SC_",",FIELDS,FLAG,"ARRAY")
+3 IF $GET(ARRAY(44,SC_",",1914,"E"))=""
SET ARRAY(44,SC_",",1914,"E")=8
+4 IF $GET(ARRAY(44,SC_",",1914,"I"))=""
SET ARRAY(44,SC_",",1914,"I")=8
+5 KILL FILE,FIELDS,FLAG
+6 QUIT
+7 ;GETCLN(RV,CLINIC) ; SD GET CLINIC DETAILS
+8 ; N STATUS,RESULT S STATUS=$$GETCLN^MBAAMAP1(.RESULT,CLINIC)
+9 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+10 ; I 'STATUS S RV=-1
+11 ; Q
+12 ;LSTCLNS(RV,SEARCH,START,NUMBER) ; SD GET CLINICS BY NAME
+13 ; N STATUS,RESULT S STATUS=$$LSTCLNS^MBAAMAP1(.RESULT,SEARCH,.START,NUMBER)
+14 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+15 ; I 'STATUS S RV=-1
+16 ; Q
+17 ;FRSTAVBL(RV,SC) ; SD GET FIRST AVAILABLE APPT
+18 ; N STATUS,RESULT S STATUS=$$FRSTAVBL^MBAAMAP1(.RESULT,SC)
+19 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+20 ; I 'STATUS S RV=-1
+21 ; Q
+22 ;CLNCK(RV,CLN) ; SD VALID CLINIC STOP CODE
+23 ; N STATUS,RESULT S STATUS=$$CLNCK^MBAAMAP1(.RESULT,CLN)
+24 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+25 ; Q
CLNRGHT(RV,CLN) ; MBAA RPC: MBAA VERIFY CLINIC ACCESS
+1 NEW STATUS,RESULT
SET STATUS=$$CLNRGHT^MBAAMAP1(.RESULT,CLN)
+2 ;D MERGE^MBAAMRPC(.RV,.RESULT)
+3 SET RV(0)=0
+4 IF $GET(STATUS)=1
SET RV(0)=1
+5 QUIT
+6 ;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
+7 ;CLNVSC(RV,SC) ; SD VALID STOP CODE
+8 ; N STATUS,RESULT S STATUS=$$CLNVSC^MBAAMAP1(.RESULT,SC)
+9 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+10 ; Q
SLOTS(RV,SC) ; MBAA RPC: MBAA GET CLINIC AVAILABILITY
+1 NEW STATUS,RESULT
SET STATUS=$$SLOTS^MBAAMAP1(.RESULT,SC)
+2 IF 'STATUS
SET RV=-1
+3 DO MERGE^MBAAMRPC(.RV,.RESULT)
+4 ;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
+5 ;GETPEND(RV,PAT,DT) ; SD GET PATIENT PENDING APPTS
+6 ; N STATUS,RESULT S STATUS=$$GETPEND^MBAAMAP1(.RESULT,PAT,DT)
+7 ; I 'STATUS S RV=-1
+8 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+9 ; Q
+10 ;GETAPTS(RV,DFN,SD) ; SD GET PATIENT APPOINTMENTS
+11 ; N STATUS,RESULT S STATUS=$$GETAPTS^MBAAMAP1(.RESULT,DFN,.SD)
+12 ; I 'STATUS S RV=-1
+13 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+14 ; Q
+15 ;HASPEND(RV,PAT,DT) ; SD HAS PATIENT PENDING APPTS
+16 ; N STATUS,RESULT S STATUS=$$HASPEND^MBAAMAP1(.RESULT,PAT,DT)
+17 ; I 'STATUS S RV=-1
+18 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+19 ; Q
LSTCRSNS(RV,SEARCH,START,NUMBER) ; MBAA RPC: MBAA LIST CANCELLATION REASONS
+1 NEW STATUS,RESULT
SET STATUS=$$LSTCRSNS^MBAAMAP1(.RESULT,SEARCH,START,NUMBER)
+2 IF 'STATUS
SET RV=-1
+3 DO MERGE^MBAAMRPC(.RV,.RESULT)
+4 QUIT
+5 ;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
+6 ;LISTEWL(RV,DFN,STATUS,BEGIN,END) ; SD EWL LIST
+7 ; N STATUS,RESULT S STATUS=$$LIST^MBAAWLAP(.RESULT,DFN,STATUS,BEGIN,END)
+8 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+9 ; Q
+10 ;DETALEWL(RV,IEN) ; SD EWL DETAIL
+11 ; N STATUS,RESULT S STATUS=$$DETAIL^MBAAWLAP(.RESULT,IEN)
+12 ; I 'STATUS S RV=-1
+13 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+14 ; Q
+15 ;NEWEWL(RV,SDWLD) ; MBAA RPC: MBAA EWL NEW
+16 ;N STATUS,RESULT S STATUS=$$NEW^MBAAWLAP(.RESULT,SDWLD)
+17 ;I 'STATUS S RV=-1
+18 ;D MERGE^MBAAMRPC(.RV,.RESULT)
+19 ;Q
+20 ;code below is not being used in the initial release of MBAA. It will be released at a later date in a future release of MBAA
+21 ;UPDTEWL(RV,SDWLIEN,SDWLD) ; SD EWL UPDATE
+22 ; N STATUS,RESULT S STATUS=$$UPDATE^MBAAWLAP(.RESULT,SDWLIEN,.SDWLD)
+23 ; I 'STATUS S RV=-1
+24 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+25 ; Q
+26 ;DISPEWL(RV,SDWLDFN,SDWLIEN,SDWLDISP,SDWLAPPT) ; SD EWL DISPOSITION
+27 ; N STATUS,RESULT S STATUS=$$DISP^MBAAWLAP(.RESULT,SDWLDFN,SDWLIEN,SDWLDISP,.SDWLAPPT)
+28 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+29 ; Q
+30 ;DELEWL(RV,SDWLIEN) ; SD EWL DELETE
+31 ; N STATUS,RESULT S STATUS=$$DELETE^MBAAWLAP(.RESULT,SDWLIEN)
+32 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+33 ; Q
+34 ;ISEWL(RV,DFN) ; SD EWL IS PATIENT ON LIST
+35 ; N STATUS,RESULT S STATUS=$$HASENTRY^MBAAWLAP(.RESULT,DFN)
+36 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+37 ; Q
+38 ;LSTSRT(RV) ; SD GET REQUEST TYPES
+39 ; N STATUS,RESULT S STATUS=$$LSTSRT^MBAAMAP1(.RESULT)
+40 ; I 'STATUS S RV=-1
+41 ; D MERGE^MBAAMRPC(.RV,.RESULT)
+42 ; Q