<commit_before>{% set translationDomain = "report-prof-current-fees" %}
{% trans_default_domain translationDomain %}
{% import 'AppBundle:Macros:macros-review.html.twig' as macros %}

<div class="section" id="prof-current-fees-xsection">

    <div class="dont-break">
        <h2 class="section-heading">{{ 'startPage.pageTitle'|trans }}</h2>
        <div class="box">
            <h3 class="label question bold">{{ 'existPage.form.hasFees.label'|trans }}</h3>

            <table class="checkboxes labelvalue inline">
                <tr>
                    <td class="value checkbox">{% if report.currentProfPaymentsReceived == 'yes' %}X{% else %}&nbsp;{% endif %}</td>
                    <td class="label">{{ 'yes' | trans({}, 'common' ) }}</td>
                    <td class="value checkbox">{% if report.currentProfPaymentsReceived == 'no' %}X{% else %}&nbsp;{% endif %}</td>
                    <td class="label">{{ 'no' | trans({}, 'common' ) }}</td>
                </tr>
            </table>

            {% if report.currentFixedServiceFees %}

                <div id="closing-summary" class="section">
                    <div class="box box-heading flush-half--bottom">
                        <h3 class="flush--bottom">Current Fixed Fees Summarised</h3>
                    </div>

                    <div class="box box-white">
                        <table class="money">
                            <th>{{ 'summaryPage.table.dateReceived' | trans }}</th>
                            <th>{{ 'summaryPage.table.service' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.charged' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.received' | trans }}</thclass>

                            {% for currentFixedServiceFee in report.currentFixedServiceFees %}
                                <tr>

                                    <td class="width-fifth numeric-small no-wrap">{{ currentFixedServiceFee.paymentReceivedDate  | date("j F Y")}}</td>
                                    <td class="width-third">{{ ('addTypePage.form.serviceType.' ~ currentFixedServiceFee.serviceTypeId) | trans }}</td>
                                    <td class="grey numeric width-sixth numeric-small">£{{ currentFixedServiceFee.amountCharged | money_format }}</td>
                                    <td class="grey numeric width-sixth numeric-small">£{{ currentFixedServiceFee.amountReceived | money_format }}</td>
                                </tr>
                            {% endfor %}
                                <td>
                                    <td class="width-third">&nbsp;</td>
                                    <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalFixedFeesCharged'] | money_format }}</td>
                                    <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalFixedFeesReceived'] | money_format  }}</td>
                                    </td class="width-fifth">&nbsp;</td>
                                </tr>
                        </table>
                    </div>
                </div>

            {% endif %}

            {% if report.currentAssessedServiceFees %}

                <div id="closing-summary" class="section">
                    <div class="box box-heading flush-half--bottom">
                        <h3 class="flush--bottom">Current Assessed Fees Summarised</h3>
                    </div>

                    <div class="box box-white">
                        <table class="money">
                            <th>{{ 'summaryPage.table.dateReceived' | trans }}</th>
                            <th>{{ 'summaryPage.table.service' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.charged' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.received' | trans }}</thclass>

                                {% for currentAssessedFee in report.currentAssessedServiceFees %}
                                    <tr>

                                        <td class="width-fifth numeric-small no-wrap">{{ currentAssessedFee.paymentReceivedDate  | date("j F Y")}}</td>
                                        <td class="width-third">{{ ('addTypePage.form.serviceType.' ~ currentAssessedFee.serviceTypeId) | trans }}</td>
                                        <td class="grey numeric width-sixth numeric-small">£{{ currentAssessedFee.amountCharged | money_format }}</td>
                                        <td class="grey numeric width-sixth numeric-small">£{{ currentAssessedFee.amountReceived | money_format }}</td>
                                    </tr>
                                {% endfor %}
                            <td>
                            <td class="width-third">&nbsp;</td>
                            <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalAssessedFeesCharged'] | money_format  }}</td>
                            <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalAssessedFeesReceived'] | money_format  }}</td>
                            </td class="width-fifth">&nbsp;</td>
                            </tr>
                        </table>
                    </div>
                </div>


            {% endif %}
        </div>

    </div>

    <div>
        {{ macros.answerYesNo({
            question: 'estCostsPage.form.estimateCosts.legend' | trans({}, 'report-prof-current-fees'),
            answer: report.previousProfFeesEstimateGiven,
            moreDetails: report.profFeesEstimateSccoReason,
            showMoreDetailsWith: 'yes'
        }) }}
    </div>

</div><commit_msg>DDPB-1984-prof-current-fees fix preview last answer<commit_after>{% set translationDomain = "report-prof-current-fees" %}
{% trans_default_domain translationDomain %}
{% import 'AppBundle:Macros:macros-review.html.twig' as macros %}

