public function delete()
 {
     //In single_pages, do not prepend "action_" (unlike blocks)
     $delete_ids = $this->post('delete_ids');
     if (!empty($delete_ids) && is_array($delete_ids)) {
         CustomContactForm::deleteSubmissions($delete_ids);
     }
     $this->redirect('/dashboard/reports/custom_contact_form');
 }
 public function delete($form_key = null)
 {
     //In single_pages, do not prepend "action_" (unlike blocks)
     //Note that we don't actually need the form key to delete submissions,
     // but we do want it so we know where to redirect back to when we're done.
     $delete_ids = $this->post('delete_ids');
     if (!empty($delete_ids) && is_array($delete_ids)) {
         CustomContactForm::deleteSubmissions($delete_ids);
     }
     $this->redirect('/dashboard/reports/custom_contact_form', $form_key);
 }
Esempio n. 3
0
 public function getNotificationEmailReplyTo()
 {
     $field_name = CustomContactForm::getReplyToFieldName($this->form_key);
     return empty($field_name) ? '' : $this->field_values[$field_name];
 }
 private function setAvailableForms()
 {
     $this->set('available_forms', CustomContactForm::getFormKeysAndTitles());
 }