Skip to content

Commit

Permalink
Merge 473fa45 into a42018f
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmiller committed Apr 7, 2020
2 parents a42018f + 473fa45 commit cf1a659
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 4 deletions.
18 changes: 18 additions & 0 deletions elcid/migrations/0041_auto_20200407_1145.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 2.0.9 on 2020-04-07 11:45

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('elcid', '0040_auto_20200407_0940'),
]

operations = [
migrations.AlterField(
model_name='icuround',
name='fio2',
field=models.CharField(blank=True, max_length=20, null=True, verbose_name='FiO₂'),
),
]
8 changes: 6 additions & 2 deletions elcid/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -833,7 +833,10 @@ class InotropicDrug(lookuplists.LookupList):


class ICURound(EpisodeSubrecord):
VENTILATION_TYPES = enum('NIV', "Intubated")
NIV = 'NIV'
INTUBATED = "Intubated"

VENTILATION_TYPES = enum(NIV, INTUBATED)

when = models.DateTimeField(
blank=True, null=True
Expand All @@ -842,7 +845,8 @@ class ICURound(EpisodeSubrecord):
ventilation_type = models.CharField(
max_length=200, blank=True, null=True, choices=VENTILATION_TYPES
)
fio2 = models.FloatField(
fio2 = models.CharField(
max_length=20,
blank=True, null=True, verbose_name="FiO₂"
)
inotropic = models.NullBooleanField(blank=True)
Expand Down
4 changes: 2 additions & 2 deletions elcid/templates/forms/icu_round_form.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
</div>

<div class="col-md-4 col-md-offset-1">
{% radio model="formItem.editing.micro_input_icu_round_relation.icu_round.ventilation_type" field="ICURound.ventilation_type" style="vertical"%}
{% select model="formItem.editing.micro_input_icu_round_relation.icu_round.ventilation_type" field="ICURound.ventilation_type" style="vertical"%}
</div>
<div class="col-md-4 col-md-offset-1">
<div class="col-md-4 col-md-offset-1" ng-show="formItem.editing.micro_input_icu_round_relation.icu_round.ventilation_type == '{{ models.ICURound.INTUBATED }}'">
{% input model="formItem.editing.micro_input_icu_round_relation.icu_round.fio2" field="ICURound.fio2" style="vertical"%}
</div>
</div>
Expand Down

0 comments on commit cf1a659

Please sign in to comment.