show long error message in selftest admin panel
This commit is contained in:
@@ -115,6 +115,10 @@ body {
|
||||
height: 0 !important;
|
||||
}
|
||||
|
||||
.generic_nodisplay {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.boxedcontent {
|
||||
color: #333333;
|
||||
border: 1px solid #444444;
|
||||
@@ -853,12 +857,32 @@ html, body {
|
||||
min-width: 300px;
|
||||
}
|
||||
|
||||
.selftest_parent {
|
||||
width: 800px;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.selftest_outputchild {
|
||||
border: 1px solid #888;
|
||||
background: #F8F8F8;
|
||||
color: #000000;
|
||||
font-family: Consolas, Monaco, "Courier New", Menlo, monospace;
|
||||
white-space: pre;
|
||||
max-height: 600px;
|
||||
overflow-x: auto;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.consistency_result_fin {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.consistency_result {
|
||||
width: 500px;
|
||||
color: #222222;
|
||||
border: 1px solid #888;
|
||||
padding: 0 5px;
|
||||
margin: 1px 0;
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
.consistency_result:after {
|
||||
|
||||
6
www/data/css/styles.min.css
vendored
6
www/data/css/styles.min.css
vendored
@@ -18,6 +18,7 @@
|
||||
.blockcontent{display:block;width:100%}
|
||||
.generic_hidden{visibility:hidden !important}
|
||||
.generic_collapsed{visibility:collapse !important;display:none !important;width:0 !important;height:0 !important}
|
||||
.generic_nodisplay{display:none !important}
|
||||
.boxedcontent{color:#333;border:1px solid #444;background:#e0e0e0;width:100%;margin-left:auto;margin-right:auto}
|
||||
.boxedcontent .bc_header{background-color:#bbb;color:#222;padding:0 4px}
|
||||
.boxedcontent .bc_data{padding:8px}
|
||||
@@ -167,7 +168,10 @@ html,body{margin:0;padding:0;height:100%}
|
||||
.kvl_100 div span:first-child{min-width:100px}
|
||||
.kvl_200 div span:first-child{min-width:200px}
|
||||
.kvl_300 div span:first-child{min-width:300px}
|
||||
.consistency_result{width:500px;color:#222;border:1px solid #888;padding:0 5px;margin:1px 0}
|
||||
.selftest_parent{width:800px;max-width:100%}
|
||||
.selftest_outputchild{border:1px solid #888;background:#f8f8f8;color:#000;font-family:Consolas,Monaco,"Courier New",Menlo,monospace;white-space:pre;max-height:600px;overflow-x:auto;overflow-y:auto}
|
||||
.consistency_result_fin{cursor:pointer}
|
||||
.consistency_result{color:#222;border:1px solid #888;padding:0 5px;margin:1px 0;flex-grow:1}
|
||||
.consistency_result:after{content:" "}
|
||||
.consistency_result_ok{background:#0f0}
|
||||
.consistency_result_warn{background:#ff0}
|
||||
|
||||
@@ -41,12 +41,32 @@
|
||||
.kvl_200 div span:first-child { min-width: 200px; }
|
||||
.kvl_300 div span:first-child { min-width: 300px; }
|
||||
|
||||
.selftest_parent {
|
||||
width: 800px;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.selftest_outputchild {
|
||||
border: $COL_ADMIN_STATUS_BORDER;
|
||||
background: $LAYER2_CODE_BG;
|
||||
color: $LAYER2_CODE_FG;
|
||||
font-family: $FONT_CODE;
|
||||
white-space: pre;
|
||||
max-height: 600px;
|
||||
overflow-x: auto;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.consistency_result_fin {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.consistency_result {
|
||||
width: 500px;
|
||||
color: $COL_ADMIN_STATUS_FG;
|
||||
border: $COL_ADMIN_STATUS_BORDER;
|
||||
padding: 0 5px;
|
||||
margin: 1px 0;
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
.consistency_result:after { content: '\00a0' }
|
||||
|
||||
@@ -85,6 +85,10 @@ body {
|
||||
height:0 !important;
|
||||
}
|
||||
|
||||
.generic_nodisplay {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.boxedcontent {
|
||||
color: $LAYER1_FG;
|
||||
border: $LAYER1_BORDER;
|
||||
|
||||
@@ -71,14 +71,31 @@ function startAjaxReplace(target, url)
|
||||
});
|
||||
}
|
||||
|
||||
function showSelfTestOutput(id1, id2)
|
||||
{
|
||||
if (!$(id1).hasClass('consistency_result_fin')) return;
|
||||
|
||||
if ($(id2).hasClass('generic_nodisplay'))
|
||||
{
|
||||
$('.selftest_outputchild').addClass('generic_nodisplay');
|
||||
$(id2).removeClass('generic_nodisplay');
|
||||
}
|
||||
else
|
||||
{
|
||||
$('.selftest_outputchild').addClass('generic_nodisplay');
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function refreshConsistencyDisplaySequential(skip)
|
||||
{
|
||||
let i = 0;
|
||||
for (let apibutton of $('.consistence_ajax_handler').toArray())
|
||||
for (let apibutton of $('.selftest_sequential .consistence_ajax_handler').toArray())
|
||||
{
|
||||
if (i++ !== skip) continue;
|
||||
|
||||
const filter = $(apibutton).data('filter');
|
||||
const outdiv = $($(apibutton).data('stid'));
|
||||
|
||||
$(apibutton).removeClass('consistency_result_intermed');
|
||||
$(apibutton).addClass('consistency_result_running');
|
||||
@@ -89,15 +106,17 @@ function refreshConsistencyDisplaySequential(skip)
|
||||
let json = JSON.parse(data);
|
||||
$(apibutton).removeClass('consistency_result_intermed');
|
||||
$(apibutton).removeClass('consistency_result_running');
|
||||
$(apibutton).addClass('consistency_result_fin');
|
||||
|
||||
if (json.result === 0) $(apibutton).addClass('consistency_result_ok');
|
||||
if (json.result === 1) $(apibutton).addClass('consistency_result_warn');
|
||||
if (json.result === 2) $(apibutton).addClass('consistency_result_err');
|
||||
|
||||
$(apibutton).text(json.message);
|
||||
$(apibutton).attr('title', json.long);
|
||||
//$(apibutton).attr('title', json.long);
|
||||
outdiv.text(json.long);
|
||||
|
||||
setTimeout(() => refreshConsistencyDisplay(skip+1), 10);
|
||||
setTimeout(() => refreshConsistencyDisplaySequential(skip+1), 10);
|
||||
})
|
||||
.fail((xhr, status, err) =>
|
||||
{
|
||||
@@ -105,17 +124,21 @@ function refreshConsistencyDisplaySequential(skip)
|
||||
$(apibutton).removeClass('consistency_result_running');
|
||||
|
||||
$(apibutton).addClass('consistency_result_err');
|
||||
$(apibutton).text(err);
|
||||
$(apibutton).addClass('consistency_result_fin');
|
||||
$(apibutton).text(("" + err).substr(0, 48));
|
||||
|
||||
setTimeout(() => refreshConsistencyDisplay(skip+1), 10);
|
||||
//$(apibutton).attr('title', json.long);
|
||||
outdiv.text(err);
|
||||
|
||||
setTimeout(() => refreshConsistencyDisplaySequential(skip+1), 10);
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
function refreshConsistencyDisplayParallel(skip)
|
||||
function refreshConsistencyDisplayParallel()
|
||||
{
|
||||
for (let apibutton of $('.consistence_ajax_handler').toArray())
|
||||
for (let apibutton of $('.selftest_parallel .consistence_ajax_handler').toArray())
|
||||
{
|
||||
const filter = $(apibutton).data('filter');
|
||||
|
||||
@@ -149,6 +172,6 @@ function refreshConsistencyDisplayParallel(skip)
|
||||
|
||||
$(function()
|
||||
{
|
||||
//setTimeout(() => refreshConsistencyDisplaySequential(0), 200);
|
||||
setTimeout(() => refreshConsistencyDisplayParallel(), 200);
|
||||
for (let apibutton of $('.selftest_sequential').toArray()) setTimeout(() => refreshConsistencyDisplaySequential(0), 200);
|
||||
for (let apibutton of $('.selftest_parallel').toArray()) setTimeout(() => refreshConsistencyDisplayParallel(), 200);
|
||||
});
|
||||
Reference in New Issue
Block a user