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

AQAOQT13.m

Go to the documentation of this file.
AQAOQT13 ; IHS/ORDC/LJF - BRAINSTORMING REPORTS SUBRTNS ;
 ;;1.01;QAI MANAGEMENT;;OCT 05, 1995
 ;
 ;This rtn contains entry points for the reports function.
 ;
RESULTS ;ENTRY POINT >> SUBRTN to print multivoting results <<
 ;called by AQAOQT1
 D INIT^AQAOUTIL
 S AQAORNG=$P(^AQAO1(8,AQAOMTG,0),U,2),AQAORNG=$P(^AQAO1(1,AQAORNG,0),U)
 S Y=$P(^AQAO1(8,AQAOMTG,0),U) X ^DD("DD") S AQAORNG=AQAORNG_" - "_Y
 S AQAOTY="MULTIVOTING RESULTS FOR "_$P(^AQAO1(8,AQAOMTG,0),U,3)
 D HEADING^AQAOUTIL W ?AQAOIOMX-$L(AQAORNG)/2,AQAORNG,!,AQAOLINE,!
 ;
 ; >> gather results
LOOP S AQAOY=0 K AQAOCNT
 F  S AQAOY=$O(^AQAO1(7,"AC",AQAOMTG,AQAOY)) Q:AQAOY=""  D
 .Q:'$O(^AQAO1(7,AQAOY,"MV",0))  S X=^AQAO1(7,AQAOY,0)
 .S AQAOCAT=$S($P(X,U,3)]"":$P(X,U,3),1:$P(X,U))
 .S AQAOX=0
 .F  S AQAOX=$O(^AQAO1(7,AQAOY,"MV",AQAOX)) Q:AQAOX'=+AQAOX  D
 ..Q:'$D(^AQAO1(7,AQAOY,"MV",AQAOX,0))  S AQAOS=^(0)
 ..S AQAOUSN=$P(AQAOS,U) ;voter name
 ..S AQAOCNT(AQAOCAT)=$G(AQAOCNT(AQAOCAT))+$P(AQAOS,U,2) ;total count
 ..S AQAOCNT(AQAOCAT,AQAOUSN)=$P(AQAOS,U,2) ;count by voter
 ;
 ; >> print results
 S AQAOCAT=0
 F  S AQAOCAT=$O(AQAOCNT(AQAOCAT)) Q:AQAOCAT=""  Q:AQAOSTOP=U  D
 .W !!,AQAOCAT
 .S AQAOUSN=0 F  S AQAOUSN=$O(AQAOCNT(AQAOCAT,AQAOUSN)) Q:AQAOUSN=""  D
 ..W !?15,AQAOUSN,?55,$J(AQAOCNT(AQAOCAT,AQAOUSN),3)
 ..I $Y>(IOSL-4) D
 ...D NEWPG^AQAOUTIL Q:AQAOSTOP=U
 ...W ?AQAOIOMX-$L(AQAORNG)/2,AQAORNG,!,AQAOLINE,!
 .W !?55,"______",!?55,$J(AQAOCNT(AQAOCAT),3)
 I IOST["C-" D
 .W ! K DIR S DIR(0)="E"
 .S DIR("A")="Press RETURN when ready to continue" D ^DIR
 D ^%ZISC I $D(ZTQUEUED) D KILL^AQAOUTIL
 Q
 ; >> END OF RESULTS SUBRTN <<
 ;
 ;
FULL ;ENTRY POINT >> SUBRTN to print full report <<
 ;called by AQAOQT1
 D INIT^AQAOUTIL
 S AQAORNG=$P(^AQAO1(8,AQAOMTG,0),U,2),AQAORNG=$P(^AQAO1(1,AQAORNG,0),U)
 S Y=$P(^AQAO1(8,AQAOMTG,0),U) X ^DD("DD") S AQAORNG=AQAORNG_" - "_Y
 S AQAOTY="BRAINSTORMING REPORT FOR "_$P(^AQAO1(8,AQAOMTG,0),U,3)
 D HEADING^AQAOUTIL W ?AQAOIOMX-$L(AQAORNG)/2,AQAORNG,!,AQAOLINE,!
 ;
 W !,"MINUTES: " K ^UTILITY("DIQ1",$J)
 S DIC=9002169.8,DR="1",DA=AQAOMTG D EN^DIQ1
 K ^UTILITY($J,"W") S AQAOX=0
 F  S AQAOX=$O(^UTILITY("DIQ1",$J,9002169.8,AQAOMTG,1,AQAOX)) Q:AQAOX=""  D
 .S X=^UTILITY("DIQ1",$J,9002169.8,AQAOMTG,1,AQAOX)
 .S DIWL=10,DIWR=75,DIWF="WB4" D ^DIWP
 D ^DIWW
 ;
 I $Y>(IOSL-4) D  Q:AQAOSTOP=U
 .D NEWPG^AQAOUTIL Q:AQAOSTOP=U
 .W ?AQAOIOMX-$L(AQAORNG)/2,AQAORNG,!,AQAOLINE,!
 W !!,"MEMBERS IN ATTENDANCE:  " S AQAOX=0
 F  S AQAOX=$O(^AQAO1(8,AQAOMTG,"MEM",AQAOX)) Q:AQAOX'=+AQAOX  Q:AQAOSTOP=U  D
 .Q:'$D(^AQAO1(8,AQAOMTG,"MEM",AQAOX,0))  S AQAOS=^(0)
 .W ?25,$P(^VA(200,+AQAOS,0),U) S X=$P(AQAOS,U,2)
 .W ?55,$S(X="L":"LEADER",X="F":"FACILITATOR",1:"MEMBER"),!
 .I $Y>(IOSL-4) D
 ..D NEWPG^AQAOUTIL Q:AQAOSTOP=U
 ..W ?AQAOIOMX-$L(AQAORNG)/2,AQAORNG,!,AQAOLINE,!
 ;
 W !!,"BRAINSTORMING IDEAS AND CATEGORIES:"
 S AQAOX=0
MORE F  S AQAOX=$O(^AQAO1(7,"AC",AQAOMTG,AQAOX)) Q:AQAOX=""  Q:AQAOSTOP=U  D
 .W !?5,$P(^AQAO1(7,AQAOX,0),U),?40,$P(^(0),U,3)
 .I $Y>(IOSL-4) D
 ..D NEWPG^AQAOUTIL Q:AQAOSTOP=U
 ..W ?AQAOIOMX-$L(AQAORNG)/2,AQAORNG,!,AQAOLINE,!
 ;
 W !!,"MULTIVOTING RESULTS:"
 D LOOP ;print multivoting results
 D ^%ZISC I $D(ZTQUEUED) D KILL^AQAOUTIL
 Q
 ; >> END OF FULL SUBRTN <<