mirror of
https://git.proxmox.com/git/pmg-gui
synced 2025-08-14 23:35:37 +00:00
MailTracker: do not search when not both datetime parameters are given
in the gui, we always expect an end and starttime, the only case where we do not get this is when the fields are invalid, so bail out in that case instead of searching Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
parent
2e330d4477
commit
e8e332fe01
@ -49,6 +49,10 @@ Ext.define('PMG.MailTrackerFilter', {
|
||||
if (value) { param[name] = value; }
|
||||
});
|
||||
|
||||
// there must always be a start and endtime, otherwise the field was invalid
|
||||
if (!param.starttime || !param.endtime) {
|
||||
return undefined;
|
||||
}
|
||||
return param;
|
||||
},
|
||||
|
||||
@ -260,6 +264,9 @@ Ext.define('PMG.MailTracker', {
|
||||
var filter = this.lookupReference('filter');
|
||||
var status = this.lookupReference('status');
|
||||
var params = filter.getFilterParams();
|
||||
if (params === undefined) {
|
||||
return; // something went wrong with the filters bail out
|
||||
}
|
||||
status.update(''); // clear status before load
|
||||
view.store.proxy.setExtraParams(params);
|
||||
view.store.proxy.setUrl('/api2/json/nodes/' + Proxmox.NodeName + '/tracker');
|
||||
|
Loading…
Reference in New Issue
Block a user