Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
J
jumpserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
jumpserver
Commits
25ebb5c4
Commit
25ebb5c4
authored
Mar 06, 2018
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Update] 修改一些bug
parent
bc230e0e
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
36 additions
and
10 deletions
+36
-10
settings.py
apps/jumpserver/settings.py
+1
-1
jumpserver.css
apps/static/css/jumpserver.css
+6
-0
logo-text.png
apps/static/img/logo-text.png
+0
-0
_header_bar.html
apps/templates/_header_bar.html
+1
-2
_user_profile.html
apps/templates/_user_profile.html
+1
-1
tasks.py
apps/terminal/tasks.py
+12
-6
session_list.html
apps/terminal/templates/terminal/session_list.html
+15
-0
No files found.
apps/jumpserver/settings.py
View file @
25ebb5c4
...
...
@@ -397,6 +397,6 @@ BOOTSTRAP3 = {
}
TOKEN_EXPIRATION
=
CONFIG
.
TOKEN_EXPIRATION
or
3600
DISPLAY_PER_PAGE
=
CONFIG
.
DISPLAY_PER_PAGE
DISPLAY_PER_PAGE
=
CONFIG
.
DISPLAY_PER_PAGE
or
25
DEFAULT_EXPIRED_YEARS
=
70
USER_GUIDE_URL
=
""
apps/static/css/jumpserver.css
View file @
25ebb5c4
...
...
@@ -427,3 +427,9 @@ div.dataTables_wrapper div.dataTables_filter {
text-align
:
center
;
padding
:
5px
0
;
}
.profile-dropdown
li
a
{
font-size
:
12px
!important
;
}
apps/static/img/logo-text.png
View replaced file @
bc230e0e
View file @
25ebb5c4
12.4 KB
|
W:
|
H:
17.7 KB
|
W:
|
H:
2-up
Swipe
Onion skin
apps/templates/_header_bar.html
View file @
25ebb5c4
...
...
@@ -33,9 +33,8 @@
</span>
</span>
</a>
<ul
class=
"dropdown-menu animated fadeInRight m-t-xs"
>
<ul
class=
"dropdown-menu animated fadeInRight m-t-xs
profile-dropdown
"
>
<li><a
href=
"{% url 'users:user-profile' %}"
><i
class=
"fa fa-cogs"
>
</i><span>
{% trans 'Profile' %}
</span></a></li>
<li
class=
"divider"
></li>
{% if request.user.is_superuser %}
{% if request.COOKIES.IN_ADMIN_PAGE == 'No' %}
<li><a
id=
"switch_admin"
><i
class=
"fa fa-exchange"
></i><span>
{% trans 'Admin page' %}
</span></a></li>
...
...
apps/templates/_user_profile.html
View file @
25ebb5c4
...
...
@@ -3,7 +3,7 @@
<li
class=
"nav-header"
>
<div
class=
"dropdown profile-element"
>
<div
href=
"http://www.jumpserver.org"
target=
"_blank"
>
<img
alt=
"
image"
height=
"55"
src=
"/static/img/logo-text.png"
style=
"margin-left: 1
0px"
/>
<img
alt=
"
logo"
height=
"55"
width=
"185"
src=
"/static/img/logo-text.png"
style=
"margin-left: 2
0px"
/>
</div>
</div>
<div
class=
"clearfix"
></div>
...
...
apps/terminal/tasks.py
View file @
25ebb5c4
...
...
@@ -8,7 +8,7 @@ from django.utils import timezone
from
common.celery
import
register_as_period_task
,
after_app_ready_start
,
\
after_app_shutdown_clean
from
.models
import
Status
from
.models
import
Status
,
Session
CACHE_REFRESH_INTERVAL
=
10
...
...
@@ -20,11 +20,17 @@ RUNNING = False
@after_app_ready_start
@after_app_shutdown_clean
def
delete_terminal_status_period
():
yesterday
=
timezone
.
now
()
-
datetime
.
timedelta
(
days
=
1
)
yesterday
=
timezone
.
now
()
-
datetime
.
timedelta
(
days
=
3
)
Status
.
objects
.
filter
(
date_created__lt
=
yesterday
)
.
delete
()
@shared_task
@register_as_period_task
(
interval
=
3600
)
@after_app_ready_start
@after_app_shutdown_clean
def
clean_orphan_session
():
active_sessions
=
Session
.
objects
.
filter
(
is_finished
=
False
)
for
session
in
active_sessions
:
if
not
session
.
terminal
.
is_active
:
session
.
is_finished
=
True
session
.
save
()
apps/terminal/templates/terminal/session_list.html
View file @
25ebb5c4
...
...
@@ -109,6 +109,21 @@
{% endfor %}
{% endblock %}
{% block content_bottom_left %}
<div
id=
"actions"
>
<div
class=
"input-group"
>
<select
class=
"form-control m-b"
style=
"width: auto"
id=
"slct_bulk_update"
>
<option
value=
"delete"
>
{% trans 'Terminate selected' %}
</option>
</select>
<div
class=
"input-group-btn pull-left"
style=
"padding-left: 5px;"
>
<button
id=
'btn_bulk_update'
style=
"height: 32px;"
class=
"btn btn-sm btn-primary"
>
{% trans 'Submit' %}
</button>
</div>
</div>
</div>
{% endblock %}
{% block custom_foot_js %}
<script
src=
"{% static 'js/plugins/datepicker/bootstrap-datepicker.js' %}"
></script>
<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