enju_biblio 0.1.0.pre64 → 0.1.0.pre65

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 84f441b00ab4993e30a148f4586a3df9b3f6a7c7
4
- data.tar.gz: 9bed5a638d31eee0f50ba95607f63814efb6f14c
3
+ metadata.gz: 3c839ddf139ea8e9fc7d2926aa37afabf51fe325
4
+ data.tar.gz: 280ec8b0ea508ab3cd854ffc8f413f65963bd977
5
5
  SHA512:
6
- metadata.gz: 44a827b4622c2e70a28852b7a66ab287d56ba367354b4d7fba8cbda18f9e734b724dacb43e32fcc2cbdcfc0dde30c85fae945d2fdc900306bd0129ba5914d042
7
- data.tar.gz: 6fc8700461ee0c88c84c79c9a713b838a40ab68e0a17cc2377a9a36a2d122e48df7145650ed059cd4aef9d84bd2d4a1901c0edbeb8e9619569fbc7b7e4ba90e0
6
+ metadata.gz: e8c750255c7992b6af9e86b9359a8ef20c1f333486b20dc46ca553afdf8e1bf2506b343c32b92d2434897c19c6a46e985bb1188714e09efa57c80f62310aa0e8
7
+ data.tar.gz: 1360353ffe8e1d3b68ec1480d2f5ee0f17713a462924254610cb39b958071094b8ab9798504149428498f0d4be5fabcc6062cc21bcc490fe2fb94bffc8f5bc65
@@ -157,6 +157,10 @@ class AgentImportFile < ActiveRecord::Base
157
157
  AgentImportFileTransition
158
158
  end
159
159
 
160
+ def self.initial_state
161
+ :pending
162
+ end
163
+
160
164
  def open_import_file
161
165
  tempfile = Tempfile.new(self.class.name.underscore)
162
166
  if Setting.uploaded_file.storage == :s3
@@ -92,9 +92,9 @@ module EnjuBiblio
92
92
  if manifestation.items.empty?
93
93
  if manifestation.series_master?
94
94
  if manifestation.children.empty?
95
- return true
95
+ true
96
96
  else
97
- return false
97
+ false
98
98
  end
99
99
  else
100
100
  true
@@ -13,7 +13,7 @@ class ImportRequest < ActiveRecord::Base
13
13
  has_many :import_request_transitions
14
14
 
15
15
  def state_machine
16
- @state_machine ||= ImportRequestStateMachine.new(self, transition_class: ImportRequestTransition)
16
+ ImportRequestStateMachine.new(self, transition_class: ImportRequestTransition)
17
17
  end
18
18
 
19
19
  delegate :can_transition_to?, :transition_to!, :transition_to, :current_state,
@@ -61,10 +61,13 @@ class ImportRequest < ActiveRecord::Base
61
61
  end
62
62
 
63
63
  private
64
-
65
64
  def self.transition_class
66
65
  ImportRequestTransition
67
66
  end
67
+
68
+ def self.initial_state
69
+ :pending
70
+ end
68
71
  end
69
72
 
70
73
  # == Schema Information
@@ -41,6 +41,10 @@ class ResourceExportFile < ActiveRecord::Base
41
41
  def self.transition_class
42
42
  ResourceExportFileTransition
43
43
  end
44
+
45
+ def self.initial_state
46
+ :pending
47
+ end
44
48
  end
45
49
 
46
50
  # == Schema Information
@@ -724,6 +724,10 @@ class ResourceImportFile < ActiveRecord::Base
724
724
  ResourceImportFileTransition
725
725
  end
726
726
 
727
+ def self.initial_state
728
+ :pending
729
+ end
730
+
727
731
  def set_identifier(row)
728
732
  identifier = {}
729
733
  %w(isbn issn doi jpno).each do |id_type|
@@ -1,3 +1,3 @@
1
1
  module EnjuBiblio
2
- VERSION = "0.1.0.pre64"
2
+ VERSION = "0.1.0.pre65"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: enju_biblio
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0.pre64
4
+ version: 0.1.0.pre65
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kosuke Tanabe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-12 00:00:00.000000000 Z
11
+ date: 2015-02-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: paperclip