settings.html 15.7 KB
Newer Older
Don Mitchell committed
1
<%inherit file="base.html" />
David Baumgold committed
2
<%block name="title">${_("Schedule &amp; Details Settings")}</%block>
3
<%block name="bodyclass">is-signedin course schedule view-settings feature-upload</%block>
Don Mitchell committed
4 5

<%namespace name='static' file='static_content.html'/>
6
<%!
7
  from django.utils.translation import ugettext as _
cahrens committed
8
  from xmodule.modulestore.django import loc_mapper
9 10
%>

Don Mitchell committed
11 12
<%block name="jsextra">
  <link rel="stylesheet" type="text/css" href="${static.url('js/vendor/timepicker/jquery.timepicker.css')}" />
13

14 15 16 17
  <script type="text/template" id="upload-dialog-tpl">
    <%static:include path="js/upload-dialog.underscore" />
  </script>

Don Mitchell committed
18
  <script type="text/javascript">
19 20 21 22
window.CMS = window.CMS || {};
CMS.URL = CMS.URL || {};
CMS.URL.UPLOAD_ASSET = '${upload_asset_url}';

23 24
require(["domReady!", "jquery", "js/models/settings/course_details", "js/views/settings/main"],
  function(doc, $, CourseDetailsModel, MainView) {
cahrens committed
25
    // highlighting labels when fields are focused in
26 27 28 29
    $("form :input").focus(function() {
      $("label[for='" + this.id + "']").addClass("is-focused");
    }).blur(function() {
      $("label").removeClass("is-focused");
30
      });
31 32 33 34 35 36 37 38 39 40 41
    var model = new CourseDetailsModel();
    model.urlRoot = '${details_url}';
    model.fetch({
      success: function(model) {
        var editor = new MainView({
            el: $('.settings-details'),
            model: model
        });
        editor.render();
      },
      reset: true
Don Mitchell committed
42
    });
43
});
Don Mitchell committed
44 45 46 47
  </script>
</%block>

<%block name="content">
48
<div class="wrapper-mast wrapper">
49
  <header class="mast has-subtitle">
Brian Talbot committed
50
    <h1 class="page-header">
51 52
      <small class="subtitle">${_("Settings")}</small>
      <span class="sr">&gt; </span>${_("Schedule & Details")}
Brian Talbot committed
53
    </h1>
54 55
  </header>
</div>
Don Mitchell committed
56

57 58 59
<div class="wrapper-content wrapper">
  <section class="content">
    <article class="content-primary" role="main">
60
      <form id="settings_details" class="settings-details" method="post" action="">
61
        <section class="group-settings basic">
62
          <header>
63 64
            <h2 class="title-2">${_("Basic Information")}</h2>
            <span class="tip">${_("The nuts and bolts of your course")}</span>
65 66
          </header>

67 68
          <ol class="list-input">
            <li class="field text is-not-editable" id="field-course-organization">
69
              <label for="course-organization">${_("Organization")}</label>
Don Mitchell committed
70 71
              <input title="${_('This field is disabled: this information cannot be changed.')}" type="text" 
                class="long" id="course-organization" readonly />
72
            </li>
73

74
            <li class="field text is-not-editable" id="field-course-number">
75
              <label for="course-number">${_("Course Number")}</label>
Don Mitchell committed
76 77
              <input title="${_('This field is disabled: this information cannot be changed.')}" type="text" 
                class="short" id="course-number" readonly>
78 79 80
            </li>

            <li class="field text is-not-editable" id="field-course-name">
81
              <label for="course-name">${_("Course Name")}</label>
Don Mitchell committed
82 83
              <input title="${_('This field is disabled: this information cannot be changed.')}" type="text" 
                class="long" id="course-name" readonly />
84 85
            </li>
          </ol>
86

87
          % if about_page_editable:
88
          <div class="note note-promotion note-promotion-courseURL has-actions">
89
            <h3 class="title">${_("Course Summary Page")} <span class="tip">${_("(for student enrollment and access)")}</span></h3>
90
            <div class="copy">
Don Mitchell committed
91
              <p><a class="link-courseURL" rel="external" href="https:${lms_link_for_about_page}">https:${lms_link_for_about_page}</a></p>
92
            </div>
93

94 95
            <ul class="list-actions">
              <li class="action-item">
Don Mitchell committed
96 97 98
                <a title="${_('Send a note to students via email')}" 
                    href="mailto:someone@domain.com?Subject=Enroll%20in%20${context_course.display_name_with_default}&body=The%20course%20&quot;${context_course.display_name_with_default}&quot;,%20provided%20by%20edX,%20is%20open%20for%20enrollment.%20Please%20navigate%20to%20this%20course%20at%20https:${lms_link_for_about_page}%20to%20enroll." class="action action-primary">
                    <i class="icon-envelope-alt icon-inline"></i>${_("Invite your students")}</a>
99 100 101
              </li>
            </ul>
          </div>
102
          % endif
103 104 105

          % if not about_page_editable:
          <div class="notice notice-incontext notice-workflow">
106
            <h3 class="title">${_("Promoting Your Course with edX")}</h3>
