source: FOIAVistA/trunk/r/CLINICAL_MONITORING_SYSTEM-QAM/QAMC14.m@ 1394

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

initial load of FOIAVistA 6/30/08 version

File size: 1.2 KB
Line 
1QAMC14 ;HISC/DAD-CONDITION: SPECIALTY TRANSFER ;7/27/92 13:05
2 ;;1.0;Clinical Monitoring System;;09/13/1993
3EN1 ; *** CONDITION CODE
4 S TXSPGRP=$S($D(^QA(743,QAMD0,"COND",QAMD1,"P1"))#2:+^("P1"),1:0)
5 F TXSPDT=(QAMTODAY-.0000001):0 S TXSPDT=$O(^DGPM("AMV6",TXSPDT)) Q:(TXSPDT'>0)!(TXSPDT\1'?7N)!(TXSPDT>(QAMTODAY+.9999999)) F QAMDFN=0:0 S QAMDFN=$O(^DGPM("AMV6",TXSPDT,QAMDFN)) Q:QAMDFN'>0 D LOOP0
6 K TXSPGRP,TXSPDT,TXSPD0,TXSP
7 Q
8LOOP0 F TXSPD0=0:0 S TXSPD0=$O(^DGPM("AMV6",TXSPDT,QAMDFN,TXSPD0)) Q:TXSPD0'>0 D LOOP1
9 Q
10LOOP1 I TXSPGRP S TXSP=+$S($D(^DGPM(TXSPD0,0))#2:$P(^(0),"^",9),1:0) Q:$O(^QA(743.5,TXSPGRP,"GRP","AB",+TXSP,0))'>0
11 S ^UTILITY($J,"QAM CONDITION",QAMD1,QAMDFN)="",^(QAMDFN,TXSPDT)=TXSPD0
12 Q
13EN2 ; *** PARAMETER CODE
14 K DIC,DIR,DIRUT S DIC=743.5,DIC(0)="EMNQZ",DIC("S")="I $P(^QA(743.5,+Y,0),""^"",2)=45.7"
15 S DIC("A")="TREATING SPECIALTY GROUP: ",DIC("B")=$S($D(^QA(743,QAMD0,"COND",QAMD1,"P1"))#2:$P(^("P1"),"^",2),1:"") K:DIC("B")="" DIC("B")
16 S DIR("?",1)="Enter a GROUP name that contains MAS treating specialties,",DIR("?")="or press 'RETURN' for all treating specialties."
17 S QAMPARAM="P1" D EN2^QAMUTL1 I $D(DIRUT) S Y=-1 G Y
18 S:Y]"" ^QA(743,QAMD0,"COND",QAMD1,"P1")=+Y_"^"_Y(0,0)
19EXIT K Y
20 K QAMPARAM,QAMY
21Y Q
Note: See TracBrowser for help on using the repository browser.