diff options
author | Filipp Lepalaan <f@230.to> | 2014-02-20 12:44:49 +0200 |
---|---|---|
committer | Filipp Lepalaan <f@230.to> | 2014-02-20 12:44:49 +0200 |
commit | 3321241b61766045a68a3d607b67e11a95014e87 (patch) | |
tree | d13ce50a7c46f986f403733e9922e766665e7d2b /apps/it/static/js/it.js | |
parent | 75ad7e4bd7d69243e7e5281c2642f00478fb072d (diff) | |
download | pudding-3321241b61766045a68a3d607b67e11a95014e87.tar.gz pudding-3321241b61766045a68a3d607b67e11a95014e87.tar.bz2 pudding-3321241b61766045a68a3d607b67e11a95014e87.zip |
Require logins, removed jquery UI
Diffstat (limited to 'apps/it/static/js/it.js')
-rw-r--r-- | apps/it/static/js/it.js | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/apps/it/static/js/it.js b/apps/it/static/js/it.js new file mode 100644 index 0000000..9a05b0a --- /dev/null +++ b/apps/it/static/js/it.js @@ -0,0 +1,32 @@ +$('.media').hover( + function(){ + $(this).find('.btn-group').show(); + }, + function(){ + $('.btn-group').hide(); + }); + Dropzone.options.myAwesomeDropzone = { + paramName: "attachment", // The name that will be used to transfer the file + maxFilesize: 2, // MB + }; + $('.confirm').click(function(e){ + if(confirm('Are you sure?')) { + return true; + } + e.preventDefault(); + }); + $('.searchfield').on('keyup', function(e){ + if(e.keyCode == 13) { + document.location = '/search/?q=' + $(this).val(); + } + }); + $('.autocomplete').each(function(i, e){ + $(e).autocomplete({source: $(e).data('source')}); + }); + $('.draggable').draggable({opacity: 0.75, zIndex: 100, cursor: 'pointer'}); + $('.dragarea').droppable({ + out: function(e, ui) { + $.ajax($(ui.draggable).data('destroy')); + $(ui.draggable).remove(); + } + }); |