99 lines
4.6 KiB
Plaintext
99 lines
4.6 KiB
Plaintext
@model LaaProductionWeb.Services.Models.Reports.KottmannReportModel
|
|
|
|
@using LaaProductionWeb.Services.Models.Reports
|
|
|
|
<form action="~/Report/Kottmann" method="post" autocomplete="off" class="h-100" id="kot_report">
|
|
<div class="table-responsive h-100 mh-100">
|
|
<table class="table table-sm table-bordered mb-0">
|
|
<thead class="bg-light">
|
|
<tr>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.FertigungsNr)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.SerialNr)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.PcbId)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.Typ)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.Nennweite)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.Baulaenge)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.StartDruck)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.EndDruck)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.DruckZeit)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.Dicht)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.Datum)</th>
|
|
<th class="text-nowrap p-2">@this.Model.Display(x => x.Bemerkung)</th>
|
|
</tr>
|
|
<tr>
|
|
@foreach (var filter in this.Model.Filter)
|
|
{
|
|
if (filter.Type == PropertyType.Date)
|
|
{
|
|
<td>@this.Html.Partial("DateFilter", filter)</td>
|
|
}
|
|
else
|
|
{
|
|
<td>@this.Html.Partial("Filter", filter)</td>
|
|
}
|
|
}
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach (var item in this.Model.Items)
|
|
{
|
|
<tr>
|
|
<td class="text-nowrap p-2">@item.FertigungsNr</td>
|
|
<td class="text-nowrap p-2">@item.SerialNr</td>
|
|
<td class="text-nowrap p-2">@item.PcbId</td>
|
|
<td class="text-nowrap p-2">@item.Typ</td>
|
|
<td class="text-nowrap p-2">@item.Nennweite</td>
|
|
<td class="text-nowrap p-2">@item.Baulaenge</td>
|
|
<td class="text-nowrap p-2">@item.StartDruck</td>
|
|
<td class="text-nowrap p-2">@item.EndDruck</td>
|
|
<td class="text-nowrap p-2">@item.DruckZeit</td>
|
|
<td class="text-nowrap p-2"><i class="bi bi-bold @(item.Dicht ? "bi-check text-success" : "bi-x text-danger")"></i></td>
|
|
<td class="text-nowrap p-2">@($"{item.Datum:dd.MM.yyyy}")</td>
|
|
<td class="text-nowrap p-2">@item.Bemerkung</td>
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</form>
|
|
|
|
<form action="~/Report/KottmannCSV" method="post" autocomplete="off" class="position-fixed bottom-0 end-0 m-2">
|
|
@foreach (var filter in this.Model.Filter)
|
|
{
|
|
this.Html.Partial("HiddenFilter", filter);
|
|
}
|
|
<button class="btn btn-light border-success" type="submit">
|
|
<i class="bi bi-filetype-csv text-success"></i>
|
|
</button>
|
|
</form>
|
|
|
|
@section scripts {
|
|
<script>
|
|
let form = document.getElementById('kot_report');
|
|
let inputFields = form
|
|
.querySelectorAll('input')
|
|
.forEach(x => x.onchange = () => form.submit());
|
|
|
|
@*let tbody = this.document.getElementById('tbody');
|
|
let modal = this.document.getElementById('modal');
|
|
let modalBtn = this.document.getElementById('modal_btn');
|
|
|
|
modal.addEventListener('hide.bs.modal', x => this.location.hash = '');
|
|
|
|
window.addEventListener('hashchange', function () {
|
|
tbody.innerHTML = null;
|
|
if (location.hash) {
|
|
let testId = location.hash.substring(1);
|
|
if (testId) {
|
|
fetch(`@this.Url.Action("HeliumResults", "Report")?testId=${testId}`)
|
|
.then(response => response.text())
|
|
.then(function (html) {
|
|
tbody.innerHTML = html;
|
|
modalBtn.click();
|
|
})
|
|
.catch(x => console.log(x));
|
|
}
|
|
}
|
|
});*@
|
|
</script>
|
|
} |