Class: Subledger::Domain::PostedJournalEntry

Inherits:
JournalEntry show all
Includes:
Roles::Postable
Defined in:
lib/subledger/domain/journal_entry.rb

Defined Under Namespace

Classes: Entity

Instance Attribute Summary

Attributes inherited from JournalEntry

#book, #effective_at, #org, #post_delay

Attributes included from Roles::Versionable

#version

Attributes included from Roles::Storable

#client, #store

Attributes included from Roles::Identifiable

#id

Attributes included from Roles::Describable

#description, #reference

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Roles::Postable

#post, #posted_klass, #posting_klass

Methods inherited from JournalEntry

active_klass, archived_klass, #balance, #balanced?, create_and_post, #initialize, #line, #lines, patch_keys, post_keys, posted_klass, posting_klass, root_klass

Methods included from Roles::Restable

#patch_hash, #post_hash, #serializable_hash, #to_json

Methods included from Roles::Collectable

included

Methods included from Roles::Progressable

#progress

Methods included from Roles::Updatable

included

Methods included from Roles::Readable

included, #read

Methods included from Roles::Creatable

#create, included

Methods included from Roles::Versionable

included

Methods included from Roles::Storable

raise_unless_creatable

Methods included from Roles::Describable

raise_unless_creatable

Methods included from Roles::Attributable

#attributes

Methods included from Subledger::Domain

#==, #collection_name, #entity_name, included, #to_s

Constructor Details

This class inherits a constructor from Subledger::Domain::JournalEntry

Class Method Details

.sub_klassesObject



288
289
290
# File 'lib/subledger/domain/journal_entry.rb', line 288

def self.sub_klasses
  [ posted_klass ]
end

.update(args) ⇒ Object

Raises:



292
293
294
# File 'lib/subledger/domain/journal_entry.rb', line 292

def self.update args
  raise JournalEntryError, 'posted journal entries are not updatable'
end

Instance Method Details

#updateObject



296
297
298
# File 'lib/subledger/domain/journal_entry.rb', line 296

def update
  self.class.update( { } )
end