107
            <div class="copy">
108 109 110 111
              <p>${_('Your course summary page will not be viewable until your '
                      'course has been announced. To provide content for the '
                      'page and preview it, follow the instructions provided '
                      'by your <abbr title="Program Manager">PM</abbr>.')}</p>
112 113 114
            </div>
          </div>
          % endif
115
        </section>
Don Mitchell committed
116

117
        <hr class="divide" />
118

119
        <section class="group-settings schedule">
120
          <header>
121
            <h2 class="title-2">${_('Course Schedule')}</h2>
122
            <span class="tip">${_('Dates that control when your course can be viewed')}</span>
123
          </header>
Don Mitchell committed
124

125 126 127
          <ol class="list-input">
            <li class="field-group field-group-course-start" id="course-start">
              <div class="field date" id="field-course-start-date">
128
                <label for="course-start-date">${_("Course Start Date")}</label>
129
                <input type="text" class="start-date date start datepicker" id="course-start-date" placeholder="MM/DD/YYYY" autocomplete="off" />
130
                <span class="tip tip-stacked">${_("First day the course begins")}</span>
131
              </div>
132 133

              <div class="field time" id="field-course-start-time">
134
                <label for="course-start-time">${_("Course Start Time")}</label>
135
                <input type="text" class="time start timepicker" id="course-start-time" value="" placeholder="HH:MM" autocomplete="off" />
136 137
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
138 139 140 141
            </li>

            <li class="field-group field-group-course-end" id="course-end">
              <div class="field date" id="field-course-end-date">
142
                <label for="course-end-date">${_("Course End Date")}</label>
143
                <input type="text" class="end-date date end" id="course-end-date" placeholder="MM/DD/YYYY" autocomplete="off" />
144
                <span class="tip tip-stacked">${_("Last day your course is active")}</span>
145
              </div>
146 147

              <div class="field time" id="field-course-end-time">
148
                <label for="course-end-time">${_("Course End Time")}</label>
149
                <input type="text" class="time end" id="course-end-time" value="" placeholder="HH:MM" autocomplete="off" />
150 151 152
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
            </li>
153
          </ol>
154

155 156 157
          <ol class="list-input">
            <li class="field-group field-group-enrollment-start" id="enrollment-start">
              <div class="field date" id="field-enrollment-start-date">
158
                <label for="course-enrollment-start-date">${_("Enrollment Start Date")}</label>
159
                <input type="text" class="start-date date start" id="course-enrollment-start-date" placeholder="MM/DD/YYYY" autocomplete="off" />
160
                <span class="tip tip-stacked">${_("First day students can enroll")}</span>
161
              </div>
162 163

              <div class="field time" id="field-enrollment-start-time">
164
                <label for="course-enrollment-start-time">${_("Enrollment Start Time")}</label>
165
                <input type="text" class="time start" id="course-enrollment-start-time" value="" placeholder="HH:MM" autocomplete="off" />
166 167
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
168 169 170 171
            </li>

            <li class="field-group field-group-enrollment-end" id="enrollment-end">
              <div class="field date" id="field-enrollment-end-date">
172
                <label for="course-enrollment-end-date">${_("Enrollment End Date")}</label>
173
                <input type="text" class="end-date date end" id="course-enrollment-end-date" placeholder="MM/DD/YYYY" autocomplete="off" />
174
                <span class="tip tip-stacked">${_("Last day students can enroll")}</span>
175
              </div>
176 177

              <div class="field time" id="field-enrollment-end-time">
178
                <label for="course-enrollment-end-time">${_("Enrollment End Time")}</label>
179
                <input type="text" class="time end" id="course-enrollment-end-time" value="" placeholder="HH:MM" autocomplete="off" />
180 181 182
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
            </li>
183
          </ol>
184 185 186

          % if not about_page_editable:
          <div class="notice notice-incontext notice-workflow">
187
            <h3 class="title">${_("These Dates Are Not Used When Promoting Your Course")}</h3>
188 189 190 191 192
            <div class="copy">
              <p>${_('These dates impact <strong>when your courseware can be viewed</strong>, but they are <strong>not the dates shown on your course summary page</strong>.  To provide the course start and registration dates as shown on your course summary page, follow the instructions provided by your <abbr title="Program Manager">PM</abbr> or Conrad Warre <a rel="email" class="action action-email" href="mailto:conrad@edx.org">(conrad@edx.org)</a>.')}</p>
            </div>
          </div>
          % endif
193
        </section>
194
        <hr class="divide" />
195 196 197 198 199 200
            <section class="group-settings marketing">
              <header>
                <h2 class="title-2">${_("Introducing Your Course")}</h2>
                <span class="tip">${_("Information for prospective students")}</span>
              </header>
              <ol class="list-input">
201
                % if about_page_editable:
202 203 204
                <li class="field text" id="field-course-overview">
                  <label for="course-overview">${_("Course Overview")}</label>
                  <textarea class="tinymce text-editor" id="course-overview"></textarea>
