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
Tristan Cavelier
slapos.toolbox
Commits
58044d23
Commit
58044d23
authored
Oct 28, 2013
by
Alain Takoudjou
Committed by
Nicolas Wavrant
Feb 14, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update popup box to display more than one msg at a time
parent
c9634348
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
51 additions
and
53 deletions
+51
-53
slapos/runner/static/css/styles.css
slapos/runner/static/css/styles.css
+18
-13
slapos/runner/static/js/jquery/popupBox.js
slapos/runner/static/js/jquery/popupBox.js
+30
-37
slapos/runner/static/js/scripts/softwareFolder.js
slapos/runner/static/js/scripts/softwareFolder.js
+2
-2
slapos/runner/templates/layout.html
slapos/runner/templates/layout.html
+1
-1
No files found.
slapos/runner/static/css/styles.css
View file @
58044d23
...
@@ -683,22 +683,25 @@ a.lshare img{
...
@@ -683,22 +683,25 @@ a.lshare img{
#error
{
#error
{
padding
:
0px
;
padding
:
0px
;
position
:
absolute
;
position
:
absolute
;
top
:
-2
px
;
top
:
0
px
;
left
:
0
;
left
:
0
;
right
:
0
;
right
:
70px
;
}
}
#error
>
div
{
#error
div
{
background
:
none
repeat
scroll
0
0
#afcee4
;
background
:
none
repeat
scroll
0
0
#FFC8F4
;
border
:
1px
solid
#FFF
;
border
:
1px
solid
#A70073
;
width
:
500px
;
padding
:
5px
;
margin
:
0
auto
;
margin
:
5px
0
;
border-top
:
none
;
min-width
:
300px
;
border-radius
:
0
0
4px
4px
;
max-width
:
500px
;
float
:
right
;
border-radius
:
4px
;
box-shadow
:
0
2px
4px
rgba
(
0
,
0
,
0
,
0.2
);
box-shadow
:
0
2px
4px
rgba
(
0
,
0
,
0
,
0.2
);
text-align
:
center
;
text-align
:
left
;
position
:
relative
;
position
:
relative
;
z-index
:
170
;
z-index
:
170
;
clear
:
both
;
}
}
#error
table
{
#error
table
{
...
@@ -723,7 +726,7 @@ a.lshare img{
...
@@ -723,7 +726,7 @@ a.lshare img{
width
:
30px
;
width
:
30px
;
height
:
22px
;
height
:
22px
;
}
}
#error
p
{
white-space
:
pre-wrap
;
word-wrap
:
break-word
;
width
:
430px
;
padding-bottom
:
5px
;}
#error
p
{
white-space
:
pre-wrap
;
word-wrap
:
break-word
;
width
:
95%
;
padding-bottom
:
5px
;}
.noscroll
{
.noscroll
{
overflow
:
hidden
;
overflow
:
hidden
;
}
}
...
@@ -735,13 +738,15 @@ a.lshare img{
...
@@ -735,13 +738,15 @@ a.lshare img{
.list
{
display
:
block
;
padding
:
5px
;
background
:
#E7E7E7
;
margin-bottom
:
7px
;}
.list
{
display
:
block
;
padding
:
5px
;
background
:
#E7E7E7
;
margin-bottom
:
7px
;}
div
.sep
{
display
:
block
;
height
:
7px
;}
div
.sep
{
display
:
block
;
height
:
7px
;}
.slidebox
{
padding
:
10px
;
}
.slidebox
{
padding
:
10px
;
}
.alert_message
{
background
:
url(../images/alert.png)
center
no-repeat
;
height
:
26px
;}
.alert_message
{
background
:
url(../images/alert.png)
center
no-repeat
;
height
:
26px
;}
.error_message
{
background
:
url(../images/exit.png)
center
no-repeat
;
height
:
26px
;}
.error_message
{
background
:
url(../images/exit.png)
center
no-repeat
;
height
:
26px
;}
.confirm_message
{
background
:
url(../images/confirm.png)
center
no-repeat
;
height
:
26px
;}
.confirm_message
{
background
:
url(../images/confirm.png)
center
no-repeat
;
height
:
26px
;}
.info_message
{
background
:
url(../images/info.png)
center
no-repeat
;
height
:
26px
;}
.info_message
{
background
:
url(../images/info.png)
center
no-repeat
;
height
:
26px
;}
#error
p
{
font-size
:
13px
;
color
:
#4A131F
;}
#error
p
{
font-size
:
13px
;
color
:
#4A131F
;}
#pClose
,
.close
{
background
:
url(../images/close.png)
no-repeat
0px
0px
;
display
:
block
;
width
:
22px
;
height
:
22px
;
cursor
:
pointer
}
.pClose
,
.close
{
background
:
url(../images/close.png)
no-repeat
0px
0px
;
display
:
block
;
width
:
22px
;
height
:
22px
;
cursor
:
pointer
}
#pClose
:hover
,
.close
:hover
{
background
:
url(../images/close_hover.png)
no-repeat
0px
0px
;}
.pClose
:hover
,
.close
:hover
{
background
:
url(../images/close_hover.png)
no-repeat
0px
0px
;}
.md5sum
{
margin
:
10px
;
font-size
:
15px
;}
.md5sum
{
margin
:
10px
;
font-size
:
15px
;}
.title
{
background
:
#e4e4e4
;
width
:
100%
;
height
:
26px
;
padding-top
:
2px
;
text-indent
:
5px
;
color
:
#737373
;
text-shadow
:
0px
1px
#FFF
;}
.title
{
background
:
#e4e4e4
;
width
:
100%
;
height
:
26px
;
padding-top
:
2px
;
text-indent
:
5px
;
color
:
#737373
;
text-shadow
:
0px
1px
#FFF
;}
.menu-box-left
{
float
:
left
;
width
:
135px
;
font-size
:
14px
;
background
:
#e4e4e4
;
padding
:
5px
0
5px
5px
;
margin-top
:
10px
;
.menu-box-left
{
float
:
left
;
width
:
135px
;
font-size
:
14px
;
background
:
#e4e4e4
;
padding
:
5px
0
5px
5px
;
margin-top
:
10px
;
...
...
slapos/runner/static/js/jquery/popup.js
→
slapos/runner/static/js/jquery/popup
Box
.js
View file @
58044d23
/*jslint undef: true */
/*global $, window, document */
/* vim: set et sts=4: */
// jQuery Message Popup
// jQuery Message Popup
// Display a message on the top of page, with floating
// Display a message on the top of page, with floating
//
//
(
function
(
$
,
document
,
window
)
{
(
function
(
$
,
document
,
window
)
{
var
isShow
=
null
;
var
isShow
=
null
,
var
showDelayTimer
=
null
;
top
=
0
,
boxCount
=
0
,
showDelayTimer
=
null
;
$
.
extend
(
$
.
fn
,
{
$
.
extend
(
$
.
fn
,
{
Popup
:
function
(
msg
,
option
)
{
Popup
:
function
(
msg
,
option
)
{
var
h
;
var
h
,
$box
=
$
(
this
),
currentBox
=
'
bcontent
'
+
boxCount
;
if
(
option
.
type
===
undefined
)
option
.
type
=
"
info
"
;
if
(
option
.
type
===
undefined
)
option
.
type
=
"
info
"
;
if
(
option
.
closebtn
===
undefined
)
option
.
closebtn
=
false
;
if
(
option
.
closebtn
===
undefined
)
option
.
closebtn
=
false
;
if
(
option
.
duration
===
undefined
)
option
.
duration
=
0
;
if
(
option
.
duration
===
undefined
)
option
.
duration
=
0
;
if
(
option
.
load
===
undefined
)
option
.
load
=
false
;
if
(
option
.
load
===
undefined
)
option
.
load
=
false
;
var
$box
=
$
(
this
);
if
(
showDelayTimer
){
clearTimeout
(
showDelayTimer
);}
setupBox
();
if
(
isShow
){
$box
.
fadeOut
(
'
normal
'
,
function
()
{
setupBox
();
});
}
else
{
setupBox
();}
function
setupBox
(){
function
setupBox
(){
if
(
msg
===
undefined
){
if
(
msg
===
undefined
){
msg
=
"
Cannot execute your request. Please make sure you are logged in!!
"
;
msg
=
"
Cannot execute your request. Please make sure you are logged in!!
"
;
option
.
type
=
"
error
"
;
option
.
type
=
"
error
"
;
}
}
$box
.
empty
();
$box
.
css
(
'
top
'
,
'
-1000px
'
);
$box
.
show
();
$box
.
show
();
$box
.
append
(
'
<div><table id="bcontent"><tr>
'
+
$box
.
css
(
'
top
'
,
+
(
$
(
window
).
scrollTop
())
+
'
px
'
);
$box
.
append
(
'
<div id="
'
+
currentBox
+
'
" style="display:none"><table><tr>
'
+
'
<td valign="middle" class="logo
'
+
option
.
type
+
'
_message"></td>
'
+
'
<td valign="middle" class="logo
'
+
option
.
type
+
'
_message"></td>
'
+
'
<td valign="middle"><p>
'
+
msg
+
'
</p></td>
'
+
'
<td valign="middle"><p>
'
+
msg
+
'
</p></td>
'
+
'
<td valign="middle" class="b_close"><span id="pClose"></span></td></tr></table></div>
'
);
'
<td valign="middle" class="b_close"><span id="pClose
'
+
boxCount
+
'
" class="pClose"></span></td></tr></table></div>
'
);
$
(
"
#pClose
"
+
boxCount
).
bind
(
"
click
"
,
function
()
{
close
(
$
(
"
#
"
+
currentBox
));
});
$
(
"
#
"
+
currentBox
).
fadeIn
();
boxCount
++
;
$
(
window
).
scroll
(
function
(){
$
(
window
).
scroll
(
function
(){
$box
.
animate
({
top
:
$
(
window
).
scrollTop
()
+
"
px
"
},{
queue
:
false
,
duration
:
350
});
$box
.
animate
({
top
:
$
(
window
).
scrollTop
()
+
"
px
"
},{
queue
:
false
,
duration
:
350
});
});
});
h
=
$
(
"
#bcontent
"
).
height
()
+
5
;
$
(
"
#pClose
"
).
bind
(
"
click
"
,
function
()
{
close
();
});
showBox
();
if
(
option
.
duration
!==
0
){
if
(
option
.
duration
!==
0
){
showDelayTimer
=
setTimeout
(
function
(){
showDelayTimer
=
setTimeout
(
function
(){
showDelayTimer
=
null
;
showDelayTimer
=
null
;
close
();
close
(
$
(
"
#
"
+
currentBox
)
);
},
option
.
duration
);
},
option
.
duration
);
}
}
}
function
showBox
(){
if
(
option
.
load
){
if
(
option
.
load
){
$
(
window
).
load
(
function
(){
$
(
window
).
load
(
function
(){
$box
.
css
(
'
top
'
,
+
(
$
(
window
).
scrollTop
()
-
h
)
+
'
px
'
);
$box
.
animate
({
top
:
"
+=
"
+
h
+
"
px
"
},
"
slow
"
);
isShow
=
true
;
});
});
}
}
else
{
$box
.
css
(
'
top
'
,
+
(
$
(
window
).
scrollTop
()
-
h
)
+
'
px
'
);
$box
.
animate
({
top
:
"
+=
"
+
h
+
"
px
"
},
"
slow
"
);
isShow
=
true
;
}
}
}
function
close
(){
function
close
(
$elt
){
$box
.
animate
({
top
:
"
-=
"
+
h
+
"
px
"
},
"
slow
"
,
function
(){
$elt
.
unbind
(
'
click
'
);
$box
.
fadeOut
(
"
normal
"
,
function
()
{
$elt
.
fadeOut
();
isShow
=
false
;
$elt
.
remove
();
});
});
}
}
}
}
});
});
...
...
slapos/runner/static/js/scripts/softwareFolder.js
View file @
58044d23
...
@@ -55,9 +55,9 @@ $(document).ready(function () {
...
@@ -55,9 +55,9 @@ $(document).ready(function () {
if
(
data
.
code
===
1
)
{
if
(
data
.
code
===
1
)
{
$
(
"
#edit_info
"
).
empty
();
$
(
"
#edit_info
"
).
empty
();
name
=
file
.
split
(
'
/
'
);
name
=
file
.
split
(
'
/
'
);
if
(
file
.
length
>
80
)
{
if
(
file
.
length
>
75
)
{
//substring title.
//substring title.
start
=
file
.
length
-
80
;
start
=
file
.
length
-
75
;
path
=
"
...
"
+
file
.
substring
(
file
.
indexOf
(
"
/
"
,
(
start
+
1
)));
path
=
"
...
"
+
file
.
substring
(
file
.
indexOf
(
"
/
"
,
(
start
+
1
)));
}
}
$
(
"
#edit_info
"
).
append
(
"
"
+
path
);
$
(
"
#edit_info
"
).
append
(
"
"
+
path
);
...
...
slapos/runner/templates/layout.html
View file @
58044d23
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
<script
src=
"{{ url_for('static', filename='js/jquery/jquery-1.10.2.min.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jquery-1.10.2.min.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jquery-ui-1.10.3.custom.min.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jquery-ui-1.10.3.custom.min.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jquery.form.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jquery.form.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/popup.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/popup
Box
.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jqueryToolTip.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/jqueryToolTip.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/superfish.min.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/superfish.min.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/hoverIntent.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
<script
src=
"{{ url_for('static', filename='js/jquery/hoverIntent.js') }}"
type=
"text/javascript"
charset=
"utf-8"
></script>
...
...
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