116 lines
2.9 KiB
PHP
116 lines
2.9 KiB
PHP
<?php
|
|
/**
|
|
* @file
|
|
* admin.features.inc
|
|
*/
|
|
|
|
/**
|
|
* Implements hook_ctools_plugin_api().
|
|
*/
|
|
function admin_ctools_plugin_api($module = NULL, $api = NULL) {
|
|
if ($module == "strongarm" && $api == "strongarm") {
|
|
return array("version" => "1");
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Implements hook_views_api().
|
|
*/
|
|
function admin_views_api($module = NULL, $api = NULL) {
|
|
return array("api" => "3.0");
|
|
}
|
|
|
|
/**
|
|
* Implements hook_workflow_default_workflows().
|
|
*/
|
|
function admin_workflow_default_workflows() {
|
|
$workflows = array();
|
|
|
|
// Exported workflow: Publication
|
|
$workflows['Publication'] = array(
|
|
'name' => 'Publication',
|
|
'tab_roles' => 'author,3,4',
|
|
'options' => 'a:4:{s:16:"comment_log_node";s:1:"0";s:15:"comment_log_tab";s:1:"0";s:13:"name_as_title";s:1:"0";s:12:"watchdog_log";s:1:"0";}',
|
|
'states' => array(
|
|
0 => array(
|
|
'state' => '(creation)',
|
|
'weight' => -50,
|
|
'sysid' => 1,
|
|
'status' => 1,
|
|
'name' => 'Publication',
|
|
),
|
|
1 => array(
|
|
'state' => 'Brouillon',
|
|
'weight' => -20,
|
|
'sysid' => 0,
|
|
'status' => 1,
|
|
'name' => 'Publication',
|
|
),
|
|
2 => array(
|
|
'state' => 'En attente',
|
|
'weight' => -20,
|
|
'sysid' => 0,
|
|
'status' => 1,
|
|
'name' => 'Publication',
|
|
),
|
|
3 => array(
|
|
'state' => 'Publié',
|
|
'weight' => -20,
|
|
'sysid' => 0,
|
|
'status' => 1,
|
|
'name' => 'Publication',
|
|
),
|
|
),
|
|
'transitions' => array(
|
|
0 => array(
|
|
'roles' => 'workflow_features_author_name,administrator,root',
|
|
'state' => '(creation)',
|
|
'target_state' => 'Brouillon',
|
|
),
|
|
1 => array(
|
|
'roles' => 'administrator,root',
|
|
'state' => '(creation)',
|
|
'target_state' => 'En attente',
|
|
),
|
|
2 => array(
|
|
'roles' => 'administrator,root',
|
|
'state' => '(creation)',
|
|
'target_state' => 'Publié',
|
|
),
|
|
3 => array(
|
|
'roles' => 'workflow_features_author_name,administrator,root',
|
|
'state' => 'Brouillon',
|
|
'target_state' => 'En attente',
|
|
),
|
|
4 => array(
|
|
'roles' => 'workflow_features_author_name,administrator,root',
|
|
'state' => 'En attente',
|
|
'target_state' => 'Brouillon',
|
|
),
|
|
5 => array(
|
|
'roles' => 'workflow_features_author_name,administrator,root',
|
|
'state' => 'En attente',
|
|
'target_state' => 'Publié',
|
|
),
|
|
6 => array(
|
|
'roles' => 'workflow_features_author_name,administrator,root',
|
|
'state' => 'Publié',
|
|
'target_state' => 'Brouillon',
|
|
),
|
|
7 => array(
|
|
'roles' => 'workflow_features_author_name,administrator,root',
|
|
'state' => 'Publié',
|
|
'target_state' => 'En attente',
|
|
),
|
|
),
|
|
'node_types' => array(
|
|
0 => 'documentair',
|
|
1 => 'episode',
|
|
2 => 'page',
|
|
3 => 'thematique',
|
|
),
|
|
);
|
|
|
|
return $workflows;
|
|
}
|