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

BWCMGR.m

Go to the documentation of this file.
  1. BWCMGR ;IHS/ANMC/MWR - ADD/EDIT CASE MANAGER;15-Feb-2003 21:50;PLS
  1. ;;2.0;WOMEN'S HEALTH;**8**;MAY 16, 1996
  1. ;;* MICHAEL REMILLARD, DDS * ALASKA NATIVE MEDICAL CENTER *
  1. ;; CALLED BY OPTION: "BW ADD/EDIT CASE MANAGERS" TO ADD AND EDIT
  1. ;; CASE MANAGERS.
  1. ;
  1. ;---> DIE ADD/EDIT CASE MANAGERS LOOP.
  1. D SETVARS^BWUTL5
  1. N Y
  1. F D Q:$G(Y)<0
  1. .D TITLE^BWUTL5("ADD/EDIT CASE MANAGERS")
  1. .D DIC^BWFMAN(9002086.01,"QEMAL",.Y," Select CASE MANAGER: ")
  1. .Q:Y<0
  1. .D DIE^BWFMAN(9002086.01,.02,+Y,.BWPOP)
  1. .S:BWPOP Y=-1
  1. ;
  1. EXIT ;EP
  1. D KILLALL^BWUTL8
  1. Q
  1. ;
  1. TRANS ;EP
  1. ;---> TRANSFER ONE CASE MANAGER'S PATIENTS TO ANOTHER CASE MANAGER.
  1. ;
  1. D TRANS1
  1. D EXIT
  1. Q
  1. ;
  1. TRANS1 ;EP
  1. D TITLE^BWUTL5("TRANSFER A CASE MANAGER'S PATIENTS")
  1. D TEXT1
  1. D DIC^BWFMAN(9002086.01,"QEMA",.Y," Select OLD CASE MANAGER: ")
  1. Q:Y<0
  1. S BWCMGR=+Y
  1. D DIC^BWFMAN(9002086.01,"QEMA",.Y," Select NEW CASE MANAGER: ")
  1. Q:Y<0
  1. S BWCMGR1=+Y
  1. W !!?3,"All patients currently assigned to: ",$$PERSON^BWUTL1(BWCMGR)
  1. W !?3,"will be reassigned to.............: ",$$PERSON^BWUTL1(BWCMGR1)
  1. ;
  1. ;---> YES/NO
  1. W !!?3,"Do you wish to proceed?"
  1. S DIR("?")=" Enter YES to swap Case Managers."
  1. S DIR(0)="Y",DIR("A")=" Enter Yes or No"
  1. D ^DIR W !
  1. Q:$D(DIRUT)!('Y)
  1. S N=0,M=0
  1. F S N=$O(^BWP("C",BWCMGR,N)) Q:'N D
  1. .D DIE^BWFMAN(9002086,".1////"_BWCMGR1,N,.BWPOP)
  1. .Q:BWPOP S M=M+1
  1. W !?3,M," patients transferred from ",$$PERSON^BWUTL1(BWCMGR)
  1. W " to ",$$PERSON^BWUTL1(BWCMGR1),"." D DIRZ^BWUTL3
  1. Q
  1. ;
  1. TEXT1 ;EP
  1. ;;The purpose of this utility is to aid in the transfer of all of one
  1. ;;Case Manager's patients to another Case Manager, such as when there
  1. ;;is a turnover in staff. The program will ask you for an "OLD" Case
  1. ;;Manager and then for a "NEW" Case Manager. All patients who were
  1. ;;previously assigned to the "OLD" Case Manager will be reassigned to
  1. ;;the "NEW" Case Manager.
  1. ;;
  1. ;;If the "NEW" Case Manager you are looking for cannot be selected,
  1. ;;that person must first be added to the file of Case Managers by
  1. ;;using the "Add/Edit Case Managers" option.
  1. ;;
  1. S BWTAB=5,BWLINL="TEXT1" D PRINTX
  1. Q
  1. ;
  1. PRINTX ;EP
  1. N I,T,X S T="" F I=1:1:BWTAB S T=T_" "
  1. F I=1:1 S X=$T(@BWLINL+I) Q:X'[";;" W !,T,$P(X,";;",2)
  1. Q