You are here

function sheetnode_node_presave in Sheetnode 7.2

Same name and namespace in other branches
  1. 7 sheetnode.module \sheetnode_node_presave()

Implements hook_node_presave().

File

./sheetnode.module, line 294
Module file for the sheetnode module.

Code

function sheetnode_node_presave($node) {
  if ($node->type == 'sheetnode' && isset($node->devel_generate)) {

    // Generate random spreadsheets for sheetnodes.
    $node->sheetnode = array(
      'template' => NULL,
    ) + _sheetnode_devel_generate($node, NULL, NULL, NULL);
  }
}