<div class="section" id="prof-current-fees-xsection">

    <div class="dont-break">
        <h2 class="section-heading">{{ 'startPage.pageTitle'|trans }}</h2>
        <div class="box">
            <h3 class="label question bold">{{ 'existPage.form.hasFees.label'|trans }}</h3>

            <table class="checkboxes labelvalue inline">
                <tr>
                    <td class="value checkbox">{% if report.currentProfPaymentsReceived == 'yes' %}X{% else %}&nbsp;{% endif %}</td>
                    <td class="label">{{ 'yes' | trans({}, 'common' ) }}</td>
                    <td class="value checkbox">{% if report.currentProfPaymentsReceived == 'no' %}X{% else %}&nbsp;{% endif %}</td>
                    <td class="label">{{ 'no' | trans({}, 'common' ) }}</td>
                </tr>
            </table>

            {% if report.currentFixedServiceFees %}

                <div id="closing-summary" class="section">
                    <div class="box box-heading flush-half--bottom">
                        <h3 class="flush--bottom">Current Fixed Fees Summarised</h3>
                    </div>

                    <div class="box box-white">
                        <table class="money">
                            <th>{{ 'summaryPage.table.dateReceived' | trans }}</th>
                            <th>{{ 'summaryPage.table.service' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.charged' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.received' | trans }}</thclass>

                            {% for currentFixedServiceFee in report.currentFixedServiceFees %}
                                <tr>

                                    <td class="width-fifth numeric-small no-wrap">{{ currentFixedServiceFee.paymentReceivedDate  | date("j F Y")}}</td>
                                    <td class="width-third">{{ ('addTypePage.form.serviceType.' ~ currentFixedServiceFee.serviceTypeId) | trans }}</td>
                                    <td class="grey numeric width-sixth numeric-small">£{{ currentFixedServiceFee.amountCharged | money_format }}</td>
                                    <td class="grey numeric width-sixth numeric-small">£{{ currentFixedServiceFee.amountReceived | money_format }}</td>
                                </tr>
                            {% endfor %}
                                <td>
                                    <td class="width-third">&nbsp;</td>
                                    <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalFixedFeesCharged'] | money_format }}</td>
                                    <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalFixedFeesReceived'] | money_format  }}</td>
                                    </td class="width-fifth">&nbsp;</td>
                                </tr>
                        </table>
                    </div>
                </div>

            {% endif %}

            {% if report.currentAssessedServiceFees %}

                <div id="closing-summary" class="section">
                    <div class="box box-heading flush-half--bottom">
                        <h3 class="flush--bottom">Current Assessed Fees Summarised</h3>
                    </div>

                    <div class="box box-white">
                        <table class="money">
                            <th>{{ 'summaryPage.table.dateReceived' | trans }}</th>
                            <th>{{ 'summaryPage.table.service' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.charged' | trans }}</th>
                            <th class="numeric">{{ 'summaryPage.table.received' | trans }}</th>

                                {% for currentAssessedFee in report.currentAssessedServiceFees %}
                                    <tr>

                                        <td class="width-fifth numeric-small no-wrap">{{ currentAssessedFee.paymentReceivedDate  | date("j F Y")}}</td>
                                        <td class="width-third">{{ ('addTypePage.form.serviceType.' ~ currentAssessedFee.serviceTypeId) | trans }}</td>
                                        <td class="grey numeric width-sixth numeric-small">£{{ currentAssessedFee.amountCharged | money_format }}</td>
                                        <td class="grey numeric width-sixth numeric-small">£{{ currentAssessedFee.amountReceived | money_format }}</td>
                                    </tr>
                                {% endfor %}
                            <td>
                            <td class="width-third">&nbsp;</td>
                            <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalAssessedFeesCharged'] | money_format  }}</td>
                            <td class="width-sixth reverse numeric">£{{ report.feeTotals['totalAssessedFeesReceived'] | money_format  }}</td>
                            </td class="width-fifth">&nbsp;</td>
                            </tr>
                        </table>
                    </div>
                </div>


            {% endif %}
        </div>

    </div>

    {% if report.currentProfPaymentsReceived == 'yes' %}
    <div>
        {{ macros.answerYesNo({
            question: 'estCostsPage.form.estimateCosts.legend' | trans({}, 'report-prof-current-fees'),
            answer: report.previousProfFeesEstimateGiven,
            moreDetails: report.profFeesEstimateSccoReason,
            showMoreDetailsWith: 'yes'
        }) }}
    </div>
    {% endif %}

</div>
{'fraction_non_alphanumeric': 0.14121808143547274, 'fraction_numerical': 0.001725327812284334, 'mean_word_length': 1.45979206450244, 'pattern_counts': {'":': 0, '<': 203, '<?xml version=': 0, '>': 203, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 44, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5713531', 'n_tokens_mistral': 3151, 'n_tokens_neox': 2862, 'n_words': 571}