Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
1feac858
authored
Oct 15, 2013
by
Kálmán Viktor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: jquery slider fix for vm create
parent
e78300a6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
24 deletions
+32
-24
circle/dashboard/static/dashboard/dashboard.js
+32
-24
No files found.
circle/dashboard/static/dashboard/dashboard.js
View file @
1feac858
...
@@ -21,9 +21,9 @@ $(function () {
...
@@ -21,9 +21,9 @@ $(function () {
'</div>' + */
'</div>' + */
'</div><!-- /.modal-content -->'
+
'</div><!-- /.modal-content -->'
+
'</div><!-- /.modal-dialog -->'
+
'</div><!-- /.modal-dialog -->'
+
'</div>
<!-- /.modal -->
'
;
'</div>'
;
$
(
'
.container
'
).
append
(
html
);
$
(
'
body
'
).
append
(
html
);
vmCreateLoaded
();
vmCreateLoaded
();
$
(
'#vm-create-modal'
).
modal
(
'show'
);
$
(
'#vm-create-modal'
).
modal
(
'show'
);
$
(
'#vm-create-modal'
).
on
(
'hidden.bs.modal'
,
function
()
{
$
(
'#vm-create-modal'
).
on
(
'hidden.bs.modal'
,
function
()
{
...
@@ -52,31 +52,16 @@ $(function () {
...
@@ -52,31 +52,16 @@ $(function () {
$
(
'[title]'
).
tooltip
();
$
(
'[title]'
).
tooltip
();
$
(
':input[title]'
).
tooltip
({
trigger
:
'focus'
,
placement
:
'auto right'
});
$
(
':input[title]'
).
tooltip
({
trigger
:
'focus'
,
placement
:
'auto right'
});
$
(
".knob"
).
knob
();
$
(
".knob"
).
knob
();
$
(
"[data-slider]"
)
.
each
(
function
()
{
if
(
window
.
location
.
hash
)
var
input
=
$
(
this
);
$
(
"a[href="
+
window
.
location
.
hash
+
"]"
).
tab
(
'show'
);
$
(
"<span>"
)
.
addClass
(
"output"
)
.
html
(
$
(
this
).
val
())
.
insertAfter
(
input
);
})
.
bind
(
"slider:ready slider:changed"
,
function
(
event
,
data
)
{
$
(
this
)
.
nextAll
(
".output:first"
)
.
html
(
data
.
value
.
toFixed
(
3
));
});
$
(
"[data-mark]"
)
.
each
(
function
()
{
var
value
=
$
(
this
).
attr
(
'data-mark'
).
parseFloat
();
});
if
(
window
.
location
.
hash
)
$
(
"a[href="
+
window
.
location
.
hash
+
"]"
).
tab
(
'show'
);
vmCreateLoaded
();
vmCreateLoaded
();
});
});
function
vmCreateLoaded
()
{
function
vmCreateLoaded
()
{
$
(
'.vm-create-advanced'
).
hide
();
// temporarily disable for testing
//$('.vm-create-advanced').hide();
$
(
'.vm-create-advanced-btn'
).
click
(
function
()
{
$
(
'.vm-create-advanced-btn'
).
click
(
function
()
{
$
(
'.vm-create-advanced'
).
stop
().
slideToggle
();
$
(
'.vm-create-advanced'
).
stop
().
slideToggle
();
if
(
$
(
'.vm-create-advanced-icon'
).
hasClass
(
'icon-caret-down'
))
{
if
(
$
(
'.vm-create-advanced-icon'
).
hasClass
(
'icon-caret-down'
))
{
...
@@ -85,5 +70,28 @@ function vmCreateLoaded() {
...
@@ -85,5 +70,28 @@ function vmCreateLoaded() {
$
(
'.vm-create-advanced-icon'
).
removeClass
(
'icon-caret-up'
).
addClass
(
'icon-caret-down'
);
$
(
'.vm-create-advanced-icon'
).
removeClass
(
'icon-caret-up'
).
addClass
(
'icon-caret-down'
);
}
}
});
});
}
$
(
"[data-slider]"
).
each
(
function
()
{
if
(
$
(
this
).
css
(
'display'
)
!=
"none"
)
$
(
this
).
simpleSlider
();
});
$
(
"[data-slider]"
)
.
each
(
function
()
{
var
input
=
$
(
this
);
$
(
"<span>"
)
.
addClass
(
"output"
)
.
html
(
$
(
this
).
val
())
.
insertAfter
(
input
);
})
.
bind
(
"slider:ready slider:changed"
,
function
(
event
,
data
)
{
$
(
this
)
.
nextAll
(
".output:first"
)
.
html
(
data
.
value
.
toFixed
(
3
));
});
$
(
"[data-mark]"
).
each
(
function
()
{
var
value
=
$
(
this
).
attr
(
'data-mark'
).
parseFloat
();
});
}
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