view-counter
1 year ago
block-by-role.blade.php
1 year ago
block-ips.blade.php
1 year ago
capabilities.blade.php
1 year ago
dark-mode.blade.php
2 years ago
delete.blade.php
1 year ago
disable-admin-toolbar-analytics.blade.php
2 years ago
disable-views-column.blade.php
1 year ago
disable-widget.blade.php
2 years ago
email-reports.blade.php
1 year ago
export-data.blade.php
2 years ago
export-reports.blade.php
2 years ago
first-day-of-week.blade.php
2 years ago
index.blade.php
2 years ago
notice.blade.php
2 years ago
pruner.blade.php
1 year ago
refresh-salt.blade.php
2 years ago
track-authenticated-users.blade.php
2 years ago
view-counter.blade.php
2 years ago
woocommerce.blade.php
1 year ago
pruner.blade.php
79 lines
| 1 | @php /** @var $pruner IAWP\Data_Pruning\Pruning_Scheduler */ @endphp |
| 2 | |
| 3 | <div data-controller="pruner" class="settings-container prune"> |
| 4 | <div class="heading"> |
| 5 | <h2><?php |
| 6 | esc_html_e('Automatically Delete Old Data', 'independent-analytics'); ?></h2> |
| 7 | <a class="tutorial-link" href="https://independentwp.com/knowledgebase/your-data/automatically-delete-old-data/" target="_blank"> |
| 8 | <?php |
| 9 | esc_html_e('Read Tutorial', 'independent-analytics'); ?> |
| 10 | </a> |
| 11 | </div> |
| 12 | <div class="schedule-notification @if($pruner->is_enabled()) is-scheduled @endif" |
| 13 | data-pruner-target="statusMessage" |
| 14 | data-testid="data-pruner-notice"> |
| 15 | <span class="dashicons dashicons-yes-alt"></span><span |
| 16 | class="dashicons dashicons-dismiss"></span> |
| 17 | <p><?php |
| 18 | echo wp_kses_post($pruner->status_message()); ?></p> |
| 19 | </div> |
| 20 | <div class="iawp-section"> |
| 21 | <select data-pruner-target="cutoffs" data-action="pruner#selectChanged" data-testid="data-pruner-select"> |
| 22 | @foreach($pruner->cutoff_options() as $cutoff_option) |
| 23 | <option value="{{$cutoff_option[0]}}" |
| 24 | @if($cutoff_option[0] === $pruner->get_pruning_cutoff()) selected @endif>{{$cutoff_option[1]}}</option> |
| 25 | @endforeach |
| 26 | </select> |
| 27 | </div> |
| 28 | <div class="button-group"> |
| 29 | <button class="button iawp-button purple" |
| 30 | data-pruner-target="saveButton" |
| 31 | data-action="pruner#saveClick" |
| 32 | data-original-text="<?php echo __('Save', 'independent-analytics') ?>" |
| 33 | data-loading-text="<?php echo __('Saving...', 'independent-analytics') ?>" |
| 34 | disabled="disabled" |
| 35 | data-testid="save-data-pruner" |
| 36 | > |
| 37 | <?php esc_html_e('Save', 'independent-analytics'); ?> |
| 38 | </button> |
| 39 | </div> |
| 40 | <!-- Confirmation modal --> |
| 41 | <div id="prune-modal" aria-hidden="true" class="mm micromodal-slide" data-testid="prune-modal"> |
| 42 | <div tabindex="-1" class="mm__overlay" data-action="click->pruner#cancelConfirmation"> |
| 43 | <div role="dialog" aria-modal="true" aria-labelledby="raa-modal-title" |
| 44 | class="mm__container"> |
| 45 | <h1><?php |
| 46 | esc_html_e('Enable automatic data deletion', 'independent-analytics'); ?></h1> |
| 47 | <p> |
| 48 | <?php |
| 49 | esc_html_e( |
| 50 | 'This will delete all data older then the selected timeframe, reducing the size of the database tables that Independent Analytics uses.', |
| 51 | 'independent-analytics' |
| 52 | ) ?> |
| 53 | </p> |
| 54 | <p> |
| 55 | <strong data-pruner-target="confirmationText" data-testid="date-confirmation"></strong> |
| 56 | </p> |
| 57 | <button type="submit" |
| 58 | class="iawp-button purple" |
| 59 | data-action="pruner#confirmClick" |
| 60 | data-pruner-target="confirmButton" |
| 61 | data-original-text="<?php echo esc_attr__('Enable Automatic Data Deletion', 'independent-analytics'); ?>" |
| 62 | data-loading-text="<?php echo esc_attr__('Enabling Automatic Data Deletion...', 'independent-analytics'); ?>" |
| 63 | data-testid="submit-data-pruner" |
| 64 | > |
| 65 | <?php |
| 66 | esc_html_e('Enable Automatic Data Deletion', 'independent-analytics'); ?> |
| 67 | </button> |
| 68 | <button class="iawp-button ghost-purple" |
| 69 | data-action="pruner#cancelConfirmation" |
| 70 | data-testid="close-data-pruner" |
| 71 | > |
| 72 | <?php |
| 73 | esc_html_e('Cancel', 'independent-analytics') ?> |
| 74 | </button> |
| 75 | </div> |
| 76 | </div> |
| 77 | </div> |
| 78 | </div> |
| 79 |