From f9ab993d99567a9d8db8ec29db179cddfa1cca07 Mon Sep 17 00:00:00 2001 From: CruiseDevice Date: Fri, 8 Feb 2019 15:05:46 +0530 Subject: Show alert on clicking Undo Changes button --- yaksh/static/yaksh/js/requesthandler.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'yaksh/static') diff --git a/yaksh/static/yaksh/js/requesthandler.js b/yaksh/static/yaksh/js/requesthandler.js index 952de3a..7ccdef0 100644 --- a/yaksh/static/yaksh/js/requesthandler.js +++ b/yaksh/static/yaksh/js/requesthandler.js @@ -197,6 +197,11 @@ if (question_type == 'upload' || question_type == 'code') { reset_editor = function() { global_editor.editor.setValue(init_val); global_editor.editor.clearHistory(); + $('#undo_changes').modal('hide'); + } + + confirm = function(){ + $("#undo_changes").modal("show"); } }); function user_arranged_options(){ -- cgit