Skip to content
This repository has been archived by the owner on Feb 1, 2021. It is now read-only.

Commit

Permalink
Merge pull request #45 from Progi1984/issue19444
Browse files Browse the repository at this point in the history
Fixed check of the status of checkboxes
  • Loading branch information
Progi1984 authored Jun 10, 2020
2 parents 9d93325 + 55b8ef1 commit bed268d
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions pscleaner.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,24 +92,18 @@ public function getContent()
<script type="text/javascript">
$(document).ready(function(){
$("#submitTruncateCatalog").click(function(){
if ($(\'#checkTruncateCatalog_on\').attr(\'checked\') != "checked")
{
if (!$(\'#checkTruncateCatalog_on\').is(\':checked\')) {
alert(\''.addslashes(html_entity_decode($this->trans('Please read the disclaimer and click "Yes" above', array(), 'Modules.Pscleaner.Admin'))).'\');
return false;
}
if (confirm(\''.addslashes(html_entity_decode($this->trans('Are you sure that you want to delete all catalog data?', array(), 'Modules.Pscleaner.Admin'))).'\'))
return true;
return false;
return window.confirm(\''.addslashes(html_entity_decode($this->trans('Are you sure that you want to delete all catalog data?', array(), 'Modules.Pscleaner.Admin'))).'\');
});
$("#submitTruncateSales").click(function(){
if ($(\'#checkTruncateSales_on\').attr(\'checked\') != "checked")
{
if (!$(\'#checkTruncateSales_on\').is(\':checked\')) {
alert(\''.addslashes(html_entity_decode($this->trans('Please read the disclaimer and click "Yes" above', array(), 'Modules.Pscleaner.Admin'))).'\');
return false;
}
if (confirm(\''.addslashes(html_entity_decode($this->trans('Are you sure that you want to delete all sales data?', array(), 'Modules.Pscleaner.Admin'))).'\'))
return true;
return false;
return window.confirm(\''.addslashes(html_entity_decode($this->trans('Are you sure that you want to delete all sales data?', array(), 'Modules.Pscleaner.Admin'))).'\');
});
});
</script>';
Expand Down

0 comments on commit bed268d

Please sign in to comment.