mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-10-23 06:38:40 +02:00
* Added result messages about folder operations,
* Better display (I hope) of those messages. see #55
This commit is contained in:
+3
-3
@@ -74,7 +74,7 @@ def getctx(status, level=1, callback=None, **kwargs):
|
||||
ctx[kw] = v
|
||||
return ctx
|
||||
|
||||
def ajax_response(request, status="ok", error=None,
|
||||
def ajax_response(request, status="ok", respmsg=None,
|
||||
url="", ajaxnav=False, norefresh=False,
|
||||
template=None, **kwargs):
|
||||
"""Ajax response shortcut
|
||||
@@ -97,8 +97,8 @@ def ajax_response(request, status="ok", error=None,
|
||||
else:
|
||||
content = ""
|
||||
jsonctx = {"status" : status, "content" : content}
|
||||
if error is not None:
|
||||
jsonctx["error"] = error
|
||||
if respmsg is not None:
|
||||
jsonctx["respmsg"] = respmsg
|
||||
if ajaxnav:
|
||||
jsonctx["ajaxnav"] = True
|
||||
if url != "":
|
||||
|
||||
Reference in New Issue
Block a user