Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
a13cea73
Commit
a13cea73
authored
Aug 29, 2013
by
Pavel Yushchenko
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'select' of
https://github.com/Man2Life/edx-platform
into select
parents
8a78e74e
a40a8846
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
42 additions
and
1 deletions
+42
-1
lms/envs/common.py
+7
-0
lms/templates/dashboard.html
+30
-1
lms/urls.py
+5
-0
No files found.
lms/envs/common.py
View file @
a13cea73
...
...
@@ -238,6 +238,10 @@ TEMPLATE_CONTEXT_PROCESSORS = (
# Hack to get required link URLs to password reset templates
'mitxmako.shortcuts.marketing_link_context_processor'
,
# ...
"announcements.context_processors.site_wide_announcements"
,
# ..
)
# use the ratelimit backend to prevent brute force attacks
...
...
@@ -728,6 +732,9 @@ INSTALLED_APPS = (
'djcelery'
,
'south'
,
'announcements'
,
# Monitor the status of services
'service_status'
,
...
...
lms/templates/dashboard.html
View file @
a13cea73
...
...
@@ -11,7 +11,6 @@
<
%
namespace
name=
'static'
file=
'static_content.html'
/>
<
%
block
name=
"title"
><title>
${_("Dashboard")}
</title></
%
block>
<
%
block
name=
"js_extra"
>
<script
type=
"text/javascript"
>
(
function
()
{
...
...
@@ -91,6 +90,36 @@
</section>
%endif
<style>
div
.announcements-wrapper
section
.announcements
>
ol
{
list-style
:
none
;
margin-bottom
:
1.41575em
;
padding-left
:
0
;
}
div
.announcements-wrapper
section
.announcements
>
ol
>
li
h2
{
font-size
:
0.875em
;
font-weight
:
bold
;
background
:
url("/static/images/calendar-icon.png")
0
center
no-repeat
;
padding-left
:
20px
;
}
</style>
% if site_wide_announcements:
<div
class=
"announcements-wrapper"
>
<section
class=
"announcements"
>
<ol>
% for announcement in site_wide_announcements:
<li
class=
"announcement"
>
<h2
class=
"title"
><span
class=
"date"
>
${announcement.creation_date}
<span>
${announcement}
</h2>
${announcement.content}
<!-- <a id="hide" href="${reverse('announcement_hide', args=[announcement.pk])}?next=${request.path}">Убрать</a> -->
</li>
% endfor
</ol>
</section>
</div>
% endif
<section
class=
"profile-sidebar"
>
<header
class=
"profile"
>
<h1
class=
"user-name"
>
${ user.username }
</h1>
...
...
lms/urls.py
View file @
a13cea73
...
...
@@ -13,6 +13,11 @@ if settings.DEBUG or settings.MITX_FEATURES.get('ENABLE_DJANGO_ADMIN_SITE'):
admin
.
autodiscover
()
urlpatterns
=
(
''
,
# nopep8
# ...
url
(
r"^announcements/"
,
include
(
"announcements.urls"
)),
# ...
# certificate view
url
(
r'^update_certificate$'
,
'certificates.views.update_certificate'
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment