Sha256: 840b6558319fae4109c634168cf894fdb37580f03f05198ba718f5eddc6377d7
Contents?: true
Size: 670 Bytes
Versions: 7
Compression:
Stored size: 670 Bytes
Contents
# frozen_string_literal: true require "rubyXL" module Decidim module Admin module Import module Readers # Imports any exported XLSX file to local objects. It transforms the # import data using the creator into the final target objects. class XLSX < Base MIME_TYPE = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" def read_rows workbook = RubyXL::Parser.parse(file) sheet = workbook.worksheets[0] sheet.each_with_index do |row, index| yield row.cells.map(&:value), index end end end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems