Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F94040090
webaccount_display.html
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Dec 3, 10:46
Size
3 KB
Mime Type
text/html
Expires
Thu, Dec 5, 10:46 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22719882
Attached To
R3600 invenio-infoscience
webaccount_display.html
View Options
{#
## This file is part of Invenio.
## Copyright (C) 2012 CERN.
##
## Invenio is free software; you can redistribute it and/or
## modify it under the terms of the GNU General Public License as
## published by the Free Software Foundation; either version 2 of the
## License, or (at your option) any later version.
##
## Invenio is distributed in the hope that it will be useful, but
## WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
## General Public License for more details.
##
## You should have received a copy of the GNU General Public License
## along with Invenio; if not, write to the Free Software Foundation, Inc.,
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
#}
{% from "_formhelpers.html" import render_field with context %}
{% extends "page.html" %}
{% set title = _('Your Account') %}
{% block title %}
<div
class=
"page-header"
>
<h1>
{{ title }}
<small
class=
"clearfix"
>
<div
class=
"pull-right"
>
<input
placeholder=
"{{ _('Filter widgets') }}"
type=
"text"
name=
"widget"
autofocus
/>
</div>
</small>
</h1>
</div>
{% endblock %}
{% block header %}
{{ super() }}
{% css "js/redmond/jquery-ui-1.8.17.custom.css" %}
{% js "js/jquery-ui.min.js" %}
{#
{% js "js/jquery-ui-timepicker-addon.js" %}
#}
{% endblock header %}
{% block body %}
<div
class=
"container"
>
<div
class=
"row"
>
<div
class=
"span12"
>
<ul
id=
"widgets"
class=
"thumbnails"
>
{%- for p in plugins if p.widget -%}
<li
id=
"{{ p.__class__.__name__}}"
class=
"widget span{{ p.widget.size }}"
>
<div
class=
"thumbnail"
>
<div
class=
"caption"
>
<h4>
{%- if p.icon -%}
<small><i
style=
"margin-top: 0px;"
class=
"icon-{{ p.icon|safe }}"
></i>
</small>
{%- endif -%}
{%- if p.view -%}
<a
class=
""
href=
"{{ p.view|safe }}"
>
{{ p.title|safe }}
</a>
{%- else -%}
{{ p.title|safe }}
{%- endif -%}
<small>
{%- if p.edit -%}
<a
class=
"edit"
href=
"{{ p.edit|safe }}"
><i
class=
"icon-wrench"
></i></a>
{%- endif -%}
<button
type=
"button"
class=
"close"
>
×
</button>
</small>
</h4>
<div
style=
"
overflow: hidden;
width: 90%;
height: 80px;
text-overflow: ellipsis;"
>
{{ p.widget()|safe }}
</div>
</div>
</div>
</li>
{%- endfor -%}
</ul>
</div>
</div>
</div>
<script>
$
(
function
()
{
$
(
'input[name=widget]'
).
keyup
(
function
(
e
)
{
var
filter
=
$
(
this
).
val
()
if
(
filter
.
length
>
0
&&
e
.
keyCode
===
13
)
{
var
l
=
$
(
'#widgets li:visible'
).
find
(
'a.edit'
).
first
().
attr
(
'href'
)
if
(
l
.
length
>
0
)
{
window
.
location
.
href
=
l
}
return
false
}
$
(
'#widgets li'
).
each
(
function
(
i
,
li
)
{
if
(
$
(
li
).
find
(
'.caption'
).
text
().
indexOf
(
filter
)
>
-
1
||
filter
==
''
)
{
$
(
this
).
show
()
}
else
{
$
(
this
).
hide
()
}
})
})
$
(
"#widgets li"
).
each
(
function
()
{
var
$
e
=
$
(
this
)
$
e
.
find
(
'.close'
).
on
(
'click'
,
function
()
{
$
e
.
hide
()
})
})
$
(
"#widgets"
).
sortable
({
update
:
function
(
event
,
ui
)
{
var
newOrder
=
$
(
this
).
sortable
(
'toArray'
);
$
.
ajax
({
url
:
'{{ url_for('
youraccount
.
edit
', name='
dashboard_user_settings
') }}'
,
type
:
'POST'
,
data
:
$
.
param
({
order
:
newOrder
},
true
)
});
}
});
$
(
"#widgets"
).
disableSelection
();
});
</script>
<style>
#widgets
li
.thumbnail
{
background
:
white
;
}
#widgets
li
.ui-sortable-placeholder
{
background
:
#CCC
;
height
:
120px
;
display
:
block
;
float
:
left
;
visibility
:
visible
!important
;
}
</style>
{% endblock %}
Event Timeline
Log In to Comment