Sunat Books
A ruby gem to get accounting books for SUNAT
Install
You can install via
gem install sunat_books
or by adding to your Gemfile
gem 'sunat_books'
Usage
require 'sunat_books'
to get a pdf format
pdf = SunatBooks::Pdf::Buys.new(company, tickets, month, year)
pdf.render
to get the txt file for electronic books
ple = SunatBooks::Ple::Buys.new(ruc, tickets, month, year, options)
Currently allowed options are:
-
yml
: path location to a custom layout file -
layout
: a hash to define method names to replace in layout -
book_format
: book format to use