Guest User

Untitled

a guest
May 28th, 2018
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.19 KB | None | 0 0
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <action-sequence>
  3. <name>analysis_default.xaction</name>
  4. <title>Analisis Berita</title>
  5. <version>1</version>
  6. <logging-level>DEBUG</logging-level>
  7. <documentation>
  8. <author>Muhammad Ichsan</author>
  9. <help>The following fields need to be set: General Tab Title field is the name that will display when navigating with the Pentaho Solution Browser. (mandatory) Description field is the name that will display in the Pentaho Solution Browser. (mandatory) Visible checkbox set whether this will display in the Pentaho Solution Browser. (optional) Define Process Tab Data Model is the filename of the mondrian schema. This must be named *.mondrian.xml. (mandatory) Data Source is the JNDI connection (server connection contains server, database and userid/password) that the model will use. (mandatory)</help>
  10. <result-type>report</result-type>
  11. <description>This is a template to quickly create an Analysis View in the Pentaho solution repository. All that needs to be set is the data model (mondran schema, *.mondrian.xml) and the JNDI connection that the model will use. For more information, please see the Help field on the General Tab.</description>
  12. <icon>analysis_default.png</icon>
  13. </documentation>
  14.  
  15. <inputs>
  16. <mode type="string">
  17. <default-value/>
  18. <sources>
  19. <request>mode</request>
  20. </sources>
  21. </mode>
  22. <tahunKejadian type="string">
  23. <sources>
  24. <request>tahunKejadian</request>
  25. </sources>
  26. <default-value/>
  27. </tahunKejadian>
  28. <nipPenulis type="string">
  29. <sources>
  30. <request>nipPenulis</request>
  31. </sources>
  32. <default-value/>
  33. </nipPenulis>
  34. <topik type="string">
  35. <sources>
  36. <request>topik</request>
  37. </sources>
  38. <default-value/>
  39. </topik>
  40. <kota type="string">
  41. <sources>
  42. <request>kota</request>
  43. </sources>
  44. <default-value/>
  45. </kota>
  46. <mdx type="string">
  47. <sources>
  48. <request>MDX</request>
  49. </sources>
  50. </mdx>
  51. </inputs>
  52.  
  53. <outputs>
  54. <model type="string"/>
  55. <connection type="string"/>
  56. <mdx type="string"/>
  57. <options type="list"/>
  58. <title type="string"/>
  59. <url type="string">
  60. <destinations>
  61. <response>redirect</response>
  62. </destinations>
  63. </url>
  64. </outputs>
  65.  
  66. <resources/>
  67.  
  68. <actions>
  69. <action-definition>
  70. <component-name>JavascriptRule</component-name>
  71. <action-type>JavaScript</action-type>
  72. <action-inputs>
  73. <tahunKejadian type="string"/>
  74. <nipPenulis type="string"/>
  75. <topik type="string"/>
  76. <kota type="string"/>
  77. </action-inputs>
  78. <action-outputs>
  79. <tahunKejadianSelects type="string"/>
  80. <nipPenulisSelects type="string"/>
  81. <topikSelects type="string"/>
  82. <kotaSelects type="string"/>
  83. </action-outputs>
  84. <component-definition>
  85. <script><![CDATA[function getSelects( baseStr, values ) {
  86. rtnStr = baseStr;
  87. if ( values == null ) {
  88. // Do nothing and the baseStr will be returned
  89. }
  90. else if ( typeof( values ) == "string" ) {
  91. rtnStr += values;
  92. }
  93. else {
  94. rtnStr = baseStr;
  95. if ( (values != null) && (values.length >= 1) ) {
  96. rtnStr += values[0];
  97. for ( i = 1; i < values.length; ++i ) {
  98. rtnStr += ", " + baseStr + values[i];
  99. }
  100. }
  101. }
  102. java.lang.System.out.println( rtnStr );
  103. return( rtnStr );
  104. }
  105.  
  106. tahunKejadianSelects = getSelects( "[Waktu].[Tahun].members", tahunKejadian );
  107. nipPenulisSelects = getSelects( "[Penulis].[Seluruh Penulis]", nipPenulis );
  108. topikSelects = getSelects( "[Topik].[Seluruh Topik]", topik );
  109. kotaSelects = getSelects( "[Lokasi].[Seluruh Lokasi]", kota );]]></script>
  110. </component-definition>
  111. </action-definition>
  112.  
  113. <action-definition>
  114. <component-name>PivotViewComponent</component-name>
  115. <action-type/>
  116. <action-inputs>
  117. <mode type="string"/>
  118. <nipPenulisSelects type="string"/>
  119. <kotaSelects type="string"/>
  120. <topikSelects type="string"/>
  121. <tahunKejadianSelects type="string"/>
  122. </action-inputs>
  123. <action-outputs>
  124. <options type="list"/>
  125. <model type="string"/>
  126. <connection type="string"/>
  127. <mdx type="string"/>
  128. <title type="string"/>
  129. <url type="string"/>
  130. </action-outputs>
  131. <component-definition>
  132. <model><![CDATA[samples/analysis/Berita2kurank.xml]]></model>
  133. <jndi><![CDATA[SampleData]]></jndi>
  134. <viewer><![CDATA[Pivot]]></viewer>
  135. <query><![CDATA[select
  136. NON EMPTY {[Measures].[Jumlah]} ON COLUMNS,
  137. NON EMPTY Crossjoin(
  138. { {tahunKejadianSelects} },
  139. Crossjoin(
  140. { {nipPenulisSelects} },
  141. Crossjoin(
  142. { {topikSelects} }, { {kotaSelects} }
  143. )
  144. )
  145. ) ON ROWS
  146.  
  147. from [Analisis Berita]]]></query>
  148. </component-definition>
  149. </action-definition>
  150.  
  151. </actions>
  152. </action-sequence>
Add Comment
Please, Sign In to add comment