Commit f2652904 by Kálmán Viktor

dashboard: keep messages with with_reload

parent 5d59c0a9
......@@ -660,8 +660,10 @@ class AjaxOperationMixin(object):
resp = super(AjaxOperationMixin, self).post(
request, extra, *args, **kwargs)
if request.is_ajax():
store = messages.get_messages(request)
store.used = True
store = []
if not getattr(self, "with_reload", False):
store = messages.get_messages(request)
store.used = True
return HttpResponse(
json.dumps({'success': True,
'with_reload': getattr(self, 'with_reload', False),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment