source: WorldVistAEHR/trunk/r/AUTOMATED_INFO_COLLECTION_SYS-IBD/IBDFQSL.m@ 1432

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

initial load of WorldVistAEHR

File size: 1.7 KB
RevLine 
[613]1IBDFQSL ;ALB/CJM/AAS/MAF - ENCOUNTER FORM - Quick selection edit ;12-Jun-95
2 ;;3.0;AUTOMATED INFO COLLECTION SYS;;APR 24, 1997
3 ;allows user to select a form, then displays it for edit
4 N IBFORM,ARY,DFN,IBAPPT,RTNLIST,IBPRINT
5 S ARY="^TMP(""IBDF"",$J,""TEMPORARY CLINIC LIST"")"
6 ;
7 K @ARY
8 S VALMBCK=""
9 I $G(IBAPI("SELECT"))'="" X IBAPI("SELECT")
10 K ARY
11 I IBFORM,'$$LOCKFRM2^IBDFU7(IBFORM) D LOCKMSG2^IBDFU7(IBFORM) S IBFORM=""
12 I IBFORM D PRNTPRMS^IBDFU1C(.IBPRINT,0,1,0,1),UNCMPL^IBDF19(IBFORM,0)
13 Q:'$$FORMDSCR^IBDFU1C(.IBFORM)
14EDITBLK ;allows the user to edit everything about the block
15 ;allows user to discard or save changes to the block
16 ;
17 ;If IBBLK and IBBLK2 are used to point to two copies, one copy for editing and the other incase 'undo' is needed
18 ;
19 N IBBLK,IBVALMBG,TOP1,TOP2,BOT1,BOT2,IBBLK2,IBTKODR,IBJUNK,IFSAVE
20 ;
21 S IBVALMBG=VALMBG
22 D FULL^VALM1
23 S IBBLK=$$SLCTBLK^IBDFU8(IBFORM,IOSL,"HEADER") ;select the block
24 I IBBLK S IBLIST=$O(^IBE(357.2,"C",IBBLK,0)) D
25 .I 'IBLIST W !!,"Block does not contain a list! Try Again.",! D PAUSE^IBDFU5 Q
26 .D KILL^IBDFUA
27 .Q:$$BLKDESCR^IBDFU1B(.IBBLK) 1
28 .S (IBBLK2,IBTKODR,IBJUNK)=""
29 .D COPYBLK^IBDF5B(IBBLK,.IBBLK2,.IBBLK,.IBTKODR,.IBJUNK) I 'IBBLK S IBBLK=IBBLK2,IBBLK2="" Q ;sets IBBLK to the work copy, IBBLK2 to the copy actually on the form
30 .D TOPNBOT^IBDFU5(IBBLK,.TOP1,.BOT1)
31 .D EN^IBDFQSL1
32 .I IBBLK,IBBLK2 D
33 ..S IFSAVE=$$ASKSAVE^IBDF5B
34 ..I IFSAVE D SAVECOPY^IBDF5B(.IBBLK,.IBBLK2,IBTKODR) S IBBLK=IBBLK2,IBBLK2="" D BLKCHNG^IBDF19(IBFORM,IBBLK)
35 ..I 'IFSAVE D DLTCOPY^IBDF5B(IBBLK) S IBBLK=IBBLK2,IBBLK2=""
36 ..L -^IBE(357.1,IBBLK):1
37 .I '$G(IBFASTXT) D
38 ..S VALMBG=IBVALMBG
39 ..D TOPNBOT^IBDFU5(IBBLK,.TOP2,.BOT2)
40 ..S TOP1=$S(TOP1<TOP2:TOP1,1:TOP2),BOT1=$S(BOT1>BOT2:BOT1,1:BOT2)
41 S VALMBCK="R"
42 Q
43 ;
Note: See TracBrowser for help on using the repository browser.