Skip to content

Commit

Permalink
fix form field columns to fully fit exptimes
Browse files Browse the repository at this point in the history
  • Loading branch information
jchate6 committed Oct 22, 2024
1 parent 54b0b0c commit b086a98
Showing 1 changed file with 21 additions and 19 deletions.
40 changes: 21 additions & 19 deletions tom_lt/lt.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,12 @@ def layout(self):
css_class='col-md-16'
),
Div(
Div(css_class='col-md-2'),
Div(
PrependedText('max_airmass', 'Airmass <'),
PrependedAppendedText('max_seeing', 'Seeing <', 'arcsec'),
PrependedAppendedText('max_skybri', 'Dark + ', 'mag/arcsec\xB2'),
'photometric',
css_class='col-md-8'
css_class='col-md-16'
),
css_class='form-row'
),
Expand Down Expand Up @@ -242,7 +241,7 @@ def extra_layout(self):
'exp_count_R',
'exp_count_I',
'exp_count_Z',
css_class='col-md-6'),
css_class='col-md-4'),
css_class='form-row'
),
Div(HTML('<br><h5>Bessell</h5>'), css_class='form_row'),
Expand All @@ -253,7 +252,7 @@ def extra_layout(self):

Div('exp_count_B',
'exp_count_V',
css_class='col-md-6'),
css_class='col-md-4'),
css_class='form-row'
),
Div(HTML('<br><h5>H-alpha</h5>'), css_class='form_row'),
Expand All @@ -271,16 +270,13 @@ def extra_layout(self):
'exp_count_Halpha6705',
'exp_count_Halpha6755',
'exp_count_Halpha6822',
css_class='col-md-6'),
css_class='col-md-4'),
css_class='form-row'
),
css_class='col-md-6'
css_class='col-md-10'
),
Div(css_class='col-md-1'),
Div(
Div('binning', css_class='col-md-6'),
css_class='col'
),
Div('binning', css_class='col-md-6'),
css_class='form-row'
)

Expand Down Expand Up @@ -323,10 +319,10 @@ def extra_layout(self):
Div(
Div(
Div(PrependedAppendedText('exp_time', 'H', 's'), css_class='col-md-6'),
Div('exp_count', css_class='col-md-6'),
Div('exp_count', css_class='col-md-4'),
css_class='form-row'
),
css_class='col-md-6'
css_class='col-md-10'
),
Div(css_class='col-md-5'),

Expand Down Expand Up @@ -363,11 +359,17 @@ class LT_SPRAT_ObservationForm(LTObservationForm):

def extra_layout(self):
return Div(
Div(PrependedAppendedText('exp_time', 'SPRAT', 's'), css_class='col'),
Div('exp_count', css_class='col'),
Div('grating', css_class='col'),
Div(
Div(
Div(PrependedAppendedText('exp_time', 'SPRAT', 's'), css_class='col-md-8'),
Div('exp_count', css_class='col-md-4'),
css_class='form-row'
),
css_class='col-md-10'
),
Div('grating', css_class='col-md-10'),
css_class='form-row'
)
)

def _build_inst_schedule(self, payload):
exp_time = self.cleaned_data['exp_time']
Expand Down Expand Up @@ -406,9 +408,9 @@ def extra_layout(self):
return Div(
Div(PrependedAppendedText('exp_time_blue', 'Blue Arm', 's'),
PrependedAppendedText('exp_time_red', 'Red Arm', 's'),
css_class='col'),
Div('exp_count_blue', 'exp_count_red', css_class='col'),
Div('res_blue', 'res_red', css_class='col'),
css_class='col-md-6'),
Div('exp_count_blue', 'exp_count_red', css_class='col-md-4'),
Div('res_blue', 'res_red', css_class='col-md-2'),
css_class='form-row'
)

Expand Down

0 comments on commit b086a98

Please sign in to comment.