beef-has_assets 0.6.3 → 0.6.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.6.3
1
+ 0.6.4
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{beef-has_assets}
8
- s.version = "0.6.3"
8
+ s.version = "0.6.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Steve England"]
12
- s.date = %q{2009-10-28}
12
+ s.date = %q{2009-11-02}
13
13
  s.email = %q{steve@wearebeef.co.uk}
14
14
  s.extra_rdoc_files = [
15
15
  "LICENSE",
@@ -74,8 +74,8 @@ Gem::Specification.new do |s|
74
74
  s.rubygems_version = %q{1.3.5}
75
75
  s.summary = %q{Rails Engine. Adds uploadable assets to a model and admin area for files}
76
76
  s.test_files = [
77
- "test/test_helper.rb",
78
- "test/has_assets_test.rb"
77
+ "test/has_assets_test.rb",
78
+ "test/test_helper.rb"
79
79
  ]
80
80
 
81
81
  if s.respond_to? :specification_version then
@@ -104,7 +104,7 @@ Object.extend(AssetBrowser, {
104
104
  },
105
105
 
106
106
  loadFilesByFolder: function(folder_name, folder_id){
107
- new Ajax.Request('/admin/assets/' + this.current_grouping.replace(/$by_/, ''), { method: 'get',
107
+ new Ajax.Request('/admin/assets/' + this.current_grouping.replace(/^by_/, ''), { method: 'get',
108
108
  asynchronous:true,
109
109
  parameters: { for_content: AssetBrowser.for_content, format: 'html', category: folder_name, authenticity_token: AJ.authenticity_token() },
110
110
  onSuccess: function(response){ $(folder_id).update(response.responseText); } } );
@@ -151,8 +151,9 @@ Object.extend(AssetBrowser, {
151
151
  this.contentNodeForm.addAssetIDs = function() {
152
152
  $$('input.asset_id').invoke('remove');
153
153
  assets = $$('#asset-list li');
154
+
154
155
  if (assets.size() == 0) {
155
- $(this).insert('<input type="hidden" name="' + this.model_name + '[asset_ids]" value="" />');
156
+ $(this).insert('<input type="hidden" name="' + this.model_name + '[asset_ids]" class="asset_id" value="" />');
156
157
  } else {
157
158
  assets.each(function(li) {
158
159
  asset_id = li.id.split('-').last();
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: beef-has_assets
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.3
4
+ version: 0.6.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steve England
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-10-28 00:00:00 +00:00
12
+ date: 2009-11-02 00:00:00 +00:00
13
13
  default_executable:
14
14
  dependencies: []
15
15
 
@@ -103,5 +103,5 @@ signing_key:
103
103
  specification_version: 3
104
104
  summary: Rails Engine. Adds uploadable assets to a model and admin area for files
105
105
  test_files:
106
- - test/test_helper.rb
107
106
  - test/has_assets_test.rb
107
+ - test/test_helper.rb