Commit 7ff7f3cd by tasawernawaz Committed by Tasawer Nawaz

history dropdown on course detail page updated

ECOM-7728
parent 1d625153
......@@ -1903,12 +1903,6 @@ class CourseDetailViewTests(TestCase):
response = self.client.get(self.detail_page_url)
self.assertContains(response, 'REVISION HISTORY')
revision_url = reverse(
'publisher:publisher_course_revision', args=[self.course.id, self.course.history.first().history_id]
)
self.assertContains(
response, '<option value="{revision_url}">Latest version</option>'.format(revision_url=revision_url)
)
@ddt.ddt
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-04-19 11:14+0500\n"
"POT-Creation-Date: 2017-04-20 11:50+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......@@ -604,7 +604,6 @@ msgstr ""
#: apps/publisher/forms.py apps/publisher/models.py
#: templates/publisher/course_detail.html
#: templates/publisher/course_revision_history.html
#: templates/publisher/course_run_detail/_all.html
msgid "Expected Learnings"
msgstr ""
......@@ -1151,7 +1150,8 @@ msgid "REVISION HISTORY"
msgstr ""
#: templates/publisher/_history_widget.html
msgid "Latest version"
#, python-format
msgid "%(history_date)s&nbsp;by&nbsp;%(changed_by)s (Latest version)"
msgstr ""
#: templates/publisher/_history_widget.html
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-04-19 11:14+0500\n"
"POT-Creation-Date: 2017-04-20 11:50+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-04-19 11:14+0500\n"
"POT-Creation-Date: 2017-04-20 11:50+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......@@ -729,7 +729,6 @@ msgstr "Tértïärý (öptïönäl) Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт
#: apps/publisher/forms.py apps/publisher/models.py
#: templates/publisher/course_detail.html
#: templates/publisher/course_revision_history.html
#: templates/publisher/course_run_detail/_all.html
msgid "Expected Learnings"
msgstr "Éxpéçtéd Léärnïngs Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αмєт#"
......@@ -1322,8 +1321,11 @@ msgid "REVISION HISTORY"
msgstr "RÉVÌSÌÖN HÌSTÖRÝ Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт αм#"
#: templates/publisher/_history_widget.html
msgid "Latest version"
msgstr "Lätést vérsïön Ⱡ'σяєм ιρѕυм ∂σłσя ѕιт#"
#, python-format
msgid "%(history_date)s&nbsp;by&nbsp;%(changed_by)s (Latest version)"
msgstr ""
"%(history_date)s&nbsp;ßý&nbsp;%(changed_by)s (Lätést vérsïön) Ⱡ'σяєм ιρѕυм "
"∂σłσя ѕιт αмєт, ¢σηѕє¢т#"
#: templates/publisher/_history_widget.html
#, python-format
......
......@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-04-19 11:14+0500\n"
"POT-Creation-Date: 2017-04-20 11:50+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
......
......@@ -646,10 +646,6 @@
font-size: 14px;
}
#id_select_revisions {
max-width: 50%;
}
.download-image {
text-align: center;
margin-top: 10px;
......
......@@ -5,7 +5,11 @@
<select id="id_select_revisions">
{% for history in history_list %}
{% if forloop.first %}
<option value="{% url 'publisher:publisher_course_revision' course.id history.history_id %}">{% trans "Latest version" %}</option>
<option value="{% url 'publisher:publisher_course_revision' course.id history.history_id %}">
{% blocktrans with history.history_date|date:'d-m-Y' as history_date and history.changed_by as changed_by trimmed %}
{{ history_date }}&nbsp;by&nbsp;{{ changed_by}} (Latest version)
{% endblocktrans %}
</option>
{% else %}
<option data-revision-url="{% url 'publisher:api:course_revisions' history.history_id %}" value="{% url 'publisher:publisher_course_revision' course.id history.history_id %}">
{% blocktrans with history.history_date|date:'d-m-Y' as history_date and history.changed_by as changed_by trimmed %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment