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
f4136dec
Commit
f4136dec
authored
Nov 11, 2019
by
ibuler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Update] Stash
parent
fb9e2ac9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
11 deletions
+14
-11
node.py
apps/assets/models/node.py
+1
-1
asset_list.html
apps/assets/templates/assets/asset_list.html
+13
-10
No files found.
apps/assets/models/node.py
View file @
f4136dec
...
...
@@ -67,7 +67,7 @@ class TreeMixin:
@classmethod
def
refresh_node_assets
(
cls
,
t
=
None
):
logger
.
debug
(
"Refresh node
tree
assets"
)
logger
.
debug
(
"Refresh node assets"
)
key
=
cls
.
tree_assets_cache_key
ttl
=
cls
.
tree_cache_time
if
not
t
:
...
...
apps/assets/templates/assets/asset_list.html
View file @
f4136dec
...
...
@@ -426,13 +426,15 @@ $(document).ready(function(){
function
success
(
data
)
{
url
=
setUrlParam
(
the_url
,
'spm'
,
data
.
spm
);
requestApi
({
url
:
url
,
method
:
'DELETE'
,
success
:
refreshPage
,
flash_message
:
false
,
url
:
url
,
method
:
'DELETE'
,
success
:
function
()
{
var
msg
=
"{% trans 'Asset Deleted.' %}"
;
swal
(
"{% trans 'Asset Delete' %}"
,
msg
,
"success"
);
refreshPage
();
},
flash_message
:
false
,
});
var
msg
=
"{% trans 'Asset Deleted.' %}"
;
swal
(
"{% trans 'Asset Delete' %}"
,
msg
,
"success"
);
}
function
fail
()
{
var
msg
=
"{% trans 'Asset Deleting failed.' %}"
;
...
...
@@ -440,10 +442,11 @@ $(document).ready(function(){
}
requestApi
({
url
:
"{% url 'api-common:resources-cache' %}"
,
method
:
'POST'
,
body
:
JSON
.
stringify
(
data
),
success
:
success
,
error
:
fail
method
:
'POST'
,
body
:
JSON
.
stringify
(
data
),
success
:
success
,
error
:
fail
,
flash_message
:
false
})
})
}
...
...
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