update error message to be more specific to what the user needs to fix

This commit is contained in:
Chris Dodge
2013-07-29 15:24:27 -04:00
committed by Brian Talbot
parent d321406cc3
commit d005323ace
2 changed files with 2 additions and 2 deletions

View File

@@ -990,7 +990,7 @@ class ContentStoreTest(ModuleStoreTestCase):
def test_create_course_duplicate_course(self):
"""Test new course creation - error path"""
self.client.post(reverse('create_new_course'), self.course_data)
self.assert_course_creation_failed('There is already a course defined with the same organization, course number, and course run. Please change at least one field to be unique.')
self.assert_course_creation_failed('There is already a course defined with the same organization, course number, and course run. Please change either organization or course number to be unique.')
def assert_course_creation_failed(self, error_message):
"""

View File

@@ -120,7 +120,7 @@ def create_new_course(request):
if existing_course is not None:
return JsonResponse(
{
'ErrMsg': _('There is already a course defined with the same organization, course number, and course run. Please change at least one field to be unique.'),
'ErrMsg': _('There is already a course defined with the same organization, course number, and course run. Please change either organization or course number to be unique.'),
'OrgErrMsg': _('Either of organization or course number must be unique.'),
'CourseErrMsg': _('Either of organization or course number must be unique.'),
}