Remember last used report

This commit is contained in:
Hillel Coren 2017-02-28 18:13:43 +02:00
parent 0bdcc50e5a
commit fa4ab4bf9a

View File

@ -261,6 +261,9 @@
} else { } else {
$('#statusField').fadeOut(); $('#statusField').fadeOut();
} }
if (isStorageSupported()) {
localStorage.setItem('last:report_type', val);
}
}); });
$(function(){ $(function(){
@ -295,6 +298,11 @@
theme: 'bootstrap', theme: 'bootstrap',
widgets: ['zebra', 'uitheme'], widgets: ['zebra', 'uitheme'],
}).show(); }).show();
var lastReportType = localStorage.getItem('last:report_type');
if (lastReportType) {
$('#report_type').val(lastReportType);
}
}); });
}) })