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
87daeca8
Commit
87daeca8
authored
Nov 02, 2017
by
Bessie Steinberg
Committed by
Bill Filler
Nov 30, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove logs
parent
2ad918c1
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
30 additions
and
3 deletions
+30
-3
lms/djangoapps/courseware/views/views.py
+7
-0
lms/envs/devstack_docker.py
+1
-1
manage.py
+5
-1
openedx/core/djangoapps/plugin_api/views.py
+10
-0
openedx/features/course_experience/views/course_home.py
+4
-0
openedx/features/enterprise_support/api.py
+3
-1
No files found.
lms/djangoapps/courseware/views/views.py
View file @
87daeca8
...
...
@@ -459,14 +459,21 @@ class CourseTabView(EdxFragmentView):
course
=
get_course_with_access
(
request
.
user
,
'load'
,
course_key
)
try
:
# Render the page
logging
.
info
(
u' >> tab_type:
%
s'
,
tab_type
)
tab
=
CourseTabList
.
get_tab_by_type
(
course
.
tabs
,
tab_type
)
logging
.
info
(
u' >> tab:
%
s'
,
tab
)
logging
.
info
(
u' >> tab str:
%
s'
,
str
(
tab
))
page_context
=
self
.
create_page_context
(
request
,
course
=
course
,
tab
=
tab
,
**
kwargs
)
logging
.
info
(
u' >> page_context:
%
s'
,
page_context
)
# Show warnings if the user has limited access
# Must come after masquerading on creation of page context
self
.
register_user_access_warning_messages
(
request
,
course_key
)
set_custom_metrics_for_course_key
(
course_key
)
logging
.
info
(
u' >> CourseTabView parent class:
%
s'
,
super
(
CourseTabView
,
self
))
return
super
(
CourseTabView
,
self
)
.
get
(
request
,
course
=
course
,
page_context
=
page_context
,
**
kwargs
)
except
Exception
as
exception
:
# pylint: disable=broad-except
return
CourseTabView
.
handle_exceptions
(
request
,
course
,
exception
)
...
...
lms/envs/devstack_docker.py
View file @
87daeca8
...
...
@@ -40,7 +40,7 @@ FEATURES.update({
'ENABLE_DASHBOARD_SEARCH'
:
False
,
'ENABLE_DISCUSSION_SERVICE'
:
True
,
'SHOW_HEADER_LANGUAGE_SELECTOR'
:
True
,
'ENABLE_ENTERPRISE_INTEGRATION'
:
Fals
e
,
'ENABLE_ENTERPRISE_INTEGRATION'
:
Tru
e
,
})
ENABLE_MKTG_SITE
=
os
.
environ
.
get
(
'ENABLE_MARKETING_SITE'
,
False
)
...
...
manage.py
View file @
87daeca8
...
...
@@ -112,5 +112,9 @@ if __name__ == "__main__":
startup
.
run
()
from
django.core.management
import
execute_from_command_line
import
ptvsd
try
:
ptvsd
.
enable_attach
(
"my_secret"
,
address
=
(
'0.0.0.0'
,
21000
))
except
:
pass
execute_from_command_line
([
sys
.
argv
[
0
]]
+
django_args
)
openedx/core/djangoapps/plugin_api/views.py
View file @
87daeca8
...
...
@@ -27,6 +27,7 @@ class EdxFragmentView(FragmentView):
Respects `PIPELINE_ENABLED` setting.
"""
log
.
info
(
u' >> calling EdxFragmentView.get_css_dependencies()....'
)
if
settings
.
PIPELINE_ENABLED
:
return
[
settings
.
PIPELINE_CSS
[
group
][
'output_filename'
]]
else
:
...
...
@@ -39,6 +40,7 @@ class EdxFragmentView(FragmentView):
Respects `PIPELINE_ENABLED` setting.
"""
log
.
info
(
u' >> calling EdxFragmentView.get_js_dependencies()....'
)
if
settings
.
PIPELINE_ENABLED
:
return
[
settings
.
PIPELINE_JS
[
group
][
'output_filename'
]]
else
:
...
...
@@ -48,24 +50,28 @@ class EdxFragmentView(FragmentView):
"""
Returns list of the vendor JS files that this view depends on.
"""
log
.
info
(
u' >> calling EdxFragmentView.vendor_js_dependencies()....'
)
return
[]
def
js_dependencies
(
self
):
"""
Returns list of the JavaScript files that this view depends on.
"""
log
.
info
(
u' >> calling EdxFragmentView.js_dependencies()....'
)
return
[]
def
css_dependencies
(
self
):
"""
Returns list of the CSS files that this view depends on.
"""
log
.
info
(
u' >> calling EdxFragmentView.css_dependencies()....'
)
return
[]
def
add_fragment_resource_urls
(
self
,
fragment
):
"""
Adds URLs for JS and CSS resources needed by this fragment.
"""
log
.
info
(
u' >> calling EdxFragmentView.add_fragment_resource_urls()....'
)
# Head dependencies
for
vendor_js_file
in
self
.
vendor_js_dependencies
():
fragment
.
add_resource_url
(
staticfiles_storage
.
url
(
vendor_js_file
),
'application/javascript'
,
'head'
)
...
...
@@ -81,6 +87,7 @@ class EdxFragmentView(FragmentView):
"""
Creates the base context for rendering a fragment as a standalone page.
"""
log
.
info
(
u' >> calling EdxFragmentView.create_base_standalone_context()....'
)
return
{
'uses_pattern_library'
:
True
,
'disable_accordion'
:
True
,
...
...
@@ -100,6 +107,7 @@ class EdxFragmentView(FragmentView):
this data being provided but should instead import the functionality
it needs.
"""
log
.
info
(
u' >> calling EdxFragmentView._add_studio_standalone_context_variables()....'
)
context
.
update
({
'request'
:
request
,
'settings'
:
settings
,
...
...
@@ -113,6 +121,7 @@ class EdxFragmentView(FragmentView):
"""
Returns the page title for the standalone page, or None if there is no title.
"""
log
.
info
(
u' >> calling EdxFragmentView.standalone_page_title()....'
)
return
None
def
render_standalone_response
(
self
,
request
,
fragment
,
**
kwargs
):
...
...
@@ -121,6 +130,7 @@ class EdxFragmentView(FragmentView):
Note: if fragment is None, a 204 response will be returned (no content).
"""
log
.
info
(
u' >> calling EdxFragmentView.render_standalone_response()....'
)
if
fragment
is
None
:
return
HttpResponse
(
status
=
204
)
context
=
self
.
create_base_standalone_context
(
request
,
fragment
,
**
kwargs
)
...
...
openedx/features/course_experience/views/course_home.py
View file @
87daeca8
...
...
@@ -37,6 +37,10 @@ from .course_sock import CourseSockFragmentView
from
.latest_update
import
LatestUpdateFragmentView
from
.welcome_message
import
WelcomeMessageFragmentView
import
logging
log
=
logging
.
getLogger
(
__name__
)
EMPTY_HANDOUTS_HTML
=
u'<ol></ol>'
...
...
openedx/features/enterprise_support/api.py
View file @
87daeca8
...
...
@@ -324,7 +324,9 @@ def enterprise_enabled():
"""
Determines whether the Enterprise app is installed
"""
return
'enterprise'
in
settings
.
INSTALLED_APPS
and
settings
.
FEATURES
.
get
(
'ENABLE_ENTERPRISE_INTEGRATION'
,
False
)
is_enabled
=
'enterprise'
in
settings
.
INSTALLED_APPS
and
settings
.
FEATURES
.
get
(
'ENABLE_ENTERPRISE_INTEGRATION'
,
False
)
LOGGER
.
warning
(
"BF!! enterprise enabled=
%
s"
,
is_enabled
)
return
is_enabled
def
enterprise_customer_uuid_for_request
(
request
):
...
...
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