[Mpuls-commits] r4031 - base/trunk/mpulsweb/templates/auth

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Tue Oct 26 18:27:53 CEST 2010


Author: torsten
Date: 2010-10-26 18:27:53 +0200 (Tue, 26 Oct 2010)
New Revision: 4031

Modified:
   base/trunk/mpulsweb/templates/auth/login.mako
Log:
* mpulsweb/templates/auth/login.mako: Added select box with available db to connect to if they are defined in the dblist json.


Modified: base/trunk/mpulsweb/templates/auth/login.mako
===================================================================
--- base/trunk/mpulsweb/templates/auth/login.mako	2010-10-26 16:26:30 UTC (rev 4030)
+++ base/trunk/mpulsweb/templates/auth/login.mako	2010-10-26 16:27:53 UTC (rev 4031)
@@ -27,6 +27,7 @@
        <input id="username" type="text" size="20" name="username" maxlength="64">
     </div>
     <div class="clearer"></div>
+
     <div class="label">
       <label for="password">${_('login_label_pw')}</label>
     </div>
@@ -34,6 +35,23 @@
       <input type="password" size="20" id="password" name="password">
     </div>
     <div class="clearer"></div>
+
+    ## This additional selection field for choosing the DB to connect to will
+    ## be available as soon as there are defined databases in the dblist json
+    ## file.
+    % if len(h.get_db_selectionlist()) > 0:
+    <div class="label">
+      <label for="DB_NAME_FROM_LIST">${_('adm_form_label_agency')}:</label>
+    </div>
+    <div class="input">
+      <select name='DB_NAME_FROM_LIST' size=1>
+      % for db, info in h.get_db_selectionlist().items():
+           <option value="${db}">${info.get('label')}</option>
+      % endfor
+      </select>
+    </div>
+    % endif
+    <div class="clearer"></div>
     <p id="login_btn">
       <input type="submit" value="Anmelden" name="authform">
     </p>



More information about the Mpuls-commits mailing list