選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。
 
 
 
 
 
 

730 行
60 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>widgets Package &mdash; WNFramework v1.8 documentation</title>
  7. <link rel="stylesheet" href="_static/default.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: '1.8',
  13. COLLAPSE_INDEX: 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/underscore.js"></script>
  20. <script type="text/javascript" src="_static/doctools.js"></script>
  21. <link rel="top" title="WNFramework v1.8 documentation" href="index.html" />
  22. </head>
  23. <body>
  24. <div class="related">
  25. <h3>Navigation</h3>
  26. <ul>
  27. <li class="right" style="margin-right: 10px">
  28. <a href="genindex.html" title="General Index"
  29. accesskey="I">index</a></li>
  30. <li class="right" >
  31. <a href="py-modindex.html" title="Python Module Index"
  32. >modules</a> |</li>
  33. <li><a href="index.html">WNFramework v1.8 documentation</a> &raquo;</li>
  34. </ul>
  35. </div>
  36. <div class="document">
  37. <div class="documentwrapper">
  38. <div class="bodywrapper">
  39. <div class="body">
  40. <div class="section" id="widgets-package">
  41. <h1>widgets Package<a class="headerlink" href="#widgets-package" title="Permalink to this headline">¶</a></h1>
  42. <div class="section" id="module-webnotes.widgets.auto_master">
  43. <span id="auto-master-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">auto_master</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.auto_master" title="Permalink to this headline">¶</a></h2>
  44. <dl class="function">
  45. <dt id="webnotes.widgets.auto_master.add_to_master">
  46. <tt class="descclassname">webnotes.widgets.auto_master.</tt><tt class="descname">add_to_master</tt><big>(</big><em>fieldname</em>, <em>value</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/auto_master.html#add_to_master"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.auto_master.add_to_master" title="Permalink to this definition">¶</a></dt>
  47. <dd></dd></dl>
  48. <dl class="function">
  49. <dt id="webnotes.widgets.auto_master.create_auto_masters">
  50. <tt class="descclassname">webnotes.widgets.auto_master.</tt><tt class="descname">create_auto_masters</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/auto_master.html#create_auto_masters"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.auto_master.create_auto_masters" title="Permalink to this definition">¶</a></dt>
  51. <dd></dd></dl>
  52. <dl class="function">
  53. <dt id="webnotes.widgets.auto_master.get_master_fields">
  54. <tt class="descclassname">webnotes.widgets.auto_master.</tt><tt class="descname">get_master_fields</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/auto_master.html#get_master_fields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.auto_master.get_master_fields" title="Permalink to this definition">¶</a></dt>
  55. <dd></dd></dl>
  56. <dl class="function">
  57. <dt id="webnotes.widgets.auto_master.make_auto_master">
  58. <tt class="descclassname">webnotes.widgets.auto_master.</tt><tt class="descname">make_auto_master</tt><big>(</big><em>fieldname</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/auto_master.html#make_auto_master"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.auto_master.make_auto_master" title="Permalink to this definition">¶</a></dt>
  59. <dd></dd></dl>
  60. <dl class="function">
  61. <dt id="webnotes.widgets.auto_master.update_auto_masters">
  62. <tt class="descclassname">webnotes.widgets.auto_master.</tt><tt class="descname">update_auto_masters</tt><big>(</big><em>doc</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/auto_master.html#update_auto_masters"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.auto_master.update_auto_masters" title="Permalink to this definition">¶</a></dt>
  63. <dd></dd></dl>
  64. </div>
  65. <div class="section" id="module-webnotes.widgets.event">
  66. <span id="event-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">event</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.event" title="Permalink to this headline">¶</a></h2>
  67. <dl class="function">
  68. <dt id="webnotes.widgets.event.get_cal_events">
  69. <tt class="descclassname">webnotes.widgets.event.</tt><tt class="descname">get_cal_events</tt><big>(</big><em>m_st</em>, <em>m_end</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/event.html#get_cal_events"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.event.get_cal_events" title="Permalink to this definition">¶</a></dt>
  70. <dd></dd></dl>
  71. <dl class="function">
  72. <dt id="webnotes.widgets.event.load_month_events">
  73. <tt class="descclassname">webnotes.widgets.event.</tt><tt class="descname">load_month_events</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/event.html#load_month_events"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.event.load_month_events" title="Permalink to this definition">¶</a></dt>
  74. <dd></dd></dl>
  75. </div>
  76. <div class="section" id="module-webnotes.widgets.follow">
  77. <span id="follow-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">follow</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.follow" title="Permalink to this headline">¶</a></h2>
  78. <p>Server side methods for the follower pattern (Follow button used in forms)</p>
  79. <dl class="function">
  80. <dt id="webnotes.widgets.follow.email_followers">
  81. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">email_followers</tt><big>(</big><em>dt</em>, <em>dn</em>, <em>msg_html=None</em>, <em>msg_text=None</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#email_followers"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.email_followers" title="Permalink to this definition">¶</a></dt>
  82. <dd><p>Send an email to all followers of this object</p>
  83. </dd></dl>
  84. <dl class="function">
  85. <dt id="webnotes.widgets.follow.follow">
  86. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">follow</tt><big>(</big><em>dt=None</em>, <em>dn=None</em>, <em>user=None</em>, <em>verbose=0</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#follow"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.follow" title="Permalink to this definition">¶</a></dt>
  87. <dd><p>Add as follower to a particular record. If no parameteres, then take from the http request (form)</p>
  88. </dd></dl>
  89. <dl class="function">
  90. <dt id="webnotes.widgets.follow.get_profile_fields">
  91. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">get_profile_fields</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#get_profile_fields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.get_profile_fields" title="Permalink to this definition">¶</a></dt>
  92. <dd><p>returns a list of all profile link fields from the doctype</p>
  93. </dd></dl>
  94. <dl class="function">
  95. <dt id="webnotes.widgets.follow.has_permission">
  96. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">has_permission</tt><big>(</big><em>dt</em>, <em>user</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#has_permission"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.has_permission" title="Permalink to this definition">¶</a></dt>
  97. <dd><p>Check to see if the user has permission to follow</p>
  98. </dd></dl>
  99. <dl class="function">
  100. <dt id="webnotes.widgets.follow.is_follower">
  101. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">is_follower</tt><big>(</big><em>dt</em>, <em>dn</em>, <em>user</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#is_follower"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.is_follower" title="Permalink to this definition">¶</a></dt>
  102. <dd><p>returns true if given user is a follower</p>
  103. </dd></dl>
  104. <dl class="function">
  105. <dt id="webnotes.widgets.follow.load_followers">
  106. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">load_followers</tt><big>(</big><em>dt=None</em>, <em>dn=None</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#load_followers"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.load_followers" title="Permalink to this definition">¶</a></dt>
  107. <dd><p>returns list of followers (Full Names) for a particular object</p>
  108. </dd></dl>
  109. <dl class="function">
  110. <dt id="webnotes.widgets.follow.make_follower">
  111. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">make_follower</tt><big>(</big><em>dt</em>, <em>dn</em>, <em>user</em>, <em>verbose</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#make_follower"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.make_follower" title="Permalink to this definition">¶</a></dt>
  112. <dd><p>Add the user as a follower</p>
  113. </dd></dl>
  114. <dl class="function">
  115. <dt id="webnotes.widgets.follow.on_docsave">
  116. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">on_docsave</tt><big>(</big><em>doc</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#on_docsave"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.on_docsave" title="Permalink to this definition">¶</a></dt>
  117. <dd><p>Add the owner and all linked Profiles as followers</p>
  118. </dd></dl>
  119. <dl class="function">
  120. <dt id="webnotes.widgets.follow.setup">
  121. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">setup</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#setup"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.setup" title="Permalink to this definition">¶</a></dt>
  122. <dd><p>Make table for followers - if missing</p>
  123. </dd></dl>
  124. <dl class="function">
  125. <dt id="webnotes.widgets.follow.unfollow">
  126. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">unfollow</tt><big>(</big><em>dt=None</em>, <em>dn=None</em>, <em>user=None</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#unfollow"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.unfollow" title="Permalink to this definition">¶</a></dt>
  127. <dd><p>Unfollow a particular record. If no parameteres, then take from the http request (form)</p>
  128. </dd></dl>
  129. <dl class="function">
  130. <dt id="webnotes.widgets.follow.update_followers">
  131. <tt class="descclassname">webnotes.widgets.follow.</tt><tt class="descname">update_followers</tt><big>(</big><em>dt=None</em>, <em>dn=None</em>, <em>subject=None</em>, <em>update_by=None</em>, <em>doc=None</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/follow.html#update_followers"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.follow.update_followers" title="Permalink to this definition">¶</a></dt>
  132. <dd><p>Updates the timestamp and subject in follower table (for feed generation)</p>
  133. </dd></dl>
  134. </div>
  135. <div class="section" id="module-webnotes.widgets.form">
  136. <span id="form-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">form</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.form" title="Permalink to this headline">¶</a></h2>
  137. <p>Server side handler for &#8220;Form&#8221; events</p>
  138. <dl class="function">
  139. <dt id="webnotes.widgets.form.add_comment">
  140. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">add_comment</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#add_comment"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.add_comment" title="Permalink to this definition">¶</a></dt>
  141. <dd></dd></dl>
  142. <dl class="function">
  143. <dt id="webnotes.widgets.form.check_guest_access">
  144. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">check_guest_access</tt><big>(</big><em>doc</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#check_guest_access"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.check_guest_access" title="Permalink to this definition">¶</a></dt>
  145. <dd></dd></dl>
  146. <dl class="function">
  147. <dt id="webnotes.widgets.form.check_integrity">
  148. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">check_integrity</tt><big>(</big><em>doc</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#check_integrity"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.check_integrity" title="Permalink to this definition">¶</a></dt>
  149. <dd></dd></dl>
  150. <dl class="function">
  151. <dt id="webnotes.widgets.form.get_comments">
  152. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">get_comments</tt><big>(</big><em>doctype=None</em>, <em>docname=None</em>, <em>limit=5</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#get_comments"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.get_comments" title="Permalink to this definition">¶</a></dt>
  153. <dd></dd></dl>
  154. <dl class="function">
  155. <dt id="webnotes.widgets.form.get_fields">
  156. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">get_fields</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#get_fields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.get_fields" title="Permalink to this definition">¶</a></dt>
  157. <dd></dd></dl>
  158. <dl class="function">
  159. <dt id="webnotes.widgets.form.get_print_format">
  160. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">get_print_format</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#get_print_format"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.get_print_format" title="Permalink to this definition">¶</a></dt>
  161. <dd></dd></dl>
  162. <dl class="function">
  163. <dt id="webnotes.widgets.form.getdoc">
  164. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">getdoc</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#getdoc"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.getdoc" title="Permalink to this definition">¶</a></dt>
  165. <dd><p>Loads a doclist for a given document. This method is called directly from the client.
  166. Requries &#8220;doctype&#8221;, &#8220;docname&#8221; as form variables. If &#8220;from_archive&#8221; is set, it will get from archive.
  167. Will also call the &#8220;onload&#8221; method on the document.</p>
  168. </dd></dl>
  169. <dl class="function">
  170. <dt id="webnotes.widgets.form.getdoctype">
  171. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">getdoctype</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#getdoctype"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.getdoctype" title="Permalink to this definition">¶</a></dt>
  172. <dd></dd></dl>
  173. <dl class="function">
  174. <dt id="webnotes.widgets.form.load_single_doc">
  175. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">load_single_doc</tt><big>(</big><em>dt</em>, <em>dn</em>, <em>user</em>, <em>prefix</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#load_single_doc"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.load_single_doc" title="Permalink to this definition">¶</a></dt>
  176. <dd></dd></dl>
  177. <dl class="function">
  178. <dt id="webnotes.widgets.form.make_comment_table">
  179. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">make_comment_table</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#make_comment_table"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.make_comment_table" title="Permalink to this definition">¶</a></dt>
  180. <dd><p>Make table for comments - if missing via import module</p>
  181. </dd></dl>
  182. <dl class="function">
  183. <dt id="webnotes.widgets.form.make_csv_output">
  184. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">make_csv_output</tt><big>(</big><em>res</em>, <em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#make_csv_output"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.make_csv_output" title="Permalink to this definition">¶</a></dt>
  185. <dd></dd></dl>
  186. <dl class="function">
  187. <dt id="webnotes.widgets.form.remove_attach">
  188. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">remove_attach</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#remove_attach"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.remove_attach" title="Permalink to this definition">¶</a></dt>
  189. <dd></dd></dl>
  190. <dl class="function">
  191. <dt id="webnotes.widgets.form.remove_comment">
  192. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">remove_comment</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#remove_comment"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.remove_comment" title="Permalink to this definition">¶</a></dt>
  193. <dd></dd></dl>
  194. <dl class="function">
  195. <dt id="webnotes.widgets.form.runserverobj">
  196. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">runserverobj</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#runserverobj"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.runserverobj" title="Permalink to this definition">¶</a></dt>
  197. <dd></dd></dl>
  198. <dl class="function">
  199. <dt id="webnotes.widgets.form.savedocs">
  200. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">savedocs</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#savedocs"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.savedocs" title="Permalink to this definition">¶</a></dt>
  201. <dd></dd></dl>
  202. <dl class="function">
  203. <dt id="webnotes.widgets.form.validate_link">
  204. <tt class="descclassname">webnotes.widgets.form.</tt><tt class="descname">validate_link</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/form.html#validate_link"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.form.validate_link" title="Permalink to this definition">¶</a></dt>
  205. <dd></dd></dl>
  206. </div>
  207. <div class="section" id="module-webnotes.widgets.menus">
  208. <span id="menus-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">menus</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.menus" title="Permalink to this headline">¶</a></h2>
  209. <p>Server side methods called from DocBrowser</p>
  210. <dl class="function">
  211. <dt id="webnotes.widgets.menus.archive_items">
  212. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">archive_items</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#archive_items"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.archive_items" title="Permalink to this definition">¶</a></dt>
  213. <dd></dd></dl>
  214. <dl class="function">
  215. <dt id="webnotes.widgets.menus.can_cancel">
  216. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">can_cancel</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#can_cancel"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.can_cancel" title="Permalink to this definition">¶</a></dt>
  217. <dd></dd></dl>
  218. <dl class="function">
  219. <dt id="webnotes.widgets.menus.delete_items">
  220. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">delete_items</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#delete_items"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.delete_items" title="Permalink to this definition">¶</a></dt>
  221. <dd></dd></dl>
  222. <dl class="function">
  223. <dt id="webnotes.widgets.menus.get_columns">
  224. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">get_columns</tt><big>(</big><em>out</em>, <em>sf</em>, <em>fl</em>, <em>dt</em>, <em>tag_fields</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#get_columns"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.get_columns" title="Permalink to this definition">¶</a></dt>
  225. <dd></dd></dl>
  226. <dl class="function">
  227. <dt id="webnotes.widgets.menus.get_dt_details">
  228. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">get_dt_details</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#get_dt_details"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.get_dt_details" title="Permalink to this definition">¶</a></dt>
  229. <dd><p>Returns details called by DocBrowser this includes:
  230. the filters, columns, subject and tag_fields
  231. also if the doctype is of type &#8220;submittable&#8221;</p>
  232. </dd></dl>
  233. <dl class="function">
  234. <dt id="webnotes.widgets.menus.get_dt_trend">
  235. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">get_dt_trend</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#get_dt_trend"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.get_dt_trend" title="Permalink to this definition">¶</a></dt>
  236. <dd></dd></dl>
  237. <dl class="function">
  238. <dt id="webnotes.widgets.menus.get_menu_items">
  239. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">get_menu_items</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#get_menu_items"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.get_menu_items" title="Permalink to this definition">¶</a></dt>
  240. <dd><p>Returns a list of items to show in <cite>Options</cite> of the Web Notes Toolbar
  241. List contains Pages and Single DocTypes</p>
  242. </dd></dl>
  243. <dl class="function">
  244. <dt id="webnotes.widgets.menus.get_trend">
  245. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">get_trend</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#get_trend"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.get_trend" title="Permalink to this definition">¶</a></dt>
  246. <dd></dd></dl>
  247. <dl class="function">
  248. <dt id="webnotes.widgets.menus.has_result">
  249. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">has_result</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#has_result"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.has_result" title="Permalink to this definition">¶</a></dt>
  250. <dd></dd></dl>
  251. <dl class="function">
  252. <dt id="webnotes.widgets.menus.is_submittable">
  253. <tt class="descclassname">webnotes.widgets.menus.</tt><tt class="descname">is_submittable</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/menus.html#is_submittable"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.menus.is_submittable" title="Permalink to this definition">¶</a></dt>
  254. <dd></dd></dl>
  255. </div>
  256. <div class="section" id="module-webnotes.widgets.page">
  257. <span id="page-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">page</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.page" title="Permalink to this headline">¶</a></h2>
  258. <dl class="class">
  259. <dt id="webnotes.widgets.page.Page">
  260. <em class="property">class </em><tt class="descclassname">webnotes.widgets.page.</tt><tt class="descname">Page</tt><big>(</big><em>name</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page.html#Page"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page.Page" title="Permalink to this definition">¶</a></dt>
  261. <dd><p>A page class helps in loading a Page in the system. On loading</p>
  262. <ul class="simple">
  263. <li>Page will import Client Script from other pages where specified by <cite>$import(page_name)</cite></li>
  264. <li>Execute dynamic HTML if the <cite>content</cite> starts with <cite>#python</cite></li>
  265. </ul>
  266. <dl class="method">
  267. <dt id="webnotes.widgets.page.Page.load">
  268. <tt class="descname">load</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page.html#Page.load"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page.Page.load" title="Permalink to this definition">¶</a></dt>
  269. <dd><p>Returns <em class="xref std std-term">doclist</em> of the <cite>Page</cite></p>
  270. </dd></dl>
  271. <dl class="method">
  272. <dt id="webnotes.widgets.page.Page.load_stylesheet">
  273. <tt class="descname">load_stylesheet</tt><big>(</big><em>stylesheet</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page.html#Page.load_stylesheet"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page.Page.load_stylesheet" title="Permalink to this definition">¶</a></dt>
  274. <dd></dd></dl>
  275. </dd></dl>
  276. <dl class="function">
  277. <dt id="webnotes.widgets.page.get">
  278. <tt class="descclassname">webnotes.widgets.page.</tt><tt class="descname">get</tt><big>(</big><em>name</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page.html#get"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page.get" title="Permalink to this definition">¶</a></dt>
  279. <dd><p>Return the <em class="xref std std-term">doclist</em> of the <cite>Page</cite> specified by <cite>name</cite></p>
  280. </dd></dl>
  281. <dl class="function">
  282. <dt id="webnotes.widgets.page.getpage">
  283. <tt class="descclassname">webnotes.widgets.page.</tt><tt class="descname">getpage</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page.html#getpage"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page.getpage" title="Permalink to this definition">¶</a></dt>
  284. <dd><p>Load the page from <cite>webnotes.form</cite> and send it via <cite>webnotes.response</cite></p>
  285. </dd></dl>
  286. </div>
  287. <div class="section" id="module-webnotes.widgets.page_body">
  288. <span id="page-body-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">page_body</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.page_body" title="Permalink to this headline">¶</a></h2>
  289. <dl class="function">
  290. <dt id="webnotes.widgets.page_body.get">
  291. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">get</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#get"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.get" title="Permalink to this definition">¶</a></dt>
  292. <dd><p>returns the full rendered index.cgi
  293. Gets <cite>keywords</cite> and <cite>site_description</cite> from the <cite>Control Panel</cite></p>
  294. </dd></dl>
  295. <dl class="function">
  296. <dt id="webnotes.widgets.page_body.get_doc_content">
  297. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">get_doc_content</tt><big>(</big><em>dt</em>, <em>dn</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#get_doc_content"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.get_doc_content" title="Permalink to this definition">¶</a></dt>
  298. <dd><p>Gets the HTML content of a document record by using the overridden or standard :method: <cite>doclist.to_html</cite></p>
  299. </dd></dl>
  300. <dl class="function">
  301. <dt id="webnotes.widgets.page_body.get_page_content">
  302. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">get_page_content</tt><big>(</big><em>page</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#get_page_content"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.get_page_content" title="Permalink to this definition">¶</a></dt>
  303. <dd><p>Gets the HTML content from <cite>static_content</cite> or <cite>content</cite> property of a <cite>Page</cite></p>
  304. </dd></dl>
  305. <dl class="data">
  306. <dt id="webnotes.widgets.page_body.index_template">
  307. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">index_template</tt><a class="headerlink" href="#webnotes.widgets.page_body.index_template" title="Permalink to this definition">¶</a></dt>
  308. <dd><blockquote>
  309. <div>HTML Template of index.cgi</div></blockquote>
  310. </dd></dl>
  311. <dl class="function">
  312. <dt id="webnotes.widgets.page_body.load_default_properties">
  313. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">load_default_properties</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#load_default_properties"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.load_default_properties" title="Permalink to this definition">¶</a></dt>
  314. <dd></dd></dl>
  315. <dl class="function">
  316. <dt id="webnotes.widgets.page_body.load_page_metatags">
  317. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">load_page_metatags</tt><big>(</big><em>doc</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#load_page_metatags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.load_page_metatags" title="Permalink to this definition">¶</a></dt>
  318. <dd></dd></dl>
  319. <dl class="function">
  320. <dt id="webnotes.widgets.page_body.load_properties">
  321. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">load_properties</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#load_properties"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.load_properties" title="Permalink to this definition">¶</a></dt>
  322. <dd></dd></dl>
  323. <dl class="function">
  324. <dt id="webnotes.widgets.page_body.replace_id">
  325. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">replace_id</tt><big>(</big><em>match</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#replace_id"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.replace_id" title="Permalink to this definition">¶</a></dt>
  326. <dd></dd></dl>
  327. <dl class="function">
  328. <dt id="webnotes.widgets.page_body.scrub_ids">
  329. <tt class="descclassname">webnotes.widgets.page_body.</tt><tt class="descname">scrub_ids</tt><big>(</big><em>content</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/page_body.html#scrub_ids"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.page_body.scrub_ids" title="Permalink to this definition">¶</a></dt>
  330. <dd></dd></dl>
  331. </div>
  332. <div class="section" id="module-webnotes.widgets.query_builder">
  333. <span id="query-builder-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">query_builder</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.query_builder" title="Permalink to this headline">¶</a></h2>
  334. <dl class="function">
  335. <dt id="webnotes.widgets.query_builder.add_match_conditions">
  336. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">add_match_conditions</tt><big>(</big><em>q</em>, <em>tl</em>, <em>ur</em>, <em>ud</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#add_match_conditions"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.add_match_conditions" title="Permalink to this definition">¶</a></dt>
  337. <dd></dd></dl>
  338. <dl class="function">
  339. <dt id="webnotes.widgets.query_builder.build_description_simple">
  340. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">build_description_simple</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#build_description_simple"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.build_description_simple" title="Permalink to this definition">¶</a></dt>
  341. <dd></dd></dl>
  342. <dl class="function">
  343. <dt id="webnotes.widgets.query_builder.build_description_standard">
  344. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">build_description_standard</tt><big>(</big><em>meta</em>, <em>tl</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#build_description_standard"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.build_description_standard" title="Permalink to this definition">¶</a></dt>
  345. <dd></dd></dl>
  346. <dl class="function">
  347. <dt id="webnotes.widgets.query_builder.exec_report">
  348. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">exec_report</tt><big>(</big><em>code</em>, <em>res</em>, <em>colnames=</em><span class="optional">[</span><span class="optional">]</span>, <em>colwidths=</em><span class="optional">[</span><span class="optional">]</span>, <em>coltypes=</em><span class="optional">[</span><span class="optional">]</span>, <em>coloptions=</em><span class="optional">[</span><span class="optional">]</span>, <em>filter_values={}</em>, <em>query=''</em>, <em>from_export=0</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#exec_report"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.exec_report" title="Permalink to this definition">¶</a></dt>
  349. <dd></dd></dl>
  350. <dl class="function">
  351. <dt id="webnotes.widgets.query_builder.get_parent_dt">
  352. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">get_parent_dt</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#get_parent_dt"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.get_parent_dt" title="Permalink to this definition">¶</a></dt>
  353. <dd></dd></dl>
  354. <dl class="function">
  355. <dt id="webnotes.widgets.query_builder.get_search_criteria_list">
  356. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">get_search_criteria_list</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#get_search_criteria_list"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.get_search_criteria_list" title="Permalink to this definition">¶</a></dt>
  357. <dd></dd></dl>
  358. <dl class="function">
  359. <dt id="webnotes.widgets.query_builder.get_sql_meta">
  360. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">get_sql_meta</tt><big>(</big><em>tl</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#get_sql_meta"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.get_sql_meta" title="Permalink to this definition">¶</a></dt>
  361. <dd></dd></dl>
  362. <dl class="function">
  363. <dt id="webnotes.widgets.query_builder.get_sql_tables">
  364. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">get_sql_tables</tt><big>(</big><em>q</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#get_sql_tables"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.get_sql_tables" title="Permalink to this definition">¶</a></dt>
  365. <dd></dd></dl>
  366. <dl class="function">
  367. <dt id="webnotes.widgets.query_builder.getmatchcondition">
  368. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">getmatchcondition</tt><big>(</big><em>dt</em>, <em>ud</em>, <em>ur</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#getmatchcondition"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.getmatchcondition" title="Permalink to this definition">¶</a></dt>
  369. <dd></dd></dl>
  370. <dl class="function">
  371. <dt id="webnotes.widgets.query_builder.guess_type">
  372. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">guess_type</tt><big>(</big><em>m</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#guess_type"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.guess_type" title="Permalink to this definition">¶</a></dt>
  373. <dd><p>Returns fieldtype depending on the MySQLdb Description</p>
  374. </dd></dl>
  375. <dl class="function">
  376. <dt id="webnotes.widgets.query_builder.load_report_list">
  377. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">load_report_list</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#load_report_list"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.load_report_list" title="Permalink to this definition">¶</a></dt>
  378. <dd></dd></dl>
  379. <dl class="function">
  380. <dt id="webnotes.widgets.query_builder.runquery">
  381. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">runquery</tt><big>(</big><em>q=''</em>, <em>ret=0</em>, <em>from_export=0</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#runquery"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.runquery" title="Permalink to this definition">¶</a></dt>
  382. <dd></dd></dl>
  383. <dl class="function">
  384. <dt id="webnotes.widgets.query_builder.runquery_csv">
  385. <tt class="descclassname">webnotes.widgets.query_builder.</tt><tt class="descname">runquery_csv</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/query_builder.html#runquery_csv"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.query_builder.runquery_csv" title="Permalink to this definition">¶</a></dt>
  386. <dd></dd></dl>
  387. </div>
  388. <div class="section" id="module-webnotes.widgets.search">
  389. <span id="search-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">search</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.search" title="Permalink to this headline">¶</a></h2>
  390. <dl class="function">
  391. <dt id="webnotes.widgets.search.build_for_autosuggest">
  392. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">build_for_autosuggest</tt><big>(</big><em>res</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#build_for_autosuggest"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.build_for_autosuggest" title="Permalink to this definition">¶</a></dt>
  393. <dd></dd></dl>
  394. <dl class="function">
  395. <dt id="webnotes.widgets.search.get_std_fields_list">
  396. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">get_std_fields_list</tt><big>(</big><em>dt</em>, <em>key</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#get_std_fields_list"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.get_std_fields_list" title="Permalink to this definition">¶</a></dt>
  397. <dd></dd></dl>
  398. <dl class="function">
  399. <dt id="webnotes.widgets.search.getsearchfields">
  400. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">getsearchfields</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#getsearchfields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.getsearchfields" title="Permalink to this definition">¶</a></dt>
  401. <dd></dd></dl>
  402. <dl class="function">
  403. <dt id="webnotes.widgets.search.make_query">
  404. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">make_query</tt><big>(</big><em>fields</em>, <em>dt</em>, <em>key</em>, <em>txt</em>, <em>start</em>, <em>length</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#make_query"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.make_query" title="Permalink to this definition">¶</a></dt>
  405. <dd></dd></dl>
  406. <dl class="function">
  407. <dt id="webnotes.widgets.search.scrub_custom_query">
  408. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">scrub_custom_query</tt><big>(</big><em>query</em>, <em>key</em>, <em>txt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#scrub_custom_query"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.scrub_custom_query" title="Permalink to this definition">¶</a></dt>
  409. <dd></dd></dl>
  410. <dl class="function">
  411. <dt id="webnotes.widgets.search.search_link">
  412. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">search_link</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#search_link"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.search_link" title="Permalink to this definition">¶</a></dt>
  413. <dd></dd></dl>
  414. <dl class="function">
  415. <dt id="webnotes.widgets.search.search_widget">
  416. <tt class="descclassname">webnotes.widgets.search.</tt><tt class="descname">search_widget</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/search.html#search_widget"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.search.search_widget" title="Permalink to this definition">¶</a></dt>
  417. <dd></dd></dl>
  418. </div>
  419. <div class="section" id="module-webnotes.widgets.tags">
  420. <span id="tags-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">tags</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.tags" title="Permalink to this headline">¶</a></h2>
  421. <p>Server side functions for tagging.</p>
  422. <ul class="simple">
  423. <li>Tags can be added to any record (doctype, name) in the system.</li>
  424. <li>Items are filtered by tags</li>
  425. <li>Top tags are shown in the sidebar (?)</li>
  426. <li>Tags are also identified by the tag_fields property of the DocType</li>
  427. </ul>
  428. <p>Discussion:</p>
  429. <p>Tags are shown in the docbrowser and ideally where-ever items are searched.
  430. There should also be statistics available for tags (like top tags etc)</p>
  431. <p>Design:</p>
  432. <ul class="simple">
  433. <li>free tags (user_tags) are stored in __user_tags</li>
  434. <li>doctype tags are set in tag_fields property of the doctype</li>
  435. <li>top tags merges the tags from both the lists (only refreshes once an hour (max))</li>
  436. </ul>
  437. <dl class="class">
  438. <dt id="webnotes.widgets.tags.DocTags">
  439. <em class="property">class </em><tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">DocTags</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags" title="Permalink to this definition">¶</a></dt>
  440. <dd><p>Tags for a particular doctype</p>
  441. <dl class="method">
  442. <dt id="webnotes.widgets.tags.DocTags.add">
  443. <tt class="descname">add</tt><big>(</big><em>dn</em>, <em>tag</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.add"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.add" title="Permalink to this definition">¶</a></dt>
  444. <dd><p>add a new user tag</p>
  445. </dd></dl>
  446. <dl class="method">
  447. <dt id="webnotes.widgets.tags.DocTags.create">
  448. <tt class="descname">create</tt><big>(</big><em>tag</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.create"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.create" title="Permalink to this definition">¶</a></dt>
  449. <dd></dd></dl>
  450. <dl class="method">
  451. <dt id="webnotes.widgets.tags.DocTags.get_tag_fields">
  452. <tt class="descname">get_tag_fields</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.get_tag_fields"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.get_tag_fields" title="Permalink to this definition">¶</a></dt>
  453. <dd><p>returns tag_fields property</p>
  454. </dd></dl>
  455. <dl class="method">
  456. <dt id="webnotes.widgets.tags.DocTags.get_tags">
  457. <tt class="descname">get_tags</tt><big>(</big><em>dn</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.get_tags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.get_tags" title="Permalink to this definition">¶</a></dt>
  458. <dd><p>returns tag for a particular item</p>
  459. </dd></dl>
  460. <dl class="method">
  461. <dt id="webnotes.widgets.tags.DocTags.remove">
  462. <tt class="descname">remove</tt><big>(</big><em>dn</em>, <em>tag</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.remove"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.remove" title="Permalink to this definition">¶</a></dt>
  463. <dd><p>remove a user tag</p>
  464. </dd></dl>
  465. <dl class="method">
  466. <dt id="webnotes.widgets.tags.DocTags.setup">
  467. <tt class="descname">setup</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.setup"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.setup" title="Permalink to this definition">¶</a></dt>
  468. <dd><p>adds the _user_tags column if not exists</p>
  469. </dd></dl>
  470. <dl class="method">
  471. <dt id="webnotes.widgets.tags.DocTags.setup_tags">
  472. <tt class="descname">setup_tags</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.setup_tags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.setup_tags" title="Permalink to this definition">¶</a></dt>
  473. <dd><p>creates the tabTag table if not exists</p>
  474. </dd></dl>
  475. <dl class="method">
  476. <dt id="webnotes.widgets.tags.DocTags.update">
  477. <tt class="descname">update</tt><big>(</big><em>dn</em>, <em>tl</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#DocTags.update"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.DocTags.update" title="Permalink to this definition">¶</a></dt>
  478. <dd><p>updates the _user_tag column in the table</p>
  479. </dd></dl>
  480. </dd></dl>
  481. <dl class="class">
  482. <dt id="webnotes.widgets.tags.TagCounter">
  483. <em class="property">class </em><tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">TagCounter</tt><big>(</big><em>doctype</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#TagCounter"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.TagCounter" title="Permalink to this definition">¶</a></dt>
  484. <dd><p>Tag Counter stores tag count per doctype in table _tag_cnt</p>
  485. <dl class="method">
  486. <dt id="webnotes.widgets.tags.TagCounter.build">
  487. <tt class="descname">build</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#TagCounter.build"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.TagCounter.build" title="Permalink to this definition">¶</a></dt>
  488. <dd><p>Builds / rebuilds the counting</p>
  489. </dd></dl>
  490. <dl class="method">
  491. <dt id="webnotes.widgets.tags.TagCounter.load_top">
  492. <tt class="descname">load_top</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#TagCounter.load_top"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.TagCounter.load_top" title="Permalink to this definition">¶</a></dt>
  493. <dd></dd></dl>
  494. <dl class="method">
  495. <dt id="webnotes.widgets.tags.TagCounter.new_tag">
  496. <tt class="descname">new_tag</tt><big>(</big><em>tag</em>, <em>cnt=0</em>, <em>dt=None</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#TagCounter.new_tag"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.TagCounter.new_tag" title="Permalink to this definition">¶</a></dt>
  497. <dd><p>Creates a new row for the tag and doctype</p>
  498. </dd></dl>
  499. <dl class="method">
  500. <dt id="webnotes.widgets.tags.TagCounter.setup">
  501. <tt class="descname">setup</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#TagCounter.setup"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.TagCounter.setup" title="Permalink to this definition">¶</a></dt>
  502. <dd><p>creates the tag cnt table from the DocType</p>
  503. </dd></dl>
  504. <dl class="method">
  505. <dt id="webnotes.widgets.tags.TagCounter.update">
  506. <tt class="descname">update</tt><big>(</big><em>tag</em>, <em>diff</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#TagCounter.update"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.TagCounter.update" title="Permalink to this definition">¶</a></dt>
  507. <dd><p>updates tag cnt for a doctype and tag</p>
  508. </dd></dl>
  509. </dd></dl>
  510. <dl class="function">
  511. <dt id="webnotes.widgets.tags.add_tag">
  512. <tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">add_tag</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#add_tag"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.add_tag" title="Permalink to this definition">¶</a></dt>
  513. <dd><p>adds a new tag to a record, and creates the Tag master</p>
  514. </dd></dl>
  515. <dl class="function">
  516. <dt id="webnotes.widgets.tags.check_user_tags">
  517. <tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">check_user_tags</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#check_user_tags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.check_user_tags" title="Permalink to this definition">¶</a></dt>
  518. <dd><p>if the user does not have a tags column, then it creates one</p>
  519. </dd></dl>
  520. <dl class="function">
  521. <dt id="webnotes.widgets.tags.get_top_field_tags">
  522. <tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">get_top_field_tags</tt><big>(</big><em>dt</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#get_top_field_tags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.get_top_field_tags" title="Permalink to this definition">¶</a></dt>
  523. <dd></dd></dl>
  524. <dl class="function">
  525. <dt id="webnotes.widgets.tags.get_top_tags">
  526. <tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">get_top_tags</tt><big>(</big><em>args=''</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#get_top_tags"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.get_top_tags" title="Permalink to this definition">¶</a></dt>
  527. <dd><p>returns the top 10 tags for the doctype from fields (7) and users (3)</p>
  528. </dd></dl>
  529. <dl class="function">
  530. <dt id="webnotes.widgets.tags.remove_tag">
  531. <tt class="descclassname">webnotes.widgets.tags.</tt><tt class="descname">remove_tag</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/tags.html#remove_tag"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.tags.remove_tag" title="Permalink to this definition">¶</a></dt>
  532. <dd><p>removes tag from the record</p>
  533. </dd></dl>
  534. </div>
  535. <div class="section" id="module-webnotes.widgets.todo">
  536. <span id="todo-module"></span><h2><tt class="xref py py-mod docutils literal"><span class="pre">todo</span></tt> Module<a class="headerlink" href="#module-webnotes.widgets.todo" title="Permalink to this headline">¶</a></h2>
  537. <dl class="function">
  538. <dt id="webnotes.widgets.todo.add_todo">
  539. <tt class="descclassname">webnotes.widgets.todo.</tt><tt class="descname">add_todo</tt><big>(</big><em>user</em>, <em>date</em>, <em>priority</em>, <em>desc</em>, <em>ref_type</em>, <em>ref_name</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/todo.html#add_todo"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.todo.add_todo" title="Permalink to this definition">¶</a></dt>
  540. <dd></dd></dl>
  541. <dl class="function">
  542. <dt id="webnotes.widgets.todo.add_todo_item">
  543. <tt class="descclassname">webnotes.widgets.todo.</tt><tt class="descname">add_todo_item</tt><big>(</big><em>user</em>, <em>date</em>, <em>priority</em>, <em>desc</em>, <em>ref_type</em>, <em>ref_name</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/todo.html#add_todo_item"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.todo.add_todo_item" title="Permalink to this definition">¶</a></dt>
  544. <dd></dd></dl>
  545. <dl class="function">
  546. <dt id="webnotes.widgets.todo.get_todo_list">
  547. <tt class="descclassname">webnotes.widgets.todo.</tt><tt class="descname">get_todo_list</tt><big>(</big><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/todo.html#get_todo_list"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.todo.get_todo_list" title="Permalink to this definition">¶</a></dt>
  548. <dd></dd></dl>
  549. <dl class="function">
  550. <dt id="webnotes.widgets.todo.remove_todo">
  551. <tt class="descclassname">webnotes.widgets.todo.</tt><tt class="descname">remove_todo</tt><big>(</big><em>name</em><big>)</big><a class="reference internal" href="_modules/webnotes/widgets/todo.html#remove_todo"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#webnotes.widgets.todo.remove_todo" title="Permalink to this definition">¶</a></dt>
  552. <dd></dd></dl>
  553. </div>
  554. </div>
  555. </div>
  556. </div>
  557. </div>
  558. <div class="sphinxsidebar">
  559. <div class="sphinxsidebarwrapper">
  560. <p class="logo"><a href="index.html">
  561. <img class="logo" src="_static/wnflogo200.gif" alt="Logo"/>
  562. </a></p>
  563. <h3><a href="index.html">Table Of Contents</a></h3>
  564. <ul>
  565. <li><a class="reference internal" href="#">widgets Package</a><ul>
  566. <li><a class="reference internal" href="#module-webnotes.widgets.auto_master"><tt class="docutils literal"><span class="pre">auto_master</span></tt> Module</a></li>
  567. <li><a class="reference internal" href="#module-webnotes.widgets.event"><tt class="docutils literal"><span class="pre">event</span></tt> Module</a></li>
  568. <li><a class="reference internal" href="#module-webnotes.widgets.follow"><tt class="docutils literal"><span class="pre">follow</span></tt> Module</a></li>
  569. <li><a class="reference internal" href="#module-webnotes.widgets.form"><tt class="docutils literal"><span class="pre">form</span></tt> Module</a></li>
  570. <li><a class="reference internal" href="#module-webnotes.widgets.menus"><tt class="docutils literal"><span class="pre">menus</span></tt> Module</a></li>
  571. <li><a class="reference internal" href="#module-webnotes.widgets.page"><tt class="docutils literal"><span class="pre">page</span></tt> Module</a></li>
  572. <li><a class="reference internal" href="#module-webnotes.widgets.page_body"><tt class="docutils literal"><span class="pre">page_body</span></tt> Module</a></li>
  573. <li><a class="reference internal" href="#module-webnotes.widgets.query_builder"><tt class="docutils literal"><span class="pre">query_builder</span></tt> Module</a></li>
  574. <li><a class="reference internal" href="#module-webnotes.widgets.search"><tt class="docutils literal"><span class="pre">search</span></tt> Module</a></li>
  575. <li><a class="reference internal" href="#module-webnotes.widgets.tags"><tt class="docutils literal"><span class="pre">tags</span></tt> Module</a></li>
  576. <li><a class="reference internal" href="#module-webnotes.widgets.todo"><tt class="docutils literal"><span class="pre">todo</span></tt> Module</a></li>
  577. </ul>
  578. </li>
  579. </ul>
  580. <h3>This Page</h3>
  581. <ul class="this-page-menu">
  582. <li><a href="_sources/webnotes.widgets.txt"
  583. rel="nofollow">Show Source</a></li>
  584. </ul>
  585. <div id="searchbox" style="display: none">
  586. <h3>Quick search</h3>
  587. <form class="search" action="search.html" method="get">
  588. <input type="text" name="q" size="18" />
  589. <input type="submit" value="Go" />
  590. <input type="hidden" name="check_keywords" value="yes" />
  591. <input type="hidden" name="area" value="default" />
  592. </form>
  593. <p class="searchtip" style="font-size: 90%">
  594. Enter search terms or a module, class or function name.
  595. </p>
  596. </div>
  597. <script type="text/javascript">$('#searchbox').show(0);</script>
  598. </div>
  599. </div>
  600. <div class="clearer"></div>
  601. </div>
  602. <div class="related">
  603. <h3>Navigation</h3>
  604. <ul>
  605. <li class="right" style="margin-right: 10px">
  606. <a href="genindex.html" title="General Index"
  607. >index</a></li>
  608. <li class="right" >
  609. <a href="py-modindex.html" title="Python Module Index"
  610. >modules</a> |</li>
  611. <li><a href="index.html">WNFramework v1.8 documentation</a> &raquo;</li>
  612. </ul>
  613. </div>
  614. <div class="footer">
  615. &copy; Copyright 2011, Rushabh Mehta, Web Notes Technologies.
  616. Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.0.7.
  617. </div>
  618. </body>
  619. </html>