Source

transifex / transifex / templates / webtrans / transfile_edit.html

Full commit
{% extends "projects/base.html" %}
{% load i18n %}
{% load txcommontags %}
{% load txpagination %}

{% block extra_head %}
<link media="screen" href="{{ MEDIA_URL }}css/tablesorter.css" type="text/css" rel="stylesheet" />
<link media="screen" href="{{ MEDIA_URL }}css/webtrans.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="{{ MEDIA_URL }}js/tablesorted.js"></script>
<script type="text/javascript" src="{{ MEDIA_URL }}js/table_pagination.js"></script>
<script type="text/javascript" src="{{ MEDIA_URL }}js/web_editor.js"></script>

<!-- Google suggest -->
<script src="http://www.google.com/jsapi" type="text/javascript"></script>    
<script type="text/javascript">
//<!--
{% if WEBTRANS_SUGGESTIONS %}
  google.load("language", "1");
  {% include 'webtrans/js/google-translate.js' %}
{% endif %}
//-->
</script>
{% endblock %}

{% block title %}
{% with pofile.object as component %}
{{ block.super }}
| {{ component.project.name }}
| {% blocktrans with component.name as component_name %}{{ component_name }}{% endblocktrans %}
| {% blocktrans with pofile.filename as filename %}Translate '{{ filename }}'{% endblocktrans %}
{% endwith %}
{% endblock %}

{% block breadcrumb %}
{% with pofile.object as component %}
{{ block.super }}
&raquo; <a href="{{ component.project.get_absolute_url }}">{{ component.project.name }}</a>
&raquo; <a href="{{ component.get_absolute_url }}">{{ component.name }}</a>
&raquo; {% blocktrans with pofile.filename as filename %}Translate '<code>{{ filename }}</code>'{% endblocktrans %}
{% endwith %}
{% endblock %}

{% block content_title %}
<h2 class="pagetitle">{% blocktrans with component.name as component_name and pofile.filename as filename %}Translate '<code>{{ filename }}</code>'{% endblocktrans %}</h2>
{% endblock %}

{% block content %}

{% if pofile.total %}
  <form action='' method='post' class='webtrans'>
  <h3>{% trans "Current status for this page" %}</h3>

<fieldset class="floatright">
  <legend>{% trans "Settings" %}</legend>
  <table class="definition">
  <tr>
    <th>{% trans "Show occurrences:" %}</th>
    <td><input id="toggle_occurrences" type="checkbox" {% if toggle_occurrences %}checked="checked"{% endif %} name="toggle_occurrences" /></td>
  </tr>
  <tr>
    <th>{% trans "Show context:" %}</th>
    <td><input id="toggle_contexts" type="checkbox" {% if toggle_contexts %}checked="checked"{% endif %} name="toggle_contexts" /></td>
  </tr>
  </table>
</fieldset>

  <table class="definition stats_totals">
  <tr>
    <th class="translated">{% trans "Translated" %}</th>
      <td id="total_translated">{{ pofile.trans }}</td>
      <td id="total_translated_perc">{{ pofile.trans_perc }}%</td>
      <td><input id="only_translated" type="checkbox" {% if only_translated %}checked="checked"{% endif %} name="only_translated"/></td>
  </tr>
  <tr>
    <th class="fuzzy">{% trans "Fuzzy" %}</th>
      <td id="total_fuzzy">{{ pofile.fuzzy }}</td>
      <td id="total_fuzzy_perc">{{ pofile.fuzzy_perc }}%</td>
      <td><input id="only_fuzzy" type="checkbox" {% if only_fuzzy %}checked="checked"{% endif %} name="only_fuzzy"/></td>
  </tr>
  <tr>
    <th class="untranslated">{% trans "Untranslated" %}</th>
      <td id="total_untranslated">{{ pofile.untrans }}</td>
      <td id="total_untranslated_perc">{{ pofile.untrans_perc }}%</td>
      <td><input id="only_untranslated" type="checkbox" {% if only_untranslated %}checked="checked"{% endif %} name="only_untranslated"/></td>
  </tr>
  <tr class="last">
    <th>{% trans "Total" %}</th>
      <td id="total_sum">{{ pofile.total }}</td>
  </tr>
  </table>
{% endif %}

  <h3>{% trans "Live translation" %}</h3>

  {% if form_message %}
    <p class="message i16 bell">{{ form_message }}</p>
  {% endif %}

  <span>{% blocktrans %}Page {{step}} of {{step_count}}{% endblocktrans %}</span>

  <div class="generic_form" >
  <table id="trans_web_edit" class="trans_web_edit stats_comp tablesorter">
   <thead>
    <tr>
      <th>{% trans "#" %}</th>
      <th>{% trans "Source String" %}</th>
      <th>{% trans "Translation" %}</th>
    {% if WEBTRANS_SUGGESTIONS %}      
      <th class="suggest_container"><abbr title="{% trans "Auto-translate" %}">{% trans "AT" %}</abbr></th>
    {% endif %}
      <th class="occurrences">{% trans "Occurrences" %}</th>
      <th>{% trans "Fuzzy?" %}</th>
    </tr>
   </thead>
   <tbody>
    {% include "webtrans/transfile_form.html" %}
   </tbody>
  </table>
  </div>

  {% txpaginate '' po_entries step ENTRIES_PER_PAGE 6 paginated_po_entries %}
  {% include 'pagination.html' %}

  <p class="submit">
  <input type="submit" name="submit" class="i16 submit" value="{% trans "Submit translations" %}" />
  </p>

  </form>
{% endblock %}