settings.html 15.9 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 8
  from contentstore import utils
  from django.utils.translation import ugettext as _
9 10
%>

Don Mitchell committed
11 12 13

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

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

Don Mitchell committed
19
  <script type="text/javascript">
20 21 22 23 24 25 26
require(["domReady!", "jquery", "js/models/settings/course_details", "js/views/settings/main"],
  function(doc, $, CourseDetailsModel, MainView) {
    // hilighting labels when fields are focused in
    $("form :input").focus(function() {
      $("label[for='" + this.id + "']").addClass("is-focused");
    }).blur(function() {
      $("label").removeClass("is-focused");
27
      });
28 29 30 31 32 33 34 35 36 37 38
    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
39
    });
40

41 42
    CMS.URL.UPLOAD_ASSET = '${upload_asset_url}';
});
Don Mitchell committed
43 44 45 46
  </script>
</%block>

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

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

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

72
            <li class="field text is-not-editable" id="field-course-number">
73 74
              <label for="course-number">${_("Course Number")}</label>
              <input title="${_('This field is disabled: this information cannot be changed.')}" type="text" class="short" id="course-number" value="[Course No.]" readonly>
75 76 77
            </li>

            <li class="field text is-not-editable" id="field-course-name">
78 79
              <label for="course-name">${_("Course Name")}</label>
              <input title="${_('This field is disabled: this information cannot be changed.')}" type="text" class="long" id="course-name" value="[Course Name]" readonly />
80 81
            </li>
          </ol>
82

83
          % if about_page_editable:
84
          <div class="note note-promotion note-promotion-courseURL has-actions">
85
            <h3 class="title">${_("Course Summary Page")} <span class="tip">${_("(for student enrollment and access)")}</span></h3>
86
            <div class="copy">
87
              <p><a class="link-courseURL" rel="external" href="https:${utils.get_lms_link_for_about_page(course_location)}" />https:${utils.get_lms_link_for_about_page(course_location)}</a></p>
88
            </div>
89

90 91
            <ul class="list-actions">
              <li class="action-item">
92
                <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:${utils.get_lms_link_for_about_page(course_location)}%20to%20enroll." class="action action-primary"><i class="icon-envelope-alt icon-inline"></i>${_("Invite your students")}</a>
93 94 95
              </li>
            </ul>
          </div>
96
          % endif
97 98 99

          % if not about_page_editable:
          <div class="notice notice-incontext notice-workflow">
100
            <h3 class="title">${_("Promoting Your Course with edX")}</h3>
101
            <div class="copy">
102
              <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> or Conrad Warre <a rel="email" class="action action-email" href="mailto:conrad@edx.org">(conrad@edx.org)</a>.')}</p>
103 104 105
            </div>
          </div>
          % endif
106
        </section>
Don Mitchell committed
107

108
        <hr class="divide" />
109

110
        <section class="group-settings schedule">
111
          <header>
112 113
            <h2 class="title-2">${_('Course Schedule')}</h2>
            <span class="tip">${_('Dates that control when your course can be viewed.')}</span>
114
          </header>
Don Mitchell committed
115

116 117 118
          <ol class="list-input">
            <li class="field-group field-group-course-start" id="course-start">
              <div class="field date" id="field-course-start-date">
119
                <label for="course-start-date">${_("Course Start Date")}</label>
120
                <input type="text" class="start-date date start datepicker" id="course-start-date" placeholder="MM/DD/YYYY" autocomplete="off" />
121
                <span class="tip tip-stacked">${_("First day the course begins")}</span>
122
              </div>
123 124

              <div class="field time" id="field-course-start-time">
125
                <label for="course-start-time">${_("Course Start Time")}</label>
126
                <input type="text" class="time start timepicker" id="course-start-time" value="" placeholder="HH:MM" autocomplete="off" />
127 128
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
129 130 131 132
            </li>

            <li class="field-group field-group-course-end" id="course-end">
              <div class="field date" id="field-course-end-date">
133
                <label for="course-end-date">${_("Course End Date")}</label>
134
                <input type="text" class="end-date date end" id="course-end-date" placeholder="MM/DD/YYYY" autocomplete="off" />
135
                <span class="tip tip-stacked">${_("Last day your course is active")}</span>
136
              </div>
137 138

              <div class="field time" id="field-course-end-time">
139
                <label for="course-end-time">${_("Course End Time")}</label>
140
                <input type="text" class="time end" id="course-end-time" value="" placeholder="HH:MM" autocomplete="off" />
141 142 143
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
            </li>
144
          </ol>
145

146 147 148
          <ol class="list-input">
            <li class="field-group field-group-enrollment-start" id="enrollment-start">
              <div class="field date" id="field-enrollment-start-date">
149
                <label for="course-enrollment-start-date">${_("Enrollment Start Date")}</label>
150
                <input type="text" class="start-date date start" id="course-enrollment-start-date" placeholder="MM/DD/YYYY" autocomplete="off" />
151
                <span class="tip tip-stacked">${_("First day students can enroll")}</span>
152
              </div>
153 154

              <div class="field time" id="field-enrollment-start-time">
155
                <label for="course-enrollment-start-time">${_("Enrollment Start Time")}</label>
