diff --git a/smash/web/models.py b/smash/web/models.py index c5b2915b5b2839bb9cd92bd1defb4f12061592fa..820bce3b01bcc6a08352186f1049ca9829b0e235 100644 --- a/smash/web/models.py +++ b/smash/web/models.py @@ -173,19 +173,6 @@ class Visit(models.Model): verbose_name='Visit ends at' ) # Deadline before which all appointments need to be scheduled - TYPE_CHOICES_LEVEL_A_VISIT = 'A' - TYPE_CHOICES_LEVEL_B_VISIT = 'B' - TYPE_CHOICES_OTHER = 'O' - - TYPE_CHOICES = ( - (TYPE_CHOICES_LEVEL_A_VISIT, 'Level A visit'), - (TYPE_CHOICES_LEVEL_B_VISIT, 'Level B visit'), - (TYPE_CHOICES_OTHER, 'Other') - ) - visit_type = models.CharField(max_length=1, choices=TYPE_CHOICES, - verbose_name='Visit type', - default='O' - ) is_finished = models.BooleanField( verbose_name='Has ended', default=False diff --git a/smash/web/templates/visits/index.html b/smash/web/templates/visits/index.html index adb835d2f3166d5a462010292d963f30516d77d8..65a47aea2b1bbf053fc0e350164edff192c9ce72 100644 --- a/smash/web/templates/visits/index.html +++ b/smash/web/templates/visits/index.html @@ -41,8 +41,7 @@ <th>Full information</th> <th>Visit begins</th> <th>Visit ends</th> - <th>Visit type</th> - <th>Finished?</th> + <th>Finished?</th> </tr> </thead> <tbody> @@ -58,10 +57,7 @@ <td> {{ visit.datetime_end }} </td> - <td> - {{ visit.get_visit_type_display }} - </td> - <td> + <td> {% if visit.is_finished %}<button type="button" class="btn btn-block btn-success">YES</button> {% else %}<button type="button" class="btn btn-block btn-danger">NO</button> {% endif %} diff --git a/smash/web/tests/test_VisitAddForm.py b/smash/web/tests/test_VisitAddForm.py index 9a35892b17104ab8d46beaaffbc004890821386e..83ba6a8b4fc1a0fb6e60bc974112c8c946dcafb0 100644 --- a/smash/web/tests/test_VisitAddForm.py +++ b/smash/web/tests/test_VisitAddForm.py @@ -16,7 +16,6 @@ class SubjectAddFormTests(TestCase): self.sample_data = {'datetime_begin': "2017-01-01", 'datetime_end': "2017-02-02", - 'visit_type': Visit.TYPE_CHOICES_OTHER, 'subject' : self.subject.id }