You are here

workflow_extensions.install in Workflow Extensions 7

Same filename and directory in other branches
  1. 6 workflow_extensions.install

Install and uninstall hooks for Workflow Extensions module.

File

workflow_extensions.install
View source
<?php

/**
 * @file
 * Install and uninstall hooks for Workflow Extensions module.
 */

/**
 * Implements hook_install().
 */
function workflow_extensions_install() {

  // Patch by galaxor: [#1346078]
  // Weight should be a higher weight than Noderelationships module. That way
  // it can grab the submit handlers when dealing with a form in a modalframe.
  // If we don't get that handler, the modalframe won't close.
  db_update('system')
    ->fields(array(
    'weight' => 2,
  ))
    ->condition('name', 'workflow_extensions')
    ->execute();
}

/**
 * Implements hook_uninstall().
 */
function workflow_extensions_uninstall() {

  // Delete all workflow_extensions_* variables at once
  db_delete('variable')
    ->condition('name', 'workflow_extensions_%%', 'LIKE')
    ->execute();
}