mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-12-02 12:13:54 +01:00
* see #92: Some graphical fixes,
* Documentation update, * Ugly hacks to make the stats plugin work as before.
This commit is contained in:
@@ -41,7 +41,7 @@ window.addEvent("domready", function() {
|
||||
} else {
|
||||
infobox.error(resp.error);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
get_period = function() {
|
||||
if ($("period").value != "custom") {
|
||||
@@ -55,7 +55,7 @@ window.addEvent("domready", function() {
|
||||
return "period=custom"
|
||||
+ "&start=" + $("dateTravelStart").value
|
||||
+ "&end=" + $("dateTravelEnd").value;
|
||||
}
|
||||
};
|
||||
|
||||
get_graph = function(evt) {
|
||||
{% if user.is_superuser %}
|
||||
@@ -70,7 +70,7 @@ window.addEvent("domready", function() {
|
||||
}
|
||||
new Request.JSON({url : url + "?" + p, noCache: true,
|
||||
onSuccess : getgraph_callback}).get();
|
||||
}
|
||||
};
|
||||
|
||||
{% if user.is_superuser %}
|
||||
$("domain").addEvent("change", get_graph);
|
||||
|
||||
@@ -25,12 +25,12 @@ periods = [{"name" : "day", "label" : _("Day")},
|
||||
@good_domain
|
||||
@permission_required("admin.view_mailboxes")
|
||||
def index(request):
|
||||
domain = None
|
||||
domains = None
|
||||
period = request.GET.has_key("period") and request.GET["period"] or "day"
|
||||
domid = request.GET.has_key("domid") and request.GET["domid"] or ""
|
||||
if request.user.is_superuser:
|
||||
domains = Domain.objects.all()
|
||||
domain = "global"
|
||||
else:
|
||||
domain = Domain.objects.get(pk=domid)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user