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
9a010780
Commit
9a010780
authored
Dec 10, 2015
by
asadiqbal
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SOL-1455 enhancement
parent
87a0f0a4
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
27 additions
and
15 deletions
+27
-15
common/test/acceptance/tests/lms/test_lms_instructor_dashboard.py
+1
-1
lms/static/js/certificates/models/certificate_exception.js
+1
-1
lms/static/js/certificates/views/certificate_bulk_whitelist.js
+16
-10
lms/static/js/spec/instructor_dashboard/certificates_exception_spec.js
+2
-2
lms/static/sass/course/instructor/_instructor_2.scss
+5
-0
lms/templates/instructor/instructor_dashboard_2/certificate-bulk-white-list.underscore
+2
-1
No files found.
common/test/acceptance/tests/lms/test_lms_instructor_dashboard.py
View file @
9a010780
...
@@ -754,7 +754,7 @@ class CertificatesTest(BaseInstructorDashboardTest):
...
@@ -754,7 +754,7 @@ class CertificatesTest(BaseInstructorDashboardTest):
self
.
assertIn
(
self
.
assertIn
(
'Student username/email field is required and can not be empty. '
'Student username/email field is required and can not be empty. '
'Kindly fill in username/email and then press "Add
Exception
" button.'
,
'Kindly fill in username/email and then press "Add
to Exception List
" button.'
,
self
.
certificates_section
.
message
.
text
self
.
certificates_section
.
message
.
text
)
)
...
...
lms/static/js/certificates/models/certificate_exception.js
View file @
9a010780
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
validate
:
function
(
attrs
){
validate
:
function
(
attrs
){
if
(
!
_
.
str
.
trim
(
attrs
.
user_name
)
&&
!
_
.
str
.
trim
(
attrs
.
user_email
))
{
if
(
!
_
.
str
.
trim
(
attrs
.
user_name
)
&&
!
_
.
str
.
trim
(
attrs
.
user_email
))
{
return
gettext
(
'Student username/email field is required and can not be empty. '
+
return
gettext
(
'Student username/email field is required and can not be empty. '
+
'Kindly fill in username/email and then press "Add
Exception
" button.'
);
'Kindly fill in username/email and then press "Add
to Exception List
" button.'
);
}
}
}
}
...
...
lms/static/js/certificates/views/certificate_bulk_whitelist.js
View file @
9a010780
...
@@ -161,23 +161,30 @@
...
@@ -161,23 +161,30 @@
break
;
break
;
case
MESSAGE_GROUP
.
data_format_error
:
case
MESSAGE_GROUP
.
data_format_error
:
text
=
qty
>
1
?
gettext
(
qty
+
' records are not in correct format'
):
text
=
qty
>
1
?
gettext
(
qty
+
' records are not in correct format and not added to'
+
gettext
(
qty
+
' record is not in correct format'
);
' the exception list'
):
gettext
(
qty
+
' record is not in correct format and not added to the exception'
+
' list'
);
break
;
break
;
case
MESSAGE_GROUP
.
user_not_exist
:
case
MESSAGE_GROUP
.
user_not_exist
:
text
=
qty
>
1
?
gettext
(
qty
+
' learners do not exist in LMS'
):
text
=
qty
>
1
?
gettext
(
qty
+
' learners do not exist in LMS and not added to the'
+
gettext
(
qty
+
' learner does not exist in LMS'
);
' exception list'
):
gettext
(
qty
+
' learner does not exist in LMS and not added to the exception list'
);
break
;
break
;
case
MESSAGE_GROUP
.
user_already_white_listed
:
case
MESSAGE_GROUP
.
user_already_white_listed
:
text
=
qty
>
1
?
gettext
(
qty
+
' learners are already white listed'
):
text
=
qty
>
1
?
gettext
(
qty
+
' learners are already white listed and not added to'
+
gettext
(
qty
+
' learner is already white listed'
);
' the exception list'
):
gettext
(
qty
+
' learner is already white listed and not added to the exception '
+
'list'
);
break
;
break
;
case
MESSAGE_GROUP
.
user_not_enrolled
:
case
MESSAGE_GROUP
.
user_not_enrolled
:
text
=
qty
>
1
?
gettext
(
qty
+
' learners are not enrolled in course'
):
text
=
qty
>
1
?
gettext
(
qty
+
' learners are not enrolled in course and not added to'
+
gettext
(
qty
+
' learner is not enrolled in course'
);
' the exception list'
):
gettext
(
qty
+
' learner is not enrolled in course and not added to the exception'
+
' list'
);
break
;
break
;
}
}
return
text
;
return
text
;
...
@@ -199,8 +206,7 @@
...
@@ -199,8 +206,7 @@
chooseFile
:
function
(
event
)
{
chooseFile
:
function
(
event
)
{
if
(
event
&&
event
.
preventDefault
)
{
event
.
preventDefault
();
}
if
(
event
&&
event
.
preventDefault
)
{
event
.
preventDefault
();
}
if
(
event
.
currentTarget
.
files
.
length
===
1
)
{
if
(
event
.
currentTarget
.
files
.
length
===
1
)
{
this
.
$el
.
find
(
DOM_SELECTORS
.
upload_csv_button
).
removeClass
(
'is-disabled'
)
this
.
$el
.
find
(
DOM_SELECTORS
.
upload_csv_button
).
removeClass
(
'disabled'
);
.
addClass
(
'btn-blue'
);
this
.
$el
.
find
(
DOM_SELECTORS
.
browse_file
).
val
(
this
.
$el
.
find
(
DOM_SELECTORS
.
browse_file
).
val
(
event
.
currentTarget
.
value
.
substring
(
event
.
currentTarget
.
value
.
lastIndexOf
(
"
\
\"
) + 1));
event
.
currentTarget
.
value
.
substring
(
event
.
currentTarget
.
value
.
lastIndexOf
(
"
\
\"
) + 1));
}
}
...
...
lms/static/js/spec/instructor_dashboard/certificates_exception_spec.js
View file @
9a010780
...
@@ -25,7 +25,7 @@ define([
...
@@ -25,7 +25,7 @@ define([
var
EXPECTED_ERRORS
=
{
var
EXPECTED_ERRORS
=
{
user_name_or_email_required
:
'Student username/email field is required and can not be empty. '
+
user_name_or_email_required
:
'Student username/email field is required and can not be empty. '
+
'Kindly fill in username/email and then press "Add
Exception
" button.'
'Kindly fill in username/email and then press "Add
to Exception List
" button.'
};
};
beforeEach
(
function
()
{
beforeEach
(
function
()
{
...
@@ -338,7 +338,7 @@ define([
...
@@ -338,7 +338,7 @@ define([
var
error_messages
=
{
var
error_messages
=
{
empty_user_name_email
:
'Student username/email field is required and can not be empty. '
+
empty_user_name_email
:
'Student username/email field is required and can not be empty. '
+
'Kindly fill in username/email and then press "Add
Exception
" button.'
,
'Kindly fill in username/email and then press "Add
to Exception List
" button.'
,
duplicate_user
:
"<p>"
+
(
duplicate_user
)
+
" already in exception list.</p>"
duplicate_user
:
"<p>"
+
(
duplicate_user
)
+
" already in exception list.</p>"
};
};
...
...
lms/static/sass/course/instructor/_instructor_2.scss
View file @
9a010780
...
@@ -2160,6 +2160,7 @@ input[name="subject"] {
...
@@ -2160,6 +2160,7 @@ input[name="subject"] {
}
}
#certificate-white-list-editor
{
#certificate-white-list-editor
{
padding-top
:
5px
;
.certificate-exception-inputs
{
.certificate-exception-inputs
{
.student-username-or-email
{
.student-username-or-email
{
width
:
300px
;
width
:
300px
;
...
@@ -2179,7 +2180,9 @@ input[name="subject"] {
...
@@ -2179,7 +2180,9 @@ input[name="subject"] {
.white-listed-students
{
.white-listed-students
{
margin-top
:
10px
;
margin-top
:
10px
;
padding-top
:
5px
;
table
{
table
{
margin-top
:
5px
;
width
:
100%
;
width
:
100%
;
word-wrap
:
break-word
;
word-wrap
:
break-word
;
...
@@ -2260,6 +2263,7 @@ input[name="subject"] {
...
@@ -2260,6 +2263,7 @@ input[name="subject"] {
.bulk-white-list-exception
{
.bulk-white-list-exception
{
margin-top
:
10px
;
margin-top
:
10px
;
padding-top
:
5px
;
.white-list-csv
{
.white-list-csv
{
.bulk-exception-results
{
.bulk-exception-results
{
margin-top
:
10px
;
margin-top
:
10px
;
...
@@ -2271,6 +2275,7 @@ input[name="subject"] {
...
@@ -2271,6 +2275,7 @@ input[name="subject"] {
.message
{
.message
{
padding
:
5px
10px
;
padding
:
5px
10px
;
margin
:
2px
;
margin
:
2px
;
border-top-style
:
none
;
}
}
}
}
...
...
lms/templates/instructor/instructor_dashboard_2/certificate-bulk-white-list.underscore
View file @
9a010780
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
<input class="file_field" id="browseBtn" name="students_list" type="file" accept=".csv"/>
<input class="file_field" id="browseBtn" name="students_list" type="file" accept=".csv"/>
</div>
</div>
</div>
</div>
<div><button class="
is-
disabled upload-csv-button" type="submit"><%= gettext('Add to Exception List') %></button></div>
<div><button class="
btn-blue
disabled upload-csv-button" type="submit"><%= gettext('Add to Exception List') %></button></div>
</form>
</form>
<div class="bulk-exception-results hidden"></div>
<div class="bulk-exception-results hidden"></div>
</div>
</div>
\ No newline at end of file
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