cAFA5 ;Standaardfuncties beheer poorten en printers ;%AFA5 [ 06/30/00 3:30 PM ] Q ; AP(DEV) ; aantal locale printers per poort N I,R,UQC,USC,UREF,IREF D DMS^cAN000("UQC","USC","SYS.LP",1) I '$L(UQC)!'$L(USC) G APZ S R="" S UREF=^DMC(UQC,USC,"DATA","REF"),IREF=^("INDEX") S I=DEV_" " F S I=$O(@IREF@(103,I)) Q:$P(I," ")'=DEV I '$$SIG^cAFA1("SYS.LP",^(I),130) S R=R+1 APZ Q $G(R) ; TYPE(K) ; bepalen type poort + ophalen gegevens I '$L(K) S K=3 G TYPEZ ; LPD-printer I $ZV["MSM",K,$D(^|"MGR"|QSYS(0,"DDB",K)),$P(^(K),",")="LPD" S K=3_D_$P($P(^(K),",",2),"^")_D_$P($P(^(K),",",2),"^",2) G TYPEZ ;LPD-printer I $ZV["MSM",K,$D(^|"MGR"|SYS(0,"DDB",K)),$P(^(K),",")="LATP" S K=2 G TYPEZ ;Lat-printer S K=1 ; M-printer (LPT1, PRT, serieel) TYPEZ Q K ; O(RSORT,R,UI1,DUI1) ; wijzigen ^HULP("SORT",RSORT ... in hor. scherm ; RSORT = volgnr ; R = inhoud veld waarmee de sortering opgebouwd wordt ; UI1 = index uit ^DATA of INDEX ; DUI1 = index uit ^DATA ; KU - 03.02.99 (zie PR_LE) ; |- Mag enkel meegegeven worden indien er gelopen wordt op een index- ; bestand en als er een sortering is. ; vb UI1 ="1003 1002 1003" dit is UI1 uit ^INDEX ; DUI1 = $P(UI1," ",2,99) dus 1002 1003 ; bestand en als er een sortering is. S ^HULP("SORT",RSORT,$$DI^cAN000(R,UI1))=$G(DUI1,UI1) OZ Q ; W(RSORT,R,UI1,UI1O) ; wijzigen ^HULP("SORT",RSORT... in hor. scherm ; RSORT = volgnr ; R = inhoud veld waarmee de sortering opgebouwd wordt ; UI1 = intern nummer ^DATA ... ; UI1O = intern nummer ^HULP("SORT",RSORT,... N I S I=^HULP("SORT",RSORT,UI1O) K ^(UI1O) S ^HULP("SORT",RSORT,$$DI^cAN000(R,UI1))=I WZ Q ; V(RSORT,UI1O) ; verwijderen ^HULP("SORT",RSORT ... in hor. scherm ; RSORT = volgnr ; UI1O = intern nummer ^HULP("SORT",RSORT,... K ^HULP("SORT",RSORT,UI1O) VZ Q ; P(UI1,DMS,DMSC) ; toevoegen centrale printer aan ^cPRINT of bestandsloc. aan %LOC ; DMS = DMS van %PRINT of %LOC ; DMSC = DMS van centr. printers of bestandslocaties N UQC,USC,UREF,SW2,SW3,UFU,UQCCP,USCCP,UREFCP,B,EIGC,NUI1 D DMS^cAN000("UQC","USC",DMS,1) I '$L(UQC)!'$L(USC) G PZ S UREF=^DMC(UQC,USC,"DATA","REF"),(SW2,SW3)=1,UFU="O" D DMS^cAN000("UQCCP","USCCP",DMSC,1) I '$L(UQCCP)!'$L(USCCP) G PZ S UREFCP=^DMC(UQCCP,USCCP,"DATA","REF") S B(1)=$G(@UREFCP@(0)) I '$L(B(1)) G PZ S EIGC=$P(B(1),D,11) S $P(B(1),D,11)=EIGC S UI1=1000 F S UI1=$O(@UREF) Q:UI1="" I $P(@UREF@(0),D,3,8)=$P(B(1),D,3,8) S NUI1=UI1 Q I '$G(NUI1) S (NUI1,UI1)=$$NR^cAN000 D U^cAN000 PZ Q $G(NUI1) ; VCOMB(Q,UQA,USA,DMS,UI1O,IND) ; verwijderen combinatie-bestand users en printers N UQC,USC,UREF,IREF,UI1,SW3,UXX,I1,UFU,A,B G VCOMB:$G(USA)="",VCOMBZ:$G(UQA)="" D DMS^cAN000("UQC","USC",DMS) I UQC=""!(USC="") G VCOMBZ S IND=$G(IND,102) S UXX=$G(^DMA(UQA,USA,0,4)) S UREF=$G(^DMC(UQC,USC,"DATA","REF")) Q:'$L(UREF) S IREF=$G(^DMC(UQC,USC,"DATA","INDEX")) Q:'$L(IREF) S I1=UI1O_" ",SW3=1,UFU="V" F S I1=$O(@IREF@(IND,I1)) Q:$P(I1," ")'=UI1O!'$L(I1) D . S UI1=^(I1) . K B D R^cAN000 M A=B . D B^cAN000(130,2) ; set niveau = 2 . I $L($P(UXX,D,2)) X $P(UXX,D,2) . D U^cAN000,K^cAN000 ; effectief verwijderen VCOMBZ Q ; AUSRCP(UI1CP,RSORT,SRT) ; alle gebruikers aan 1 centrale locale ; UI1CP = intern nummer printer ; RSORT = volgnr. sortering in ^HULP ; SRT="CP" indien niet bestaand N UQCU,USCU,UQC,USC,UREFU,UREF S SRT=$G(SRT,"CP") D DMS^cAN000("UQCU","USCU","USR") I '$L(UQCU)!'$L(USCU) G YZ S UREFU=$G(^DMC(UQCU,USCU,"DATA","REF")) I '$L(UREFU) G YZ S UREFU=$P(UREFU,",UI1)")_",UI1USR)" D DMS^cAN000("UQC","USC","USR_SYS."_SRT) S UREF=$G(^DMC(UQC,USC,"DATA","REF")) I '$L(UREF) G YZ S UI1USR=0,CODE=$$SIG^cAFA1("SYS."_SRT,UI1CP,101) D EG^cAFA1 F S UI1USR=$O(@UREFU) Q:UI1USR="" D . I $$SIG^cAFA1("USR",UI1USR,130) Q . S K=$$OCOMB(UQC,USC,UI1USR_" "_UI1CP,UI1USR_D_UI1CP_D_CODE) . I K,$G(RSORT) D O^cAFA5(RSORT,$$SIG^cAFA1("USR",UI1USR,101),UI1USR_" "_UI1CP) D C^cA612 Q ; OCOMB(UQC,USC,UI1,A) ; openen koppelbestand ; UQC koppelbestand ; USC koppelbestand ; UI1 = intern nummer koppelbestand ; A = inhoud (B(1)) N UREF,SW2,SW3,UFU,B,OK S UREF=$G(^DMC(UQC,USC,"DATA","REF")) I '$L(UREF) G OCOMBZ I $D(@UREF) G OCOMBZ S UFU="O",(SW2,SW3)=1,B(1)=A D U^cAN000 OCOMBZ Q $G(OK) ; YZ Q ; ZZ ; 05.02.01 - 16 u 23 * V7.84