Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
3pia
VISPA
VISPA web
Commits
d4a32bcc
Commit
d4a32bcc
authored
Sep 30, 2014
by
Martin Urban
Browse files
File: Remove complete list without looping
parent
1d8b995e
Changes
2
Hide whitespace changes
Inline
Side-by-side
vispa/controller/filesystem.py
View file @
d4a32bcc
...
...
@@ -131,6 +131,7 @@ class FSAjaxController(AbstractController):
self
.
release_session
()
fs
=
self
.
get
(
'fs'
)
self
.
release_database
()
path
=
json
.
loads
(
path
)
# 'path' can be a unicode/string or list of unicodes/strings
# so convert it with the convert function
fs
.
remove
(
path
)
...
...
vispa/extensions/file/static/js/base/actions.js
View file @
d4a32bcc
...
...
@@ -150,7 +150,6 @@ var FileBaseActions = Class.extend({
var
dfd
=
self
.
FileBase
.
instance
.
POST
(
"
/ajax/fs/paste
"
,
{
"
path
"
:
this
.
FileBase
.
workflow
.
path
,
// "paths": JSON.stringify(paths),
"
paths
"
:
JSON
.
stringify
(
paths
),
"
cut
"
:
cut
});
...
...
@@ -186,15 +185,13 @@ var FileBaseActions = Class.extend({
_remove
:
function
()
{
var
self
=
this
;
$
.
each
(
self
.
entries
,
function
(
index
,
path
)
{
var
dfd
=
self
.
FileBase
.
instance
.
GET
(
"
/ajax/fs/remove
"
,
{
"
path
"
:
path
});
dfd
.
done
(
function
(
response
)
{
self
.
FileBase
.
updateView
();
});
var
dfd
=
self
.
FileBase
.
instance
.
GET
(
"
/ajax/fs/remove
"
,
{
"
path
"
:
JSON
.
stringify
(
self
.
entries
)
});
dfd
.
done
(
function
(
response
)
{
self
.
FileBase
.
updateView
();
this
.
entries
=
{};
});
this
.
entries
=
{};
},
download
:
function
()
{
...
...
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