|
|
|
@ -552,27 +552,27 @@ function addFileCourseSource(inputEl, file, eagerUpload,checkBox) {
|
|
|
|
|
fileSpan.append(
|
|
|
|
|
$('<input>', {
|
|
|
|
|
'type': 'text',
|
|
|
|
|
'class': 'filename readonly',
|
|
|
|
|
'class': 'upload_filename readonly',
|
|
|
|
|
'name': 'attachments[' + attachmentId + '][filename]',
|
|
|
|
|
'readonly': 'readonly'
|
|
|
|
|
}).val(file.name),
|
|
|
|
|
$('<input>', {
|
|
|
|
|
'type': 'text',
|
|
|
|
|
'class': 'description',
|
|
|
|
|
'name': 'attachments[' + attachmentId + '][description]',
|
|
|
|
|
'maxlength': 254,
|
|
|
|
|
'placeholder': $(inputEl).data('descriptionPlaceholder')
|
|
|
|
|
}).toggle(!eagerUpload),
|
|
|
|
|
$('<span >' + $(inputEl).data('fieldIsPublic') + ':</span>').attr({
|
|
|
|
|
'class': 'ispublic-label'
|
|
|
|
|
}),
|
|
|
|
|
$('<input>', {
|
|
|
|
|
'type': 'checkbox',
|
|
|
|
|
'class': 'is_public_checkbox',
|
|
|
|
|
'value': 1,
|
|
|
|
|
'name': 'attachments[' + attachmentId + '][is_public_checkbox]',
|
|
|
|
|
checked: 'checked'
|
|
|
|
|
}).toggle(!eagerUpload),
|
|
|
|
|
// $('<input>', {
|
|
|
|
|
// 'type': 'text',
|
|
|
|
|
// 'class': 'description',
|
|
|
|
|
// 'name': 'attachments[' + attachmentId + '][description]',
|
|
|
|
|
// 'maxlength': 254,
|
|
|
|
|
// 'placeholder': $(inputEl).data('descriptionPlaceholder')
|
|
|
|
|
// }).toggle(!eagerUpload),
|
|
|
|
|
// $('<span >' + $(inputEl).data('fieldIsPublic') + ':</span>').attr({
|
|
|
|
|
// 'class': 'ispublic-label'
|
|
|
|
|
// }),
|
|
|
|
|
// $('<input>', {
|
|
|
|
|
// 'type': 'checkbox',
|
|
|
|
|
// 'class': 'is_public_checkbox',
|
|
|
|
|
// 'value': 1,
|
|
|
|
|
// 'name': 'attachments[' + attachmentId + '][is_public_checkbox]',
|
|
|
|
|
// checked: 'checked'
|
|
|
|
|
// }).toggle(!eagerUpload),
|
|
|
|
|
$('<a> </a>').attr({
|
|
|
|
|
'href': "#",
|
|
|
|
|
'class': 'remove-upload'
|
|
|
|
|