Skip to content
Snippets Groups Projects
Unverified Commit 928cd76e authored by Peter Rotich's avatar Peter Rotich Committed by GitHub
Browse files

Merge pull request #4650 from JediKev/issue/dashboard-export-period

issue: Dashboard Export Period
parents b218896d b951032c
No related branches found
No related tags found
No related merge requests found
......@@ -122,4 +122,16 @@ foreach ($groups as $g=>$desc) {
</form>
<script>
$.drawPlots(<?php echo JsonDataEncoder::encode($report->getPlotData()); ?>);
// Set Selected Period For Dashboard Stats and Export
<?php if ($report && $report->end) { ?>
$("div#basic_search select option").each(function(){
// Remove default selection
if ($(this)[0].selected)
$(this).removeAttr('selected');
// Set the selected period by the option's value (periods equal
// option's values)
if ($(this).val() == "<?php echo $report->end; ?>")
$(this).attr("selected","selected");
});
<?php } ?>
</script>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment