- Timestamp:
- 08/09/12 12:25:44 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/2.4.2-expresso1/prototype/modules/calendar/js/helpers.js
r6959 r6974 1467 1467 }); 1468 1468 var maxSizeFile = 2000000; 1469 $('#fileupload ').fileupload({1469 $('#fileuploadevent').fileupload({ 1470 1470 sequentialUploads: true, 1471 1471 add: function (e, data) { … … 1484 1484 attach.error = 'Tamanho de arquivo nao permitido!!' 1485 1485 1486 $(' .attachments-list').append(DataLayer.render(path+'templates/attachment_add_itemlist.ejs', {1486 $('div.new-event-win .attachments-list').append(DataLayer.render(path+'templates/attachment_add_itemlist.ejs', { 1487 1487 file : attach 1488 1488 })); 1489 1489 1490 1490 if(file.size < maxSizeFile){ 1491 $(' .fileinput-button.new').append(data.fileInput[0]).removeClass('new');1492 $(' .attachments-list').find('[type=file]').addClass('hidden');1491 $('div.new-event-win .fileinput-button.new').append(data.fileInput[0]).removeClass('new'); 1492 $('div.new-event-win .attachments-list').find('[type=file]').addClass('hidden'); 1493 1493 1494 1494 }else 1495 $(' .fileinput-button.new').removeClass('new');1495 $('div.new-event-win .fileinput-button.new').removeClass('new'); 1496 1496 1497 1497 1498 $(' .attachments-list').find('.button.close').button({1498 $('div.new-event-win .attachments-list').find('.button.close').button({ 1499 1499 icons: { 1500 1500 primary: "ui-icon-close" … … 1503 1503 }).click(function(){ 1504 1504 var idAttach = $(this).parent().find('input[name="fileId[]"]').val(); 1505 $(' .attachment-list').find('input[value="'+idAttach+'"]')1505 $('div.new-event-win .attachment-list').find('input[value="'+idAttach+'"]') 1506 1506 $(this).parent().remove(); 1507 1507 }); … … 1510 1510 }, 1511 1511 done: function(e, data){ 1512 var currentUpload = $(' .progress.after-upload:first').removeClass('after-upload').addClass('on-complete').hide();1512 var currentUpload = $('div.new-event-win .progress.after-upload:first').removeClass('after-upload').addClass('on-complete').hide(); 1513 1513 1514 1514 if(!!data.result && data.result != "[]"){ 1515 1515 var newAttach = (attch = jQuery.parseJSON(data.result)) ? attch : jQuery.parseJSON(data.result[0].activeElement.childNodes[0].data); 1516 $(' .attachment-list').append('<input tyepe="hidden" name="attachment[]" value="'+newAttach['attachment'][0][0].id+'"/>');1516 $('div.new-event-win .attachment-list').append('<input tyepe="hidden" name="attachment[]" value="'+newAttach['attachment'][0][0].id+'"/>'); 1517 1517 currentUpload.removeClass('on-complete').parents('p') 1518 1518 .append('<input type="hidden" name="fileId[]" value="'+newAttach['attachment'][0][0].id+'"/>') … … 1525 1525 1526 1526 if(!!window.FormData) 1527 $('#fileupload ').bind('fileuploadstart', function () {1527 $('#fileuploadevent').bind('fileuploadstart', function () { 1528 1528 var widget = $(this), 1529 progressElement = $('#fileupload-progress ').fadeIn(),1529 progressElement = $('#fileupload-progress-event').fadeIn(), 1530 1530 interval = 500, 1531 1531 total = 0, … … 2240 2240 }) 2241 2241 .click(function(){ 2242 meu_container.find('.button.'+typeCalendar.type).qtip('destroy');2242 $('.qtip.qtip-blue').remove(); 2243 2243 }); 2244 2244
Note: See TracChangeset
for help on using the changeset viewer.