Explorar o código

Fix UI lang mapping and hardcoded dir in get_lang_map().

scossu hai 8 meses
pai
achega
22b2a2660c
Modificáronse 2 ficheiros con 3 adicións e 3 borrados
  1. 1 1
      scriptshifter/tables/__init__.py
  2. 2 2
      scriptshifter/templates/index.html

+ 1 - 1
scriptshifter/tables/__init__.py

@@ -600,7 +600,7 @@ def get_lang_map(conn, lang_id, t_dir):
             """SELECT src, dest FROM tbl_trans_map
             WHERE lang_id = ? AND dir = ?
             ORDER BY sort ASC""",
-            (lang_id, FEAT_S2R))
+            (lang_id, t_dir))
 
     for row in qry:
         yield (Token(row[0]), row[1])

+ 2 - 2
scriptshifter/templates/index.html

@@ -60,7 +60,7 @@
             <label for="lang">Language</label>
             <select id="lang" name="lang">
                 {% for k, v in languages.items() %}
-                    <option value="{{ k }}">{{ v["name"] }}</option>
+                    <option value="{{ k }}">{{ v["label"] }}</option>
                 {% endfor %}
             </select>
         </fieldset>
@@ -176,4 +176,4 @@
     {% endif %}
 
     <script type="text/javascript" src="/static/ss.js"></script>
-{% endblock %}
+{% endblock %}