relaton-iso 1.13.5 → 1.13.6

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
  SHA256:
3
- metadata.gz: 545043eab945ec715dbf08c77dbd3c07379b87d0c06c317431223a97cb0b7816
4
- data.tar.gz: 8f7594c2399682c780e47eb4e770deb19d48a17ffd5c21efc1938a463768eb25
3
+ metadata.gz: 15e59c996299424282311bbcff81938de7f3cedec23726db9d4cfa377bc37f3b
4
+ data.tar.gz: 1ccc769d95eb05561a57ba6d4f55ffb006a10cf76bbd362d667d4906db4c38b2
5
5
  SHA512:
6
- metadata.gz: 15b2628861c98f99a4879ec5d4c94f52d6551cdd20b322127d9ec4f42e2370e6f85350b95a257ecaaa49843bd29975a74e33fadff12bcbacc594d5ab3dd00d75
7
- data.tar.gz: d5491c7ac248b6e3ba7bee7dbd2c32527103a3ede84dc14bfc67d29597c35e735ea47b5beed488f104ae3e9a46e28201aad0bc2667a85203a95d9bb9c9486c6e
6
+ metadata.gz: 927b2cfea7b54d87022642a0e04555c12716a09f800fc79f7133162ffccd9f91ea1ce95b99a3feb18d42e7e1326844585e5384d2f3d777f0b39fd960f0fcd1ce
7
+ data.tar.gz: 72ae5ee67833161e820559911ccb9d712952a31225b184475d4c85e6a16fa4405805238c71b12eb733dadb8442ba419c6e2f49cc2917cf8fd924b9fdcd607d9d
@@ -1,7 +1,7 @@
1
1
  module RelatonIso
2
2
  class DocumentIdentifier < RelatonBib::DocumentIdentifier
3
3
  def id
4
- id_str = @id.to_s.sub(/\sED\d+/, "")
4
+ id_str = @id.to_s.sub(/\sED\d+/, "").squeeze(" ").sub(/^ISO\/\s/, "ISO ") # workarounds for pubid gem bugs
5
5
  if @all_parts
6
6
  if type == "URN"
7
7
  return "#{@id.urn}:ser"
@@ -98,7 +98,7 @@ module RelatonIso
98
98
  # @return [Array<RelatonBib::DocumentIdentifier>]
99
99
  #
100
100
  def fetch_relaton_docids(doc, pubid)
101
- pubid.urn_stage = stage_code(doc).to_f
101
+ pubid.stage = Pubid::Iso::Stage.new(harmonized_code: stage_code(doc))
102
102
  [
103
103
  RelatonIso::DocumentIdentifier.new(id: pubid, type: "ISO", primary: true),
104
104
  RelatonIso::DocumentIdentifier.new(id: pubid, type: "URN"),
@@ -226,7 +226,7 @@ module RelatonIso
226
226
  end
227
227
 
228
228
  def stage_code(doc)
229
- doc.at("//ul[@class='dropdown-menu']/li[@class='active']"\
229
+ doc.at("//ul[@class='dropdown-menu']/li[@class='active']" \
230
230
  "/a/span[@class='stage-code']").text
231
231
  end
232
232
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module RelatonIso
4
- VERSION = "1.13.5"
4
+ VERSION = "1.13.6"
5
5
  end
data/relaton_iso.gemspec CHANGED
@@ -40,6 +40,6 @@ Gem::Specification.new do |spec|
40
40
 
41
41
  spec.add_dependency "algolia"
42
42
  spec.add_dependency "pubid-core", "1.2.1"
43
- spec.add_dependency "pubid-iso", "~> 0.2.0"
43
+ spec.add_dependency "pubid-iso", "0.2.1"
44
44
  spec.add_dependency "relaton-iso-bib", "~> 1.13.0"
45
45
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relaton-iso
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.13.5
4
+ version: 1.13.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-10-22 00:00:00.000000000 Z
11
+ date: 2022-10-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: byebug
@@ -196,16 +196,16 @@ dependencies:
196
196
  name: pubid-iso
197
197
  requirement: !ruby/object:Gem::Requirement
198
198
  requirements:
199
- - - "~>"
199
+ - - '='
200
200
  - !ruby/object:Gem::Version
201
- version: 0.2.0
201
+ version: 0.2.1
202
202
  type: :runtime
203
203
  prerelease: false
204
204
  version_requirements: !ruby/object:Gem::Requirement
205
205
  requirements:
206
- - - "~>"
206
+ - - '='
207
207
  - !ruby/object:Gem::Version
208
- version: 0.2.0
208
+ version: 0.2.1
209
209
  - !ruby/object:Gem::Dependency
210
210
  name: relaton-iso-bib
211
211
  requirement: !ruby/object:Gem::Requirement