Class: Onoma::AccountingSystem

Inherits:
Record::Base show all
Defined in:
lib/onoma/models/accounting_system.rb

Class Method Summary collapse

Methods inherited from Record::Base

method_missing, respond_to?

Class Method Details

.with_fiscal_positionObject



4
5
6
7
8
9
# File 'lib/onoma/models/accounting_system.rb', line 4

def with_fiscal_position
  Onoma::FiscalPosition.items.values
      .reduce(Set.new) {|acc, fp| acc << fp.accounting_system}
      .map {|e| Onoma::AccountingSystem[e]}
      .compact
end