BurstActionSequence.xaction 5.95 KB
Newer Older
Thitichaipun Wutthisak committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177
<?xml version="1.0" encoding="UTF-8"?>
<action-sequence> 
  <title>%title</title>
  <version>1</version>
  <logging-level>DEBUG</logging-level>
  <documentation> 
    <author>Doug Moran</author>  
    <description>%description</description>  
    <help/>  
    <result-type>email</result-type>  
    <icon>BurstActionSequence.png</icon> 
  </documentation>

  <inputs> 
    <output-type type="string"> 
      <default-value>xls</default-value> 
    </output-type>  
    <print-prefix type="string"> 
      <default-value>Generating</default-value> 
    </print-prefix> 
  </inputs>

  <outputs/>

  <resources> 
    <report-definition> 
      <solution-file> 
        <location>JFreeQuadrantForRegion.xml</location>  
        <mime-type>text/xml</mime-type> 
      </solution-file> 
    </report-definition> 
  </resources>
  
  <actions> 
    <action-definition> 
      <component-name>SQLLookupRule</component-name>
      <action-type>Query For Manager Information</action-type>
      <action-outputs> 
        <query-result type="result-set" mapping="burst-data"/>  
        <REGION type="string"/>  
        <EMAIL type="string"/>  
        <MANAGER_NAME type="string"/> 
      </action-outputs>
      <component-definition> 
        <jndi>SampleData</jndi>  
        <query><![CDATA[select distinct REGION, MANAGER_NAME, EMAIL from DEPARTMENT_MANAGERS]]></query> 
      </component-definition> 
    </action-definition>
  
    <actions loop-on="burst-data"> 
      <action-definition> 
        <component-name>UtilityComponent</component-name>
        <action-type>Format The Email Attach Name</action-type>
        <action-inputs> 
          <REGION type="string"/>  
          <output-type type="string"/> 
        </action-inputs>
        <action-outputs> 
          <formatted_msg type="string" mapping="attach-name"/> 
        </action-outputs>
        <component-definition> 
          <format> 
            <format-string>%filename-msg</format-string>  
            <return>formatted_msg</return>  
            <arg>REGION</arg>  
            <arg>output-type</arg> 
          </format> 
        </component-definition> 
      </action-definition>
  
      <action-definition> 
        <component-name>UtilityComponent</component-name>
        <action-type>Format The Email Subject</action-type>
        <action-inputs> 
          <REGION type="string"/> 
        </action-inputs>
        <action-outputs> 
          <formatted_msg type="string" mapping="subject"/> 
        </action-outputs>
        <component-definition> 
          <format> 
            <format-string>%subject-msg</format-string>  
            <arg>REGION</arg>  
            <return>formatted_msg</return> 
          </format> 
        </component-definition> 
      </action-definition>
  
      <action-definition> 
        <component-name>UtilityComponent</component-name>
        <action-type>Format The Email Msg</action-type>
        <action-inputs> 
          <MANAGER_NAME type="string"/>  
          <subject type="string"/> 
        </action-inputs>
        <action-outputs> 
          <formatted_msg type="string" mapping="message-html"/> 
        </action-outputs>
        <component-definition> 
          <format> 
            <format-string>%message-msg</format-string>  
            <arg>MANAGER_NAME</arg>  
            <arg>subject</arg>  
            <return>formatted_msg</return> 
          </format> 
        </component-definition> 
      </action-definition>
  
      <action-definition> 
        <component-name>UtilityComponent</component-name>
        <action-type>Print Parameters</action-type>
        <action-inputs> 
          <print-prefix type="string"/>  
          <subject type="string"/>  
          <MANAGER_NAME type="string"/> 
        </action-inputs>
        <component-definition> 
          <print> 
            <delimiter>" - "</delimiter>  
            <arg>print-prefix</arg>  
            <arg>subject</arg>  
            <arg>MANAGER_NAME</arg> 
          </print> 
        </component-definition> 
      </action-definition>
  
      <action-definition> 
        <component-name>SQLLookupRule</component-name>
        <action-type>Query For Report Data</action-type>
        <action-inputs> 
          <REGION type="string"/> 
        </action-inputs>
        <action-outputs> 
          <query-result type="result-set" mapping="reportData"/> 
        </action-outputs>
        <component-definition> 
          <jndi>SampleData</jndi>  
          <live>true</live>  
          <query><![CDATA[select   QUADRANT_ACTUALS.REGION,   QUADRANT_ACTUALS.DEPARTMENT,   QUADRANT_ACTUALS.POSITIONTITLE,   QUADRANT_ACTUALS.ACTUAL,   QUADRANT_ACTUALS.BUDGET,   QUADRANT_ACTUALS.VARIANCE  from QUADRANT_ACTUALS where QUADRANT_ACTUALS.REGION={PREPARE:REGION} order by QUADRANT_ACTUALS.REGION, QUADRANT_ACTUALS.DEPARTMENT]]></query> 
        </component-definition> 
      </action-definition>
  
      <action-definition> 
        <component-name>JFreeReportComponent</component-name>
        <action-type>Create The Report</action-type>
        <action-inputs> 
          <data type="result-set" mapping="reportData"/>  
          <output-type type="string"/> 
        </action-inputs>
        <action-resources> 
          <report-definition type="resource"/> 
        </action-resources>
        <action-outputs> 
          <report-output type="content" mapping="reportOutput"/> 
        </action-outputs>
        <component-definition/> 
      </action-definition>
  
      <action-definition> 
        <component-name>EmailComponent</component-name>
        <action-type>Email</action-type>
        <action-inputs> 
          <subject type="string"/>  
          <message-html type="string"/>  
          <to type="string" mapping="EMAIL"/>  
          <attach-name type="string"/>  
          <reportOutput type="content"/>
        </action-inputs>
        <component-definition>
          <attachment-ref name-param="attach-name" input-param="reportOutput"/>
        </component-definition> 
      </action-definition>
 
    </actions>
 
  </actions> 
</action-sequence>