source: WorldVistAEHR/trunk/r/ZZREGIONAL-A1C-A5C-CRHD-RGED-RGUT-RGWB-RG/CRHD7.m@ 814

Last change on this file since 814 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 1.7 KB
Line 
1CRHD7 ; CAIRO/CLC - TEAM ROSTER ;4/22/08 12:53
2 ;;1.0;CRHD;****;Jan 28, 2008;Build 19
3 ;=================================================================
4MGR(CRHDRTN,DUZ) ;check for the Manager key
5 N CRHDKN,CRHDOUT
6 S CRHDRTN=0
7 S CRHDKN=$$FIND1^DIC(19.1,"","X","CRHD SHIFT CHG HANDOFF MGR","","","CRHDOUT")
8 D GETS^DIQ(200,DUZ_",","51*","I","CRHDOUT")
9 I CRHDKN>0 S CRHDRTN=$D(CRHDOUT(200.051,+CRHDKN_","_DUZ_","))
10 Q
11TEAMMEM(CRHDRTN,CRHDTM) ;
12 N CRHDTMM,CRHDCT,CRHDOP,CRHDPG,CRHDX1,CRHDRM,CRHDEM
13 N CRHDTT,CRHDSORT,CRHDTTCT,CRHDTIT,CRHDFG,CRHDUIF,CRHDX
14 S CRHDCT=1
15 I $P(CRHDTM,"^",2)="USR" D
16 .S CRHDTM=$$GET^XPAR("USR.`"_+CRHDTM,"ORLP DEFAULT TEAM",1,"I")
17 I +CRHDTM D
18 .I '$D(^OR(100.21,+CRHDTM,0)) K CRHDRTN S CRHDRTN="" Q
19 .K CRHDTMM
20 .D TEAMPROV^ORQPTQ1(.CRHDTMM,+CRHDTM)
21 .I $D(CRHDTMM) D
22 ..S CRHDX1=0
23 ..F S CRHDX1=$O(CRHDTMM(CRHDX1)) Q:'CRHDX1 D
24 ...D DISP^CRHDUD(.CRHDUIF,+CRHDTMM(CRHDX1))
25 ...I $D(CRHDUIF) S CRHDSORT($P(CRHDUIF,"^",2))=CRHDUIF
26 I $D(CRHDSORT) D
27 .S CRHDCT=0
28 .S CRHDX=""
29 .F S CRHDX=$O(CRHDSORT(CRHDX)) Q:CRHDX="" D
30 ..S CRHDCT=CRHDCT+1
31 ..S CRHDRTN(CRHDCT)=CRHDSORT(CRHDX)
32 Q
33GETMPEXP(CRHDLST,CRHDUSR,CRHDDIV) ;get temp flds expiration time
34 K CRHDLST
35 N CRHDPARA,CRHDTITL,CRHDPP
36 F CRHDPP=1,2,3,4 D
37 .D GETONEP^CRHD4(.CRHDPARA,CRHDUSR,"TEMP_FLD_"_CRHDPP_"_TITLE",CRHDDIV)
38 .I $G(CRHDPARA(1))'="" D
39 ..S CRHDTITL=$$UP^XLFSTR(CRHDPARA(1))
40 ..S CRHDLST(CRHDTITL)=""
41 ..K CRHDPARA
42 ..D GETONEP^CRHD4(.CRHDPARA,CRHDUSR,"edt_TEMP_FLD_"_CRHDPP_"_EXPIRE",CRHDDIV)
43 ..I $G(CRHDPARA(1))'="" S CRHDLST(CRHDTITL)=CRHDPARA(1)
44 Q
45DELTMPTX(CRHDFLDA,DA) ;KILL TEXT FOR TEMP FLD DATA
46 N DIE,DR
47 S DIE="^CRHD(183.2,"_CRHDFLDA_",1,"
48 S DA(1)=CRHDFLDA,DR=".01///@"
49 D ^DIE
50 Q
Note: See TracBrowser for help on using the repository browser.