156
                <input type="text" class="time start" id="course-enrollment-start-time" value="" placeholder="HH:MM" autocomplete="off" />
157 158
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
159 160 161 162
            </li>

            <li class="field-group field-group-enrollment-end" id="enrollment-end">
              <div class="field date" id="field-enrollment-end-date">
163
                <label for="course-enrollment-end-date">${_("Enrollment End Date")}</label>
164
                <input type="text" class="end-date date end" id="course-enrollment-end-date" placeholder="MM/DD/YYYY" autocomplete="off" />
165
                <span class="tip tip-stacked">${_("Last day students can enroll")}</span>
166
              </div>
167 168

              <div class="field time" id="field-enrollment-end-time">
169
                <label for="course-enrollment-end-time">${_("Enrollment End Time")}</label>
170
                <input type="text" class="time end" id="course-enrollment-end-time" value="" placeholder="HH:MM" autocomplete="off" />
171 172 173
                <span class="tip tip-stacked" id="timezone"></span>
              </div>
            </li>
174
          </ol>
175 176 177

          % if not about_page_editable:
          <div class="notice notice-incontext notice-workflow">
178
            <h3 class="title">${_("These Dates Are Not Used When Promoting Your Course")}</h3>
179 180 181 182 183
            <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
184
        </section>
185
        <hr class="divide" />
186 187 188 189 190 191
            <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">
192
                % if about_page_editable:
193 194 195
                <li class="field text" id="field-course-overview">
                  <label for="course-overview">${_("Course Overview")}</label>
                  <textarea class="tinymce text-editor" id="course-overview"></textarea>
196 197 198 199 200 201 202
                  <%def name='overview_text()'><%
                    a_link_start = '<a class="link-courseURL" rel="external" href="'
                    a_link_end = '">' + _("your course summary page") + '</a>'
                    a_link = a_link_start + utils.get_lms_link_for_about_page(course_location) + a_link_end
                    text = _("Introductions, prerequisites, FAQs that are used on %s (formatted in HTML)") % a_link
                    %>${text}</%def>
                  <span class="tip tip-stacked">${overview_text()}</span>
203
                </li>
204
                % endif
205

206 207 208 209
                <li class="field image" id="field-course-image">
                  <label>${_("Course Image")}</label>
                  <div class="current current-course-image">
                    % if context_course.course_image:
210 211 212 213 214 215 216 217 218 219 220
                    <span class="wrapper-course-image">
                      <img class="course-image" id="course-image" src="${utils.course_image_url(context_course)}" alt="${_('Course Image')}"/>
                    </span>

                    <% ctx_loc = context_course.location %>
                    <span class="msg msg-help">${_("You can manage this image along with all of your other")} <a href="${reverse('asset_index', kwargs=dict(org=ctx_loc.org, course=ctx_loc.course, name=ctx_loc.name))}">${_("files &amp; uploads")}</a></span>

                    % else:
                    <span class="wrapper-course-image">
                      <img class="course-image placeholder" id="course-image" src="${utils.course_image_url(context_course)}" alt="${_('Course Image')}"/>
                    </span>
221
                    <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>
222 223 224
                    % endif
                  </div>

225 226 227
                  <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" />
228
                      <span class="tip tip-stacked">${_("Please provide a valid path and name to your course image (Note: only JPEG or PNG format supported)")}</span>
229 230
                    </div>
                    <button type="button" class="action action-upload-image">${_("Upload Course Image")}</button>
231 232 233
                  </div>
                </li>

234
                % if about_page_editable:
235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250
                <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>
251
                % endif
252 253 254
              </ol>
            </section>

255
          % if about_page_editable:
256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271
            <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>
272
          % endif
273 274 275
      </form>
    </article>
    <aside class="content-supplementary" role="complimentary">
276
     <div class="bit">
277 278
        <h3 class="title-3">${_("How will these settings be used?")}</h3>
        <p>${_("Your course's schedule settings determine when students can enroll in and begin a course.")}</p>
279

280
        <p>${_("Additionally, details provided on this page are also used in edX's catalog of courses, which new and returning students use to choose new courses to study.")}</p>
281
      </div>
282 283

      <div class="bit">
284 285 286
      % if context_course:
      <% ctx_loc = context_course.location %>
      <%! from django.core.urlresolvers import reverse %>
287
        <h3 class="title-3">${_("Other Course Settings")}</h3>
288 289
        <nav class="nav-related">
          <ul>
290
            <li class="nav-item"><a href="${reverse('contentstore.views.course_config_graders_page', kwargs={'org' : ctx_loc.org, 'course' : ctx_loc.course, 'name': ctx_loc.name})}">${_("Grading")}</a></li>
291
            <li class="nav-item"><a href="${reverse('manage_users', kwargs=dict(org=ctx_loc.org, course=ctx_loc.course, name=ctx_loc.name))}">${_("Course Team")}</a></li>
292
            <li class="nav-item"><a href="${reverse('course_advanced_settings', kwargs={'org' : ctx_loc.org, 'course' : ctx_loc.course, 'name': ctx_loc.name})}">${_("Advanced Settings")}</a></li>
293 294
          </ul>
        </nav>
295
      % endif
296 297 298 299
      </div>
    </aside>
  </section>
</div>
300
</%block>