From b17bf99805aebdffec2d84667d3b66f29d0c0c74 Mon Sep 17 00:00:00 2001 From: steinm Date: Mon, 17 Dec 2012 18:30:59 +0000 Subject: [PATCH] - remove content from modal box when opening --- styles/bootstrap/application.js | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/styles/bootstrap/application.js b/styles/bootstrap/application.js index 9088361b9..119f0494f 100644 --- a/styles/bootstrap/application.js +++ b/styles/bootstrap/application.js @@ -1,12 +1,17 @@ $(document).ready( function() { -$('body').on('touchstart.dropdown', '.dropdown-menu', function (e) { e.stopPropagation(); }); -$('#expirationdate, #fromdate, #todate') - .datepicker() - .on('changeDate', function(ev){ - $('#expirationdate, #fromdate, #todate').datepicker('hide'); + $('body').on('hidden', '.modal', function () { + $(this).removeData('modal'); }); + $('body').on('touchstart.dropdown', '.dropdown-menu', function (e) { e.stopPropagation(); }); + + $('#expirationdate, #fromdate, #todate') + .datepicker() + .on('changeDate', function(ev){ + $('#expirationdate, #fromdate, #todate').datepicker('hide'); + }); + $(".chzn-select").chosen(); $(".chzn-select-deselect").chosen({allow_single_deselect:true});