Skip to content

Commit

Permalink
Removed auto generate entity
Browse files Browse the repository at this point in the history
  • Loading branch information
wondie committed Apr 4, 2018
1 parent 3006dd0 commit 8ba0907
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions data/configuration/profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,12 @@ def __init__(self, name, configuration):
self._str_table_exists = False

self._admin_spatial_unit = AdministrativeSpatialUnit(self)

self.removed_entities = []

#Add default entities to the entity collection
self.add_entity(self.supporting_document)
self.add_entity(self._admin_spatial_unit)

self.add_entity(self.social_tenure)

def _prefix(self):
Expand Down Expand Up @@ -134,6 +134,16 @@ def administrative_spatial_unit(self):
"""
return self._admin_spatial_unit

@property
def auto_generate_code(self):

"""
:return: Returns the entity corresponding to the auto generate code
:rtype: AutoGenerateCode
"""
# Added in 1.7.4
return self._admin_spatial_unit

@property
def key(self):
"""
Expand Down Expand Up @@ -206,7 +216,7 @@ def has_entity(self, entity):
Check if the entity exsts in the profile.
:param entity: Short name of an entity or entity object.
:type entity: str or Entity
:return: Return True if the entity exists in the profile, otherwise
:return: Return True if the entity exists in the profile, otherwise
False.
:rtype: bool
"""
Expand All @@ -231,7 +241,7 @@ def entity_by_name(self, name):

if len(items) == 0:
return None

else:
return items[0]

Expand Down Expand Up @@ -653,5 +663,4 @@ def str_table_exists(self):
@str_table_exists.setter
def str_table_exists(self, value):
self._str_table_exists = value



0 comments on commit 8ba0907

Please sign in to comment.