drag/drop feature for new content #443
This commit is contained in:
parent
b03a69e87c
commit
6aae60cff6
@ -21,10 +21,6 @@
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
%>
|
||||
|
||||
<div class="box">
|
||||
<%= form_tag({:controller => 'dmsf_upload', :action => 'upload_files', :id => @project, :folder_id => @folder},
|
||||
:id => 'uploadform', :method => :post, :multipart => true) do %>
|
||||
<div class="dmsf_upload_select">
|
||||
<select id="uploader_select">
|
||||
<option value="1">
|
||||
@ -35,16 +31,21 @@
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<h3><%= l(:label_upload) %></h3>
|
||||
|
||||
<%= form_tag({:controller => 'dmsf_upload', :action => 'upload_files', :id => @project, :folder_id => @folder},
|
||||
:id => 'uploadform', :method => :post, :multipart => true) do %>
|
||||
<div id="uploader">
|
||||
<div class="box">
|
||||
<p>
|
||||
<label><%= l(:label_attachment_plural) %></label>
|
||||
<%= render :partial => 'attachments/form' %>
|
||||
</p>
|
||||
</div>
|
||||
<%= submit_tag l(:label_upload) %>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
var originalUploaderContent;
|
||||
@ -55,6 +56,7 @@
|
||||
$('#uploader_select').change(function() {
|
||||
if($(this).val() === '2') {
|
||||
uploader.html(originalUploaderContent);
|
||||
setupFileDrop();
|
||||
} else {
|
||||
initPlUploader(uploader);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user