/
vih_short_course_commerce.features.inc
78 lines (72 loc) · 1.91 KB
/
vih_short_course_commerce.features.inc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
<?php
/**
* @file
* vih_short_course_commerce.features.inc
*/
/**
* Implements hook_commerce_line_item_default_types().
*/
function vih_short_course_commerce_commerce_line_item_default_types() {
$items = array(
'vih_short_course' => array(
'name' => 'VIH Short Course',
'description' => 'A customizable product line item type.',
'product' => TRUE,
'add_form_submit_value' => 'Add product',
'base' => 'commerce_product_line_item',
),
);
// Translatables
// Included for use with string extractors like potx.
t('Add product');
return $items;
}
/**
* Implements hook_commerce_product_default_types().
*/
function vih_short_course_commerce_commerce_product_default_types() {
$items = array(
'vih_short_course_basic' => array(
'type' => 'vih_short_course_basic',
'name' => 'VIH Short Course Basic',
'description' => '',
'help' => '',
'revision' => 1,
),
);
return $items;
}
/**
* Implements hook_ctools_plugin_api().
*/
function vih_short_course_commerce_ctools_plugin_api($module = NULL, $api = NULL) {
if ($module == "page_manager" && $api == "pages_default") {
return array("version" => "1");
}
if ($module == "strongarm" && $api == "strongarm") {
return array("version" => "1");
}
}
/**
* Implements hook_views_api().
*/
function vih_short_course_commerce_views_api($module = NULL, $api = NULL) {
return array("api" => "3.0");
}
/**
* Implements hook_node_info().
*/
function vih_short_course_commerce_node_info() {
$items = array(
'short_course_basic' => array(
'name' => t('Short Course Basic'),
'base' => 'node_content',
'description' => t('Use <em>short course basic</em> for courses where you need info about room type and social security number.'),
'has_title' => '1',
'title_label' => t('Title'),
'help' => '',
),
);
drupal_alter('node_info', $items);
return $items;
}