Package Gnumed :: Package business :: Module gmEMRStructItems :: Class cEncounter
[frames] | no frames]

Class cEncounter

source code

                                   object --+    
                                            |    
pycommon.gmBusinessDBObject.cBusinessDBObject --+
                                                |
                                               cEncounter

Represents one encounter.

Instance Methods
 
set_active(self)
Set the encounter as the active one.
source code
 
transfer_clinical_data(self, source_episode=None, target_episode=None)
Moves every element currently linked to the current encounter and the source_episode onto target_episode.
source code
 
same_payload(self, another_object=None) source code
 
has_clinical_data(self) source code
 
has_narrative(self) source code
 
has_soap_narrative(self, soap_cats=None)
soap_cats: <space> = admin category
source code
 
has_documents(self) source code
 
get_latest_soap(self, soap_cat=None, episode=None) source code
 
get_episodes(self, exclude=None) source code
 
add_code(self, pk_code=None, field=None)
<pk_code> must be a value from ref.coding_system_root.pk_coding_system (clin.lnk_code2item_root.fk_generic_code)
source code
 
remove_code(self, pk_code=None, field=None)
<pk_code> must be a value from ref.coding_system_root.pk_coding_system (clin.lnk_code2item_root.fk_generic_code)
source code
 
format_soap(self, episodes=None, left_margin=0, soap_cats='soapu', emr=None, issues=None) source code
 
format_latex(self, date_format=None, soap_cats=None, soap_order=None) source code
 
format_header(self, fancy_header=True, left_margin=0, with_rfe_aoe=False) source code
 
format_by_episode(self, episodes=None, issues=None, left_margin=0, patient=None, with_soap=False, with_tests=True, with_docs=True, with_vaccinations=True, with_family_history=True) source code
 
format(self, episodes=None, with_soap=False, left_margin=0, patient=None, issues=None, with_docs=True, with_tests=True, fancy_header=True, with_vaccinations=True, with_co_encountlet_hints=False, with_rfe_aoe=False, with_family_history=True, by_episode=False)
Format an encounter.
source code

Inherited from pycommon.gmBusinessDBObject.cBusinessDBObject: __del__, __getitem__, __init__, __setitem__, __str__, __unicode__, fields_as_dict, get_fields, get_patient, get_updatable_fields, is_modified, refetch_payload, save, save_payload

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __subclasshook__

Properties
  episodes
  generic_codes_rfe
  generic_codes_aoe
  praxis_branch
  org_unit

Inherited from object: __class__

Method Details

set_active(self)

source code 

Set the encounter as the active one.

"Setting active" means making sure the encounter row has the youngest "last_affirmed" timestamp of all encounter rows for this patient.

transfer_clinical_data(self, source_episode=None, target_episode=None)

source code 

Moves every element currently linked to the current encounter and the source_episode onto target_episode.

@param source_episode The episode the elements are currently linked to. @type target_episode A cEpisode intance. @param target_episode The episode the elements will be relinked to. @type target_episode A cEpisode intance.

same_payload(self, another_object=None)

source code 
Overrides: pycommon.gmBusinessDBObject.cBusinessDBObject.same_payload

format(self, episodes=None, with_soap=False, left_margin=0, patient=None, issues=None, with_docs=True, with_tests=True, fancy_header=True, with_vaccinations=True, with_co_encountlet_hints=False, with_rfe_aoe=False, with_family_history=True, by_episode=False)

source code 

Format an encounter.

with_co_encountlet_hints:

  • whether to include which *other* episodes were discussed during this encounter
  • (only makes sense if episodes != None)
Overrides: pycommon.gmBusinessDBObject.cBusinessDBObject.format

Property Details

episodes

Get Method:
get_episodes(self, exclude=None)
Set Method:
unreachable(x)

generic_codes_rfe

Get Method:
_get_generic_codes_rfe(self)
Set Method:
_set_generic_codes_rfe(self, pk_codes)

generic_codes_aoe

Get Method:
_get_generic_codes_aoe(self)
Set Method:
_set_generic_codes_aoe(self, pk_codes)

praxis_branch

Get Method:
_get_praxis_branch(self)
Set Method:
unreachable(x)

org_unit

Get Method:
_get_org_unit(self)
Set Method:
unreachable(x)