diff options
| author | 2023-02-08 00:40:16 -0500 | |
|---|---|---|
| committer | 2023-02-08 00:40:16 -0500 | |
| commit | b0bc0772184c68b8d4baac678c5fb707dc23af7f (patch) | |
| tree | 62c95563dd5d57e9db8268227acf4cc91e75af04 /lib/roo/open_office.rb | |
| parent | e44f5d5d1935ee40a6bbb232e649d91e8aa9ce74 (diff) | |
| parent | ae103e148eb3c15606b816505492d870ef062ad3 (diff) | |
Update upstream source from tag 'upstream/2.10.0'
Update to upstream version '2.10.0'
with Debian dir 3c0f78b1f632920ec992d7bf7e43a8b0ced0b21d
Diffstat (limited to 'lib/roo/open_office.rb')
| -rw-r--r-- | lib/roo/open_office.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/roo/open_office.rb b/lib/roo/open_office.rb index f172363..542c5b4 100644 --- a/lib/roo/open_office.rb +++ b/lib/roo/open_office.rb @@ -423,7 +423,10 @@ module Roo @style[sheet][key] = style_name case @cell_type[sheet][key] when :float - @cell[sheet][key] = (table_cell.attributes['value'].to_s.include?(".") || table_cell.children.first.text.include?(".")) ? v.to_f : v.to_i + value = (table_cell.attributes['value'].to_s.include?(".") || table_cell.children.first.text.include?(".")) ? v.to_f : v.to_i + value = 'true' if formula == '=TRUE()' + value = 'false' if formula == '=FALSE()' + @cell[sheet][key] = value when :percentage @cell[sheet][key] = v.to_f when :string @@ -517,7 +520,7 @@ module Roo str_v += child.content #.text end end - str_v.gsub!(/'/, "'") # special case not supported by unescapeHTML + str_v = str_v.gsub(/'/, "'") # special case not supported by unescapeHTML str_v = CGI.unescapeHTML(str_v) end # == 'p' end |
