<commit_before>﻿@using Microsoft.AspNetCore.Http;
@model SERVERAPI.ViewModels.ReportViewModel

@{
    ViewBag.Title = "Nutrient Report";
}
<!-- modal placeholder-->
<div id='myModal' class='modal'>
    <div class="modal-dialog">
        <div class="modal-content">
            <div id='myModalContent'></div>
        </div>
    </div>
</div>

<!-- BODY CONTENT -->

<div class="header-height"></div>

<div class="step-header">
    <div class="container">
        <div class="col-sm-10">
            @*<span class="step-header-circle">6</span>*@
            <div class="col-sm-6">
                <span class="step-header-name">Nutrient Report</span>
                &nbsp;
                <span class="step-header-steps">Step 6 of 6</span>
            </div>
            <div class="col-sm-4">
                <span class="step-header-name text-right">@Context.Session.GetString("Farm")</span>
            </div>
        </div>
        <div class="col-sm-2">
            <div class="col-sm-2">
                <input class="btn btn-primary" type="button" value="Download file" title="Download data to your local drive" onclick="location.href='@Url.Action("Download", "Home")'" />
            </div>
        </div>
    </div>
</div>

<div class="container">
    <div class="step-forms col-sm-12">
        <!-- PAGE CONTENT -->
        <form asp-controller="Report" asp-action="Report" method="post">
            <div class="form-box">
                <div class="form-box-header clearfix" style="text-align:center">
                    <legend class="form-box-heading">PDF Reports</legend>
                </div>
                <div class="form-box-body">
                    <div class="form-box-fields">
                        <div class="row" style="text-align:center">
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintComplete", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Complete Report" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintFields", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Field Summaries" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintApplication", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Application Schedule" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintSheets", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Record Keeping Sheets" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintFonts", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Fonts" /></span></a>
                            </div>
                        </div>
                    </div>
                </div>
            </div>

            <br />
            <br />
            <br />
            <br />
            <div class="form-box-submit">
                <input class="form-box-submit-button btn btn-primary" style="float:left" type="button" value="Previous" onclick="window.location.href='@Url.Action("Calculate", "Nutrients" )';" />
                <input class="form-box-submit-button btn btn-primary" style="float:right" type="button" value="Finish" onclick = "Intercept('@Model.url');"  />
            </div>
            @Html.HiddenFor(x => x.unsavedData)
            @Html.HiddenFor(x => x.url)
        </form>
    </div>
</div>
@section Scripts {
<script type="text/javascript">

    $(document).on("click", '[data_modal2]', function (e) {
        $.ajaxSetup({ cache: false });
        $type = $(this).data('type'); // this works as of jQuery 1.4.3, otherwise $(this).attr('data-type');
        $('#myModalContent').load($type, function () {
            $('#myModal').modal({
                /*backdrop: 'static',*/
                //keyboard: true
            }, 'show');
            bindForm2(this);
        });
        return false;
    });

    function bindForm2(dialog) {
        $('form', dialog).submit(function () {
            $.ajax({
                cache: false,
                url: this.action,
                type: this.method,
                data: $(this).serialize()
            })
                .done(function (result) {
                    if (result.success) {
                        $('#myModal').modal('hide');
                        //$(result.target).load(result.url); //  Load data from the server and place the returned HTML into the matched element
                        window.location.href = result.url;
                    } else {
                        $('#myModalContent').html(result);
                        bindForm2(dialog);
                    }
                });

            return false;
        });

    }

    $(document).ready(function () {
        $.ajaxSetup({ cache: false });
    });


    function Intercept(x) {
        if ($("#unsavedData").val() == "True")
        {
            $.ajaxSetup({ cache: false });
            var url = '@Url.Action("SaveWarning", "Nutrients", new { target = "zzz" })';
            $type = url.replace('zzz', x);
            $('#myModalContent').load($type, function () {
                $('#myModal').modal({
                    /*backdrop: 'static',*/
                    //keyboard: true
                }, 'show');
                bindForm2(this);
            });
            return false;
        }
        else
        {
            window.location.href = x;
        }
    }

    $(document).ready(function () {
        $("#wizard-report").addClass('wizard-item-done');
    });

</script>
}
<commit_msg>remove test fonts<commit_after>﻿@using Microsoft.AspNetCore.Http;
@model SERVERAPI.ViewModels.ReportViewModel

@{
    ViewBag.Title = "Nutrient Report";
}
<!-- modal placeholder-->
<div id='myModal' class='modal'>
    <div class="modal-dialog">
        <div class="modal-content">
            <div id='myModalContent'></div>
        </div>
    </div>
