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
cc8e8ba6
Commit
cc8e8ba6
authored
Jan 09, 2013
by
Brian Wilson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pearson reg: relax validation of phone country codes.
parent
21fe5827
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
7 deletions
+1
-7
common/djangoapps/student/models.py
+1
-7
No files found.
common/djangoapps/student/models.py
View file @
cc8e8ba6
...
@@ -288,12 +288,6 @@ class TestCenterUserForm(ModelForm):
...
@@ -288,12 +288,6 @@ class TestCenterUserForm(ModelForm):
def
clean_country
(
self
):
def
clean_country
(
self
):
return
self
.
check_country_code
(
'country'
)
return
self
.
check_country_code
(
'country'
)
def
clean_phone_country_code
(
self
):
return
self
.
check_country_code
(
'phone_country_code'
)
def
clean_fax_country_code
(
self
):
return
self
.
check_country_code
(
'fax_country_code'
)
def
clean
(
self
):
def
clean
(
self
):
cleaned_data
=
super
(
TestCenterUserForm
,
self
)
.
clean
()
cleaned_data
=
super
(
TestCenterUserForm
,
self
)
.
clean
()
...
@@ -317,7 +311,7 @@ class TestCenterUserForm(ModelForm):
...
@@ -317,7 +311,7 @@ class TestCenterUserForm(ModelForm):
cleaned_data_fields
=
[
fieldname
for
fieldname
in
cleaned_data
]
cleaned_data_fields
=
[
fieldname
for
fieldname
in
cleaned_data
]
for
fieldname
in
cleaned_data_fields
:
for
fieldname
in
cleaned_data_fields
:
if
not
TestCenterUserForm
.
can_encode_as_latin
(
cleaned_data
[
fieldname
]):
if
not
TestCenterUserForm
.
can_encode_as_latin
(
cleaned_data
[
fieldname
]):
self
.
_errors
[
fieldname
]
=
self
.
error_class
([
u'Must only use characters in Latin-1 encoding'
])
self
.
_errors
[
fieldname
]
=
self
.
error_class
([
u'Must only use characters in Latin-1
(iso-8859-1)
encoding'
])
del
cleaned_data
[
fieldname
]
del
cleaned_data
[
fieldname
]
# Always return the full collection of cleaned data.
# Always return the full collection of cleaned data.
...
...
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