|
|
@ -193,22 +193,6 @@ def agreed_child_support_amount(context, claimant_id, line_breaks=True): |
|
|
return linebreaksli(context.get('amount_income_over_high_income_limit_{}'.format(claimant_id), '')) |
|
|
return linebreaksli(context.get('amount_income_over_high_income_limit_{}'.format(claimant_id), '')) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@register.filter |
|
|
|
|
|
def css_rotate(image): |
|
|
|
|
|
""" Gets extra CSS needed for image rotation when generating PDFs """ |
|
|
|
|
|
if image.rotation == 90 or image.rotation == 270: |
|
|
|
|
|
height = image.width |
|
|
|
|
|
width = image.height |
|
|
|
|
|
else: |
|
|
|
|
|
height = image.height |
|
|
|
|
|
width = image.width |
|
|
|
|
|
|
|
|
|
|
|
if width == 0 or height/width < 1.3: |
|
|
|
|
|
return 'width: 100%' |
|
|
|
|
|
else: |
|
|
|
|
|
return 'height: 26.7cm' |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@register.filter |
|
|
@register.filter |
|
|
def name_you(responses): |
|
|
def name_you(responses): |
|
|
""" Gets and formats given_name_1_you, given_name_2_you, given_name_3_you, last_name_you from responses """ |
|
|
""" Gets and formats given_name_1_you, given_name_2_you, given_name_3_you, last_name_you from responses """ |
|
|
|