Skip to content

Commit

Permalink
Cleanup Party models
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverroick committed Apr 28, 2017
1 parent d033c91 commit 08709fa
Showing 1 changed file with 1 addition and 23 deletions.
24 changes: 1 addition & 23 deletions cadasta/party/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,28 +225,6 @@ class TenureRelationship(ResourceModelMixin, RandomIDModel):
Governs relationships between Party and SpatialUnit.
"""

CONTRACTUAL_SHARE_CROP = 'CS'
CUSTOMARY_ARRANGEMENT = 'CA'
GIFT = 'GF'
HOMESTEAD = 'HS'
INFORMAL_OCCUPANT = 'IO'
INHERITANCE = 'IN'
LEASEHOLD = 'LH'
PURCHASED_FREEHOLD = 'PF'
RENTAL = 'RN'
OTHER = 'OT'

ACQUIRED_CHOICES = ((CONTRACTUAL_SHARE_CROP, _('Contractual/Share Crop')),
(CUSTOMARY_ARRANGEMENT, _('Customary Arrangement')),
(GIFT, _('Gift')),
(HOMESTEAD, _('Homestead')),
(INFORMAL_OCCUPANT, _('Informal Occupant')),
(INHERITANCE, _('Inheritance')),
(LEASEHOLD, _('Leasehold')),
(PURCHASED_FREEHOLD, _('Purchased Freehold')),
(RENTAL, _('Rental')),
(OTHER, _('Other')))

# All tenure relationships are associated with a single project
project = models.ForeignKey(
Project, on_delete=models.CASCADE, related_name='tenure_relationships')
Expand All @@ -258,7 +236,7 @@ class TenureRelationship(ResourceModelMixin, RandomIDModel):
spatial_unit = models.ForeignKey(SpatialUnit, on_delete=models.CASCADE)

# Tenure relationships type: used to manage range of allowed attributes
tenure_type = models.CharField(max_length=10, null=False, blank=False)
tenure_type = models.CharField(max_length=10)

# JSON attributes field with management of allowed members.
attributes = JSONAttributeField(default={})
Expand Down

0 comments on commit 08709fa

Please sign in to comment.