205 206 207
                  <%def name='overview_text()'><%
                    a_link_start = '<a class="link-courseURL" rel="external" href="'
                    a_link_end = '">' + _("your course summary page") + '</a>'
Don Mitchell committed
208
                    a_link = a_link_start + lms_link_for_about_page + a_link_end
209 210 211
                    text = _("Introductions, prerequisites, FAQs that are used on %s (formatted in HTML)") % a_link
                    %>${text}</%def>
                  <span class="tip tip-stacked">${overview_text()}</span>
212
                </li>
213
                % endif
214

215 216 217 218
                <li class="field image" id="field-course-image">
                  <label>${_("Course Image")}</label>
                  <div class="current current-course-image">
                    % if context_course.course_image:
219
                    <span class="wrapper-course-image">
Don Mitchell committed
220
                      <img class="course-image" id="course-image" src="${course_image_url}" alt="${_('Course Image')}"/>
221 222
                    </span>

Don Mitchell committed
223 224 225
                    <span class="msg msg-help">
                    ${_("You can manage this image along with all of your other <a href='{}'>files &amp; uploads</a>").format(upload_asset_url)}
                    </span>
226 227 228

                    % else:
                    <span class="wrapper-course-image">
Don Mitchell committed
229
                      <img class="course-image placeholder" id="course-image" src="${course_image_url}" alt="${_('Course Image')}"/>
230
                    </span>
231
                    <span class="msg msg-empty">${_("Your course currently does not have an image. Please upload one (JPEG or PNG format, and minimum suggested dimensions are 375px wide by 200px tall)")}</span>
232 233 234
                    % endif
                  </div>

235 236 237
                  <div class="wrapper-input">
                    <div class="input">
                      <input type="text" class="long new-course-image-url" id="course-image-url" value="" placeholder="Your course image URL" autocomplete="off" />
238
                      <span class="tip tip-stacked">${_("Please provide a valid path and name to your course image (Note: only JPEG or PNG format supported)")}</span>
239 240
                    </div>
                    <button type="button" class="action action-upload-image">${_("Upload Course Image")}</button>
241 242 243
                  </div>
                </li>

244
                % if about_page_editable:
245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260
                <li class="field video" id="field-course-introduction-video">
                  <label for="course-overview">${_("Course Introduction Video")}</label>
                  <div class="input input-existing">
                    <div class="current current-course-introduction-video">
                      <iframe width="618" height="350" src="" frameborder="0" allowfullscreen></iframe>
                    </div>
                    <div class="actions">
                      <a href="#" class="remove-item remove-course-introduction-video remove-video-data"><span class="delete-icon"></span>${_("Delete Current Video")}</a>
                    </div>
                  </div>

                  <div class="input">
                    <input type="text" class="long new-course-introduction-video add-video-data" id="course-introduction-video" value="" placeholder="your YouTube video's ID" autocomplete="off" />
                    <span class="tip tip-stacked">${_("Enter your YouTube video's ID (along with any restriction parameters)")}</span>
                  </div>
                </li>
261
                % endif
262 263 264
              </ol>
            </section>

265
          % if about_page_editable:
266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281
            <hr class="divide" />

            <section class="group-settings requirements">
              <header>
                <h2 class="title-2">${_("Requirements")}</h2>
                <span class="tip">${_("Expectations of the students taking this course")}</span>
              </header>

              <ol class="list-input">
                <li class="field text" id="field-course-effort">
                  <label for="course-effort">${_("Hours of Effort per Week")}</label>
                  <input type="text" class="short time" id="course-effort" placeholder="HH:MM" />
                  <span class="tip tip-inline">${_("Time spent on all course work")}</span>
                </li>
              </ol>
            </section>
282
          % endif
283 284 285
      </form>
    </article>
    <aside class="content-supplementary" role="complimentary">
286
     <div class="bit">
287 288
        <h3 class="title-3">${_("How are these settings used?")}</h3>
        <p>${_("Your course's schedule determines when students can enroll in and begin a course.")}</p>
289

290
        <p>${_("Other information from this page appears on the About page for your course. This information includes the course overview, course image, introduction video, and estimated time requirements. Students use About pages to choose new courses to take.")}</p>
291
     </div>
292

293 294 295
     <div class="bit">
     % if context_course:
          <%
Don Mitchell committed
296 297
            course_team_url = course_locator.url_reverse('course_team/', '')
            grading_config_url = course_locator.url_reverse('settings/grading/')
298
            advanced_config_url = course_locator.url_reverse('settings/advanced/')
299
          %>
300
        <h3 class="title-3">${_("Other Course Settings")}</h3>
301 302
        <nav class="nav-related">
          <ul>
Don Mitchell committed
303
            <li class="nav-item"><a href="${grading_config_url}">${_("Grading")}</a></li>
304
            <li class="nav-item"><a href="${course_team_url}">${_("Course Team")}</a></li>
305
            <li class="nav-item"><a href="${advanced_config_url}">${_("Advanced Settings")}</a></li>
306 307
          </ul>
        </nav>
308 309
     % endif
     </div>
310 311 312
    </aside>
  </section>
</div>
313
</%block>