Hello @mohammedays,
Thank you for your feedback!
Currently there is no automatic deletion, simply because it doesn’t make sense if you want to measure how well something is performing. Especially the history is important here.
If your dashboard is too slow, you can enable caching. This can be done directly in Helpful’s settings, under System. Helpful should display several 10,000 votes without any problems.
Otherwise you can build a solution yourself to delete ALL entries automatically after 7 days. Without cronjobs you can just do that with transients – directly in admin_init, if you are interested.
So this you can put in the functions.php and then it will be executed every 7 days. The important thing is that it is also run once at the beginning. After that then every 7 days.
// only in admin area (use init, template_redirect or something else, for every page in the fronted)
add_action('admin_init', function() {
// seven days in seconds
$seven_days_in_seconds = DAY_IN_SECONDS * 7;
// transients, deletes itself automatically after seven days
$transient = get_transient('helpful_auto_delete');
// fires only, if the transients is not set
if (false === $transient) {
global $wpdb;
// db table name
$table_name = $wpdb->prefix . 'helpful';
// db query for truncate table
$wpdb->query("TRUNCATE TABLE $table_name");
// stores a transient for seven days
set_transient('helpful_auto_delete', time(), $seven_days_in_seconds);
}
});