Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.toolbox
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Klaus Wölfel
slapos.toolbox
Commits
a6ca555e
Commit
a6ca555e
authored
Jul 18, 2014
by
Nicolas Wavrant
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
runner: fix bug in displaying logs when slapgrid is not running
in page /viewLog
parent
1650be7b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
slapos/runner/static/js/scripts/process.js
slapos/runner/static/js/scripts/process.js
+3
-3
slapos/runner/static/js/scripts/viewlog.js
slapos/runner/static/js/scripts/viewlog.js
+4
-4
No files found.
slapos/runner/static/js/scripts/process.js
View file @
a6ca555e
/*jslint undef: true */
/*jslint undef: true */
/*global $, window, $SCRIPT_ROOT, setRunningState, setCookie, getCookie, deleteCookie */
/*global $, window, $SCRIPT_ROOT, setRunningState, setCookie, getCookie, deleteCookie */
/*global currentState: true, running:
tru
e, $current: true, currentProcess: true, processTypes: true */
/*global currentState: true, running:
fals
e, $current: true, currentProcess: true, processTypes: true */
/*global sendStop: true, openedlogpage: true, logReadingPosition: true, speed: true */
/*global sendStop: true, openedlogpage: true, logReadingPosition: true, speed: true */
/*global isRunning: true */
/*global isRunning: true */
/* vim: set et sts=4: */
/* vim: set et sts=4: */
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
var
url
=
$SCRIPT_ROOT
+
"
/slapgridResult
"
;
var
url
=
$SCRIPT_ROOT
+
"
/slapgridResult
"
;
var
currentState
=
false
;
var
currentState
=
false
;
var
running
=
tru
e
;
var
running
=
fals
e
;
var
currentProcess
=
""
;
var
currentProcess
=
""
;
var
processTypes
=
{
instance
:
"
instance
"
,
software
:
"
software
"
};
var
processTypes
=
{
instance
:
"
instance
"
,
software
:
"
software
"
};
var
sendStop
=
false
;
var
sendStop
=
false
;
...
@@ -55,7 +55,7 @@ function writeLogs(data) {
...
@@ -55,7 +55,7 @@ function writeLogs(data) {
size
=
data
.
content
.
position
-
logReadingPosition
;
size
=
data
.
content
.
position
-
logReadingPosition
;
if
(
size
<
0
)
{
if
(
size
<
0
)
{
clearAll
();
clearAll
(
false
);
}
}
if
(
logReadingPosition
!==
0
&&
data
.
content
.
truncated
)
{
if
(
logReadingPosition
!==
0
&&
data
.
content
.
truncated
)
{
log_info
=
"
<p class='info' rel='0'>SLAPRUNNER INFO: SLAPGRID-LOG HAS BEEN TRUNCATED HERE. To see full log reload your log page</p>
"
;
log_info
=
"
<p class='info' rel='0'>SLAPRUNNER INFO: SLAPGRID-LOG HAS BEEN TRUNCATED HERE. To see full log reload your log page</p>
"
;
...
...
slapos/runner/static/js/scripts/viewlog.js
View file @
a6ca555e
/*jslint undef: true */
/*jslint undef: true */
/*global $, document, window,
processState,
getCookie, setCookie, setSpeed, $SCRIPT_ROOT */
/*global $, document, window, getCookie, setCookie, setSpeed, $SCRIPT_ROOT */
/*global openedlogpage: true */
/*global openedlogpage: true
, running: false
*/
/* vim: set et sts=4: */
/* vim: set et sts=4: */
$
(
document
).
ready
(
function
()
{
$
(
document
).
ready
(
function
()
{
...
@@ -53,7 +53,7 @@ $(document).ready(function () {
...
@@ -53,7 +53,7 @@ $(document).ready(function () {
}
}
function
updatelogBox
()
{
function
updatelogBox
()
{
if
(
processState
===
"
Stopped
"
||
processState
===
"
Checking
"
||
$
(
"
#manual
"
).
is
(
"
:checked
"
))
{
if
(
!
running
||
$
(
"
#manual
"
).
is
(
"
:checked
"
))
{
$
(
"
#salpgridLog
"
).
hide
();
$
(
"
#salpgridLog
"
).
hide
();
$
(
"
#manualLog
"
).
show
();
$
(
"
#manualLog
"
).
show
();
$
(
"
#slapstate
"
).
hide
();
$
(
"
#slapstate
"
).
hide
();
...
@@ -113,7 +113,7 @@ $(document).ready(function () {
...
@@ -113,7 +113,7 @@ $(document).ready(function () {
})
})
.
always
(
function
()
{
.
always
(
function
()
{
sending
=
false
;
sending
=
false
;
if
(
processState
===
"
Stopped
"
||
processState
===
"
Checking
"
||
$
(
"
#manual
"
).
is
(
"
:checked
"
))
{
if
(
!
running
||
$
(
"
#manual
"
).
is
(
"
:checked
"
))
{
$
(
"
#logheader
"
).
html
(
info
);
$
(
"
#logheader
"
).
html
(
info
);
}
else
{
}
else
{
$
(
"
#logheader
"
).
html
(
"
Inspecting slapgrid log - Click for more options
"
);
$
(
"
#logheader
"
).
html
(
"
Inspecting slapgrid log - Click for more options
"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment