<reponame>DaleProctor/tscharts<gh_stars>10-100
#(C) Copyright <NAME> 2020
#(C) Copyright Thousand Smiles Foundation 2020
#
#Licensed under the Apache License, Version 2.0 (the "License");
#you may not use this file except in compliance with the License.
#
#You may obtain a copy of the License at
#http://www.apache.org/licenses/LICENSE-2.0
#
#Unless required by applicable law or agreed to in writing, software
#distributed under the License is distributed on an "AS IS" BASIS,
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#See the License for the specific language governing permissions and
#limitations under the License.

from __future__ import unicode_literals

from django.db import models

from patient.models import Patient
from clinic.models import Clinic
from enthistory.models import ENTHistory

# this model used to add history found in an ENT exam not accounted for in
# the design of the database, but which needs to be recorded nonetheless.

class ENTHistoryExtra(models.Model):
    enthistory = models.ForeignKey(ENTHistory)
    time = models.DateTimeField(auto_now=True)
    name = models.CharField(max_length=64, default = "")  # name of condition 
    duration = models.CharField(max_length = 1, choices = ENTHistory.EAR_DURATION_CHOICES, default = ENTHistory.EAR_DURATION_NONE)
    side = models.CharField(max_length = 1, choices = ENTHistory.EAR_SIDE_CHOICES, default = ENTHistory.EAR_SIDE_BOTH)
