first import
This commit is contained in:
@@ -0,0 +1,151 @@
|
||||
<?php
|
||||
/**
|
||||
* @file
|
||||
* popsu_position_ville.features.field.inc
|
||||
*/
|
||||
|
||||
/**
|
||||
* Implements hook_field_default_fields().
|
||||
*/
|
||||
function popsu_position_ville_field_default_fields() {
|
||||
$fields = array();
|
||||
|
||||
// Exported field: 'node-popsu_point_ville-field_popsu_positionville_x'.
|
||||
$fields['node-popsu_point_ville-field_popsu_positionville_x'] = array(
|
||||
'field_config' => array(
|
||||
'active' => '1',
|
||||
'cardinality' => '1',
|
||||
'deleted' => '0',
|
||||
'entity_types' => array(),
|
||||
'field_name' => 'field_popsu_positionville_x',
|
||||
'foreign keys' => array(),
|
||||
'indexes' => array(),
|
||||
'locked' => '0',
|
||||
'module' => 'number',
|
||||
'settings' => array(),
|
||||
'translatable' => '0',
|
||||
'type' => 'number_integer',
|
||||
),
|
||||
'field_instance' => array(
|
||||
'bundle' => 'popsu_point_ville',
|
||||
'default_value' => array(
|
||||
0 => array(
|
||||
'value' => '0',
|
||||
),
|
||||
),
|
||||
'deleted' => '0',
|
||||
'description' => '',
|
||||
'display' => array(
|
||||
'default' => array(
|
||||
'label' => 'above',
|
||||
'module' => 'number',
|
||||
'settings' => array(
|
||||
'decimal_separator' => '.',
|
||||
'prefix_suffix' => TRUE,
|
||||
'scale' => 0,
|
||||
'thousand_separator' => ' ',
|
||||
),
|
||||
'type' => 'number_integer',
|
||||
'weight' => 3,
|
||||
),
|
||||
'teaser' => array(
|
||||
'label' => 'above',
|
||||
'settings' => array(),
|
||||
'type' => 'hidden',
|
||||
'weight' => 0,
|
||||
),
|
||||
),
|
||||
'entity_type' => 'node',
|
||||
'field_name' => 'field_popsu_positionville_x',
|
||||
'label' => 'Position X',
|
||||
'required' => 0,
|
||||
'settings' => array(
|
||||
'max' => '',
|
||||
'min' => '',
|
||||
'prefix' => '',
|
||||
'suffix' => '',
|
||||
'user_register_form' => FALSE,
|
||||
),
|
||||
'widget' => array(
|
||||
'active' => 0,
|
||||
'module' => 'number',
|
||||
'settings' => array(),
|
||||
'type' => 'number',
|
||||
'weight' => '4',
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
// Exported field: 'node-popsu_point_ville-field_popsu_positionville_y'.
|
||||
$fields['node-popsu_point_ville-field_popsu_positionville_y'] = array(
|
||||
'field_config' => array(
|
||||
'active' => '1',
|
||||
'cardinality' => '1',
|
||||
'deleted' => '0',
|
||||
'entity_types' => array(),
|
||||
'field_name' => 'field_popsu_positionville_y',
|
||||
'foreign keys' => array(),
|
||||
'indexes' => array(),
|
||||
'locked' => '0',
|
||||
'module' => 'number',
|
||||
'settings' => array(),
|
||||
'translatable' => '0',
|
||||
'type' => 'number_integer',
|
||||
),
|
||||
'field_instance' => array(
|
||||
'bundle' => 'popsu_point_ville',
|
||||
'default_value' => array(
|
||||
0 => array(
|
||||
'value' => '0',
|
||||
),
|
||||
),
|
||||
'deleted' => '0',
|
||||
'description' => '',
|
||||
'display' => array(
|
||||
'default' => array(
|
||||
'label' => 'above',
|
||||
'module' => 'number',
|
||||
'settings' => array(
|
||||
'decimal_separator' => '.',
|
||||
'prefix_suffix' => TRUE,
|
||||
'scale' => 0,
|
||||
'thousand_separator' => ' ',
|
||||
),
|
||||
'type' => 'number_integer',
|
||||
'weight' => 4,
|
||||
),
|
||||
'teaser' => array(
|
||||
'label' => 'above',
|
||||
'settings' => array(),
|
||||
'type' => 'hidden',
|
||||
'weight' => 0,
|
||||
),
|
||||
),
|
||||
'entity_type' => 'node',
|
||||
'field_name' => 'field_popsu_positionville_y',
|
||||
'label' => 'Position Y',
|
||||
'required' => 0,
|
||||
'settings' => array(
|
||||
'max' => '',
|
||||
'min' => '',
|
||||
'prefix' => '',
|
||||
'suffix' => '',
|
||||
'user_register_form' => FALSE,
|
||||
),
|
||||
'widget' => array(
|
||||
'active' => 0,
|
||||
'module' => 'number',
|
||||
'settings' => array(),
|
||||
'type' => 'number',
|
||||
'weight' => '5',
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
// Translatables
|
||||
// Included for use with string extractors like potx.
|
||||
t('Position X');
|
||||
t('Position Y');
|
||||
|
||||
return $fields;
|
||||
}
|
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
/**
|
||||
* @file
|
||||
* popsu_position_ville.features.inc
|
||||
*/
|
||||
|
||||
/**
|
||||
* Implements hook_ctools_plugin_api().
|
||||
*/
|
||||
function popsu_position_ville_ctools_plugin_api() {
|
||||
list($module, $api) = func_get_args();
|
||||
if ($module == "field_group" && $api == "field_group") {
|
||||
return array("version" => "1");
|
||||
}
|
||||
list($module, $api) = func_get_args();
|
||||
if ($module == "strongarm" && $api == "strongarm") {
|
||||
return array("version" => "1");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements hook_views_api().
|
||||
*/
|
||||
function popsu_position_ville_views_api() {
|
||||
return array("version" => "3.0");
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements hook_node_info().
|
||||
*/
|
||||
function popsu_position_ville_node_info() {
|
||||
$items = array(
|
||||
'popsu_point_ville' => array(
|
||||
'name' => t('Position Ville'),
|
||||
'base' => 'node_content',
|
||||
'description' => t('Ce type de contenu permet de placer une ville sur la carte de la page d\'accueil'),
|
||||
'has_title' => '1',
|
||||
'title_label' => t('Nom de la ville'),
|
||||
'help' => '',
|
||||
),
|
||||
);
|
||||
return $items;
|
||||
}
|
@@ -0,0 +1,72 @@
|
||||
<?php
|
||||
/**
|
||||
* @file
|
||||
* popsu_position_ville.field_group.inc
|
||||
*/
|
||||
|
||||
/**
|
||||
* Implements hook_field_group_info().
|
||||
*/
|
||||
function popsu_position_ville_field_group_info() {
|
||||
$export = array();
|
||||
|
||||
$field_group = new stdClass();
|
||||
$field_group->disabled = FALSE; /* Edit this to true to make a default field_group disabled initially */
|
||||
$field_group->api_version = 1;
|
||||
$field_group->identifier = 'group_popsu_positionville_basic|node|popsu_point_ville|form';
|
||||
$field_group->group_name = 'group_popsu_positionville_basic';
|
||||
$field_group->entity_type = 'node';
|
||||
$field_group->bundle = 'popsu_point_ville';
|
||||
$field_group->mode = 'form';
|
||||
$field_group->parent_name = '';
|
||||
$field_group->data = array(
|
||||
'label' => 'Informations essentielles',
|
||||
'weight' => '0',
|
||||
'children' => array(
|
||||
0 => 'field_popsu_positionville_ville',
|
||||
1 => 'field_popsu_positionville_popsu',
|
||||
2 => 'title',
|
||||
),
|
||||
'format_type' => 'tab',
|
||||
'format_settings' => array(
|
||||
'formatter' => 'closed',
|
||||
'instance_settings' => array(
|
||||
'description' => '',
|
||||
'classes' => '',
|
||||
'required_fields' => 1,
|
||||
),
|
||||
),
|
||||
);
|
||||
$export['group_popsu_positionville_basic|node|popsu_point_ville|form'] = $field_group;
|
||||
|
||||
$field_group = new stdClass();
|
||||
$field_group->disabled = FALSE; /* Edit this to true to make a default field_group disabled initially */
|
||||
$field_group->api_version = 1;
|
||||
$field_group->identifier = 'group_popsu_positionville_posi|node|popsu_point_ville|form';
|
||||
$field_group->group_name = 'group_popsu_positionville_posi';
|
||||
$field_group->entity_type = 'node';
|
||||
$field_group->bundle = 'popsu_point_ville';
|
||||
$field_group->mode = 'form';
|
||||
$field_group->parent_name = '';
|
||||
$field_group->data = array(
|
||||
'label' => 'Position sur la carte',
|
||||
'weight' => '2',
|
||||
'children' => array(
|
||||
0 => 'field_popsu_positionville_x',
|
||||
1 => 'field_popsu_positionville_y',
|
||||
2 => 'field_popsu_positionville_out',
|
||||
),
|
||||
'format_type' => 'tab',
|
||||
'format_settings' => array(
|
||||
'formatter' => 'closed',
|
||||
'instance_settings' => array(
|
||||
'description' => '',
|
||||
'classes' => '',
|
||||
'required_fields' => 1,
|
||||
),
|
||||
),
|
||||
);
|
||||
$export['group_popsu_positionville_posi|node|popsu_point_ville|form'] = $field_group;
|
||||
|
||||
return $export;
|
||||
}
|
@@ -0,0 +1,28 @@
|
||||
name = POPSU Position Ville
|
||||
description = POPSU - Type de contenu Position d'une ville sur la carte
|
||||
core = 7.x
|
||||
package = POPSU
|
||||
version = 7.x-1.0-beta9
|
||||
project = popsu_position_ville
|
||||
dependencies[] = field_group
|
||||
dependencies[] = number
|
||||
dependencies[] = popsu_taxonomies
|
||||
dependencies[] = strongarm
|
||||
dependencies[] = views
|
||||
features[ctools][] = field_group:field_group:1
|
||||
features[ctools][] = strongarm:strongarm:1
|
||||
features[ctools][] = views:views_default:3.0
|
||||
features[features_api][] = api:1
|
||||
features[field][] = node-popsu_point_ville-field_popsu_positionville_x
|
||||
features[field][] = node-popsu_point_ville-field_popsu_positionville_y
|
||||
features[field_group][] = group_popsu_positionville_basic|node|popsu_point_ville|form
|
||||
features[field_group][] = group_popsu_positionville_posi|node|popsu_point_ville|form
|
||||
features[node][] = popsu_point_ville
|
||||
features[variable][] = field_bundle_settings_node__popsu_point_ville
|
||||
features[variable][] = language_content_type_popsu_point_ville
|
||||
features[variable][] = menu_options_popsu_point_ville
|
||||
features[variable][] = menu_parent_popsu_point_ville
|
||||
features[variable][] = node_options_popsu_point_ville
|
||||
features[variable][] = node_preview_popsu_point_ville
|
||||
features[variable][] = node_submitted_popsu_point_ville
|
||||
features[views_view][] = points_villes
|
@@ -0,0 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* @file
|
||||
* Code for the POPSU Position Ville feature.
|
||||
*/
|
||||
|
||||
include_once 'popsu_position_ville.features.inc';
|
@@ -0,0 +1,79 @@
|
||||
<?php
|
||||
/**
|
||||
* @file
|
||||
* popsu_position_ville.strongarm.inc
|
||||
*/
|
||||
|
||||
/**
|
||||
* Implements hook_strongarm().
|
||||
*/
|
||||
function popsu_position_ville_strongarm() {
|
||||
$export = array();
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'field_bundle_settings_node__popsu_point_ville';
|
||||
$strongarm->value = array(
|
||||
'view_modes' => array(),
|
||||
'extra_fields' => array(
|
||||
'form' => array(
|
||||
'title' => array(
|
||||
'weight' => '1',
|
||||
),
|
||||
'path' => array(
|
||||
'weight' => '3',
|
||||
),
|
||||
),
|
||||
'display' => array(),
|
||||
),
|
||||
);
|
||||
$export['field_bundle_settings_node__popsu_point_ville'] = $strongarm;
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'language_content_type_popsu_point_ville';
|
||||
$strongarm->value = '0';
|
||||
$export['language_content_type_popsu_point_ville'] = $strongarm;
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'menu_options_popsu_point_ville';
|
||||
$strongarm->value = array();
|
||||
$export['menu_options_popsu_point_ville'] = $strongarm;
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'menu_parent_popsu_point_ville';
|
||||
$strongarm->value = 'main-menu:0';
|
||||
$export['menu_parent_popsu_point_ville'] = $strongarm;
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'node_options_popsu_point_ville';
|
||||
$strongarm->value = array(
|
||||
0 => 'status',
|
||||
1 => 'revision',
|
||||
);
|
||||
$export['node_options_popsu_point_ville'] = $strongarm;
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'node_preview_popsu_point_ville';
|
||||
$strongarm->value = '0';
|
||||
$export['node_preview_popsu_point_ville'] = $strongarm;
|
||||
|
||||
$strongarm = new stdClass();
|
||||
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
|
||||
$strongarm->api_version = 1;
|
||||
$strongarm->name = 'node_submitted_popsu_point_ville';
|
||||
$strongarm->value = 0;
|
||||
$export['node_submitted_popsu_point_ville'] = $strongarm;
|
||||
|
||||
return $export;
|
||||
}
|
@@ -0,0 +1,105 @@
|
||||
<?php
|
||||
/**
|
||||
* @file
|
||||
* popsu_position_ville.views_default.inc
|
||||
*/
|
||||
|
||||
/**
|
||||
* Implements hook_views_default_views().
|
||||
*/
|
||||
function popsu_position_ville_views_default_views() {
|
||||
$export = array();
|
||||
|
||||
$view = new view();
|
||||
$view->name = 'points_villes';
|
||||
$view->description = 'Liste des points à afficher sur la carte de la page d\'accueil';
|
||||
$view->tag = 'POPSU';
|
||||
$view->base_table = 'node';
|
||||
$view->human_name = 'Points Villes';
|
||||
$view->core = 7;
|
||||
$view->api_version = '3.0';
|
||||
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
|
||||
|
||||
/* Display: Master */
|
||||
$handler = $view->new_display('default', 'Master', 'default');
|
||||
$handler->display->display_options['css_class'] = 'map-home';
|
||||
$handler->display->display_options['use_more_always'] = FALSE;
|
||||
$handler->display->display_options['use_more_text'] = 'plus';
|
||||
$handler->display->display_options['access']['type'] = 'perm';
|
||||
$handler->display->display_options['cache']['type'] = 'none';
|
||||
$handler->display->display_options['query']['type'] = 'views_query';
|
||||
$handler->display->display_options['query']['options']['distinct'] = TRUE;
|
||||
$handler->display->display_options['exposed_form']['type'] = 'basic';
|
||||
$handler->display->display_options['exposed_form']['options']['submit_button'] = 'Appliquer';
|
||||
$handler->display->display_options['exposed_form']['options']['reset_button_label'] = 'Réinitialiser';
|
||||
$handler->display->display_options['exposed_form']['options']['exposed_sorts_label'] = 'Trier par';
|
||||
$handler->display->display_options['pager']['type'] = 'none';
|
||||
$handler->display->display_options['pager']['options']['offset'] = '0';
|
||||
$handler->display->display_options['style_plugin'] = 'default';
|
||||
$handler->display->display_options['style_options']['row_class'] = 'point-carte';
|
||||
$handler->display->display_options['row_plugin'] = 'fields';
|
||||
/* Champ: Contenu : Nid */
|
||||
$handler->display->display_options['fields']['nid']['id'] = 'nid';
|
||||
$handler->display->display_options['fields']['nid']['table'] = 'node';
|
||||
$handler->display->display_options['fields']['nid']['field'] = 'nid';
|
||||
$handler->display->display_options['fields']['nid']['label'] = '';
|
||||
$handler->display->display_options['fields']['nid']['exclude'] = TRUE;
|
||||
$handler->display->display_options['fields']['nid']['element_label_colon'] = FALSE;
|
||||
/* Champ: Contenu : POPSU */
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['id'] = 'field_popsu_positionville_popsu';
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['table'] = 'field_data_field_popsu_positionville_popsu';
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['field'] = 'field_popsu_positionville_popsu';
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['label'] = '';
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['exclude'] = TRUE;
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['element_label_colon'] = FALSE;
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['type'] = 'taxonomy_term_reference_plain';
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['delta_offset'] = '0';
|
||||
$handler->display->display_options['fields']['field_popsu_positionville_popsu']['separator'] = ' ';
|
||||
/* Champ: Contenu : Titre */
|
||||
$handler->display->display_options['fields']['title']['id'] = 'title';
|
||||
$handler->display->display_options['fields']['title']['table'] = 'node';
|
||||
$handler->display->display_options['fields']['title']['field'] = 'title';
|
||||
$handler->display->display_options['fields']['title']['label'] = '';
|
||||
$handler->display->display_options['fields']['title']['alter']['alter_text'] = TRUE;
|
||||
$handler->display->display_options['fields']['title']['alter']['text'] = '<div id="point-nid-[nid]" class="placement-carte [field_popsu_positionville_popsu]"><span class="map-title">[title]</span></div>';
|
||||
$handler->display->display_options['fields']['title']['alter']['word_boundary'] = FALSE;
|
||||
$handler->display->display_options['fields']['title']['alter']['ellipsis'] = FALSE;
|
||||
$handler->display->display_options['fields']['title']['element_label_colon'] = FALSE;
|
||||
$handler->display->display_options['fields']['title']['link_to_node'] = FALSE;
|
||||
/* Critère de tri: Contenu : Titre */
|
||||
$handler->display->display_options['sorts']['title']['id'] = 'title';
|
||||
$handler->display->display_options['sorts']['title']['table'] = 'node';
|
||||
$handler->display->display_options['sorts']['title']['field'] = 'title';
|
||||
/* Critère de filtrage: Contenu : Publié */
|
||||
$handler->display->display_options['filters']['status']['id'] = 'status';
|
||||
$handler->display->display_options['filters']['status']['table'] = 'node';
|
||||
$handler->display->display_options['filters']['status']['field'] = 'status';
|
||||
$handler->display->display_options['filters']['status']['value'] = 1;
|
||||
$handler->display->display_options['filters']['status']['group'] = 1;
|
||||
$handler->display->display_options['filters']['status']['expose']['operator'] = FALSE;
|
||||
/* Critère de filtrage: Contenu : Type */
|
||||
$handler->display->display_options['filters']['type']['id'] = 'type';
|
||||
$handler->display->display_options['filters']['type']['table'] = 'node';
|
||||
$handler->display->display_options['filters']['type']['field'] = 'type';
|
||||
$handler->display->display_options['filters']['type']['value'] = array(
|
||||
'popsu_point_ville' => 'popsu_point_ville',
|
||||
);
|
||||
|
||||
/* Display: POPSU Points villes pour la carte */
|
||||
$handler = $view->new_display('block', 'POPSU Points villes pour la carte', 'block_1');
|
||||
$handler->display->display_options['defaults']['hide_admin_links'] = FALSE;
|
||||
$translatables['points_villes'] = array(
|
||||
t('Master'),
|
||||
t('plus'),
|
||||
t('Appliquer'),
|
||||
t('Réinitialiser'),
|
||||
t('Trier par'),
|
||||
t('Asc'),
|
||||
t('Desc'),
|
||||
t('<div id="point-nid-[nid]" class="placement-carte [field_popsu_positionville_popsu]"><span class="map-title">[title]</span></div>'),
|
||||
t('POPSU Points villes pour la carte'),
|
||||
);
|
||||
$export['points_villes'] = $view;
|
||||
|
||||
return $export;
|
||||
}
|
Reference in New Issue
Block a user