elibri_onix 0.1.3 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +0 -1
- data/Gemfile.lock +13 -14
- data/elibri_onix.gemspec +2 -5
- data/lib/elibri_onix.rb +0 -2
- data/lib/elibri_onix/onix_3_0/price.rb +2 -4
- data/lib/elibri_onix/onix_3_0/product.rb +21 -27
- data/lib/elibri_onix/onix_3_0/supply_detail.rb +2 -4
- data/lib/elibri_onix/onix_3_0/supporting_resource.rb +2 -4
- data/lib/elibri_onix/version.rb +1 -1
- metadata +28 -44
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,43 +1,42 @@
|
|
1
1
|
GEM
|
2
2
|
remote: http://rubygems.org/
|
3
3
|
specs:
|
4
|
-
activesupport (3.1.
|
4
|
+
activesupport (3.1.1)
|
5
5
|
multi_json (~> 1.0)
|
6
6
|
coderay (0.9.8)
|
7
7
|
git (1.2.5)
|
8
8
|
i18n (0.6.0)
|
9
|
-
jeweler (1.6.
|
9
|
+
jeweler (1.6.4)
|
10
10
|
bundler (~> 1.0)
|
11
11
|
git (>= 1.2.5)
|
12
12
|
rake
|
13
13
|
metaclass (0.0.1)
|
14
|
-
method_source (0.6.
|
15
|
-
ruby_parser (
|
16
|
-
minitest (2.
|
14
|
+
method_source (0.6.6)
|
15
|
+
ruby_parser (~> 2.0.5)
|
16
|
+
minitest (2.6.1)
|
17
17
|
mocha (0.10.0)
|
18
18
|
metaclass (~> 0.0.1)
|
19
19
|
multi_json (1.0.3)
|
20
20
|
nokogiri (1.5.0)
|
21
|
-
pry (0.9.6)
|
22
|
-
coderay (
|
23
|
-
method_source (
|
24
|
-
ruby_parser (
|
21
|
+
pry (0.9.6.2)
|
22
|
+
coderay (~> 0.9.8)
|
23
|
+
method_source (~> 0.6.5)
|
24
|
+
ruby_parser (~> 2.0.5)
|
25
25
|
slop (~> 2.1.0)
|
26
|
-
rake (0.
|
27
|
-
rcov (0.9.
|
26
|
+
rake (0.9.2)
|
27
|
+
rcov (0.9.11)
|
28
28
|
roxml (3.1.6)
|
29
29
|
activesupport (>= 2.3.0)
|
30
30
|
nokogiri (>= 1.3.3)
|
31
|
-
ruby_parser (2.
|
31
|
+
ruby_parser (2.0.6)
|
32
32
|
sexp_processor (~> 3.0)
|
33
|
-
sexp_processor (3.0.
|
33
|
+
sexp_processor (3.0.7)
|
34
34
|
slop (2.1.0)
|
35
35
|
|
36
36
|
PLATFORMS
|
37
37
|
ruby
|
38
38
|
|
39
39
|
DEPENDENCIES
|
40
|
-
activesupport (>= 3.1.0)
|
41
40
|
bundler (~> 1.0.0)
|
42
41
|
i18n
|
43
42
|
jeweler (~> 1.6.2)
|
data/elibri_onix.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{elibri_onix}
|
8
|
-
s.version = "0.1.
|
8
|
+
s.version = "0.1.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Marcin Urbanski"]
|
12
|
-
s.date = %q{2011-10-
|
12
|
+
s.date = %q{2011-10-18}
|
13
13
|
s.description = %q{EDItEUR ONIX format subset implementation used in Elibri publication system}
|
14
14
|
s.email = %q{marcin@urbanski.vdl.pl}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -72,7 +72,6 @@ Gem::Specification.new do |s|
|
|
72
72
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
73
73
|
s.add_runtime_dependency(%q<roxml>, ["= 3.1.6"])
|
74
74
|
s.add_runtime_dependency(%q<i18n>, [">= 0"])
|
75
|
-
s.add_runtime_dependency(%q<activesupport>, [">= 3.1.0"])
|
76
75
|
s.add_development_dependency(%q<pry>, [">= 0"])
|
77
76
|
s.add_development_dependency(%q<mocha>, [">= 0"])
|
78
77
|
s.add_development_dependency(%q<minitest>, [">= 0"])
|
@@ -82,7 +81,6 @@ Gem::Specification.new do |s|
|
|
82
81
|
else
|
83
82
|
s.add_dependency(%q<roxml>, ["= 3.1.6"])
|
84
83
|
s.add_dependency(%q<i18n>, [">= 0"])
|
85
|
-
s.add_dependency(%q<activesupport>, [">= 3.1.0"])
|
86
84
|
s.add_dependency(%q<pry>, [">= 0"])
|
87
85
|
s.add_dependency(%q<mocha>, [">= 0"])
|
88
86
|
s.add_dependency(%q<minitest>, [">= 0"])
|
@@ -93,7 +91,6 @@ Gem::Specification.new do |s|
|
|
93
91
|
else
|
94
92
|
s.add_dependency(%q<roxml>, ["= 3.1.6"])
|
95
93
|
s.add_dependency(%q<i18n>, [">= 0"])
|
96
|
-
s.add_dependency(%q<activesupport>, [">= 3.1.0"])
|
97
94
|
s.add_dependency(%q<pry>, [">= 0"])
|
98
95
|
s.add_dependency(%q<mocha>, [">= 0"])
|
99
96
|
s.add_dependency(%q<minitest>, [">= 0"])
|
data/lib/elibri_onix.rb
CHANGED
@@ -18,10 +18,8 @@ module Elibri
|
|
18
18
|
xml_accessor :printed_on_product, :from => 'PrintedOnProduct', :as => Fixnum
|
19
19
|
xml_accessor :position_on_product, :from => 'PositionOnProduct', :as => Fixnum
|
20
20
|
|
21
|
-
|
22
|
-
|
23
|
-
tax.xml_accessor :tax_rate_percent, :from => 'TaxRatePercent', :as => BigDecimal
|
24
|
-
end
|
21
|
+
xml_accessor :tax_type, :in => 'Tax', :from => 'TaxType', :as => Fixnum
|
22
|
+
xml_accessor :tax_rate_percent, :in => 'Tax', :from => 'TaxRatePercent', :as => BigDecimal
|
25
23
|
|
26
24
|
|
27
25
|
def printed_on_product?
|
@@ -37,33 +37,27 @@ module Elibri
|
|
37
37
|
xml_accessor :related_products, :as => [RelatedProduct], :in => 'RelatedMaterial'
|
38
38
|
xml_accessor :supply_details, :as => [SupplyDetail], :in => 'ProductSupply'
|
39
39
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
publishing_detail.xml_accessor :imprint, :as => Imprint
|
62
|
-
publishing_detail.xml_accessor :publisher, :as => Publisher
|
63
|
-
publishing_detail.xml_accessor :publishing_status, :from => 'PublishingStatus', :as => Fixnum
|
64
|
-
publishing_detail.xml_accessor :publishing_date, :as => PublishingDate
|
65
|
-
publishing_detail.xml_accessor :sales_restrictions, :as => [SalesRestriction]
|
66
|
-
end
|
40
|
+
xml_accessor :product_composition, :in => 'DescriptiveDetail', :from => 'ProductComposition', :as => Fixnum
|
41
|
+
xml_accessor :product_form, :in => 'DescriptiveDetail', :from => 'ProductForm'
|
42
|
+
xml_accessor :measures, :in => 'DescriptiveDetail', :as => [Measure]
|
43
|
+
xml_accessor :title_details, :in => 'DescriptiveDetail', :as => [TitleDetail]
|
44
|
+
xml_accessor :collections, :in => 'DescriptiveDetail', :as => [Collection]
|
45
|
+
xml_accessor :contributors, :in => 'DescriptiveDetail', :as => [Contributor]
|
46
|
+
xml_accessor :languages, :in => 'DescriptiveDetail', :as => [Language]
|
47
|
+
xml_accessor :extents, :in => 'DescriptiveDetail', :as => [Extent]
|
48
|
+
xml_accessor :subjects, :in => 'DescriptiveDetail', :as => [Subject]
|
49
|
+
xml_accessor :audience_ranges, :in => 'DescriptiveDetail', :as => [AudienceRange]
|
50
|
+
xml_accessor :edition_statement, :in => 'DescriptiveDetail', :from => 'EditionStatement'
|
51
|
+
xml_accessor :number_of_illustrations, :in => 'DescriptiveDetail', :from => 'NumberOfIllustrations', :as => Fixnum
|
52
|
+
|
53
|
+
xml_accessor :text_contents, :in => 'CollateralDetail', :as => [TextContent]
|
54
|
+
xml_accessor :supporting_resources, :in => 'CollateralDetail', :as => [SupportingResource]
|
55
|
+
|
56
|
+
xml_accessor :imprint, :in => 'PublishingDetail', :as => Imprint
|
57
|
+
xml_accessor :publisher, :in => 'PublishingDetail', :as => Publisher
|
58
|
+
xml_accessor :publishing_status, :in => 'PublishingDetail', :from => 'PublishingStatus', :as => Fixnum
|
59
|
+
xml_accessor :publishing_date, :in => 'PublishingDetail', :as => PublishingDate
|
60
|
+
xml_accessor :sales_restrictions, :in => 'PublishingDetail', :as => [SalesRestriction]
|
67
61
|
|
68
62
|
|
69
63
|
def isbn13
|
@@ -17,10 +17,8 @@ module Elibri
|
|
17
17
|
xml_accessor :price, :as => Price
|
18
18
|
|
19
19
|
|
20
|
-
|
21
|
-
|
22
|
-
stock.xml_accessor :quantity_coded, :as => StockQuantityCoded
|
23
|
-
end
|
20
|
+
xml_accessor :on_hand, :in => 'Stock', :from => 'OnHand', :as => Fixnum
|
21
|
+
xml_accessor :quantity_coded, :in => 'Stock', :as => StockQuantityCoded
|
24
22
|
|
25
23
|
|
26
24
|
def quantity_code
|
@@ -13,10 +13,8 @@ module Elibri
|
|
13
13
|
xml_accessor :audience, :from => 'ContentAudience', :as => Fixnum
|
14
14
|
xml_accessor :mode, :from => 'ResourceMode', :as => Fixnum
|
15
15
|
|
16
|
-
|
17
|
-
|
18
|
-
version.xml_accessor :link, :from => 'ResourceLink'
|
19
|
-
end
|
16
|
+
xml_accessor :form, :in => 'ResourceVersion', :from => 'ResourceForm', :as => Fixnum
|
17
|
+
xml_accessor :link, :in => 'ResourceVersion', :from => 'ResourceLink'
|
20
18
|
|
21
19
|
end
|
22
20
|
|
data/lib/elibri_onix/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: elibri_onix
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 19
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 4
|
10
|
+
version: 0.1.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Marcin Urbanski
|
@@ -15,13 +15,12 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-10-
|
18
|
+
date: 2011-10-18 00:00:00 +02:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
|
-
name: roxml
|
23
22
|
type: :runtime
|
24
|
-
|
23
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
25
24
|
none: false
|
26
25
|
requirements:
|
27
26
|
- - "="
|
@@ -32,12 +31,12 @@ dependencies:
|
|
32
31
|
- 1
|
33
32
|
- 6
|
34
33
|
version: 3.1.6
|
34
|
+
name: roxml
|
35
|
+
version_requirements: *id001
|
35
36
|
prerelease: false
|
36
|
-
requirement: *id001
|
37
37
|
- !ruby/object:Gem::Dependency
|
38
|
-
name: i18n
|
39
38
|
type: :runtime
|
40
|
-
|
39
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
41
40
|
none: false
|
42
41
|
requirements:
|
43
42
|
- - ">="
|
@@ -46,28 +45,12 @@ dependencies:
|
|
46
45
|
segments:
|
47
46
|
- 0
|
48
47
|
version: "0"
|
48
|
+
name: i18n
|
49
|
+
version_requirements: *id002
|
49
50
|
prerelease: false
|
50
|
-
requirement: *id002
|
51
|
-
- !ruby/object:Gem::Dependency
|
52
|
-
name: activesupport
|
53
|
-
type: :runtime
|
54
|
-
version_requirements: &id003 !ruby/object:Gem::Requirement
|
55
|
-
none: false
|
56
|
-
requirements:
|
57
|
-
- - ">="
|
58
|
-
- !ruby/object:Gem::Version
|
59
|
-
hash: 3
|
60
|
-
segments:
|
61
|
-
- 3
|
62
|
-
- 1
|
63
|
-
- 0
|
64
|
-
version: 3.1.0
|
65
|
-
prerelease: false
|
66
|
-
requirement: *id003
|
67
51
|
- !ruby/object:Gem::Dependency
|
68
|
-
name: pry
|
69
52
|
type: :development
|
70
|
-
|
53
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
71
54
|
none: false
|
72
55
|
requirements:
|
73
56
|
- - ">="
|
@@ -76,12 +59,12 @@ dependencies:
|
|
76
59
|
segments:
|
77
60
|
- 0
|
78
61
|
version: "0"
|
62
|
+
name: pry
|
63
|
+
version_requirements: *id003
|
79
64
|
prerelease: false
|
80
|
-
requirement: *id004
|
81
65
|
- !ruby/object:Gem::Dependency
|
82
|
-
name: mocha
|
83
66
|
type: :development
|
84
|
-
|
67
|
+
requirement: &id004 !ruby/object:Gem::Requirement
|
85
68
|
none: false
|
86
69
|
requirements:
|
87
70
|
- - ">="
|
@@ -90,12 +73,12 @@ dependencies:
|
|
90
73
|
segments:
|
91
74
|
- 0
|
92
75
|
version: "0"
|
76
|
+
name: mocha
|
77
|
+
version_requirements: *id004
|
93
78
|
prerelease: false
|
94
|
-
requirement: *id005
|
95
79
|
- !ruby/object:Gem::Dependency
|
96
|
-
name: minitest
|
97
80
|
type: :development
|
98
|
-
|
81
|
+
requirement: &id005 !ruby/object:Gem::Requirement
|
99
82
|
none: false
|
100
83
|
requirements:
|
101
84
|
- - ">="
|
@@ -104,12 +87,12 @@ dependencies:
|
|
104
87
|
segments:
|
105
88
|
- 0
|
106
89
|
version: "0"
|
90
|
+
name: minitest
|
91
|
+
version_requirements: *id005
|
107
92
|
prerelease: false
|
108
|
-
requirement: *id006
|
109
93
|
- !ruby/object:Gem::Dependency
|
110
|
-
name: bundler
|
111
94
|
type: :development
|
112
|
-
|
95
|
+
requirement: &id006 !ruby/object:Gem::Requirement
|
113
96
|
none: false
|
114
97
|
requirements:
|
115
98
|
- - ~>
|
@@ -120,12 +103,12 @@ dependencies:
|
|
120
103
|
- 0
|
121
104
|
- 0
|
122
105
|
version: 1.0.0
|
106
|
+
name: bundler
|
107
|
+
version_requirements: *id006
|
123
108
|
prerelease: false
|
124
|
-
requirement: *id007
|
125
109
|
- !ruby/object:Gem::Dependency
|
126
|
-
name: jeweler
|
127
110
|
type: :development
|
128
|
-
|
111
|
+
requirement: &id007 !ruby/object:Gem::Requirement
|
129
112
|
none: false
|
130
113
|
requirements:
|
131
114
|
- - ~>
|
@@ -136,12 +119,12 @@ dependencies:
|
|
136
119
|
- 6
|
137
120
|
- 2
|
138
121
|
version: 1.6.2
|
122
|
+
name: jeweler
|
123
|
+
version_requirements: *id007
|
139
124
|
prerelease: false
|
140
|
-
requirement: *id008
|
141
125
|
- !ruby/object:Gem::Dependency
|
142
|
-
name: rcov
|
143
126
|
type: :development
|
144
|
-
|
127
|
+
requirement: &id008 !ruby/object:Gem::Requirement
|
145
128
|
none: false
|
146
129
|
requirements:
|
147
130
|
- - ">="
|
@@ -150,8 +133,9 @@ dependencies:
|
|
150
133
|
segments:
|
151
134
|
- 0
|
152
135
|
version: "0"
|
136
|
+
name: rcov
|
137
|
+
version_requirements: *id008
|
153
138
|
prerelease: false
|
154
|
-
requirement: *id009
|
155
139
|
description: EDItEUR ONIX format subset implementation used in Elibri publication system
|
156
140
|
email: marcin@urbanski.vdl.pl
|
157
141
|
executables: []
|