You are here

function webform_update_7429 in Webform 7.4

Add column highest_valid_page to webform_submissions table.

Add a column to the submission table to store the page on which to resume a draft. Sites with many, many submissions may wish to execute this update with 'drush updatedb'.

File

./webform.install, line 2345
Webform module install/schema hooks.

Code

function webform_update_7429() {

  // Add highest_valid_page column to webform_submissions.
  if (!db_field_exists('webform_submissions', 'highest_valid_page')) {
    $spec = array(
      'description' => 'For drafts, the highest validated page number.',
      'type' => 'int',
      'size' => 'small',
      'not null' => TRUE,
      'default' => 0,
    );
    db_add_field('webform_submissions', 'highest_valid_page', $spec);
  }
  return t('Webforms will now resume draft submissions on the page where the submitter left off.');
}