You are here

function _signup_render_signup_edit_form in Signup 6

Same name and namespace in other branches
  1. 6.2 includes/node_output.inc \_signup_render_signup_edit_form()
  2. 7 includes/node_output.inc \_signup_render_signup_edit_form()

Helper function to render the form to edit your own signup.

1 call to _signup_render_signup_edit_form()
_signup_current_user_signup in includes/node_output.inc
Helper function to generate the output for the current user's signup.

File

includes/node_output.inc, line 161
Code used to generate singup-related output when viewing nodes.

Code

function _signup_render_signup_edit_form($signup, $type) {
  $path = drupal_get_path('module', 'signup');
  if ($type == 'node') {
    drupal_add_css("{$path}/signup.css");
  }
  drupal_add_js("{$path}/js/signup_edit_form.js");
  module_load_include('inc', 'signup', 'includes/signup_edit_form');
  $form = drupal_get_form('signup_edit_form', $signup, $type);
  $form_errors = form_get_errors() ? TRUE : FALSE;
  drupal_add_js(array(
    'signupEditFormErrors' => $form_errors,
  ), 'setting');
  return $form;
}