I know that changes don’t take effect until someone updates a post containing your custom field data regarding additions and deletions etc.
But it is alarmingly easy to delete a row from a repeater, would it be possible to add some type of optional speed bump to that process?
A prompt or nag pop up that asks “Are you sure you want to delete this?”, I think would be a welcome addition, especially for those who pass off content input and such to maybe not so mindful types.
Thanks for the feature request. I do agree that this prompt is a good idea, however I feel that many devs would become frustrated at the decrease in speed to operate the repeater field.
I think a good solution at the moment would be to add a custom prompt like so:
add_action('acf/input/admin_footer', function(){
?>
<script type="text/javascript">
(function($) {
$('body').on('click', '.acf-repeater-remove-row', function( e ){
return confirm("are you sure?");
})
})(jQuery);
</script>
<?php
});
Cheers
E
Hi guys!
I think this is a good idea, have a confirmation as part of ACF.
In some cases another users (which aren’t developers) uses the fields to insert/alter/remove data in posts, pages, etc.
Usually, these users don’t have so much “developer” skills, and deletes a field as a mistake. It already happened with a client, and is a little frustrating for the user (depending on the field deleted, a lot of work could be lost).
An idea is to do as the guys at MailChimp does: when deleting a block, a dialog appears. This dialog have an information about “how to delete a block without dialog”, which is “hit ALT to delete without asking”.
So, if a read this info, next time I know how to delete without ask.
By the way, I really LOVE ACF. Thanks, E!
PS.: I’ve tried to make the JS above work, but till now it didn’t work.
Cheers
The topic ‘Feature Request: 2 Step Delete’ is closed to new replies.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.