[613] | 1 | OOPSXV27 ;WIOFO/LLH-POST INIT ROUTINE, FILL FIELD 331 ;11/26/04
|
---|
| 2 | ;;2.0;ASISTS;**7**;Jun 03, 2002
|
---|
| 3 | ; Patch 7 - auto populate index "AF" from 1/1/2004 to date
|
---|
| 4 | ;
|
---|
| 5 | ENT ;
|
---|
| 6 | N IEN,FILE,FLD4,FLD88
|
---|
| 7 | S FILE=2260,IEN=0
|
---|
| 8 | D BMES^XPDUTL("Updating new index for OSHA 300 Log for cases created in 2004") H 1
|
---|
| 9 | D MES^XPDUTL(" ")
|
---|
| 10 | S FLD4=3040100
|
---|
| 11 | F S FLD4=$O(^OOPS(FILE,"AD",FLD4)) Q:FLD4'>0 D
|
---|
| 12 | .S IEN=0 F S IEN=$O(^OOPS(FILE,"AD",FLD4,IEN)) Q:IEN'>0 D
|
---|
| 13 | ..S FLD88=$$GET1^DIQ(FILE,IEN,88,"I")
|
---|
| 14 | ..I $G(FLD88)'="" S ^OOPS(FILE,"AF",FLD4,FLD88,IEN)=""
|
---|
| 15 | D BMES^XPDUTL("Update Complete") H 1
|
---|
| 16 | D MES^XPDUTL(" ")
|
---|
| 17 | ;
|
---|
| 18 | ; now update Type of Incident (FILE 2161.2)
|
---|
| 19 | D BMES^XPDUTL("Updating ASISTS CRITICAL TRACKING ISSUES File (#2261.2)") H 1
|
---|
| 20 | D MES^XPDUTL(" ")
|
---|
| 21 | I $P(^OOPS(2261.2,15,0),U)'="Non Patient Care" D Q
|
---|
| 22 | .D BMES^XPDUTL("File not found as expected, update table manually")
|
---|
| 23 | .D MES^XPDUTL(" ")
|
---|
| 24 | I $P(^OOPS(2261.2,15,0),U)="Non Patient Care" D
|
---|
| 25 | .S $P(^OOPS(2261.2,15,0),U)="Lifting (Non Patient Care)"
|
---|
| 26 | .K ^OOPS(2261.2,"B","Non Patient Care",15)
|
---|
| 27 | .S ^OOPS(2261.2,"B","Lifting (Non Patient Care)",15)=""
|
---|
| 28 | .K ^OOPS(2261.2,"D","NON PATIENT CARE",15)
|
---|
| 29 | .S ^OOPS(2261.2,"D","LIFTING (NON PATIENT CARE)",15)=""
|
---|
| 30 | D BMES^XPDUTL("Table Update Complete"),MES^XPDUTL(" ")
|
---|
| 31 | Q
|
---|