function _add_bundles in Bibliography Module 7.2
1 call to _add_bundles()
- biblio_install in ./
biblio.install - Implements hook_install().
File
- ./
biblio.install, line 1132
Code
function _add_bundles() {
// _biblio_add_field('Publication Types');
$types[] = array(
'Book',
NULL,
1,
'biblio',
);
$types[] = array(
'Book Chapter',
NULL,
2,
'biblio',
);
$types[] = array(
'Journal Article',
'Written work published in a print or Internet medium',
3,
'biblio',
);
$types[] = array(
'Journal',
NULL,
3,
'biblio',
);
$types[] = array(
'Conference Paper',
NULL,
4,
'biblio',
);
$types[] = array(
'Conference Proceedings',
NULL,
5,
'biblio',
);
$types[] = array(
'Newspaper Article',
NULL,
6,
'biblio',
);
$types[] = array(
'Magazine Article',
NULL,
7,
'biblio',
);
$types[] = array(
'Web Article',
NULL,
8,
'biblio',
);
$types[] = array(
'Website',
NULL,
8,
'biblio',
);
$types[] = array(
'Web service',
NULL,
8,
'biblio',
);
$types[] = array(
'Web project page',
NULL,
8,
'biblio',
);
$types[] = array(
'Thesis',
NULL,
9,
'biblio',
);
$types[] = array(
'Report',
NULL,
10,
'biblio',
);
$types[] = array(
'Film',
NULL,
11,
'biblio',
);
$types[] = array(
'Broadcast',
NULL,
12,
'biblio',
);
$types[] = array(
'Artwork',
NULL,
13,
'biblio',
);
$types[] = array(
'Software',
NULL,
14,
'biblio',
);
$types[] = array(
'Audiovisual',
NULL,
15,
'biblio',
);
$types[] = array(
'Hearing',
NULL,
16,
'biblio',
);
$types[] = array(
'Case',
NULL,
17,
'biblio',
);
$types[] = array(
'Bill',
NULL,
18,
'biblio',
);
$types[] = array(
'Statute',
NULL,
19,
'biblio',
);
$types[] = array(
'Patent',
NULL,
20,
'biblio',
);
$types[] = array(
'Personal',
NULL,
21,
'biblio',
);
$types[] = array(
'Manuscript',
NULL,
22,
'biblio',
);
$types[] = array(
'Map',
NULL,
23,
'biblio',
);
$types[] = array(
'Chart',
NULL,
24,
'biblio',
);
$types[] = array(
'Unpublished',
NULL,
25,
'biblio',
);
$types[] = array(
'Database',
NULL,
26,
'biblio',
);
$types[] = array(
'Government Report',
NULL,
27,
'biblio',
);
$types[] = array(
'Classical',
NULL,
28,
'biblio',
);
$types[] = array(
'Legal Ruling',
NULL,
29,
'biblio',
);
$types[] = array(
'Miscellaneous',
NULL,
30,
'biblio',
);
$types[] = array(
'Miscellaneous Section',
NULL,
31,
'biblio',
);
$types[] = array(
'Presentation',
NULL,
8,
'biblio',
);
$types[] = array(
'Person',
'Human author or editor',
1,
'biblio_contributor',
);
$types[] = array(
'Organization',
'Contributor represented as an institution, corportation, or other organization',
1,
'biblio_contributor',
);
foreach ($types as $record) {
// $result[] = update_sql("INSERT INTO {biblio_types} (tid, name, description, weight) VALUES ('" . implode("', '", $record) . "')");
$query = db_insert('biblio_types')
->fields(array(
'tid' => NULL,
'name' => $record[0],
'description' => $record[1],
'weight' => $record[2],
'entity' => $record[3],
));
$query
->execute();
}
return;
}