Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.
 
 
 
 
 
 

185 рядки
8.3 KiB

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  6. <title>Creating Reports &mdash; Documentation</title>
  7. <link rel="stylesheet" href="_static/sphinxdoc.css" type="text/css" />
  8. <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
  9. <script type="text/javascript">
  10. var DOCUMENTATION_OPTIONS = {
  11. URL_ROOT: '',
  12. VERSION: '',
  13. COLLAPSE_MODINDEX: false,
  14. FILE_SUFFIX: '.html',
  15. HAS_SOURCE: true
  16. };
  17. </script>
  18. <script type="text/javascript" src="_static/jquery.js"></script>
  19. <script type="text/javascript" src="_static/doctools.js"></script>
  20. <link rel="top" title="Documentation" href="index.html" />
  21. <link rel="up" title="2. Building an Application" href="build_app.html" />
  22. <link rel="next" title="3. Server Side API" href="server_side_api.html" />
  23. <link rel="prev" title="Creating Pages" href="creating_pages.html" />
  24. </head>
  25. <body>
  26. <div style="background-color: #FFF; text-align: left; padding: 8px 0px"><img src="_static/banner300910.gif"></div>
  27. <div class="related">
  28. <h3>Navigation</h3>
  29. <ul>
  30. <li class="right" style="margin-right: 10px">
  31. <a href="genindex.html" title="General Index"
  32. accesskey="I">index</a></li>
  33. <li class="right" >
  34. <a href="modindex.html" title="Global Module Index"
  35. accesskey="M">modules</a> |</li>
  36. <li class="right" >
  37. <a href="server_side_api.html" title="3. Server Side API"
  38. accesskey="N">next</a> |</li>
  39. <li class="right" >
  40. <a href="creating_pages.html" title="Creating Pages"
  41. accesskey="P">previous</a> |</li>
  42. <li><a href="index.html">Documentation</a> &raquo;</li>
  43. <li><a href="build_app.html" accesskey="U">2. Building an Application</a> &raquo;</li>
  44. </ul>
  45. </div>
  46. <div class="sphinxsidebar">
  47. <div class="sphinxsidebarwrapper">
  48. <h3><a href="index.html">Table Of Contents</a></h3>
  49. <ul>
  50. <li><a class="reference external" href="">Creating Reports</a><ul>
  51. <li><a class="reference external" href="#filters">Filters</a></li>
  52. <li><a class="reference external" href="#saving-a-report">Saving a Report</a></li>
  53. <li><a class="reference external" href="#seeing-the-query">Seeing the Query</a></li>
  54. <li><a class="reference external" href="#adding-joins">Adding Joins</a></li>
  55. <li><a class="reference external" href="#over-riding-the-query">Over-riding the query</a></li>
  56. <li><a class="reference external" href="#adding-scripts">Adding Scripts</a></li>
  57. </ul>
  58. </li>
  59. </ul>
  60. <h4>Previous topic</h4>
  61. <p class="topless"><a href="creating_pages.html"
  62. title="previous chapter">Creating Pages</a></p>
  63. <h4>Next topic</h4>
  64. <p class="topless"><a href="server_side_api.html"
  65. title="next chapter">3. Server Side API</a></p>
  66. <h3>This Page</h3>
  67. <ul class="this-page-menu">
  68. <li><a href="_sources/creating_reports.txt"
  69. rel="nofollow">Show Source</a></li>
  70. </ul>
  71. <div id="searchbox" style="display: none">
  72. <h3>Quick search</h3>
  73. <form class="search" action="search.html" method="get">
  74. <input type="text" name="q" size="18" />
  75. <input type="submit" value="Go" />
  76. <input type="hidden" name="check_keywords" value="yes" />
  77. <input type="hidden" name="area" value="default" />
  78. </form>
  79. <p class="searchtip" style="font-size: 90%">
  80. Enter search terms or a module, class or function name.
  81. </p>
  82. </div>
  83. <script type="text/javascript">$('#searchbox').show(0);</script>
  84. </div>
  85. </div>
  86. <div class="document">
  87. <div class="documentwrapper">
  88. <div class="bodywrapper">
  89. <div class="body">
  90. <div class="section" id="creating-reports">
  91. <h1>Creating Reports<a class="headerlink" href="#creating-reports" title="Permalink to this headline">¶</a></h1>
  92. <p>Reports can be created and saved using the Report Builder. A report is saved in a record of type
  93. &#8220;Search Criteria&#8221;</p>
  94. <p>A Report is a SQL query that runs on the server side. The report builder builds the SQL query:</p>
  95. <ul class="simple">
  96. <li>Column selector</li>
  97. <li>Filters</li>
  98. <li>Sorting</li>
  99. </ul>
  100. <p>Using the Search Criteria you can customize this query by adding</p>
  101. <ul class="simple">
  102. <li>more tables</li>
  103. <li>more conditions</li>
  104. <li>post-processing server side code</li>
  105. <li>styling the report with HTML by setting color etc.</li>
  106. </ul>
  107. <div class="section" id="filters">
  108. <h2>Filters<a class="headerlink" href="#filters" title="Permalink to this headline">¶</a></h2>
  109. <p>Filters appear in the report on fields where &#8220;In Filter&#8221; is checked in DocType</p>
  110. </div>
  111. <div class="section" id="saving-a-report">
  112. <h2>Saving a Report<a class="headerlink" href="#saving-a-report" title="Permalink to this headline">¶</a></h2>
  113. <p>Once you have selected the columns, you can save the report by the &#8220;Save&#8221; button on the toolbar. After saving
  114. you can open the &#8220;Search Criteria&#8221; record by the &#8220;Advanced&#8221; button.</p>
  115. <p>In the Search Criteria, you can customize various parts of the report by setting the fields</p>
  116. </div>
  117. <div class="section" id="seeing-the-query">
  118. <h2>Seeing the Query<a class="headerlink" href="#seeing-the-query" title="Permalink to this headline">¶</a></h2>
  119. <p>To see the query that has been generated, check the &#8220;Show Query&#8221; check box at the bottom of the &#8220;Result&#8221;
  120. section.</p>
  121. </div>
  122. <div class="section" id="adding-joins">
  123. <h2>Adding Joins<a class="headerlink" href="#adding-joins" title="Permalink to this headline">¶</a></h2>
  124. <p>If you want to join the selected table with another table, then you can add the table in the &#8220;Additional
  125. Tables&#8221; field. Note all tables in the database are named as &#8220;tab&#8221; + DocType name</p>
  126. <div class="admonition note">
  127. <p class="first admonition-title">Note</p>
  128. <p class="last">Whenever you add tables, conditions, use the standard way of naming the fields as <cite>tablename</cite>.`fieldname`</p>
  129. </div>
  130. </div>
  131. <div class="section" id="over-riding-the-query">
  132. <h2>Over-riding the query<a class="headerlink" href="#over-riding-the-query" title="Permalink to this headline">¶</a></h2>
  133. <p>You can completely customize a query using the Override field. Note, when you write a query it has to be in
  134. the <a class="reference external" href="glossary.html#term-standard-query"><em class="xref">Standard Query</em></a> format.</p>
  135. </div>
  136. <div class="section" id="adding-scripts">
  137. <h2>Adding Scripts<a class="headerlink" href="#adding-scripts" title="Permalink to this headline">¶</a></h2>
  138. <p>Using scripts, you can:</p>
  139. <ol class="arabic simple">
  140. <li>Add / remove filters</li>
  141. <li>Add columns (for example row totals)</li>
  142. <li>Add rows (for example column totals)</li>
  143. <li>Modify values</li>
  144. <li>Get values from other tables etc</li>
  145. <li>Add color to the values (from client side)</li>
  146. </ol>
  147. </div>
  148. </div>
  149. </div>
  150. </div>
  151. </div>
  152. <div class="clearer"></div>
  153. </div>
  154. <div class="related">
  155. <h3>Navigation</h3>
  156. <ul>
  157. <li class="right" style="margin-right: 10px">
  158. <a href="genindex.html" title="General Index"
  159. >index</a></li>
  160. <li class="right" >
  161. <a href="modindex.html" title="Global Module Index"
  162. >modules</a> |</li>
  163. <li class="right" >
  164. <a href="server_side_api.html" title="3. Server Side API"
  165. >next</a> |</li>
  166. <li class="right" >
  167. <a href="creating_pages.html" title="Creating Pages"
  168. >previous</a> |</li>
  169. <li><a href="index.html">Documentation</a> &raquo;</li>
  170. <li><a href="build_app.html" >2. Building an Application</a> &raquo;</li>
  171. </ul>
  172. </div>
  173. <div class="footer">
  174. &copy; Copyright 2010, Rushabh Mehta.
  175. Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.3.
  176. </div>
  177. </body>
  178. </html>