Add confirmation box before flush
This commit is contained in:
parent
4f9fcfe573
commit
b854be546b
@ -212,6 +212,14 @@ Router\get_action('mark-as-read', function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
Router\get_action('confirm-flush-history', function() {
|
||||||
|
|
||||||
|
Response\html(Template\layout('confirm_flush', array(
|
||||||
|
'menu' => 'history'
|
||||||
|
)));
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
Router\get_action('flush-history', function() {
|
Router\get_action('flush-history', function() {
|
||||||
|
|
||||||
Model\flush_read();
|
Model\flush_read();
|
||||||
|
10
miniflux/templates/confirm_flush.php
Normal file
10
miniflux/templates/confirm_flush.php
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
<div class="page-header">
|
||||||
|
<h2>Confirmation</h2>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<p class="alert alert-info">Do you really want to remove these items from your history?</p>
|
||||||
|
|
||||||
|
<div class="form-actions">
|
||||||
|
<a href="?action=flush-history" class="btn btn-red">Yes</a>
|
||||||
|
or <a href="?action=history">cancel</a>
|
||||||
|
</div>
|
@ -7,7 +7,7 @@
|
|||||||
<div class="page-header">
|
<div class="page-header">
|
||||||
<h2>History</h2>
|
<h2>History</h2>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="?action=flush-history">flush</a></li>
|
<li><a href="?action=confirm-flush-history">flush</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user