Merge branch 'dev_newproject' of https://git.trustie.net/jacknudt/trustieforge into dev_newproject
This commit is contained in:
commit
c5eee71848
|
@ -7,7 +7,8 @@
|
|||
<% if defined?(container) && container && container.saved_attachments %>
|
||||
<% container.attachments.each_with_index do |attachment, i| %>
|
||||
<span id="attachments_p<%= i %>" class="attachment">
|
||||
<%= text_field_tag("attachments[p#{i}][filename]", attachment.filename, :class => 'upload_filename readonly', :readonly => 'readonly', :style=>'border:none;') %>
|
||||
<%= text_field_tag("attachments[p#{i}][filename]", attachment.filename, :class => 'upload_filename readonly hidden', :readonly => 'readonly', :style=>'border:none; width:460px;') %>
|
||||
|
||||
<%#= text_field_tag("attachments[p#{i}][description]", attachment.description, :maxlength => 254, :placeholder => l(:label_optional_description), :class => 'description', :style => "display: inline-block;") %>
|
||||
<!--<span class="ispublic-label"><%#= l(:field_is_public) %>:</span>-->
|
||||
<%#= check_box_tag("attachments[p#{i}][is_public_checkbox]", attachment.is_public, attachment.is_public == 1 ? true : false, :class => 'is_public') %>
|
||||
|
@ -31,7 +32,7 @@
|
|||
<span class="add_attachment" style="font-weight:normal;">
|
||||
<%#= button_tag "浏览", :type=>"button", :onclick=>"CompatibleSend();" %>
|
||||
<!--%= link_to image_tag(),"javascript:void(0)", :onclick => "_file.click()"%-->
|
||||
<%= button_tag "上传附件", :type=>"button", :onclick=>"$('#_file').click();",:onmouseover => 'this.focus()',:class => 'sub_btn' %>
|
||||
<%= button_tag "上传附件", :id => "upload_attachments", :type=>"button", :onclick=>"$('#_file').click();",:onmouseover => 'this.focus()',:class => 'sub_btn' %>
|
||||
<%= file_field_tag 'attachments[dummy][file]',
|
||||
:id => '_file',
|
||||
:class => 'file_selector',
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
<!-- 鼠标不能移动是因为 href="javascript:void(0);"导致的 -->
|
||||
<span> <a class="files_tag_select" ondblclick="rename_tag($(this),'<%= k %>','',<%= 6 %>);"><%= k%> x<%= v%></a></span>
|
||||
<% else%>
|
||||
<span class="files_tag_icon" >
|
||||
<span class="files_tag_icon break_word" >
|
||||
<a title="双击可编辑"
|
||||
onclick="search_tag_attachment('<%= search_tag_attachment_course_files_path(course)%>','<%= k%>','<%= @q%>','<%= course.id%>');"
|
||||
ondblclick="rename_tag($(this),'<%= k %>','',<%= 6 %>);"><%= k%> x<%= v%></a></span>
|
||||
|
|
|
@ -103,10 +103,10 @@ function addFile(inputEl, file, eagerUpload,btnId) {
|
|||
fileSpan.append(
|
||||
$('<input>', {
|
||||
'type': 'text',
|
||||
'class': 'upload_filename readonly',
|
||||
'class': 'upload_filename readonly hidden',
|
||||
'name': 'attachments[' + attachmentId + '][filename]',
|
||||
'readonly': 'readonly',
|
||||
'style': 'border:none;'
|
||||
'style': 'border:none; width:464px;'
|
||||
}).val(file.name),
|
||||
// $('<input>', {
|
||||
// 'type': 'text',
|
||||
|
@ -127,7 +127,8 @@ function addFile(inputEl, file, eagerUpload,btnId) {
|
|||
// }).toggle(!eagerUpload),
|
||||
$('<a> </a>').attr({
|
||||
'href': "#",
|
||||
'class': 'remove-upload'
|
||||
'class': 'remove-upload',
|
||||
'style': 'vertical-align:top;'
|
||||
}).click(function() {
|
||||
if (confirm($(inputEl).data('areYouSure'))) {
|
||||
removeFile();
|
||||
|
|
Loading…
Reference in New Issue