You are here

function _sheetnode_template_save in Sheetnode 7

Same name and namespace in other branches
  1. 5 sheetnode.module \_sheetnode_template_save()
  2. 6 sheetnode.module \_sheetnode_template_save()
  3. 7.2 sheetnode.module \_sheetnode_template_save()

Helper function to save a sheetnode template.

2 calls to _sheetnode_template_save()
sheetnode_insert in ./sheetnode.module
Implements hook_insert().
sheetnode_update in ./sheetnode.module
Implements hook_update().

File

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

Code

function _sheetnode_template_save($vid, $name, $value) {
  db_merge('sheetnode_template')
    ->key(array(
    'name' => $name,
  ))
    ->fields(array(
    'vid' => $vid,
    'value' => $value,
  ))
    ->execute();
}