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
ab88da95
Commit
ab88da95
authored
Jan 18, 2017
by
Saleem Latif
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update settings for edx-enterprise (v0.19.1) configurations.
parent
576f6755
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
8 deletions
+13
-8
common/djangoapps/util/enterprise_helpers.py
+3
-3
common/djangoapps/util/tests/test_enterprise_helpers.py
+4
-4
lms/envs/common.py
+5
-0
requirements/edx/base.txt
+1
-1
No files found.
common/djangoapps/util/enterprise_helpers.py
View file @
ab88da95
...
@@ -7,7 +7,7 @@ import logging
...
@@ -7,7 +7,7 @@ import logging
try
:
try
:
from
enterprise.models
import
EnterpriseCustomer
from
enterprise.models
import
EnterpriseCustomer
from
enterprise
import
api
as
enterprise_api
from
enterprise
import
utils
as
enterprise_utils
from
enterprise.tpa_pipeline
import
(
from
enterprise.tpa_pipeline
import
(
active_provider_requests_data_sharing
,
active_provider_requests_data_sharing
,
active_provider_enforces_data_sharing
,
active_provider_enforces_data_sharing
,
...
@@ -142,9 +142,9 @@ def get_enterprise_customer_logo_url(request):
...
@@ -142,9 +142,9 @@ def get_enterprise_customer_logo_url(request):
ec_uuid
=
parameter
.
get
(
'ec_uuid'
,
None
)
ec_uuid
=
parameter
.
get
(
'ec_uuid'
,
None
)
if
provider_id
:
if
provider_id
:
branding_info
=
enterprise_
api
.
get_enterprise_branding_info_by_provider_id
(
provider_id
=
provider_id
)
branding_info
=
enterprise_
utils
.
get_enterprise_branding_info_by_provider_id
(
identity_
provider_id
=
provider_id
)
elif
ec_uuid
:
elif
ec_uuid
:
branding_info
=
enterprise_
api
.
get_enterprise_branding_info_by_ec_uuid
(
ec_uuid
=
ec_uuid
)
branding_info
=
enterprise_
utils
.
get_enterprise_branding_info_by_ec_uuid
(
ec_uuid
=
ec_uuid
)
logo_url
=
None
logo_url
=
None
if
branding_info
and
branding_info
.
logo
:
if
branding_info
and
branding_info
.
logo
:
...
...
common/djangoapps/util/tests/test_enterprise_helpers.py
View file @
ab88da95
...
@@ -177,12 +177,12 @@ class TestEnterpriseHelpers(unittest.TestCase):
...
@@ -177,12 +177,12 @@ class TestEnterpriseHelpers(unittest.TestCase):
)
)
set_enterprise_branding_filter_param
(
request
,
provider_id
=
None
)
set_enterprise_branding_filter_param
(
request
,
provider_id
=
None
)
with
mock
.
patch
(
'enterprise.
api
.get_enterprise_branding_info_by_ec_uuid'
,
return_value
=
branding_info
):
with
mock
.
patch
(
'enterprise.
utils
.get_enterprise_branding_info_by_ec_uuid'
,
return_value
=
branding_info
):
logo_url
=
get_enterprise_customer_logo_url
(
request
)
logo_url
=
get_enterprise_customer_logo_url
(
request
)
self
.
assertEqual
(
logo_url
,
'/test/image.png'
)
self
.
assertEqual
(
logo_url
,
'/test/image.png'
)
set_enterprise_branding_filter_param
(
request
,
provider_id
)
set_enterprise_branding_filter_param
(
request
,
provider_id
)
with
mock
.
patch
(
'enterprise.
api
.get_enterprise_branding_info_by_provider_id'
,
return_value
=
branding_info
):
with
mock
.
patch
(
'enterprise.
utils
.get_enterprise_branding_info_by_provider_id'
,
return_value
=
branding_info
):
logo_url
=
get_enterprise_customer_logo_url
(
request
)
logo_url
=
get_enterprise_customer_logo_url
(
request
)
self
.
assertEqual
(
logo_url
,
'/test/image.png'
)
self
.
assertEqual
(
logo_url
,
'/test/image.png'
)
...
@@ -195,7 +195,7 @@ class TestEnterpriseHelpers(unittest.TestCase):
...
@@ -195,7 +195,7 @@ class TestEnterpriseHelpers(unittest.TestCase):
branding_info
=
mock
.
Mock
()
branding_info
=
mock
.
Mock
()
set_enterprise_branding_filter_param
(
request
,
'test-idp'
)
set_enterprise_branding_filter_param
(
request
,
'test-idp'
)
with
mock
.
patch
(
'enterprise.
api
.get_enterprise_branding_info_by_provider_id'
,
return_value
=
branding_info
):
with
mock
.
patch
(
'enterprise.
utils
.get_enterprise_branding_info_by_provider_id'
,
return_value
=
branding_info
):
logo_url
=
get_enterprise_customer_logo_url
(
request
)
logo_url
=
get_enterprise_customer_logo_url
(
request
)
self
.
assertEqual
(
logo_url
,
None
)
self
.
assertEqual
(
logo_url
,
None
)
...
@@ -209,6 +209,6 @@ class TestEnterpriseHelpers(unittest.TestCase):
...
@@ -209,6 +209,6 @@ class TestEnterpriseHelpers(unittest.TestCase):
branding_info
=
mock
.
Mock
()
branding_info
=
mock
.
Mock
()
set_enterprise_branding_filter_param
(
request
,
provider_id
=
None
)
set_enterprise_branding_filter_param
(
request
,
provider_id
=
None
)
with
mock
.
patch
(
'enterprise.
api
.get_enterprise_branding_info_by_provider_id'
,
return_value
=
branding_info
):
with
mock
.
patch
(
'enterprise.
utils
.get_enterprise_branding_info_by_provider_id'
,
return_value
=
branding_info
):
logo_url
=
get_enterprise_customer_logo_url
(
request
)
logo_url
=
get_enterprise_customer_logo_url
(
request
)
self
.
assertEqual
(
logo_url
,
None
)
self
.
assertEqual
(
logo_url
,
None
)
lms/envs/common.py
View file @
ab88da95
...
@@ -2187,6 +2187,10 @@ REST_FRAMEWORK = {
...
@@ -2187,6 +2187,10 @@ REST_FRAMEWORK = {
),
),
'PAGE_SIZE'
:
10
,
'PAGE_SIZE'
:
10
,
'URL_FORMAT_OVERRIDE'
:
None
,
'URL_FORMAT_OVERRIDE'
:
None
,
'DEFAULT_THROTTLE_RATES'
:
{
'user'
:
'60/minute'
,
'service_user'
:
'120/minute'
,
},
}
}
...
@@ -2830,6 +2834,7 @@ ECOMMERCE_API_URL = None
...
@@ -2830,6 +2834,7 @@ ECOMMERCE_API_URL = None
ECOMMERCE_API_SIGNING_KEY
=
None
ECOMMERCE_API_SIGNING_KEY
=
None
ECOMMERCE_API_TIMEOUT
=
5
ECOMMERCE_API_TIMEOUT
=
5
ECOMMERCE_SERVICE_WORKER_USERNAME
=
'ecommerce_worker'
ECOMMERCE_SERVICE_WORKER_USERNAME
=
'ecommerce_worker'
ENTERPRISE_SERVICE_WORKER_USERNAME
=
'enterprise_worker'
COURSE_CATALOG_API_URL
=
None
COURSE_CATALOG_API_URL
=
None
...
...
requirements/edx/base.txt
View file @
ab88da95
...
@@ -48,7 +48,7 @@ edx-i18n-tools==0.3.7
...
@@ -48,7 +48,7 @@ edx-i18n-tools==0.3.7
edx-lint==0.4.3
edx-lint==0.4.3
edx-django-oauth2-provider==1.1.4
edx-django-oauth2-provider==1.1.4
edx-django-sites-extensions==2.1.1
edx-django-sites-extensions==2.1.1
edx-enterprise==0.
9.0
edx-enterprise==0.
19.1
edx-oauth2-provider==1.2.0
edx-oauth2-provider==1.2.0
edx-opaque-keys==0.4.0
edx-opaque-keys==0.4.0
edx-organizations==0.4.2
edx-organizations==0.4.2
...
...
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