</div>

<!-- BODY CONTENT -->

<div class="header-height"></div>

<div class="step-header">
    <div class="container">
        <div class="col-sm-10">
            @*<span class="step-header-circle">6</span>*@
            <div class="col-sm-6">
                <span class="step-header-name">Nutrient Report</span>
                &nbsp;
                <span class="step-header-steps">Step 6 of 6</span>
            </div>
            <div class="col-sm-4">
                <span class="step-header-name text-right">@Context.Session.GetString("Farm")</span>
            </div>
        </div>
        <div class="col-sm-2">
            <div class="col-sm-2">
                <input class="btn btn-primary" type="button" value="Download file" title="Download data to your local drive" onclick="location.href='@Url.Action("Download", "Home")'" />
            </div>
        </div>
    </div>
</div>

<div class="container">
    <div class="step-forms col-sm-12">
        <!-- PAGE CONTENT -->
        <form asp-controller="Report" asp-action="Report" method="post">
            <div class="form-box">
                <div class="form-box-header clearfix" style="text-align:center">
                    <legend class="form-box-heading">PDF Reports</legend>
                </div>
                <div class="form-box-body">
                    <div class="form-box-fields">
                        <div class="row" style="text-align:center">
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintComplete", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Complete Report" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintFields", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Field Summaries" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintApplication", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Application Schedule" /></span></a>
                            </div>
                            <div style="margin-top:10px">
                                <a href="@Url.Action("PrintSheets", "Report")" target="_blank"><span aria-hidden="true" style="font-size:20px; padding-top:5px"><input class="form-box-submit-button btn btn-primary" style="width:200px" type="button" value="Record Keeping Sheets" /></span></a>
                            </div>
                        </div>
                    </div>
                </div>
            </div>

            <br />
            <br />
            <br />
            <br />
            <div class="form-box-submit">
                <input class="form-box-submit-button btn btn-primary" style="float:left" type="button" value="Previous" onclick="window.location.href='@Url.Action("Calculate", "Nutrients" )';" />
                <input class="form-box-submit-button btn btn-primary" style="float:right" type="button" value="Finish" onclick = "Intercept('@Model.url');"  />
            </div>
            @Html.HiddenFor(x => x.unsavedData)
            @Html.HiddenFor(x => x.url)
        </form>
    </div>
</div>
@section Scripts {
<script type="text/javascript">

    $(document).on("click", '[data_modal2]', function (e) {
        $.ajaxSetup({ cache: false });
        $type = $(this).data('type'); // this works as of jQuery 1.4.3, otherwise $(this).attr('data-type');
        $('#myModalContent').load($type, function () {
            $('#myModal').modal({
                /*backdrop: 'static',*/
                //keyboard: true
            }, 'show');
            bindForm2(this);
        });
        return false;
    });

    function bindForm2(dialog) {
        $('form', dialog).submit(function () {
            $.ajax({
                cache: false,
                url: this.action,
                type: this.method,
                data: $(this).serialize()
            })
                .done(function (result) {
                    if (result.success) {
                        $('#myModal').modal('hide');
                        //$(result.target).load(result.url); //  Load data from the server and place the returned HTML into the matched element
                        window.location.href = result.url;
                    } else {
                        $('#myModalContent').html(result);
                        bindForm2(dialog);
                    }
                });

            return false;
        });

    }

    $(document).ready(function () {
        $.ajaxSetup({ cache: false });
    });


    function Intercept(x) {
        if ($("#unsavedData").val() == "True")
        {
            $.ajaxSetup({ cache: false });
            var url = '@Url.Action("SaveWarning", "Nutrients", new { target = "zzz" })';
            $type = url.replace('zzz', x);
            $('#myModalContent').load($type, function () {
                $('#myModal').modal({
                    /*backdrop: 'static',*/
                    //keyboard: true
                }, 'show');
                bindForm2(this);
            });
            return false;
        }
        else
        {
            window.location.href = x;
        }
    }

    $(document).ready(function () {
        $("#wizard-report").addClass('wizard-item-done');
    });

</script>
}

{'fraction_non_alphanumeric': 0.17373943000313186, 'fraction_numerical': 0.008612590040714062, 'mean_word_length': 1.7159260046778653, 'pattern_counts': {'":': 0, '<': 194, '<?xml version=': 0, '>': 198, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 15, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3305824', 'n_tokens_mistral': 3657, 'n_tokens_neox': 3484, 'n_words': 663}