PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / trunk
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More vtrunk
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/helpers/FrmEntriesHelper.php +42 -30 6.31 → trunk View file →
@@ -761,8 +761,20 @@
761 761 private static function get_action_links( $id, $entry ) {
762 762 $page = FrmAppHelper::get_param( 'frm_action' );
763 763 $actions = array();
764 764
765 + $actions['frm_edit'] = array(
766 + 'url' => '#',
767 + 'label' => __( 'Edit Entry', 'formidable' ),
768 + 'class' => 'frm_noallow',
769 + 'data' => array(
770 + 'upgrade' => __( 'Entry edits', 'formidable' ),
771 + 'medium' => 'edit-entries',
772 + 'content' => 'entry',
773 + ),
774 + 'icon' => 'frmfont frm_pencil_icon',
775 + );
776 +
765 777 if ( $page !== 'show' ) {
766 778 $actions['frm_view'] = array(
767 779 'url' => admin_url( 'admin.php?page=formidable-entries&frm_action=show&id=' . $id . '&form=' . $entry->form_id ),
768 780 'label' => __( 'View Entry', 'formidable' ),
@@ -769,20 +781,8 @@
769 781 'icon' => 'frmfont frm_save_icon',
770 782 );
771 783 }
772 784
773 - if ( current_user_can( 'frm_delete_entries' ) ) {
774 - $actions['frm_delete'] = array(
775 - 'url' => wp_nonce_url( admin_url( 'admin.php?page=formidable-entries&frm_action=destroy&id=' . $id . '&form=' . $entry->form_id ) ),
776 - 'label' => __( 'Delete Entry', 'formidable' ),
777 - 'icon' => 'frmfont frm_delete_icon',
778 - 'data' => array(
779 - 'frmverify' => __( 'Permanently delete this entry?', 'formidable' ),
780 - 'frmverify-btn' => 'frm-button-red',
781 - ),
782 - );
783 - }
784 -
785 785 if ( $page === 'show' ) {
786 786 $actions['frm_print'] = array(
787 787 'url' => '#',
788 788 'label' => __( 'Print Entry', 'formidable' ),
@@ -792,20 +792,8 @@
792 792 'icon' => 'frmfont frm_printer_icon',
793 793 );
794 794 }
795 795
796 - $actions['frm_resend'] = array(
797 - 'url' => '#',
798 - 'label' => __( 'Resend Emails', 'formidable' ),
799 - 'class' => 'frm_noallow',
800 - 'data' => array(
801 - 'upgrade' => __( 'Resend Emails', 'formidable' ),
802 - 'medium' => 'resend-email',
803 - 'content' => 'entry',
804 - ),
805 - 'icon' => 'frmfont frm_email_icon',
806 - );
807 -
808 796 if ( ! function_exists( 'frm_pdfs_autoloader' ) ) {
809 797 $actions['frm_download_pdf'] = array(
810 798 'url' => '#',
811 799 'label' => __( 'Download as PDF', 'formidable' ),
@@ -814,21 +802,45 @@
814 802 'icon' => 'frmfont frm_download_icon',
815 803 );
816 804 }
817 805
818 - $actions['frm_edit'] = array(
806 + $actions['frm_resend'] = array(
819 807 'url' => '#',
820 - 'label' => __( 'Edit Entry', 'formidable' ),
808 + 'label' => __( 'Resend Emails', 'formidable' ),
821 809 'class' => 'frm_noallow',
822 810 'data' => array(
823 - 'upgrade' => __( 'Entry edits', 'formidable' ),
824 - 'medium' => 'edit-entries',
811 + 'upgrade' => __( 'Resend Emails', 'formidable' ),
812 + 'medium' => 'resend-email',
825 813 'content' => 'entry',
826 814 ),
827 - 'icon' => 'frmfont frm_pencil_icon',
815 + 'icon' => 'frmfont frm_email_icon',
828 816 );
829 817
830 - return apply_filters( 'frm_entry_actions_dropdown', $actions, compact( 'id', 'entry' ) );
818 + if ( current_user_can( 'frm_delete_entries' ) ) {
819 + $actions['frm_delete'] = array(
820 + 'url' => wp_nonce_url( admin_url( 'admin.php?page=formidable-entries&frm_action=destroy&id=' . $id . '&form=' . $entry->form_id ) ),
821 + 'label' => __( 'Delete Entry', 'formidable' ),
822 + 'class' => 'frm_delete_entry',
823 + 'icon' => 'frmfont frm_delete_icon',
824 + 'data' => array(
825 + 'frmverify' => __( 'Permanently delete this entry?', 'formidable' ),
826 + 'frmverify-btn' => 'frm-button-red',
827 + ),
828 + );
829 + }
830 +
831 + $actions = apply_filters( 'frm_entry_actions_dropdown', $actions, compact( 'id', 'entry' ) );
832 +
833 + if ( ! isset( $actions['frm_delete'] ) ) {
834 + return $actions;
835 + }
836 +
837 + // Make delete the last link.
838 + $delete_action = $actions['frm_delete'];
839 + unset( $actions['frm_delete'] );
840 + $actions['frm_delete'] = $delete_action;
841 +
842 + return $actions;
831 843 }
832 844
833 845 /**
834 846 * Gets data attributes for PDFs addon upgrade link.