dynarex-blog 0.3.12 → 0.3.13

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.
Files changed (2) hide show
  1. data/lib/dynarex-blog.rb +9 -5
  2. metadata +1 -1
data/lib/dynarex-blog.rb CHANGED
@@ -135,11 +135,15 @@ class DynarexBlog
135
135
  total_pages, remainder = %w(/ %).map {|x| total_records.send x, 10}
136
136
  total_pages += 1 if remainder > 0
137
137
 
138
- [
139
- ['total_records', total_records],
140
- ['page_number', number],
141
- ['total_pages', total_pages]
142
- ].each do |name, text|
138
+ summary = {
139
+ total_records: total_records,
140
+ page_number: number,
141
+ total_pages: total_pages
142
+ }
143
+
144
+ context = lookup[/^([a-zA-Z][\w\+-]+)_lookup.xml/,1]
145
+ summary[:context] = context if context
146
+ summary.each do |name, text|
143
147
  r.root.elements['summary'].add Element.new(name).add_text(text.to_s)
144
148
  end
145
149
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dynarex-blog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.12
4
+ version: 0.3.13
5
5
  platform: ruby
6
6
  authors: []
7
7