Managed empty data case in check page.
This commit is contained in:
parent
f5ffce2fbf
commit
843b8b1d46
2 changed files with 50 additions and 35 deletions
|
@ -107,7 +107,14 @@ public class PropertyFileCheckPage
|
||||||
//
|
//
|
||||||
data.setContent("statsTitle", title);
|
data.setContent("statsTitle", title);
|
||||||
|
|
||||||
|
//
|
||||||
int index = 0;
|
int index = 0;
|
||||||
|
if (checks.isEmpty())
|
||||||
|
{
|
||||||
|
data.setAttribute("fullBlockTable", "class", "xid:nodisplay");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
for (PropertyCheck check : checks)
|
for (PropertyCheck check : checks)
|
||||||
{
|
{
|
||||||
//
|
//
|
||||||
|
@ -118,9 +125,18 @@ public class PropertyFileCheckPage
|
||||||
|
|
||||||
index += 1;
|
index += 1;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
index = 0;
|
index = 0;
|
||||||
for (PropertyCheck check : checks.extractActiveLines())
|
PropertyChecks subchecks = checks.extractActiveLines();
|
||||||
|
if (subchecks.isEmpty())
|
||||||
|
{
|
||||||
|
data.setAttribute("shrunkBlockTable", "class", "xid:nodisplay");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
for (PropertyCheck check : subchecks)
|
||||||
{
|
{
|
||||||
//
|
//
|
||||||
data.setContent("shrunkLine", index, "shrunkLineIndex", check.getIndex());
|
data.setContent("shrunkLine", index, "shrunkLineIndex", check.getIndex());
|
||||||
|
@ -130,9 +146,18 @@ public class PropertyFileCheckPage
|
||||||
|
|
||||||
index += 1;
|
index += 1;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//
|
||||||
index = 0;
|
index = 0;
|
||||||
for (PropertyCheck check : checks.extractAlertLines())
|
subchecks = checks.extractAlertLines();
|
||||||
|
if (subchecks.isEmpty())
|
||||||
|
{
|
||||||
|
data.setAttribute("alertBlockTable", "class", "xid:nodisplay");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
for (PropertyCheck check : subchecks)
|
||||||
{
|
{
|
||||||
//
|
//
|
||||||
data.setContent("alertLine", index, "alertLineIndex", check.getIndex());
|
data.setContent("alertLine", index, "alertLineIndex", check.getIndex());
|
||||||
|
@ -142,6 +167,7 @@ public class PropertyFileCheckPage
|
||||||
|
|
||||||
index += 1;
|
index += 1;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
String content = PresenterUtils.dynamize("/fr/devinsy/statoolinfos/htmlize/propertyFileCheck.xhtml", data).toString();
|
String content = PresenterUtils.dynamize("/fr/devinsy/statoolinfos/htmlize/propertyFileCheck.xhtml", data).toString();
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
<span id="voidCount" class="bg_void" style="padding: 0 10px;" title="Inconnus">n/a</span>
|
<span id="voidCount" class="bg_void" style="padding: 0 10px;" title="Inconnus">n/a</span>
|
||||||
</div>
|
</div>
|
||||||
<div id="fullBlock" style="width: 100%;">
|
<div id="fullBlock" style="width: 100%;">
|
||||||
<table class="table_simple">
|
<table id="fullBlockTable" class="table_simple">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr id="line">
|
<tr id="line">
|
||||||
<td id="lineIndex" style="width: 30px; text-align: right; padding-right: 5px;">000</td>
|
<td id="lineIndex" style="width: 30px; text-align: right; padding-right: 5px;">000</td>
|
||||||
|
@ -38,7 +38,7 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
<div id="shrunkBlock" style="width: 100%; display: none;">
|
<div id="shrunkBlock" style="width: 100%; display: none;">
|
||||||
<table class="table_simple">
|
<table id="shrunkBlockTable" class="table_simple">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr id="shrunkLine">
|
<tr id="shrunkLine">
|
||||||
<td id="shrunkLineIndex" style="width: 30px; text-align: right; right; padding-right: 5px;">000</td>
|
<td id="shrunkLineIndex" style="width: 30px; text-align: right; right; padding-right: 5px;">000</td>
|
||||||
|
@ -49,7 +49,7 @@
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
<div id="alertBlock" style="width: 100%; display: none;">
|
<div id="alertBlock" style="width: 100%; display: none;">
|
||||||
<table class="table_simple">
|
<table id="alertBlockTable" class="table_simple">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr id="alertLine">
|
<tr id="alertLine">
|
||||||
<td id="alertLineIndex" style="width: 30px; text-align: right; right; padding-right: 5px;">000</td>
|
<td id="alertLineIndex" style="width: 30px; text-align: right; right; padding-right: 5px;">000</td>
|
||||||
|
@ -59,17 +59,6 @@
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
<div id="alertBlock" style="width: 100%; display: none;">
|
|
||||||
<table class="table_simple">
|
|
||||||
<tbody>
|
|
||||||
<tr id="alertLine">
|
|
||||||
<td id="alertLineIndex" style="width: 30px; text-align: right;">000</td>
|
|
||||||
<td id="alertLineContent" style="padding-left: 10px;">n/a</td>
|
|
||||||
<td id="alertLineComment" style="width: 200px; padding-left: 10px;">n/a</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
Loading…
Reference in a new issue