You are here

function nopremium_node_operations in Node Option Premium 7

Same name and namespace in other branches
  1. 6 nopremium.module \nopremium_node_operations()

Implementation of hook_node_operations().

File

./nopremium.module, line 38
Written by Henri MEDOT <henri.medot[AT]absyx[DOT]fr> http://www.absyx.fr

Code

function nopremium_node_operations() {
  return array(
    'premium' => array(
      'label' => t('Make premium'),
      'callback' => 'node_mass_update',
      'callback arguments' => array(
        'updates' => array(
          'status' => NODE_PUBLISHED,
          'premium' => NODE_PREMIUM,
        ),
      ),
    ),
    'non_premium' => array(
      'label' => t('Make non-premium'),
      'callback' => 'node_mass_update',
      'callback arguments' => array(
        'updates' => array(
          'premium' => NODE_NOT_PREMIUM,
        ),
      ),
    ),
  );
}