ActionSaveSettings.php 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. <?php if ( ! defined( 'ABSPATH' ) ) exit;
  2. return apply_filters( 'ninja_forms_action_email_settings', array(
  3. /*
  4. * To
  5. */
  6. 'submitter_email' => array(
  7. 'name' => 'submitter_email',
  8. 'type' => 'email-select',
  9. 'options' => array(),
  10. 'group' => 'primary',
  11. 'label' => __( 'Designated Submitter\'s Email Address', 'ninja-forms' ),
  12. 'value' => '',
  13. 'help' => __( 'The email address used in this field will be allowed to '
  14. . 'make data export and delete requests on behalf of their form submission.', 'ninja-forms' ),
  15. ),
  16. 'fields_save_toggle' => array(
  17. 'name' => 'fields-save-toggle',
  18. 'type' => 'button-toggle',
  19. 'width' => 'full',
  20. 'options' => array(
  21. array( 'label' => __( 'Save All', 'ninja-forms' ), 'value' => 'save_all' ),
  22. array( 'label' => __( 'Save None', 'ninja-forms' ), 'value' => 'save_none' )
  23. ),
  24. 'group' => 'primary',
  25. 'label' => __( 'Fields', 'ninja-forms' ),
  26. 'value' => 'save_all',
  27. ),
  28. /*
  29. |--------------------------------------------------------------------------
  30. | Exception Field
  31. |--------------------------------------------------------------------------
  32. */
  33. 'exception_fields' => array(
  34. 'name' => 'exception_fields',
  35. 'type' => 'option-repeater',
  36. 'label' => __( 'Except', 'ninja-forms' ) . ' <a href="#" class="nf-add-new">' .
  37. __( 'Add New', 'ninja-forms' ) . '</a>',
  38. 'width' => 'full',
  39. 'group' => 'primary',
  40. 'tmpl_row' => 'nf-tmpl-save-field-repeater-row',
  41. 'value' => array(),
  42. 'columns' => array(
  43. 'form_field' => array(
  44. 'header' => __( 'Form Field', 'ninja-forms' ),
  45. 'default' => '',
  46. 'options' => array(),
  47. ),
  48. ),
  49. ),
  50. /*
  51. * Set subs to expire.
  52. */
  53. 'set_subs_to_expire' => array(
  54. 'name' => 'set_subs_to_expire',
  55. 'type' => 'toggle',
  56. 'group' => 'advanced',
  57. 'label' => __( 'Set Submissions to expire?', 'ninja-forms' ),
  58. 'value' => 0,
  59. 'help' => __( 'Sets submissions to be trashes after a certain number of days, it affects all existing and new submissions', 'ninja-forms' ),
  60. 'width' => 'one-half',
  61. ),
  62. /*
  63. * Subs expire in?
  64. */
  65. 'subs_expire_time' => array(
  66. 'name' => 'subs_expire_time',
  67. 'type' => 'number',
  68. 'group' => 'advanced',
  69. 'label' => __( 'How long in days until subs expire?', 'ninja-forms' ),
  70. 'value' => '90',
  71. 'min_val' => 1, // new minimum value setting
  72. 'max_val' => null, // new maximum value setting
  73. 'width' => 'one-half',
  74. 'deps' => array(
  75. 'set_subs_to_expire' => 1
  76. )
  77. ),
  78. ));