summaryrefslogtreecommitdiff
path: root/yaksh/static
diff options
context:
space:
mode:
authorprathamesh2017-09-01 17:22:29 +0530
committerprathamesh2017-09-01 17:22:29 +0530
commit1e3bb9e325214be0105f8b907badc84b2dbbeb91 (patch)
tree3327924e1879524909d5f1603dfe7d3dbda4c05a /yaksh/static
parente2c65655dcdc5558cfb4ab668c3012024d27ac75 (diff)
parent9e0f737c25a5156aa884d27357af0aef1145c4b7 (diff)
downloadonline_test-1e3bb9e325214be0105f8b907badc84b2dbbeb91.tar.gz
online_test-1e3bb9e325214be0105f8b907badc84b2dbbeb91.tar.bz2
online_test-1e3bb9e325214be0105f8b907badc84b2dbbeb91.zip
Merge branch 'master' of https://github.com/FOSSEE/online_test into improve-code-server
Conflicts Resolved: yaksh/templates/yaksh/question.html
Diffstat (limited to 'yaksh/static')
-rw-r--r--yaksh/static/yaksh/js/course.js31
-rw-r--r--yaksh/static/yaksh/js/show_question.js4
2 files changed, 35 insertions, 0 deletions
diff --git a/yaksh/static/yaksh/js/course.js b/yaksh/static/yaksh/js/course.js
index 5b79e68..8fb2773 100644
--- a/yaksh/static/yaksh/js/course.js
+++ b/yaksh/static/yaksh/js/course.js
@@ -35,4 +35,35 @@ $(".reject").change( function(){
});
}
});
+
+$(function() {
+ $('textarea#email_body').froalaEditor({
+ heightMin: 200,
+ heightMax: 200
+ })
+ });
+
+$("#send_mail").click(function(){
+ var subject = $("#subject").val();
+ var body = $('#email_body').val();
+ var status = false;
+ var selected = [];
+ $('#reject input:checked').each(function() {
+ selected.push($(this).attr('value'));
+ });
+
+ if (subject == '' || body == ''){
+ $("#error_msg").html("Please enter mail details");
+ $("#dialog").dialog();
+ }
+ else if (selected.length == 0){
+ $("#error_msg").html("Please select atleast one user");
+ $("#dialog").dialog();
+ }
+ else {
+ status = true;
+ }
+ return status;
+});
+
});
diff --git a/yaksh/static/yaksh/js/show_question.js b/yaksh/static/yaksh/js/show_question.js
index e3ed1cc..e7cd817 100644
--- a/yaksh/static/yaksh/js/show_question.js
+++ b/yaksh/static/yaksh/js/show_question.js
@@ -37,3 +37,7 @@ function confirm_edit(frm)
else
return true;
}
+$(document).ready(function()
+ {
+ $("#questions-table").tablesorter({sortList: [[0,0], [4,0]]});
+ }); \ No newline at end of file