You are here

function protected_node_views_tables in Protected Node 5

File

./protected_node.views.inc, line 3

Code

function protected_node_views_tables() {
  $tables["protected_nodes"] = array(
    "name" => "protected_nodes",
    "join" => array(
      "left" => array(
        "table" => "node",
        "field" => "nid",
      ),
      "right" => array(
        "table" => "protected_nodes",
        "field" => "nid",
      ),
    ),
    "filters" => array(
      "passwd" => array(
        "field" => "passwd",
        "name" => t("Protected: Only show nodes that"),
        'operator' => array(
          'IS NOT' => t('Are'),
          'IS' => t('Are Not'),
        ),
        'help' => t('Filter in/out nodes protected with passwords.'),
        'handler' => 'views_handler_filter_null',
        'value' => _protected_node_hidden_form(NULL, t('protected.')),
      ),
    ),
  );
  return $tables;
}