mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-05-18 21:40:52 -04:00
Fix sales tax summary with time filter (#4166)
This commit is contained in:
@@ -61,7 +61,7 @@ class Summary_sales_taxes extends Summary_report
|
||||
}
|
||||
else
|
||||
{
|
||||
$builder->where('sale_time BETWEEN ' . rawurldecode($inputs['start_date']) . ' AND ' . rawurldecode($inputs['end_date']));
|
||||
$builder->where('sale_time BETWEEN ' . $this->db->escape(rawurldecode($inputs['start_date'])) . ' AND ' . $this->db->escape(rawurldecode($inputs['end_date'])));
|
||||
}
|
||||
|
||||
$builder->select('reporting_authority, jurisdiction_name, tax_category, tax_rate, SUM(sale_tax_amount) AS tax');
|
||||
|
||||
@@ -77,13 +77,11 @@ use Config\OSPOS;
|
||||
}
|
||||
echo esc(getBrowserNameAndVersion($_SERVER['HTTP_USER_AGENT']));
|
||||
?><br>
|
||||
.Server Software: <?= esc($_SERVER['SERVER_SOFTWARE']) ?><br>
|
||||
.PHP Version: <?= PHP_VERSION ?><br>
|
||||
.DB Version: <?= esc($dbVersion) ?><br>
|
||||
.Server Port: <?= esc($_SERVER['SERVER_PORT']) ?><br>
|
||||
.OS: <?= php_uname('s') .' '. php_uname('r') ?><br><br>
|
||||
.OS Time Zone: <span id="timezone" style="font-weight:600"></span><br>
|
||||
.OSPOS Time Zone: <span id="ostimezone" style="font-weight:600;" ><?= esc($config['timezone']) ?></span>
|
||||
Server Software: <?= esc($_SERVER['SERVER_SOFTWARE']) ?><br>
|
||||
PHP Version: <?= PHP_VERSION ?><br>
|
||||
DB Version: <?= esc($dbVersion) ?><br>
|
||||
Server Port: <?= esc($_SERVER['SERVER_PORT']) ?><br>
|
||||
OS: <?= php_uname('s') .' '. php_uname('r') ?><br><br>
|
||||
<br><br>
|
||||
|
||||
File Permissions:<br>
|
||||
@@ -229,13 +227,14 @@ use Config\OSPOS;
|
||||
document.getSelection().removeAllRanges();
|
||||
});
|
||||
|
||||
document.getElementById("timezone").innerText = Intl.DateTimeFormat().resolvedOptions().timeZone;
|
||||
|
||||
$(function() {
|
||||
$('#timezone').clone().appendTo('#timezoneE');
|
||||
});
|
||||
|
||||
if($('#timezone').html() !== $('#ostimezone').html())
|
||||
document.getElementById("TimeError").innerHTML = '<span style="color: red;"><?= lang('Config.timezone_error') ?></span><br><br><?= lang('Config.user_timezone') ?><div id="timezoneE" style="font-weight:600;"></div><br><?= lang('Config.os_timezone') ?><div id="ostimezoneE" style="font-weight:600;"><?= esc($config['timezone']) ?></div><br>';
|
||||
if($('#timezone').html() !== $('#ostimezone').html()) {
|
||||
document.getElementById("timezone").innerText = Intl.DateTimeFormat().resolvedOptions().timeZone;
|
||||
document.getElementById("TimeError").innerHTML = '<span style="color: red;"><?= lang('Config.timezone_error') ?></span><br><br><?= lang('Config.user_timezone') ?><div id="timezoneE" style="font-weight:600;"></div><br><?= lang('Config.os_timezone') ?><div id="ostimezoneE" style="font-weight:600;"><?= esc($config['timezone']) ?></div><br>';
|
||||
}
|
||||
|
||||
</script>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user