Skip to content

Commit 2800572

Browse files
committed
Added confirmation dialog when deleting logs
1 parent b6f5ba4 commit 2800572

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ All notable changes to this project will be documented in this file.
2828
- SecImprove: Cli arguments were glob expanded when written to log file
2929
- Fixed: Removing web domains would let sftp accounts still configured in sshd
3030
- SecImprove: File operations in user home folder will be executed as the real user
31+
- Added a confirmation dialog when deleting user logs (/list/log/)
3132

3233
## [1.0.5] - 2019-08-06 - Hotfix
3334
### Bugfixes

web/inc/i18n/en.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -486,6 +486,7 @@
486486
'DELETE_PACKAGE_CONFIRMATION' => 'Are you sure you want to delete package %s?',
487487
'DELETE_IP_CONFIRMATION' => 'Are you sure you want to delete IP address %s?',
488488
'DELETE_RULE_CONFIRMATION' => 'Are you sure you want to delete rule #%s?',
489+
'DELETE_LOGS_CONFIRMATION' => 'Are you sure you want to delete the logs?',
489490
'SUSPEND_RULE_CONFIRMATION' => 'Are you sure you want to suspend rule #%s?',
490491
'UNSUSPEND_RULE_CONFIRMATION' => 'Are you sure you want to unsuspend rule #%s?',
491492
'Are you sure you want to stop service' => 'Are you sure you want to stop service %s?',

web/templates/admin/list_log.html

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,16 @@
22
<div class="l-sort clearfix noselect">
33
<div class="l-unit-toolbar__buttonstrip">
44
<a href="javascript:location.reload();" class="ui-button cancel" title="<?=__('Refresh')?>"><i class="fas fa-redo status-icon green"></i> <?=__('Refresh')?></a>
5-
<a href="/delete/log/?token=<?=$_SESSION['token']?>" class="ui-button cancel" title="<?=__('Delete')?>"><i class="fas fa-times-circle status-icon red"></i> <?=__('Delete')?></a>
5+
<div class="actions-panel display-inline-block" key-action="js">
6+
<a class="data-controls do_delete ui-button cancel" title="<?=__('Delete')?>">
7+
<i class="do_delete fas fa-times-circle status-icon red"></i>
8+
<?=__('Delete')?>
9+
<input type="hidden" name="delete_url" value="/delete/log/?token=<?=$_SESSION['token']?>" />
10+
<div class="confirmation-text-delete hidden" title="<?=__('Confirmation')?>">
11+
<p class="confirmation"><?=__('DELETE_LOGS_CONFIRMATION')?></p>
12+
</div>
13+
</a>
14+
</div>
615
</div>
716
<div class="l-sort-toolbar clearfix">
817
</div>

0 commit comments

Comments
 (0)