export_git.html 2.42 KB
Newer Older
1 2 3
<%inherit file="base.html" />
<%namespace name='static' file='static_content.html'/>

4
<%!
Carson Gee committed
5 6 7
  from django.core.urlresolvers import reverse
  from django.utils.translation import ugettext as _
%>
8 9
<%block name="title">${_("Export Course to Git")}</%block>
<%block name="bodyclass">is-signedin course tools view-export-git</%block>
10 11 12 13 14 15

<%block name="content">
<div class="wrapper-mast wrapper">
  <header class="mast has-subtitle">
    <h1 class="page-header">
      <small class="subtitle">${_("Tools")}</small>
16
      <span class="sr">&gt; </span>${_("Export to Git")}
17 18 19 20
    </h1>
  </header>
</div>

21
<div class="wrapper-content wrapper">
Carson Gee committed
22 23
  <section class="content">
    <article class="content-primary" role="main">
24

Carson Gee committed
25
      <div class="introduction">
26 27 28 29 30
        <h2 class="title">${_("About Export to Git")}</h2>
        <div class="copy">
          <p>${_("Use this to export your course to its git repository.")}</p>
          <p>${_("This will then trigger an automatic update of the main LMS site and update the contents of your course visible there to students if automatic git imports are configured.")}</p>
        </div>
31 32
      </div>

33 34 35
      <div class="export-git-controls">
        <h2 class="title">${_("Export Course to Git:")}</h2>

Carson Gee committed
36
        % if not context_course.giturl:
37
        <p class="error-text">${_("giturl must be defined in your course settings before you can export to git.")}</p>
Carson Gee committed
38 39 40
        % else:
        <ul class="list-actions">
          <li class="item-action">
41
            <a class="action action-export-git"" action-primary" href="${reverse('export_git', kwargs=dict(course_key_string=unicode(context_course.id)))}?action=push">
Carson Gee committed
42
              <i class="icon-download"></i>
43
              <span class="copy">${_("Export to Git")}</span>
Carson Gee committed
44 45 46 47
            </a>
          </li>
        </ul>
        % endif
48
      </div>
49
      <div class="messages">
Carson Gee committed
50 51 52 53 54 55 56 57
        % if msg:
          % if failed:
          <h3 class="error-text">${_('Export Failed')}:</h3>
          % else:
          <h3>${_('Export Succeeded')}:</h3>
          % endif
        <pre>${msg|h}</pre>
        % endif
58
      </div>
59
    </article>
60
    <aside class="content-supplementary" role="complementary">
61
      <dl class="export-git-info-block">
Carson Gee committed
62
        <dt>${_("Your course:")}</dt>
63
        <dd class="course_text">${context_course.id | h}</dd>
Carson Gee committed
64 65 66
        <dt>${_("Course git url:")}</dt>
        <dd class="giturl_text">${context_course.giturl}</dd>
      </dl>
67
    </aside>
Carson Gee committed
68
  </section>
69 70
</div>
</%block>