Commit 2d10ef5f authored by ccarigna's avatar ccarigna
Browse files

Removed location node from event feature

parent 1a001f5e
......@@ -1056,126 +1056,6 @@ function uw_ct_event_field_default_fields() {
),
);
// Exported field: 'node-uw_location-field_location_details'
$fields['node-uw_location-field_location_details'] = array(
'field_config' => array(
'active' => '1',
'cardinality' => '1',
'deleted' => '0',
'entity_types' => array(),
'field_name' => 'field_location_details',
'foreign keys' => array(),
'indexes' => array(
'lid' => array(
0 => 'lid',
),
),
'module' => 'location_cck',
'settings' => array(
'gmap_macro' => '[gmap ]',
'gmap_marker' => 'drupal',
'location_settings' => array(
'display' => array(
'hide' => array(
'additional' => 0,
'city' => 0,
'coords' => 'coords',
'country' => 0,
'country_name' => 0,
'locpick' => 'locpick',
'map_link' => 'map_link',
'name' => 0,
'postal_code' => 0,
'province' => 0,
'province_name' => 0,
'street' => 0,
),
),
'form' => array(
'fields' => array(
'additional' => array(
'collect' => '1',
'default' => '',
'weight' => '-99',
),
'city' => array(
'collect' => '1',
'default' => '',
'weight' => '-97',
),
'country' => array(
'collect' => '1',
'default' => 'ca',
'weight' => '-94',
),
'locpick' => array(
'collect' => '0',
'weight' => '-93',
),
'name' => array(
'collect' => '0',
'default' => '',
'weight' => '-100',
),
'postal_code' => array(
'collect' => '1',
'default' => '',
'weight' => '-95',
),
'province' => array(
'collect' => '1',
'default' => '',
'weight' => '-96',
),
'street' => array(
'collect' => '1',
'default' => '',
'weight' => '-98',
),
),
),
),
),
'translatable' => '0',
'type' => 'location',
),
'field_instance' => array(
'bundle' => 'uw_location',
'default_value' => NULL,
'deleted' => '0',
'description' => '',
'display' => array(
'default' => array(
'label' => 'above',
'module' => 'location_cck',
'settings' => array(),
'type' => 'location_default',
'weight' => 0,
),
'teaser' => array(
'label' => 'above',
'settings' => array(),
'type' => 'hidden',
'weight' => 0,
),
),
'entity_type' => 'node',
'field_name' => 'field_location_details',
'label' => 'Location Details',
'required' => 0,
'settings' => array(
'user_register_form' => FALSE,
),
'widget' => array(
'active' => 0,
'module' => 'location_cck',
'settings' => array(),
'type' => 'location',
'weight' => '1',
),
),
);
// Translatables
// Included for use with string extractors like potx.
t('Audience');
......@@ -1188,7 +1068,6 @@ function uw_ct_event_field_default_fields() {
t('Event website');
t('Host');
t('Location');
t('Location Details');
t('Location Lookup');
t('Map');
t('Optional: a link to a website with more information specific to this event.');
......
......@@ -45,14 +45,6 @@ function uw_ct_event_node_info() {
'title_label' => t('Event Title (required)'),
'help' => '',
),
'uw_location' => array(
'name' => t('Location'),
'base' => 'node_content',
'description' => t('Content type used to generate event locations and populate location details'),
'has_title' => '1',
'title_label' => t('Location Name (building and room number or venue, meeting point)'),
'help' => '',
),
);
return $items;
}
......
......@@ -39,13 +39,11 @@ features[field][] = "node-uw_event-field_event_map_link"
features[field][] = "node-uw_event-field_event_moreinfo_link"
features[field][] = "node-uw_event-field_file"
features[field][] = "node-uw_event-field_image"
features[field][] = "node-uw_location-field_location_details"
features[field_group][] = "group_links|node|uw_event|form"
features[field_group][] = "group_location|node|uw_event|form"
features[field_group][] = "group_upload_file|node|uw_event|form"
features[field_group][] = "group_upload|node|uw_event|form"
features[node][] = "uw_event"
features[node][] = "uw_location"
features[rdf_mappings][] = "node-uw_event"
features[user_permission][] = "create uw_event content"
features[user_permission][] = "delete any uw_event content"
......@@ -58,41 +56,27 @@ features[user_permission][] = "override uw_event published option"
features[user_permission][] = "override uw_event revision option"
features[user_permission][] = "override uw_event sticky option"
features[variable][] = "comment_anonymous_uw_event"
features[variable][] = "comment_anonymous_uw_location"
features[variable][] = "comment_default_mode_uw_event"
features[variable][] = "comment_default_mode_uw_location"
features[variable][] = "comment_default_per_page_uw_event"
features[variable][] = "comment_default_per_page_uw_location"
features[variable][] = "comment_form_location_uw_event"
features[variable][] = "comment_form_location_uw_location"
features[variable][] = "comment_preview_uw_event"
features[variable][] = "comment_preview_uw_location"
features[variable][] = "comment_subject_field_uw_event"
features[variable][] = "comment_subject_field_uw_location"
features[variable][] = "comment_uw_event"
features[variable][] = "comment_uw_location"
features[variable][] = "date_format_event_full"
features[variable][] = "date_format_event_short"
features[variable][] = "date_format_long_date_only"
features[variable][] = "date_format_time_only"
features[variable][] = "enable_revisions_page_uw_event"
features[variable][] = "enable_revisions_page_uw_location"
features[variable][] = "location_defaultnum_uw_event"
features[variable][] = "location_defaultnum_uw_location"
features[variable][] = "location_maxnum_uw_event"
features[variable][] = "location_maxnum_uw_location"
features[variable][] = "location_settings_node_uw_event"
features[variable][] = "location_settings_node_uw_location"
features[variable][] = "menu_options_uw_event"
features[variable][] = "menu_parent_uw_event"
features[variable][] = "node_options_uw_event"
features[variable][] = "node_options_uw_location"
features[variable][] = "node_preview_uw_event"
features[variable][] = "node_submitted_uw_event"
features[variable][] = "node_submitted_uw_location"
features[variable][] = "pathauto_node_uw_event_pattern"
features[variable][] = "publishcontent_uw_event"
features[variable][] = "publishcontent_uw_location"
features[variable][] = "rdf_rdftype_uw_event"
features[variable][] = "rdf_title_datatype_uw_event"
features[variable][] = "rdf_title_predicates_uw_event"
......
......@@ -70,24 +70,29 @@ function uw_ct_event_form_alter(&$form, &$form_state, $form_id) {
*/
function uw_ct_event_form_uw_event_node_form_alter(&$form, &$form_state, $form_id) {
/* Add javascript
$form['#attached']['js'] = array(
drupal_get_path('module', 'uw_ct_event') . '/js/location-ajax.js',
);
// */
// Remove the 'delete this location' checkbox on the edit form
$form['field_event_location']['und'][0]['#after_build'][] = 'uw_ct_event_remove_location_delete';
// Add Div Wrapper around form so the AJAX handler can replace the complete form within it
// Need to do this if we need to update more then one field which we do
$form['#prefix'] = '<div id="uw_new_event">';
$form['#suffix'] = '</div>';
$form['field_event_location']['#prefix'] = '<div id="uw_event_location">';
$form['field_event_location']['#suffix'] = '</div>';
// Have to set the AJAX callback parameter on the field language instance value
// Also see this issue for some extra insight: http://drupal.org/node/1024962
// Specifically on setting another form field value - as we need to below.
$form['field_event_location_lookup']['und']['#ajax'] = array(
// #ajax has two required keys: callback and wrapper.
// 'callback' is a function that will be called when this element changes.
'callback' => 'uw_ct_event_load_location_details',
// 'wrapper' is the HTML id of the page element that will be replaced.
'wrapper' => 'uw_new_event',
'method' => 'replaceWith',
'callback' => 'uw_ct_event_load_location_details', // 'callback' is a function that will be called when this element changes.
'wrapper' => 'uw_event_location', // 'wrapper' is the HTML id of the page element that will be replaced.
'method' => 'replace',
'effect' => 'fade',
);
// An AJAX request calls the form builder function for every change.
......@@ -119,6 +124,8 @@ function uw_ct_event_form_uw_event_node_form_alter(&$form, &$form_state, $form_i
}
$form['field_event_location']['und'][0]['#default_value']['locpick']['user_latitude'] = '49.001';
//dsm($form);
}
/* AJAX Callback function defined in uw_ct_contact_form_contact_node_form_alter
......@@ -127,7 +134,7 @@ function uw_ct_event_form_uw_event_node_form_alter(&$form, &$form_state, $form_i
function uw_ct_event_load_location_details($form, $form_state) {
// The form has already been submitted and updated. We can return the replaced
// item as it is.
return $form;
return $form['field_event_location'];
}
/**
......
......@@ -17,13 +17,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 0;
$export['comment_anonymous_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_anonymous_uw_location';
$strongarm->value = 0;
$export['comment_anonymous_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -31,13 +24,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 0;
$export['comment_default_mode_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_default_mode_uw_location';
$strongarm->value = 0;
$export['comment_default_mode_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -45,13 +31,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = '50';
$export['comment_default_per_page_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_default_per_page_uw_location';
$strongarm->value = '50';
$export['comment_default_per_page_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -59,13 +38,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 0;
$export['comment_form_location_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_form_location_uw_location';
$strongarm->value = 0;
$export['comment_form_location_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -73,13 +45,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = '0';
$export['comment_preview_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_preview_uw_location';
$strongarm->value = '0';
$export['comment_preview_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -87,13 +52,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 0;
$export['comment_subject_field_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_subject_field_uw_location';
$strongarm->value = 0;
$export['comment_subject_field_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -101,13 +59,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = '1';
$export['comment_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'comment_uw_location';
$strongarm->value = '1';
$export['comment_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -143,13 +94,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 1;
$export['enable_revisions_page_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'enable_revisions_page_uw_location';
$strongarm->value = 0;
$export['enable_revisions_page_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -157,13 +101,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = '1';
$export['location_defaultnum_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'location_defaultnum_uw_location';
$strongarm->value = '1';
$export['location_defaultnum_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -171,13 +108,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = '0';
$export['location_maxnum_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'location_maxnum_uw_location';
$strongarm->value = '0';
$export['location_maxnum_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -259,87 +189,6 @@ function uw_ct_event_strongarm() {
);
$export['location_settings_node_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'location_settings_node_uw_location';
$strongarm->value = array(
'multiple' => array(
'min' => '0',
'max' => '0',
'add' => '1',
),
'form' => array(
'weight' => '0',
'collapsible' => 1,
'collapsed' => 1,
'fields' => array(
'name' => array(
'collect' => '1',
'default' => '',
'weight' => '2',
),
'street' => array(
'collect' => '1',
'default' => '',
'weight' => '4',
),
'additional' => array(
'collect' => '1',
'default' => '',
'weight' => '6',
),
'city' => array(
'collect' => '0',
'default' => '',
'weight' => '8',
),
'province' => array(
'collect' => '0',
'default' => '',
'weight' => '10',
),
'postal_code' => array(
'collect' => '0',
'default' => '',
'weight' => '12',
),
'country' => array(
'collect' => '1',
'default' => 'ca',
'weight' => '14',
),
'locpick' => array(
'collect' => '1',
'weight' => '20',
),
),
),
'display' => array(
'weight' => '0',
'hide' => array(
'name' => 0,
'street' => 0,
'additional' => 0,
'city' => 0,
'province' => 0,
'postal_code' => 0,
'country' => 0,
'locpick' => 0,
'province_name' => 0,
'country_name' => 0,
'map_link' => 0,
'coords' => 0,
),
'teaser' => 1,
'full' => 1,
),
'rss' => array(
'mode' => 'simple',
),
);
$export['location_settings_node_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -365,15 +214,6 @@ function uw_ct_event_strongarm() {
);
$export['node_options_uw_event'] = $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_uw_location';
$strongarm->value = array(
0 => 'status',
);
$export['node_options_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -388,13 +228,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 0;
$export['node_submitted_uw_event'] = $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_uw_location';
$strongarm->value = 0;
$export['node_submitted_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......@@ -409,13 +242,6 @@ function uw_ct_event_strongarm() {
$strongarm->value = 1;
$export['publishcontent_uw_event'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
$strongarm->name = 'publishcontent_uw_location';
$strongarm->value = 0;
$export['publishcontent_uw_location'] = $strongarm;
$strongarm = new stdClass;
$strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */
$strongarm->api_version = 1;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment