<spanid="evennia-web-admin-utils"></span><h1>evennia.web.admin.utils<aclass="headerlink"href="#module-evennia.web.admin.utils"title="Permalink to this headline">¶</a></h1>
<codeclass="sig-prename descclassname">evennia.web.admin.utils.</code><codeclass="sig-name descname">get_and_load_typeclasses</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">parent</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">excluded_parents</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="../_modules/evennia/web/admin/utils.html#get_and_load_typeclasses"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#evennia.web.admin.utils.get_and_load_typeclasses"title="Permalink to this definition">¶</a></dt>
<dd><p>Get all typeclasses. We we need to initialize things here
for them to be actually available in the admin process.
This is intended to be used with forms.ChoiceField.</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>parent</strong> (<em>str</em><em> or </em><em>class</em><em>, </em><em>optional</em>) – Limit selection to this class and its children
(at any distance).</p></li>
<li><p><strong>exclude</strong> (<em>list</em>) – Class-parents to exclude from the resulting list. All
children of these paretns will be skipped.</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p><em>list</em>– A list of (str, str), the way ChoiceField wants it.</p>
<codeclass="sig-prename descclassname">evennia.web.admin.utils.</code><codeclass="sig-name descname">get_and_load_cmdsets</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">parent</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">excluded_parents</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="reference internal"href="../_modules/evennia/web/admin/utils.html#get_and_load_cmdsets"><spanclass="viewcode-link">[source]</span></a><aclass="headerlink"href="#evennia.web.admin.utils.get_and_load_cmdsets"title="Permalink to this definition">¶</a></dt>
<dd><p>Get all cmdsets available or as children based on a parent cmdset. We need
to initialize things here to make sure as much as possible is loaded in the
admin process. This is intended to be used with forms.ChoiceField.</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>parent</strong> (<em>str</em><em>, </em><em>optional</em>) – Python-path to the parent cmdset, if any.</p></li>
<li><p><strong>excluded_parents</strong> (<em>list</em>) – A list of cmset-paths to exclude from the result.</p></li>
</ul>
</dd>
<dtclass="field-even">Returns</dt>
<ddclass="field-even"><p><em>list</em>– A list of (str, str), the way ChoiceField wants it.</p>