', { 'id': 'attachments_' + attachmentId, 'class':'attachment' });
@@ -23,7 +25,7 @@ function addFile(inputEl, file, eagerUpload) {
fileSpan.append(
$('', { 'type': 'text', 'class': 'filename readonly', 'name': 'attachments[' + attachmentId + '][filename]', 'readonly': 'readonly'} ).val(file.name),
$('', { 'type': 'text', 'class': 'description', 'name': 'attachments[' + attachmentId + '][description]', 'maxlength': 254, 'placeholder': $(inputEl).data('description-placeholder') } ).toggle(!eagerUpload),
- $('公开:').attr({ 'class': 'ispublic-label' }) ,
+ $(''+$(inputEl).data('label_public')+'').attr({ 'class': 'ispublic-label' }) ,
$('', { 'type': 'checkbox', 'class': 'is_public_checkbox','value':1, 'name': 'attachments[' + attachmentId + '][is_public_checkbox]', checked:'checked' } ).toggle(!eagerUpload),
$(' ').attr({ 'href': "#", 'class': 'remove-upload', 'data-confirm' : "您确定要删除吗?" }).click(removeFile).toggle(!eagerUpload),
$('', { 'class': 'div_attachments', 'name': 'div_'+'attachments_' + attachmentId} )
@@ -87,7 +89,6 @@ function ajaxUpload(file, attachmentId, fileSpan, inputEl) {
var count=$('#attachments_fields>span').length;
$('#upload_file_count').html("已上传"+""+count+""+"个文件");
-
if(count>=1){
var add_attachs=$('.add_attachment');
var delete_all=$('.remove_all');