- FSCEL ;SLC/STAFF-NOIS Edit Log ;3/16/98 19:24
- ;;1.1;NOIS;;Sep 06, 1998
- ;
- NEW ; from FSCLMP, FSCOPT
- N ACTION,CALLID,CALLNUM,OK,RDATE,SITE
- D ID^FSCELID(.SITE,.RDATE,.CALLID,.CALLNUM,.OK)
- I 'OK Q
- W !?5,"Call ID: ",CALLID
- I '$$ACCESS^FSCU(DUZ,"SPEC") D NEW^FSCELSNS(CALLID,CALLNUM) Q
- D NEW^FSCELS(SITE,CALLNUM)
- N CONALERT,CONTACT,CONTNAME
- S CONALERT=$$CONALERT^FSCUP
- S CONTACT=+$P(^FSCD("CALL",CALLNUM,0),U,6),CONTNAME=""
- I CONTACT S CONTNAME=$$VALUE^FSCGET(CONTACT,7100,2.1)
- I CONALERT="F" D
- .I 'CONTACT W !,"Contact person not filled in.",$C(7) H 2 D RECON^FSCELS(SITE,CALLNUM) Q
- .D ALERT(CONTACT,CALLNUM)
- I CONALERT="P" D
- .I 'CONTACT W !,"Contact person not filled in.",$C(7) H 2 D RECON^FSCELS(SITE,CALLNUM) Q
- .N DIR,X,Y K DIR
- .S DIR(0)="YAO",DIR("A")="Would "_CONTNAME_" like to automatically be alerted to edits? ",DIR("B")="NO"
- .S DIR("?",1)="Enter YES to have this contact person alerted whenever this call is edited."
- .S DIR("?",2)="Enter NO to not schedule this person for automatic alerts."
- .S DIR("?")="^D HELP^FSCU(.DIR)"
- .S DIR("??")="FSC U1 NOIS"
- .D ^DIR K DIR
- .I Y'=1 D ALERT(CONTACT,CALLNUM)
- I $D(DTOUT) D OPEN(CALLID,CALLNUM) Q
- N DIR,X,Y K DIR
- S DIR(0)="SAMO^MAKE A NOTE:MAKE A NOTE;REFER:REFER;CLOSE:CLOSE;OPEN:OPEN",DIR("A")="Further action - (M)ake a Note, (R)efer, (C)lose, (O)pen: " S DIR("B")=$S($$CLOSE(DUZ):"CLOSE",1:"OPEN")
- S DIR("?",1)="Enter M to make a note. The call will remain open."
- S DIR("?",2)="Enter R to change the status to Referred."
- S DIR("?",3)="Enter C to close this call."
- S DIR("?",4)="Enter O or '^' to leave this call open without making a note."
- S DIR("?",5)="Enter '??' for additional help."
- S DIR("?")="^D HELP^FSCU(.DIR)"
- S DIR("??")="FSC U1 NOIS"
- D ^DIR K DIR
- S ACTION=Y
- I ACTION="OPEN"!$D(DIRUT) D OPEN(CALLID,CALLNUM)
- I ACTION="CLOSE" D
- .;D STATUS^FSCES(CALLNUM,"",1)
- .D NOTES("Make a Note (in addition to resolution summary)? ")
- .D UPDATE^FSCTASK(CALLNUM)
- .D CLOSE^FSCEC(CALLNUM,.OK) I 'OK Q
- .D STATUS^FSCES(CALLNUM,1,2)
- .D UPDATE^FSCTASK(CALLNUM)
- I ACTION="REFER" D
- .;D STATUS^FSCES(CALLNUM,"",1)
- .D UPDATE^FSCTASK(CALLNUM)
- .D STATUS^FSCES(CALLNUM,1,3)
- .D NOTES("Include a note with this status change? ")
- .D UPDATE^FSCTASK(CALLNUM)
- I ACTION="MAKE A NOTE" D
- .D NOTES("")
- .D OPEN(CALLID,CALLNUM)
- D WKLD^FSCEWKLD(CALLNUM,1)
- D LIST^FSCELL(CALLNUM)
- Q
- ;
- CLOSE(USER) ; $$(user) -> 1 or 0 for default of prompt to close call
- I $P(^FSC("SPEC",USER,0),U,13) Q 1
- Q 0
- ;
- NOTES(ASK) ; get notes
- N DIR,OK,OPER,X,Y K DIR
- I $L($G(ASK)) S OK=1 D Q:'OK
- .S DIR(0)="YAO",DIR("A")=ASK,DIR("B")="NO"
- .S DIR("?",1)="Enter YES to make a note on this call."
- .S DIR("?",2)="Enter NO change the status without making a note."
- .S DIR("?")="^D HELP^FSCU(.DIR)"
- .S DIR("??")="FSC U1 NOIS"
- .D ^DIR K DIR
- .I Y'=1 S OK=0 Q
- D DATA^FSCEN("ACTION",.OPER)
- I OPER="ACCEPT" D NOTE^FSCEF(CALLNUM,"ACTION")
- Q
- ;
- ALERT(USER,CALL) ; schedule user for alert on call
- D SETUP^FSCNOT(CALL,,,USER_U_1,"ALERT","EDITED")
- Q
- ;
- OPEN(CALLID,CALLNUM) ; from FSCELSNS
- ; msg if call is not closed or referred, status updated to open
- W !,"This call ("_CALLID_") will remain open."
- ;D STATUS^FSCES(CALLNUM,"",1)
- D UPDATE^FSCTASK(CALLNUM)
- H 1
- Q
- --- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HFSCEL 3311 printed Feb 18, 2025@23:44 Page 2
- FSCEL ;SLC/STAFF-NOIS Edit Log ;3/16/98 19:24
- +1 ;;1.1;NOIS;;Sep 06, 1998
- +2 ;
- NEW ; from FSCLMP, FSCOPT
- +1 NEW ACTION,CALLID,CALLNUM,OK,RDATE,SITE
- +2 DO ID^FSCELID(.SITE,.RDATE,.CALLID,.CALLNUM,.OK)
- +3 IF 'OK
- QUIT
- +4 WRITE !?5,"Call ID: ",CALLID
- +5 IF '$$ACCESS^FSCU(DUZ,"SPEC")
- DO NEW^FSCELSNS(CALLID,CALLNUM)
- QUIT
- +6 DO NEW^FSCELS(SITE,CALLNUM)
- +7 NEW CONALERT,CONTACT,CONTNAME
- +8 SET CONALERT=$$CONALERT^FSCUP
- +9 SET CONTACT=+$PIECE(^FSCD("CALL",CALLNUM,0),U,6)
- SET CONTNAME=""
- +10 IF CONTACT
- SET CONTNAME=$$VALUE^FSCGET(CONTACT,7100,2.1)
- +11 IF CONALERT="F"
- Begin DoDot:1
- +12 IF 'CONTACT
- WRITE !,"Contact person not filled in.",$CHAR(7)
- HANG 2
- DO RECON^FSCELS(SITE,CALLNUM)
- QUIT
- +13 DO ALERT(CONTACT,CALLNUM)
- End DoDot:1
- +14 IF CONALERT="P"
- Begin DoDot:1
- +15 IF 'CONTACT
- WRITE !,"Contact person not filled in.",$CHAR(7)
- HANG 2
- DO RECON^FSCELS(SITE,CALLNUM)
- QUIT
- +16 NEW DIR,X,Y
- KILL DIR
- +17 SET DIR(0)="YAO"
- SET DIR("A")="Would "_CONTNAME_" like to automatically be alerted to edits? "
- SET DIR("B")="NO"
- +18 SET DIR("?",1)="Enter YES to have this contact person alerted whenever this call is edited."
- +19 SET DIR("?",2)="Enter NO to not schedule this person for automatic alerts."
- +20 SET DIR("?")="^D HELP^FSCU(.DIR)"
- +21 SET DIR("??")="FSC U1 NOIS"
- +22 DO ^DIR
- KILL DIR
- +23 IF Y'=1
- DO ALERT(CONTACT,CALLNUM)
- End DoDot:1
- +24 IF $DATA(DTOUT)
- DO OPEN(CALLID,CALLNUM)
- QUIT
- +25 NEW DIR,X,Y
- KILL DIR
- +26 SET DIR(0)="SAMO^MAKE A NOTE:MAKE A NOTE;REFER:REFER;CLOSE:CLOSE;OPEN:OPEN"
- SET DIR("A")="Further action - (M)ake a Note, (R)efer, (C)lose, (O)pen: "
- SET DIR("B")=$SELECT($$CLOSE(DUZ):"CLOSE",1:"OPEN")
- +27 SET DIR("?",1)="Enter M to make a note. The call will remain open."
- +28 SET DIR("?",2)="Enter R to change the status to Referred."
- +29 SET DIR("?",3)="Enter C to close this call."
- +30 SET DIR("?",4)="Enter O or '^' to leave this call open without making a note."
- +31 SET DIR("?",5)="Enter '??' for additional help."
- +32 SET DIR("?")="^D HELP^FSCU(.DIR)"
- +33 SET DIR("??")="FSC U1 NOIS"
- +34 DO ^DIR
- KILL DIR
- +35 SET ACTION=Y
- +36 IF ACTION="OPEN"!$DATA(DIRUT)
- DO OPEN(CALLID,CALLNUM)
- +37 IF ACTION="CLOSE"
- Begin DoDot:1
- +38 ;D STATUS^FSCES(CALLNUM,"",1)
- +39 DO NOTES("Make a Note (in addition to resolution summary)? ")
- +40 DO UPDATE^FSCTASK(CALLNUM)
- +41 DO CLOSE^FSCEC(CALLNUM,.OK)
- IF 'OK
- QUIT
- +42 DO STATUS^FSCES(CALLNUM,1,2)
- +43 DO UPDATE^FSCTASK(CALLNUM)
- End DoDot:1
- +44 IF ACTION="REFER"
- Begin DoDot:1
- +45 ;D STATUS^FSCES(CALLNUM,"",1)
- +46 DO UPDATE^FSCTASK(CALLNUM)
- +47 DO STATUS^FSCES(CALLNUM,1,3)
- +48 DO NOTES("Include a note with this status change? ")
- +49 DO UPDATE^FSCTASK(CALLNUM)
- End DoDot:1
- +50 IF ACTION="MAKE A NOTE"
- Begin DoDot:1
- +51 DO NOTES("")
- +52 DO OPEN(CALLID,CALLNUM)
- End DoDot:1
- +53 DO WKLD^FSCEWKLD(CALLNUM,1)
- +54 DO LIST^FSCELL(CALLNUM)
- +55 QUIT
- +56 ;
- CLOSE(USER) ; $$(user) -> 1 or 0 for default of prompt to close call
- +1 IF $PIECE(^FSC("SPEC",USER,0),U,13)
- QUIT 1
- +2 QUIT 0
- +3 ;
- NOTES(ASK) ; get notes
- +1 NEW DIR,OK,OPER,X,Y
- KILL DIR
- +2 IF $LENGTH($GET(ASK))
- SET OK=1
- Begin DoDot:1
- +3 SET DIR(0)="YAO"
- SET DIR("A")=ASK
- SET DIR("B")="NO"
- +4 SET DIR("?",1)="Enter YES to make a note on this call."
- +5 SET DIR("?",2)="Enter NO change the status without making a note."
- +6 SET DIR("?")="^D HELP^FSCU(.DIR)"
- +7 SET DIR("??")="FSC U1 NOIS"
- +8 DO ^DIR
- KILL DIR
- +9 IF Y'=1
- SET OK=0
- QUIT
- End DoDot:1
- if 'OK
- QUIT
- +10 DO DATA^FSCEN("ACTION",.OPER)
- +11 IF OPER="ACCEPT"
- DO NOTE^FSCEF(CALLNUM,"ACTION")
- +12 QUIT
- +13 ;
- ALERT(USER,CALL) ; schedule user for alert on call
- +1 DO SETUP^FSCNOT(CALL,,,USER_U_1,"ALERT","EDITED")
- +2 QUIT
- +3 ;
- OPEN(CALLID,CALLNUM) ; from FSCELSNS
- +1 ; msg if call is not closed or referred, status updated to open
- +2 WRITE !,"This call ("_CALLID_") will remain open."
- +3 ;D STATUS^FSCES(CALLNUM,"",1)
- +4 DO UPDATE^FSCTASK(CALLNUM)
- +5 HANG 1
- +6 QUIT