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
c574bbcb
Commit
c574bbcb
authored
9 years ago
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix date change bug
parent
61deed70
master
auditor_jym
audits
dev
dev_beta
dev_beta_db
gengmei
lagacy-0.4.0
node_service
password
rbac
restrict_access
test
v52
wph
1.5.2
1.5.1
1.5.0
1.4.10
1.4.9
1.4.8
1.4.7
1.4.6
1.4.5
1.4.4
1.4.3
1.4.2
1.4.1
1.4.0
1.3.3
1.3.2
1.3.1
1.3.0
1.2.1
1.2.0
1.1.1
1.1.0
1.0.0
0.3.3
0.3.2
0.3.2-rc2
0.3.1
0.3.0-beta
v1.4.10
v1.4.7
v1.4.4
No related merge requests found
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
15 additions
and
17 deletions
+15
-17
views.py
jlog/views.py
+3
-1
datepicker3.css
static/css/plugins/datepicker/datepicker3.css
+0
-0
log_filter.html
templates/jlog/log_filter.html
+1
-1
log_offline.html
templates/jlog/log_offline.html
+5
-9
perm_role_add.html
templates/jperm/perm_role_add.html
+1
-1
perm_role_edit.html
templates/jperm/perm_role_edit.html
+1
-1
perm_role_push.html
templates/jperm/perm_role_push.html
+1
-1
perm_rule_add.html
templates/jperm/perm_rule_add.html
+1
-1
perm_rule_edit.html
templates/jperm/perm_rule_edit.html
+1
-1
run_command.html
templates/juser/run_command.html
+1
-1
No files found.
jlog/views.py
View file @
c574bbcb
...
@@ -39,10 +39,12 @@ def log_list(request, offset):
...
@@ -39,10 +39,12 @@ def log_list(request, offset):
if
host_list
:
if
host_list
:
posts
=
posts
.
filter
(
host__in
=
host_list
)
posts
=
posts
.
filter
(
host__in
=
host_list
)
if
cmd
:
if
cmd
:
log_id_list
=
set
([
log
.
log_id
for
log
in
TtyLog
.
objects
.
filter
(
cmd__contains
=
cmd
)])
log_id_list
=
set
([
log
.
log_id
for
log
in
TtyLog
.
objects
.
filter
(
cmd__contains
=
cmd
)])
posts
=
posts
.
filter
(
id__in
=
log_id_list
)
posts
=
posts
.
filter
(
id__in
=
log_id_list
)
else
:
if
not
date_seven_day
:
date_now
=
datetime
.
datetime
.
now
()
date_now
=
datetime
.
datetime
.
now
()
date_now_str
=
date_now
.
strftime
(
'
%
m/
%
d/
%
Y'
)
date_now_str
=
date_now
.
strftime
(
'
%
m/
%
d/
%
Y'
)
date_seven_day
=
(
date_now
+
datetime
.
timedelta
(
days
=-
7
))
.
strftime
(
'
%
m/
%
d/
%
Y'
)
date_seven_day
=
(
date_now
+
datetime
.
timedelta
(
days
=-
7
))
.
strftime
(
'
%
m/
%
d/
%
Y'
)
...
...
This diff is collapsed.
Click to expand it.
static/css/plugins/dat
a
picker/datepicker3.css
→
static/css/plugins/dat
e
picker/datepicker3.css
View file @
c574bbcb
File moved
This diff is collapsed.
Click to expand it.
templates/jlog/log_filter.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
templates/jlog/log_offline.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
@@ -54,14 +54,11 @@
...
@@ -54,14 +54,11 @@
<ul
class=
"nav nav-tabs"
>
<ul
class=
"nav nav-tabs"
>
<li><a
href=
"/jlog/log_list/online/"
class=
"text-center"
><i
class=
"fa fa-laptop"
></i>
在线
</a></li>
<li><a
href=
"/jlog/log_list/online/"
class=
"text-center"
><i
class=
"fa fa-laptop"
></i>
在线
</a></li>
<li
class=
"active"
><a
href=
"/jlog/log_list/offline/"
class=
"text-center"
><i
class=
"fa fa-bar-chart-o"
></i>
历史记录
</a></li>
<li
class=
"active"
><a
href=
"/jlog/log_list/offline/"
class=
"text-center"
><i
class=
"fa fa-bar-chart-o"
></i>
历史记录
</a></li>
{#
<li><a
href=
"/jlog/search/"
class=
"text-center"
><i
class=
"fa fa-bar-chart-o"
></i>
详细搜索
</a></li>
#}
</ul>
</ul>
</div>
</div>
<br/>
<br/>
<form
class=
"form-inline"
action=
""
method=
"get"
>
<form
class=
"form-inline"
action=
""
method=
"get"
>
<div
class=
"form-group"
id=
"data_5"
>
<div
class=
"form-group"
id=
"date_5"
>
<div
class=
"form-group"
id=
"data_5"
>
<div
class=
"input-daterange input-group"
id=
"datepicker"
>
<div
class=
"input-daterange input-group"
id=
"datepicker"
>
<input
type=
"text"
class=
"input-sm form-control"
style=
"width: 100px;"
name=
"start"
value=
"{{ date_seven_day }}"
>
<input
type=
"text"
class=
"input-sm form-control"
style=
"width: 100px;"
name=
"start"
value=
"{{ date_seven_day }}"
>
<span
class=
"input-group-addon"
>
to
</span>
<span
class=
"input-group-addon"
>
to
</span>
...
@@ -89,7 +86,6 @@
...
@@ -89,7 +86,6 @@
<div
class=
"form-group"
>
<div
class=
"form-group"
>
<input
id=
"cmd"
name=
"cmd"
placeholder=
"命令"
type=
"text"
class=
"form-control"
value=
"{{ cmd }}"
style=
"width: 200px;"
>
<input
id=
"cmd"
name=
"cmd"
placeholder=
"命令"
type=
"text"
class=
"form-control"
value=
"{{ cmd }}"
style=
"width: 200px;"
>
</div>
</div>
</div>
<button
id=
'search_btn'
type=
"submit"
class=
"btn btn-sm btn-primary"
>
<button
id=
'search_btn'
type=
"submit"
class=
"btn btn-sm btn-primary"
>
Search
Search
</button>
</button>
...
@@ -116,7 +112,7 @@
...
@@ -116,7 +112,7 @@
{% for post in contacts.object_list %}
{% for post in contacts.object_list %}
<tr
class=
"gradeX"
>
<tr
class=
"gradeX"
>
<td
class=
"text-center
username
"
>
{{ post.id }}
</td>
<td
class=
"text-center"
>
{{ post.id }}
</td>
<td
class=
"text-center username"
>
{{ post.user }}
</td>
<td
class=
"text-center username"
>
{{ post.user }}
</td>
<td
class=
"text-center ip"
>
{{ post.host }}
</td>
<td
class=
"text-center ip"
>
{{ post.host }}
</td>
<td
class=
"text-center remote_ip"
>
{{ post.remote_ip }}
</td>
<td
class=
"text-center remote_ip"
>
{{ post.remote_ip }}
</td>
...
@@ -201,8 +197,8 @@
...
@@ -201,8 +197,8 @@
{
#
}
#
}
{
#
}
#
}
{
#
});
#
}
{
#
});
#
}
$
(
'#dat
a
_5 .input-daterange'
).
datepicker
({
$
(
'#dat
e
_5 .input-daterange'
).
datepicker
({
dateFormat
:
'
yy-mm-dd
'
,
dateFormat
:
'
mm/dd/yy
'
,
keyboardNavigation
:
false
,
keyboardNavigation
:
false
,
forceParse
:
false
,
forceParse
:
false
,
autoclose
:
true
autoclose
:
true
...
...
This diff is collapsed.
Click to expand it.
templates/jperm/perm_role_add.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
templates/jperm/perm_role_edit.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
templates/jperm/perm_role_push.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
templates/jperm/perm_rule_add.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
templates/jperm/perm_rule_edit.html
View file @
c574bbcb
{% extends 'base.html' %}
{% extends 'base.html' %}
{% block self_head_css_js %}
{% block self_head_css_js %}
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
templates/juser/run_command.html
View file @
c574bbcb
...
@@ -69,7 +69,7 @@
...
@@ -69,7 +69,7 @@
{% block self_head_css_js %}
{% block self_head_css_js %}
{% load staticfiles %}
{% load staticfiles %}
<script
src=
"{% static 'js/jquery.shiftcheckbox.js' %}"
></script>
<script
src=
"{% static 'js/jquery.shiftcheckbox.js' %}"
></script>
<link
href=
"/static/css/plugins/dat
a
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/dat
e
picker/datepicker3.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<link
href=
"/static/css/plugins/chosen/chosen.css"
rel=
"stylesheet"
>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
<script
src=
"/static/js/plugins/chosen/chosen.jquery.js"
></script>
{% endblock %}
{% endblock %}
...
...
This diff is collapsed.
Click to expand it.
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