source: FOIAVistA/trunk/r/LAB_SERVICE-LR-LS/LRMITSEC.m@ 1590

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

initial load of FOIAVistA 6/30/08 version

File size: 4.0 KB
Line 
1LRMITSEC ;SLC/STAFF - MICRO TREND ENTRY COMPREHENSIVE ;10/19/92 10:08
2 ;;5.2;LAB SERVICE;;Sep 27, 1994
3 ; from LRMITSE
4 ;
5 D COMP K DIC,DIR,LRDN,X,Y
6 Q
7COMP W !!?10,"Criteria for all reports."
8 ; organism type
9 W ! K DIR S DIR(0)="LA^1:5",DIR("A")="Select the numbers: ",DIR("B")="" F LRX="B^1","F^2","M^3","P^4","V^5" I $D(LROTYPE($P(LRX,U))) S DIR("B")=DIR("B")_$P(LRX,U,2)_$S($L($O(LROTYPE(LRX))):",",1:"")
10 K LROTYPE,LRX
11 S DIR("A",1)="Enter the types of organisms used for all reports."
12 S DIR("A",2)="1) Bacteria, 2) Fungus, 3) Mycobacteria, 4) Parasite, 5) Virus"
13 S DIR("?")="Enter numbers for each type of organism to be included on the reports.",DIR("??")=LRHELP
14 S DIR("?",1)="Enter a number, numbers separated by commas, and/or a range of numbers"
15 S DIR("?",2)="ex: 1 or 1,3,5 or 1,3-5 or 1-5"
16 D ^DIR I $D(DIRUT) S LREND=1 Q
17 S:Y[1 LROTYPE("B")="" S:Y[2 LROTYPE("F")="" S:Y[3 LROTYPE("M")="" S:Y[4 LROTYPE("P")="" S:Y[5 LROTYPE("V")=""
18 ; specific organisms
19 W ! K DIR S DIR(0)="Y",DIR("A")="Will all reports be for specific organisms",DIR("B")="NO"
20 S DIR("?")="Enter 'Y'es or 'N'o.",DIR("??")=LRHELP
21 S DIR("?",1)="Do you want all antibiotic trend data for just selected organisms?"
22 S DIR("?",2)="This would apply to all types of reports."
23 D ^DIR I $D(DIRUT) S LREND=1 Q
24 I Y=1 D Q:LREND
25 .K DIC S DIC=61.2,DIC(0)="AEMOQZ",DIC("A")="Select Organism: ",DIC("S")="I $L($P(^(0),U,5)),$D(LROTYPE($P(^(0),U,5)))"
26 .K LRM("O"),LRSORG F D ^DIC Q:Y<1 S LRM("O","S",+Y)=$P(Y,U,2),LRSORG($P(Y(0),U,5),+Y)=""
27 .I $D(DTOUT) S LREND=1
28 ; length of stay
29 W ! K DIR S DIR(0)="NA^0:30",DIR("A")="Enter length of stay (days): ",DIR("B")=LRLOS
30 S DIR("A",1)="Number of days from patient's admission date to collection date of specimen"
31 S DIR("A",2)="to be excluded from all reports."
32 S DIR("?")="Enter the number of days.",DIR("??")=LRHELP
33 S DIR("?",1)="Collections taken before this many days from admission would be excluded."
34 S DIR("?",2)="Outpatients would also be excluded."
35 D ^DIR I $D(DIRUT) S LREND=1 Q
36 S LRLOS=Y
37 ; antibiotic pattern
38 I $D(LROTYPE("B")) D Q:LREND
39 .W ! K DIR,LRAP S DIR(0)="Y",DIR("A")="Will all reports require a specific antibiotic pattern",DIR("B")="NO"
40 .S DIR("?")="Enter 'Y'es or 'N'o.",DIR("??")=LRHELP
41 .S DIR("?",1)="You may restrict all reports to only those that have specific antibiotic"
42 .S DIR("?",2)="interpretations."
43 .D ^DIR I $D(DIRUT) S LREND=1 Q
44 .I Y=1 D Q:LREND
45 ..K DIC S DIC=62.06,DIC(0)="AEMOQZ",DIC("A")="Select Antibiotic: ",DIC("S")="I +$P(^(0),U,2),$L($P(^(0),U,5))"
46 ..F D ^DIC Q:Y<1 S LRDN=$P(Y(0),U,2) D Q:LREND
47 ...K DIR S DIR(0)="SAM^S:Susceptible;R:Resistant",DIR("A")="Select Interpretation: "
48 ...S DIR("?")="Enter 'S' or 'R'.",DIR("??")=LRHELP
49 ...S DIR("?",1)="Interpretations are evaluated as only S or R."
50 ...S DIR("?",2)="Interpretations of 'I' are counted as 'R'."
51 ...S DIR("?",3)="Interpretations of 'MS' are counted as 'S'."
52 ...D ^DIR I $D(DIRUT) S LREND=1 Q
53 ...S LRAP(LRDN)=Y
54 ..I $D(DTOUT) S LREND=1
55 ; merge criteria
56 S:'$D(LROTYPE("B")) LRMERGE="N" I $D(LROTYPE("B")) D Q:LREND
57 .W !!,"Merge criteria for all reports."
58 .K DIR S DIR(0)="SAM^N:No Merge;S:Specimen;C:Collection sample;A:Any sample",DIR("A")="(N)o merge, (S)pecimen, (C)ollection sample, or (A)ny sample: ",DIR("B")=LRMERGE
59 .S DIR("?")="Enter 'N'o merge, 'S'pecimen, 'C'olection sample, or 'A'ny sample.",DIR("??")=LRHELP
60 .S DIR("?",1)="Isolates from the same patient of the same organism can be merged."
61 .S DIR("?",2)="Merged isolates are only counted once."
62 .D ^DIR I $D(DIRUT) S LREND=1 Q
63 .S LRMERGE=Y
64 ; detailed report
65 W ! K DIR S DIR(0)="Y",DIR("A")="Include detailed patient results on all reports",DIR("B")=$S(LRDETAIL:"YES",1:"NO")
66 S DIR("?")="Enter 'Y'es or 'N'o.",DIR("??")=LRHELP
67 S DIR("?",1)="A detailed report includes specific information on all isolates."
68 S DIR("?",2)="It can be useful in confirming the counts on the trend report."
69 S DIR("?",3)="This printout is much longer than the usual report."
70 D ^DIR I $D(DIRUT) S LREND=1 Q
71 S LRDETAIL=$S(Y:1,1:0)
72 Q
Note: See TracBrowser for help on using the repository browser.