glebtv-rails-uploader 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/uploader/default/_container.html.erb +13 -13
- data/lib/uploader/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 98baab0f496d6f111968381e63cd2c9928b40a16
|
4
|
+
data.tar.gz: 729810bccdd200b8acde963b8b607a111539521e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b9ecf424db6fa7b7a4c5da4003e4e80ddd429f93dd3a6379e87e348c2cc8b3f5b8c7d778665f2350487b8e0fac5c50c45dca9d7bce815ef5248eb1691fcc654f
|
7
|
+
data.tar.gz: d631af11a18b881ab56a3d32d82bee3ea4bba19b9c864a4e6a15557cc4660894b3c16173f159bac1068bbbfd8c97e2676340d36606775b8f6cc3708d17694d94
|
@@ -3,26 +3,26 @@
|
|
3
3
|
|
4
4
|
<div class="uploader-files"></div>
|
5
5
|
|
6
|
-
|
7
|
-
|
6
|
+
<div class="uploader-dnd-hints">
|
7
|
+
<span class="uploader-button gray fileinput-button">
|
8
8
|
<span><%= I18n.t('uploader.button') %></span>
|
9
9
|
<%= fields_for field.object do |f| -%>
|
10
|
-
|
10
|
+
<%= f.fields_for field.method_name, field.klass.new do |m| -%>
|
11
11
|
<%= m.file_field(:data, field.input_html) %>
|
12
|
-
|
13
|
-
|
12
|
+
<% end -%>
|
13
|
+
<% end -%>
|
14
14
|
</span>
|
15
15
|
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
16
|
+
<div class="uploader-dnd-hint">
|
17
|
+
<%= I18n.t('uploader.or') %><span><%= I18n.t('uploader.drop') %></span>
|
18
|
+
</div>
|
19
|
+
</div>
|
20
|
+
|
21
|
+
<%= render :partial => "uploader/#{field.theme}/upload", :locals => {:field => field} %>
|
22
22
|
<%= render :partial => "uploader/#{field.theme}/download", :locals => {:field => field} %>
|
23
23
|
<%= render :partial => "uploader/#{field.theme}/sortable", :locals => {:field => field} if field.sortable? %>
|
24
24
|
|
25
|
-
|
25
|
+
<script type="text/javascript">
|
26
26
|
$(function() {
|
27
27
|
var uploader, container;
|
28
28
|
container = $("#<%= field.id %> div.uploader-files");
|
@@ -43,7 +43,7 @@
|
|
43
43
|
<% if field.exists? -%>
|
44
44
|
uploader = ($(this).data('blueimp-fileupload') || $(this).data('fileupload'));
|
45
45
|
uploader
|
46
|
-
._renderDownload(<%=raw field.values.sort_by {|s| s.sort }.map(&:to_jq_upload).to_json %>)
|
46
|
+
._renderDownload(<%=raw field.values.sort_by {|s| s.sort.nil? ? 0 : s.sort }.map(&:to_jq_upload).to_json %>)
|
47
47
|
.appendTo(container);
|
48
48
|
<% end -%>
|
49
49
|
});
|
data/lib/uploader/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: glebtv-rails-uploader
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Igor Galeta
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2014-
|
13
|
+
date: 2014-09-18 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: jquery-ui-rails
|