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

GMTSP125.m

Go to the documentation of this file.
  1. GMTSP125 ; CIO/SLC - Post Install GMTS*2.7*125 ;Mar 07, 2019@10:53:03
  1. ;;2.7;Health Summary;**125**;Oct 20, 1995;Build 15
  1. Q
  1. CI ; Component Install
  1. N GMTSIN,GMTSLIM,GMTSINST,GMTSTL,GMTSINST,GMTSTOT,GMTSBLD,GMTSCPS,GMTSCP,GMTSCI
  1. S GMTSCPS="RXDC;RXOI"
  1. F GMTSCI=1:1 Q:'$L($P(GMTSCPS,";",GMTSCI)) D
  1. . S GMTSCP=$P(GMTSCPS,";",GMTSCI) K GMTSIN
  1. . D ARRAY Q:'$D(GMTSIN)
  1. . I $L($G(GMTSIN("TIM"))),+($G(GMTSIN(0)))>0 S GMTSLIM(+($G(GMTSIN(0))),"TIM")=$G(GMTSIN("TIM"))
  1. . I $L($G(GMTSIN("OCC"))),+($G(GMTSIN(0)))>0 S GMTSLIM(+($G(GMTSIN(0))),"OCC")=$G(GMTSIN("OCC"))
  1. . S GMTSINST=$$ADD^GMTSXPD1(.GMTSIN),GMTSTOT=+($G(GMTSTOT))+($G(GMTSINST))
  1. ; Rebuild Ad Hoc Health Summary Type
  1. D:+($G(GMTSTOT))>0 BUILD^GMTSXPD3
  1. D LIM
  1. I +$$ROK("GMTSXPS1")>0 D
  1. . N GMTSHORT S GMTSHORT=1,GMTSINST="",GMTSBLD="GMTS*2.7*125" D SEND^GMTSXPS1
  1. Q
  1. ARRAY ; Build Array
  1. K GMTSIN N GMTSI,GMTSTXT,GMTSEX,GMTSFLD,GMTSUB,GMTSVAL,GMTSPDX S GMTSPDX=1,GMTSCP=$G(GMTSCP) Q:'$L(GMTSCP)
  1. F GMTSI=1:1 D Q:'$L(GMTSTXT)
  1. . S GMTSTXT="",GMTSEX="S GMTSTXT=$T("_GMTSCP_"+"_GMTSI_")" X GMTSEX S:$L(GMTSTXT,";")'>3 GMTSTXT="" Q:'$L(GMTSTXT)
  1. . S GMTSFLD=$P(GMTSTXT,";",2),GMTSUB=$P(GMTSTXT,";",3),GMTSVAL=$P(GMTSTXT,";",4)
  1. . S:$E(GMTSFLD,1)=1&(+GMTSFLD<2) GMTSVAL=$P(GMTSTXT,";",4,5)
  1. . S:$E(GMTSFLD,1)=" "!('$L(GMTSFLD)) GMTSTXT="" Q:GMTSTXT=""
  1. . S:$L(GMTSFLD)&('$L(GMTSUB)) GMTSIN(GMTSFLD)=GMTSVAL Q:$L(GMTSFLD)&('$L(GMTSUB)) S:$L(GMTSFLD)&($L(GMTSUB)) GMTSIN(GMTSFLD,GMTSUB)=GMTSVAL
  1. . S:$G(GMTSFLD)=7&(+($G(GMTSUB))>0) GMTSPDX=0
  1. K:+($G(GMTSPDX))=0 GMTSIN("PDX")
  1. Q
  1. LIM ; Limits
  1. N GMTSI,GMTST,GMTSO,GMTSA S GMTSI=0 F S GMTSI=$O(GMTSLIM(GMTSI)) Q:+GMTSI=0 D
  1. . S GMTSA=$P($G(^GMT(142.1,+($G(GMTSI)),0)),"^",3),GMTST=$G(GMTSLIM(+GMTSI,"TIM")) S:'$L(GMTST) GMTST=$S(GMTSA="Y ":"1Y ",1:"")
  1. . S GMTSA=$P($G(^GMT(142.1,+($G(GMTSI)),0)),"^",5),GMTSO=$G(GMTSLIM(+GMTSI,"OCC")) S:'$L(GMTSO) GMTSO=$S(GMTSA="Y ":"10 ",1:"")
  1. . D TO^GMTSXPD3(GMTSI,GMTST,GMTSO)
  1. Q
  1. ROK(X) ; Routine OK
  1. S X=$G(X) Q:'$L(X) 0 N GMTSEX,GMTSTXT S GMTSEX="S GMTSTXT=$T(+1^"_X_")" X GMTSEX
  1. Q:'$L(GMTSTXT) 0 Q 1
  1. ;
  1. RXDC ; Meds OP/Drug Class Component Data
  1. ;0;;269
  1. ;.01;;Meds OP/Drug Class
  1. ;1;;MAIN;GMTSPSO8
  1. ;1.1;;0
  1. ;2;;Y
  1. ;3;;RXDC
  1. ;3.5;;13
  1. ;3.5;1;This component contains information from the Outpatient Pharmacy package.
  1. ;3.5;2;It allows selection of prescriptions to display, based on the drug class.
  1. ;3.5;3;Only 'child' classes are displayed, with the exception of the HA000 class.
  1. ;3.5;4;
  1. ;3.5;5;Only time limits apply. Data presented include: drug, prescription number,
  1. ;3.5;6;status expiration/cancellation date (when appropriate), quantity, issue
  1. ;3.5;7;date, last fill date, refills remaining, provider, and cost/fill (when
  1. ;3.5;8;available).
  1. ;3.5;9;
  1. ;3.5;10;Note: If no time limit is defined, only active outpatient orders are
  1. ;3.5;11;reported. If a time limit is defined, all outpatient pharmacy orders which
  1. ;3.5;12;have an expiration or cancel date within the time limit range are
  1. ;3.5;13;reported.
  1. ;4;;
  1. ;5;;
  1. ;6;;
  1. ;7;;1
  1. ;7;1;50.605
  1. ;8;;
  1. ;9;;Meds OP/Drug Class
  1. ;10;;
  1. ;11;;
  1. ;12;;
  1. ;13;;
  1. ;14;;
  1. ;TIM;;1Y
  1. ;
  1. Q
  1. ;
  1. RXOI ; Meds OP/Rx Ord Item Component Data
  1. ;0;;270
  1. ;.01;;Meds OP/Rx Ord Item
  1. ;1;;MAIN;GMTSPSO9
  1. ;1.1;;0
  1. ;2;;Y
  1. ;3;;RXOI
  1. ;3.5;;13
  1. ;3.5;1;This component contains information from the Outpatient Pharmacy package.
  1. ;3.5;2;It allows selection of prescriptions to display, based on the Pharmacy
  1. ;3.5;3;orderable item associated with the order.
  1. ;3.5;4;
  1. ;3.5;5;Only time limits apply. Data presented include: drug, prescription number,
  1. ;3.5;6;status expiration/cancellation date (when appropriate), quantity, issue
  1. ;3.5;7;date, last fill date, refills remaining, provider, and cost/fill (when
  1. ;3.5;8;available).
  1. ;3.5;9;
  1. ;3.5;10;Note: If no time limit is defined, only active outpatient orders are
  1. ;3.5;11;reported. If a time limit is defined, all outpatient pharmacy orders which
  1. ;3.5;12;have an expiration or cancel date within the time limit range are
  1. ;3.5;13;reported.
  1. ;4;;
  1. ;5;;
  1. ;6;;
  1. ;7;;1
  1. ;7;1;50.7
  1. ;8;;
  1. ;9;;Meds OP/Rx Ord Item
  1. ;10;;
  1. ;11;;
  1. ;12;;
  1. ;13;;
  1. ;14;;
  1. ;TIM;;1Y
  1. ;
  1. Q
  1. ;