enju_inventory 0.0.10 → 0.0.11

Sign up to get free protection for your applications and to get access to all the features.
@@ -3,7 +3,12 @@ class InventoryFile < ActiveRecord::Base
3
3
  has_many :inventories, :dependent => :destroy
4
4
  has_many :items, :through => :inventories
5
5
  belongs_to :user
6
- has_attached_file :inventory, :path => ":rails_root/private:url"
6
+ if configatron.uploaded_file.storage == :s3
7
+ has_attached_file :inventory, :storage => :s3, :s3_credentials => "#{Rails.root.to_s}/config/s3.yml",
8
+ :s3_permissions => :private
9
+ else
10
+ has_attached_file :inventory, :path => ":rails_root/private:url"
11
+ end
7
12
  validates_attachment_content_type :inventory, :content_type => ['text/csv', 'text/plain', 'text/tab-separated-values']
8
13
  validates_attachment_presence :inventory
9
14
  validates_presence_of :user
@@ -1,9 +1,6 @@
1
- require 'devise'
2
- require 'cancan'
1
+ require 'enju_core'
3
2
  require 'paperclip'
4
3
  require 'inherited_resources'
5
- require 'will_paginate'
6
- require 'sunspot_rails'
7
4
 
8
5
  module EnjuInventory
9
6
  class Engine < ::Rails::Engine
@@ -1,3 +1,3 @@
1
1
  module EnjuInventory
2
- VERSION = "0.0.10"
2
+ VERSION = "0.0.11"
3
3
  end
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: enju_inventory
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.10
4
+ version: 0.0.11
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-05-30 00:00:00.000000000 Z
12
+ date: 2012-07-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -27,38 +27,6 @@ dependencies:
27
27
  - - ~>
28
28
  - !ruby/object:Gem::Version
29
29
  version: '3.2'
30
- - !ruby/object:Gem::Dependency
31
- name: devise
32
- requirement: !ruby/object:Gem::Requirement
33
- none: false
34
- requirements:
35
- - - ! '>='
36
- - !ruby/object:Gem::Version
37
- version: '0'
38
- type: :runtime
39
- prerelease: false
40
- version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ! '>='
44
- - !ruby/object:Gem::Version
45
- version: '0'
46
- - !ruby/object:Gem::Dependency
47
- name: cancan
48
- requirement: !ruby/object:Gem::Requirement
49
- none: false
50
- requirements:
51
- - - ! '>='
52
- - !ruby/object:Gem::Version
53
- version: '0'
54
- type: :runtime
55
- prerelease: false
56
- version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
- requirements:
59
- - - ! '>='
60
- - !ruby/object:Gem::Version
61
- version: '0'
62
30
  - !ruby/object:Gem::Dependency
63
31
  name: paperclip
64
32
  requirement: !ruby/object:Gem::Requirement
@@ -92,7 +60,7 @@ dependencies:
92
60
  - !ruby/object:Gem::Version
93
61
  version: '0'
94
62
  - !ruby/object:Gem::Dependency
95
- name: will_paginate
63
+ name: enju_core
96
64
  requirement: !ruby/object:Gem::Requirement
97
65
  none: false
98
66
  requirements:
@@ -108,30 +76,14 @@ dependencies:
108
76
  - !ruby/object:Gem::Version
109
77
  version: '0'
110
78
  - !ruby/object:Gem::Dependency
111
- name: sunspot_rails
112
- requirement: !ruby/object:Gem::Requirement
113
- none: false
114
- requirements:
115
- - - ! '>='
116
- - !ruby/object:Gem::Version
117
- version: '0'
118
- type: :runtime
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- none: false
122
- requirements:
123
- - - ! '>='
124
- - !ruby/object:Gem::Version
125
- version: '0'
126
- - !ruby/object:Gem::Dependency
127
- name: sunspot_solr
79
+ name: sqlite3
128
80
  requirement: !ruby/object:Gem::Requirement
129
81
  none: false
130
82
  requirements:
131
83
  - - ! '>='
132
84
  - !ruby/object:Gem::Version
133
85
  version: '0'
134
- type: :runtime
86
+ type: :development
135
87
  prerelease: false
136
88
  version_requirements: !ruby/object:Gem::Requirement
137
89
  none: false
@@ -140,7 +92,7 @@ dependencies:
140
92
  - !ruby/object:Gem::Version
141
93
  version: '0'
142
94
  - !ruby/object:Gem::Dependency
143
- name: sqlite3
95
+ name: rspec-rails
144
96
  requirement: !ruby/object:Gem::Requirement
145
97
  none: false
146
98
  requirements:
@@ -156,7 +108,7 @@ dependencies:
156
108
  - !ruby/object:Gem::Version
157
109
  version: '0'
158
110
  - !ruby/object:Gem::Dependency
159
- name: rspec-rails
111
+ name: factory_girl_rails
160
112
  requirement: !ruby/object:Gem::Requirement
161
113
  none: false
162
114
  requirements:
@@ -172,21 +124,21 @@ dependencies:
172
124
  - !ruby/object:Gem::Version
173
125
  version: '0'
174
126
  - !ruby/object:Gem::Dependency
175
- name: factory_girl_rails
127
+ name: sunspot_solr
176
128
  requirement: !ruby/object:Gem::Requirement
177
129
  none: false
178
130
  requirements:
179
- - - ! '>='
131
+ - - ~>
180
132
  - !ruby/object:Gem::Version
181
- version: '0'
133
+ version: 2.0.0.pre.120720
182
134
  type: :development
183
135
  prerelease: false
184
136
  version_requirements: !ruby/object:Gem::Requirement
185
137
  none: false
186
138
  requirements:
187
- - - ! '>='
139
+ - - ~>
188
140
  - !ruby/object:Gem::Version
189
- version: '0'
141
+ version: 2.0.0.pre.120720
190
142
  description: Inventory management for Next-L Enju
191
143
  email:
192
144
  - tanabe@mwr.mediacom.keio.ac.jp