Merge branch 'master' of github.com:FinalsClub/karmaworld
authorCharles Holbrow <charlesholbrow@gmail.com>
Thu, 21 Mar 2013 19:28:30 +0000 (15:28 -0400)
committerCharles Holbrow <charlesholbrow@gmail.com>
Thu, 21 Mar 2013 19:28:30 +0000 (15:28 -0400)
1  2 
karmaworld/assets/js/lightboxupload.js

index 9d4e1833ebd4e0a1c1cfd3d9d50a7488fb41942e,58afa1e974b0e8b0cb0c68be92ad8bad9beb1e4b..5f012d40752c2e51bc3e8f2569daf3319713985d
@@@ -39,15 -26,11 +39,16 @@@ $(function()
        element: $('#file-uploader')[0],
        multiple: false,
  
 +      onSubmit: function (id, fileName) {
 +        $('#file-uploader').hide();
 +        $('div.upload-status').show();
 +      },
 +
        onComplete: function( id, fileName, responseJSON ) {
          if( responseJSON.success ) {
+           console.log("responseJSON.note_url " + responseJSON.note_url);
            // activate the form for submitting
-           $('form#upload_form').attr('action', responseJSON.note_url);
+           $('form#add-note').attr('action', responseJSON.note_url);
            // inform the user of success
            $('#add-note-status').text('Uploaded');
            // TODO: activate the save button