Sha256: 8b85cf485b05522c56343a1c8dcbb7b28889f0dcea11c5338ccc6f13c672f483
Contents?: true
Size: 714 Bytes
Versions: 9
Compression:
Stored size: 714 Bytes
Contents
module Economic module Invoices class Repo < Economic::BaseRepo class << self def all(filter_text: "") invoices = super(filter_text: filter_text) invoices.each do |invoice| invoice.remove_instance_variable("@lines") class << invoice define_method(:lines) { raise NoMethodError } end end invoices end def send(model, url: endpoint_url) response = send_request(method: :post, url: url, payload: model.to_h.to_json) modelize_response(response) end def filter(filter_text) all(filter_text: filter_text) end end end end end
Version data entries
9 entries across 9 versions & 1 rubygems