From c2acc715004320c7309f0bf0645a70a36239b7e1 Mon Sep 17 00:00:00 2001 From: Marton Kiss Date: Tue, 24 Mar 2015 16:05:07 +0100 Subject: [PATCH] Upgrade Drupal Commons to 7.x-3.23 Apply the security fixes including: - Drupal Core - Moderately Critical - Multiple Vulnerabilities - SA-CORE-2015-001 - SA-CONTRIB-2015-079 - Chaos tool suite (ctools) - Multiple vulnerabilities The following patches were applied to 7.x-3.23 commons modules: - patches/0001-utility-links-block-install-theme.patch - patches/0002-events-page-refactor-to-pages-module.patch Installation profile got a refactor of module installation, as groups_ modules and l10n_updates deployed from an installation task to avoid memory exhausted errors of the installation process. Change-Id: I48481657124fdbbee84e1cbfec3a3a2b5f475c2c --- drupal-org-core.make | 4 +- drupal-org.make | 212 ++++++++---------- groups.info | 18 -- groups.install_callbacks.inc | 16 ++ groups.profile | 80 +++++++ .../commons_activity_page.info | 12 +- .../commons_activity_streams.features.inc | 18 +- .../commons_activity_streams.info | 12 +- .../commons_activity_streams.install | 11 + .../commons_activity_streams.module | 40 ++-- .../commons_activity_streams_groups.info | 12 +- .../commons_body.features.field_base.inc | 8 - .../commons/commons_body/commons_body.info | 12 +- .../commons_bw.features.field_base.inc | 8 - .../commons_bw.features.field_instance.inc | 6 +- modules/commons/commons_bw/commons_bw.info | 17 +- modules/commons/commons_bw/commons_bw.install | 11 + modules/commons/commons_bw/commons_bw.module | 44 +++- .../commons_content_moderation.info | 15 +- .../commons_documents.commons.inc | 20 ++ .../commons_documents.features.field_base.inc | 8 - ...mons_documents.features.field_instance.inc | 12 +- .../commons_documents/commons_documents.info | 18 +- .../commons_documents.install | 20 +- .../commons_events.features.field_base.inc | 36 --- ...commons_events.features.field_instance.inc | 6 +- .../commons_events.features.menu_links.inc | 37 --- .../commons_events/commons_events.info | 37 +-- .../commons_events/commons_events.install | 34 +++ .../commons_events/commons_events.module | 24 +- .../commons_events.strongarm.inc | 34 +++ .../commons_events.views_default.inc | 62 ----- .../includes/commons_events.forms.inc | 9 +- .../commons_events_pages.info | 12 +- .../commons_events_pages.pages_default.inc | 17 +- .../commons_events_solr.info | 14 +- .../commons_featured/commons_featured.info | 10 +- .../commons_follow.features.field_base.inc | 24 -- .../commons_follow.features.inc | 36 --- .../commons_follow/commons_follow.info | 15 +- .../commons_follow/commons_follow.module | 67 ++++++ .../commons_follow_group.info | 12 +- .../commons_follow_node.info | 15 +- .../commons_follow_term.info | 15 +- .../commons_follow_term.install | 12 + .../commons_follow_term.views_default.inc | 1 + .../commons_follow_ui/commons_follow_ui.info | 13 +- .../commons_follow_user.features.inc | 6 +- .../commons_follow_user.info | 18 +- .../commons_follow_user.install | 13 +- .../commons_follow_user.module | 28 +-- .../commons_follow_user.strongarm.inc | 48 ++++ .../commons_groups.features.field_base.inc | 30 --- .../commons_groups.features.inc | 16 -- .../commons_groups/commons_groups.info | 29 +-- .../commons_groups/commons_groups.install | 33 +++ .../commons_groups/commons_groups.module | 70 +++++- .../commons_groups.views_default.inc | 18 +- .../commons_groups_directory.info | 12 +- .../commons_groups_pages.info | 17 +- .../commons_groups_pages.panelizer.inc | 30 +++ .../commons_images/commons_images.info | 13 +- .../commons_kissmetrics.info | 10 +- .../commons_like/commons_like.features.inc | 10 - .../commons/commons_like/commons_like.info | 14 +- .../commons_like/commons_like.strongarm.inc | 34 +++ .../commons_location.features.field_base.inc | 1 - .../commons_location/commons_location.info | 12 +- ...ia.default_entity_embed_configurations.inc | 25 +++ .../commons_media.features.field_base.inc | 8 - .../commons_media.features.field_instance.inc | 19 +- .../commons_media/commons_media.features.inc | 3 + .../commons/commons_media/commons_media.info | 10 +- .../commons_media/commons_media.install | 11 + .../commons_media/commons_media.module | 117 ++++++++-- .../commons/commons_misc/commons_misc.info | 14 +- .../commons/commons_misc/commons_misc.install | 12 + .../commons/commons_misc/commons_misc.module | 39 +--- .../commons_misc/commons_misc.navbar.inc | 33 +++ .../commons_misc/commons_misc.strongarm.inc | 153 +------------ ...ommons_notices.features.field_instance.inc | 6 +- .../commons_notices/commons_notices.info | 14 +- .../commons_notify.features.field_base.inc | 17 -- .../commons_notify/commons_notify.info | 12 +- .../commons_notify/commons_notify.module | 4 +- .../commons_pages.features.field_instance.inc | 6 +- .../commons/commons_pages/commons_pages.info | 12 +- .../commons_pages/commons_pages.module | 14 -- .../commons_polls.features.field_instance.inc | 6 +- .../commons/commons_polls/commons_polls.info | 12 +- .../commons_polls/commons_polls.install | 11 + .../commons_polls/commons_polls.module | 15 -- .../commons_posts.features.field_instance.inc | 6 +- .../commons_posts/commons_posts.features.inc | 9 +- .../commons/commons_posts/commons_posts.info | 16 +- .../commons_posts/commons_posts.install | 22 ++ .../commons_posts/commons_posts.module | 21 +- ...mmons_profile_base.features.field_base.inc | 24 -- .../commons_profile_base.info | 12 +- ...ons_profile_social.features.field_base.inc | 3 - ...profile_social.features.field_instance.inc | 3 + .../commons_profile_social.info | 17 +- .../commons_q_a.features.field_base.inc | 8 - .../commons_q_a.features.field_instance.inc | 12 +- .../commons_q_a/commons_q_a.features.inc | 12 +- modules/commons/commons_q_a/commons_q_a.info | 18 +- .../commons/commons_q_a/commons_q_a.install | 33 +++ .../commons/commons_q_a/commons_q_a.module | 10 +- .../commons_q_a_pages/commons_q_a_pages.info | 12 +- ...mons_radioactivity.features.field_base.inc | 1 - .../commons_radioactivity.info | 12 +- .../commons_radioactivity.module | 2 +- .../commons_radioactivity_groups.info | 12 +- .../commons_radioactivity_groups.module | 78 +++---- .../commons_search.features.menu_links.inc | 36 --- .../commons_search/commons_search.info | 17 +- .../commons_search/commons_search.module | 12 + .../commons_search/css/commons_search.css | 3 - .../commons_search_core.info | 18 +- .../commons_search_core.strongarm.inc | 53 +++-- .../commons_search_solr.info | 17 +- .../commons_search_solr.strongarm.inc | 47 ++-- .../commons_search_solr_user.info | 17 +- .../commons_site_homepage.info | 13 +- .../commons_social_sharing.info | 12 +- .../commons_topics.features.field_base.inc | 8 - .../commons_topics/commons_topics.info | 11 +- ...s_trusted_contacts.features.field_base.inc | 51 ----- .../commons_trusted_contacts.info | 14 +- .../commons_trusted_contacts.module | 2 +- .../commons_user_profile_pages.info | 12 +- .../commons_utility_links.info | 14 +- .../commons_wikis.features.field_instance.inc | 12 +- .../commons/commons_wikis/commons_wikis.info | 24 +- .../commons_wikis/commons_wikis.install | 11 + .../commons_wikis/commons_wikis.module | 14 -- .../commons_wikis_pages.info | 12 +- ...mons_wysiwyg.features.ckeditor_profile.inc | 16 ++ .../commons_wysiwyg/commons_wysiwyg.info | 18 +- .../commons_wysiwyg/commons_wysiwyg.install | 11 + .../commons_wysiwyg/commons_wysiwyg.module | 46 +++- ...01-utility-links-block-install-theme.patch | 31 ++- ...events-page-refactor-to-pages-module.patch | 68 ++++-- 143 files changed, 1735 insertions(+), 1439 deletions(-) create mode 100644 groups.install_callbacks.inc delete mode 100644 modules/commons/commons_events/commons_events.features.menu_links.inc create mode 100644 modules/commons/commons_follow/commons_follow_user/commons_follow_user.strongarm.inc create mode 100644 modules/commons/commons_media/commons_media.default_entity_embed_configurations.inc create mode 100644 modules/commons/commons_misc/commons_misc.navbar.inc delete mode 100644 modules/commons/commons_search/commons_search.features.menu_links.inc delete mode 100644 modules/commons/commons_search/css/commons_search.css diff --git a/drupal-org-core.make b/drupal-org-core.make index cb67b12..0138345 100644 --- a/drupal-org-core.make +++ b/drupal-org-core.make @@ -3,9 +3,9 @@ core = 7.x ; Download Drupal core and apply core patches if needed. projects[drupal][type] = "core" -projects[drupal][version] = "7.34" +projects[drupal][version] = "7.35" projects[drupal][download][type] = get -projects[drupal][download][url] = http://ftp.drupal.org/files/projects/drupal-7.34.tar.gz +projects[drupal][download][url] = http://ftp.drupal.org/files/projects/drupal-7.35.tar.gz ; This patch allows install profile to list requirements on the install page ; http://drupal.org/node/1971072 diff --git a/drupal-org.make b/drupal-org.make index b7cc961..4fcf1fc 100644 --- a/drupal-org.make +++ b/drupal-org.make @@ -5,7 +5,7 @@ core = 7.x projects[addressfield][type] = "module" projects[addressfield][subdir] = "contrib" -projects[addressfield][version] = "1.0-beta5" +projects[addressfield][version] = "1.0" projects[addressfield_tokens][type] = "module" projects[addressfield_tokens][subdir] = "contrib" @@ -20,7 +20,7 @@ projects[admin_icons][download][revision] = "60d9f28801533fecc92216a60d444d89d80 projects[apachesolr][type] = "module" projects[apachesolr][subdir] = "contrib" -projects[apachesolr][version] = "1.6" +projects[apachesolr][version] = "1.7" projects[apachesolr_og][type] = "module" projects[apachesolr_og][subdir] = "contrib" @@ -50,10 +50,7 @@ projects[apachesolr_user][patch][] = "http://drupal.org/files/2077281-apache-sol projects[breakpoints][type] = "module" projects[breakpoints][subdir] = "contrib" -projects[breakpoints][download][type] = "git" -projects[breakpoints][download][url] = "http://git.drupal.org/project/breakpoints.git" -projects[breakpoints][download][branch] = "7.x-1.x" -projects[breakpoints][download][revision] = "c4f3665" +projects[breakpoints][version] = "1.3" projects[connector][type] = "module" projects[connector][subdir] = "contrib" @@ -61,37 +58,19 @@ projects[connector][version] = "1.0-beta2" projects[ckeditor][type] = "module" projects[ckeditor][subdir] = "contrib" -projects[ckeditor][download][type] = "git" -projects[ckeditor][download][url] = "http://git.drupal.org/project/ckeditor.git" -projects[ckeditor][download][branch] = "7.x-1.x" -projects[ckeditor][download][revision] = "b69a9ac" - -; Only load CSS when necessary. -; https://drupal.org/node/1370894 -projects[ckeditor][patch][] = "https://drupal.org/files/issues/attach-ckeditor-css-1370894-8.patch" +projects[ckeditor][version] = "1.16" ; Accomodate latest Media changes. ; https://drupal.org/node/2159403 -projects[ckeditor][patch][] = "https://drupal.org/files/issues/ckeditor-accomodate-latest-media-changes-0.patch" - -; Remove redundant external plugin declarations. -; https://drupal.org/comment/8284591#comment-8284591 -projects[ckeditor][patch][] = "https://drupal.org/files/issues/ckeditor-remove-external-plugin-declarations-1-alt.patch" +projects[ckeditor][patch][] = "https://drupal.org/files/issues/make_ckeditor_plugin-2159403-141.patch" projects[ctools][type] = "module" projects[ctools][subdir] = "contrib" -projects[ctools][download][type] = "git" -projects[ctools][download][url] = "http://git.drupal.org/project/ctools.git" -projects[ctools][download][branch] = "7.x-1.x" -projects[ctools][download][revision] = "e720f61d" +projects[ctools][version] = "1.7" projects[custom_search][type] = "module" projects[custom_search][subdir] = "contrib" -projects[custom_search][version] = "1.16" - -; Avoid akward sanitization of user-entered search strings. -; https://drupal.org/node/2012210 -projects[custom_search][patch][] = "http://drupal.org/files/commons_search_js_encode.patch" +projects[custom_search][version] = "1.18" projects[date][type] = "module" projects[date][subdir] = "contrib" @@ -145,6 +124,13 @@ projects[entitycache][version] = "1.2" ; http://drupal.org/node/1349566#comment-7781063 projects[entitycache][patch][] = "http://drupal.org/files/add-translation-information-on-each-request-1349566-12.patch" +projects[entity_embed][version] = "1.x-dev" +projects[entity_embed][type] = "module" +projects[entity_embed][subdir] = "contrib" +projects[entity_embed][download][type] = "git" +projects[entity_embed][download][revision] = "dcd4bac" +projects[entity_embed][download][branch] = "7.x-1.x" + projects[entityreference][type] = "module" projects[entityreference][subdir] = "contrib" projects[entityreference][version] = "1.1" @@ -153,25 +139,28 @@ projects[entityreference_prepopulate][type] = "module" projects[entityreference_prepopulate][subdir] = "contrib" projects[entityreference_prepopulate][version] = "1.5" +; Entityreference prepopulate overwrites field instance custom default value functions. +; https://drupal.org/node/2304301#comment-8973459 +projects[entityreference_prepopulate][patch][] = "https://drupal.org/files/issues/check-for-default-value-function-2304301-1.patch" + projects[entity_translation][type] = "module" projects[entity_translation][subdir] = "contrib" -projects[entity_translation][version] = "1.0-beta3" +projects[entity_translation][version] = "1.0-beta4" projects[facetapi][type] = "module" projects[facetapi][subdir] = "contrib" -projects[facetapi][version] = "1.3" +projects[facetapi][version] = "1.5" projects[features][type] = "module" projects[features][subdir] = "contrib" -projects[features][version] = "2.0" +projects[features][version] = "2.4" projects[file_entity][type] = "module" projects[file_entity][subdir] = "contrib" -projects[file_entity][version] = "2.0-alpha3" - -; Issue #2081713: Fix undefined index errors with empty (remote) files. -; https://drupal.org/node/2081713 -projects[file_entity][patch][] = "https://drupal.org/files/issues/add-filesize-checks-2081713-13.patch" +projects[file_entity][download][type] = "git" +projects[file_entity][download][url] = "http://git.drupal.org/project/file_entity.git" +projects[file_entity][download][branch] = "7.x-2.x" +projects[file_entity][download][revision] = "b610413" projects[flag][type] = "module" projects[flag][subdir] = "contrib" @@ -202,14 +191,14 @@ projects[http_client][version] = "2.4" projects[i18n][type] = "module" projects[i18n][subdir] = "contrib" -projects[i18n][version] = "1.11" +projects[i18n][version] = "1.12" projects[i18nviews][type] = "module" projects[i18nviews][subdir] = "contrib" projects[i18nviews][download][type] = "git" projects[i18nviews][download][url] = "http://git.drupal.org/project/i18nviews.git" projects[i18nviews][download][branch] = "7.x-3.x" -projects[i18nviews][download][revision] = "26bd52c" +projects[i18nviews][download][revision] = "27e9809" projects[kissmetrics][type] = "module" projects[kissmetrics][subdir] = "contrib" @@ -217,7 +206,7 @@ projects[kissmetrics][version] = "1.0-rc3" projects[l10n_update][type] = "module" projects[l10n_update][subdir] = "contrib" -projects[l10n_update][version] = "1.0" +projects[l10n_update][version] = "1.1" projects[libraries][type] = "module" projects[libraries][subdir] = "contrib" @@ -225,46 +214,49 @@ projects[libraries][version] = "2.2" projects[lingotek][type] = "module" projects[lingotek][subdir] = "contrib" -projects[lingotek][version] = "5.06" +projects[lingotek][version] = "6.01" projects[link][type] = "module" projects[link][subdir] = "contrib" -projects[link][version] = "1.2" +projects[link][version] = "1.3" projects[media][type] = "module" projects[media][subdir] = "contrib" projects[media][download][type] = "git" projects[media][download][url] = "http://git.drupal.org/project/media.git" projects[media][download][branch] = "7.x-2.x" -projects[media][download][revision] = "b2c2d78" - -; New filelfield browser widget is massively confusing the user -; https://drupal.org/comment/8570379#comment-8570379 -projects[media][patch][] = "https://drupal.org/files/issues/automatically-attach-files-2216329-2.patch" +projects[media][download][revision] = "7d9671f" projects[media_oembed][type] = "module" projects[media_oembed][subdir] = "contrib" -projects[media_oembed][version] = "2.1" +projects[media_oembed][version] = "2.2" projects[memcache][type] = "module" projects[memcache][subdir] = "contrib" -projects[memcache][version] = "1.0" +projects[memcache][version] = "1.5" projects[menu_attributes][type] = "module" projects[menu_attributes][subdir] = "contrib" -projects[menu_attributes][version] = "1.0-rc2" +projects[menu_attributes][version] = "1.0-rc3" projects[message][type] = "module" projects[message][subdir] = "contrib" -projects[message][version] = "1.9" +projects[message][download][type] = "git" +projects[message][download][url] = "http://git.drupal.org/project/message.git" +projects[message][download][branch] = "7.x-1.x" +projects[message][download][revision] = "3bbdd5e6" ; Make message access alterable. -; http://drupal.org/node/1920560#comment-7080942 -projects[message][patch][] = "http://drupal.org/files/1920560-message-access-alterable.patch" +; https://drupal.org/node/1920560#comment-7080942 +projects[message][patch][] = "https://drupal.org/files/1920560-message-access-alterable.patch" ; Add support for the undefined language. -; http://drupal.org/node/2006702#comment-7842259 -projects[message][patch][] = "http://drupal.org/files/message_field_undefined-lang.2006702-14.patch" +; https://drupal.org/node/2006702#comment-7842259 +projects[message][patch][] = "https://drupal.org/files/message_field_undefined-lang.2006702-14.patch" + +; Fix Undefined index: message_type in _field_ui on field listings +; https://drupal.org/node/1391442 +projects[message][patch][] = "https://drupal.org/files/issues/message-entity_info_hook_notice_undefined_index-1391442-34.patch" projects[message_notify][type] = "module" projects[message_notify][subdir] = "contrib" @@ -274,9 +266,17 @@ projects[message_subscribe][type] = "module" projects[message_subscribe][subdir] = "contrib" projects[message_subscribe][version] = "1.0-rc2" +; Message Subscribe sends emails regardless of context +; https://www.drupal.org/node/1828184 +projects[message_subscribe][patch][] = "https://drupal.org/files/issues/group-context-1828184-53.patch" + +; By default, don't notify blocked users +; https://www.drupal.org/node/2184567 +projects[message_subscribe][patch][] = "https://drupal.org/files/issues/2184567-message-subscribe-blocked-users-23.patch" + projects[metatag][type] = "module" projects[metatag][subdir] = "contrib" -projects[metatag][version] = "1.0-beta9" +projects[metatag][version] = "1.4" projects[module_filter][type] = "module" projects[module_filter][subdir] = "contrib" @@ -284,15 +284,11 @@ projects[module_filter][version] = "2.0" projects[mollom][type] = "module" projects[mollom][subdir] = "contrib" -projects[mollom][version] = "2.10" +projects[mollom][version] = "2.13" projects[navbar][type] = "module" projects[navbar][subdir] = "contrib" -projects[navbar][version] = "1.4" - -; Change I-beam cursors in the navbar to be a pointer instead. -; https://drupal.org/node/2173041 -projects[navbar][patch][] = "https://drupal.org/files/issues/2173041-3-i-beam-menu-hover.patch" +projects[navbar][version] = "1.6" projects[oauth][type] = "module" projects[oauth][subdir] = "contrib" @@ -312,19 +308,29 @@ projects[oembed][download][url] = "http://git.drupal.org/project/oembed.git" projects[oembed][download][branch] = "7.x-1.x" projects[oembed][download][revision] = "9aa5303" +; Remove the media submodule as it conflicts with the Media: oEmbed module. +; https://drupal.org/node/2269745#comment-8796261 +projects[oembed][patch][] = "https://drupal.org/files/issues/remove-media-submodule-2269745-2.patch" + projects[og][type] = "module" projects[og][subdir] = "contrib" projects[og][version] = "2.7" -; Fix missing class of login links in subscription field -projects[og][patch][] = "patches/0003-fix-og-subscribe-link-classes.patch" ; Auto-assign role to group manager broken on groups with overridden roles. ; https://drupal.org/node/2005800#comment-7684873 -projects[og][patch][] = "http://drupal.org/files/issues/og-default-role-member-2005800-25.patch" +projects[og][patch][] = "https://drupal.org/files/issues/og-default-role-member-2005800-25.patch" ; og_ui should give users the theme, not admin ui when creating groups. -; http://drupal.org/node/1800208 -projects[og][patch][] = "http://drupal.org/files/og_ui-group_node_add_theme-1800208-5.patch" +; https://drupal.org/node/1800208 +projects[og][patch][] = "https://drupal.org/files/og_ui-group_node_add_theme-1800208-5.patch" + +; Missing permissions when installing a new site. +; https://drupal.org/node/2301831 +projects[og][patch][] = "https://drupal.org/files/issues/og-missing-permission-roles-2301831-1.patch" + +; Missing permissions when reverting features. +; https://drupal.org/node/2021673 +projects[og][patch][] = "https://drupal.org/files/og-Do_not_export_nonexisting_roles-2021673-1.patch" projects[panelizer][type] = "module" projects[panelizer][subdir] = "contrib" @@ -339,7 +345,7 @@ projects[panels][download][revision] = "8059bda2b" projects[paranoia][type] = "module" projects[paranoia][subdir] = "contrib" -projects[paranoia][version] = "1.3" +projects[paranoia][version] = "1.4" projects[pathauto][type] = "module" projects[pathauto][subdir] = "contrib" @@ -350,30 +356,7 @@ projects[pathauto][patch][] = "https://www.drupal.org/files/pathauto-add-drush-s projects[picture][type] = "module" projects[picture][subdir] = "contrib" -projects[picture][download][type] = "git" -projects[picture][download][url] = "http://git.drupal.org/project/picture.git" -projects[picture][download][branch] = "7.x-1.x" -projects[picture][download][revision] = "18b94b9" - -; Add ctools as a dependency -; https://drupal.org/node/2173043 -projects[picture][patch][] = "https://drupal.org/files/issues/add-ctools-dependency-2173043-1.patch" - -; Allow filter tips to be translated -; https://drupal.org/node/2139459 -projects[picture][patch][] = "https://drupal.org/files/issues/translate-filter-tips-2139459-1.patch" - -; Move hook_uninstall() to picture.install to fix issues on uninstall. -; https://drupal.org/node/2173015 -projects[picture][patch][] = "https://drupal.org/files/issues/move-uninstall-hook-implementation-2173015-1.patch" - -; Remove implementation of hook_file_formatter_info() to remove duplicate file formatter. -; https://drupal.org/node/2172841 -projects[picture][patch][] = "https://drupal.org/files/issues/remove-file-formatter-hook-implementation-2172831-1.patch" - -; Remove implementation of hook_ctools_plugin_api() to fix issues with features. -; https://drupal.org/node/2172831 -projects[picture][patch][] = "https://drupal.org/files/issues/remove-ctools-hook-implementation-2172831-1.patch" +projects[picture][version] = "1.5" projects[pm_existing_pages][type] = "module" projects[pm_existing_pages][subdir] = "contrib" @@ -398,7 +381,7 @@ projects[quicktabs][patch][] = "http://drupal.org/files/2104643-revert-qt-487518 projects[r4032login][type] = "module" projects[r4032login][subdir] = "contrib" -projects[r4032login][version] = "1.7" +projects[r4032login][version] = "1.8" projects[radioactivity][type] = "module" projects[radioactivity][subdir] = "contrib" @@ -422,7 +405,7 @@ projects[realname][version] = "1.2" ; Realname entityreference autocomplete API update ; https://drupal.org/node/2225889 -projects[realname][patch][] = "https://drupal.org/files/issues/2225889-realname-correct-menu-2.patch" +projects[realname][patch][] = "https://drupal.org/files/issues/2225889-realname-correct-menu-3.patch" projects[redirect][type] = "module" projects[redirect][subdir] = "contrib" @@ -434,15 +417,15 @@ projects[registration][version] = "1.3" projects[rich_snippets][type] = "module" projects[rich_snippets][subdir] = "contrib" -projects[rich_snippets][version] = "1.0-beta3" +projects[rich_snippets][version] = "1.0-beta4" projects[rules][type] = "module" projects[rules][subdir] = "contrib" -projects[rules][version] = "2.7" +projects[rules][version] = "2.9" projects[schemaorg][type] = "module" projects[schemaorg][subdir] = "contrib" -projects[schemaorg][version] = "1.0-beta4" +projects[schemaorg][version] = "1.0-rc1" projects[search_facetapi][type] = "module" projects[search_facetapi][subdir] = "contrib" @@ -450,7 +433,7 @@ projects[search_facetapi][version] = "1.0-beta2" projects[sharethis][type] = "module" projects[sharethis][subdir] = "contrib" -projects[sharethis][version] = "2.6" +projects[sharethis][version] = "2.10" projects[smartcrop][type] = "module" projects[smartcrop][subdir] = "contrib" @@ -465,11 +448,11 @@ projects[strongarm][download][revision] = "5a2326ba67e59923ecce63d9bb5e0ed6548ab projects[timeago][type] = "module" projects[timeago][subdir] = "contrib" -projects[timeago][version] = "2.2" +projects[timeago][version] = "2.3" ; Provide a dedicated date type. -; http://drupal.org/node/1427226#comment-6638836 -projects[timeago][patch][] = "http://drupal.org/files/1427226-timeago-date-type.patch" +; https://drupal.org/node/1427226#comment-6638836 +projects[timeago][patch][] = "https://drupal.org/files/issues/1427226-timeago-date-type-6.patch" projects[title][type] = "module" projects[title][subdir] = "contrib" @@ -477,7 +460,7 @@ projects[title][version] = "1.0-alpha7" projects[token][type] = "module" projects[token][subdir] = "contrib" -projects[token][version] = "1.5" +projects[token][version] = "1.6" projects[translation_helpers][type] = "module" projects[translation_helpers][subdir] = "contrib" @@ -493,7 +476,7 @@ projects[views][version] = "3.10" ; Update Views Content access filter per core performance improvements. ; https://drupal.org/comment/8516039#comment-8516039 -projects[views][patch][] = "https://drupal.org/files/issues/2204257-views-content-access-filter-core-depends-on-core-patch.patch" +projects[views][patch][] = "https://drupal.org/files/issues/views-content_access_filter_per_core_performance-2204257-4_0.patch" projects[views_bulk_operations][type] = "module" projects[views_bulk_operations][subdir] = "contrib" @@ -509,15 +492,11 @@ projects[views_litepager][version] = "3.0" projects[views_load_more][type] = "module" projects[views_load_more][subdir] = "contrib" -projects[views_load_more][version] = "1.2" - -; Suppress notice error when loading more content from views_load_more. -; https://drupal.org/node/2207467 -projects[views_load_more][patch][] = "https://drupal.org/files/issues/fix-notice-undefined-index-2152935-3.patch" +projects[views_load_more][version] = "1.5" projects[votingapi][type] = "module" projects[votingapi][subdir] = "contrib" -projects[votingapi][version] = "2.11" +projects[votingapi][version] = "2.12" projects[voting_rules][type] = "module" projects[voting_rules][subdir] = "contrib" @@ -581,7 +560,7 @@ projects[feeds_fetcher_directory][patch][] = "https://drupal.org/files/feeds_fet projects[jquery_update][type] = "module" projects[jquery_update][subdir] = "contrib" -projects[jquery_update][version] = "2.4" +projects[jquery_update][version] = "2.5" projects[panels_ajax_tab][type] = "module" projects[panels_ajax_tab][subdir] = "contrib" @@ -622,10 +601,7 @@ projects[adaptivetheme][download][revision] = "18693ff59db7cb3171f282a982d04fe65 projects[ember][type] = "theme" projects[ember][subdir] = "contrib" -projects[ember][download][type] = "git" -projects[ember][download][url] = "http://git.drupal.org/project/ember.git" -projects[ember][download][branch] = "7.x-2.x" -projects[ember][download][revision] = "caf4df7" +projects[ember][version] = "2.0-alpha3" projects[sky][type] = "theme" projects[sky][subdir] = "contrib" @@ -643,11 +619,11 @@ libraries[backbone][type] = "libraries" libraries[backbone][download][url] = "https://github.com/jashkenas/backbone/archive/1.1.0.tar.gz" libraries[ckeditor][download][type] = "get" -libraries[ckeditor][download][url] = "http://download.cksource.com/CKEditor/CKEditor/CKEditor%204.3.4/ckeditor_4.3.4_full.zip" +libraries[ckeditor][download][url] = "http://download.cksource.com/CKEditor/CKEditor/CKEditor%204.4.7/ckeditor_4.4.7_full.zip" libraries[ckeditor][type] = "libraries" libraries[ckeditor_lineutils][download][type] = "get" -libraries[ckeditor_lineutils][download][url] = "http://download.ckeditor.com/lineutils/releases/lineutils_4.3.4.zip" +libraries[ckeditor_lineutils][download][url] = "http://download.ckeditor.com/lineutils/releases/lineutils_4.4.7.zip" libraries[ckeditor_lineutils][type] = "libraries" libraries[ckeditor_lineutils][subdir] = "ckeditor/plugins" libraries[ckeditor_lineutils][directory_name] = "lineutils" @@ -658,6 +634,12 @@ libraries[ckeditor_widget][type] = "libraries" libraries[ckeditor_widget][subdir] = "ckeditor/plugins" libraries[ckeditor_widget][directory_name] = "widget" +libraries[ckeditor_widget][download][type] = "get" +libraries[ckeditor_widget][download][url] = "http://download.ckeditor.com/widget/releases/widget_4.4.7.zip" +libraries[ckeditor_widget][type] = "libraries" +libraries[ckeditor_widget][subdir] = "ckeditor/plugins" +libraries[ckeditor_widget][directory_name] = "widget" + libraries[modernizr][download][type] = "get" libraries[modernizr][type] = "libraries" libraries[modernizr][download][url] = "https://github.com/Modernizr/Modernizr/archive/v2.7.1.tar.gz" diff --git a/groups.info b/groups.info index 0312ef2..5c04de6 100644 --- a/groups.info +++ b/groups.info @@ -48,7 +48,6 @@ dependencies[] = googleanalytics dependencies[] = http_client dependencies[] = jquery_update dependencies[] = libraries -dependencies[] = l10n_update dependencies[] = markdown dependencies[] = media dependencies[] = media_internet @@ -147,20 +146,3 @@ dependencies[] = feeds_fetcher_directory ; Custom modules dependencies[] = field_property_list dependencies[] = field_group_location - -; Features -dependencies[] = groups_groups -dependencies[] = groups_directory -dependencies[] = groups_footer -dependencies[] = groups_homepage -dependencies[] = groups_common -dependencies[] = groups_comment -dependencies[] = groups_auth -dependencies[] = groups_oauth2 -dependencies[] = groups_oauth2_picture -dependencies[] = groups_feeds -dependencies[] = groups_events -dependencies[] = groups_events_pages -dependencies[] = groups_pages -dependencies[] = groups_reports -dependencies[] = groups_wikis \ No newline at end of file diff --git a/groups.install_callbacks.inc b/groups.install_callbacks.inc new file mode 100644 index 0000000..61c8fcf --- /dev/null +++ b/groups.install_callbacks.inc @@ -0,0 +1,16 @@ + $module_name)); +} \ No newline at end of file diff --git a/groups.profile b/groups.profile index d61e44a..3448f33 100644 --- a/groups.profile +++ b/groups.profile @@ -93,6 +93,11 @@ function groups_install_tasks() { 'groups_revert_features' => array( 'display' => FALSE, ), + 'groups_install_additional_modules' => array( + 'display_name' => st('Install additional functionality'), + 'display' => FALSE, + 'type' => 'batch', + ), 'groups_demo_content' => array( 'display' => FALSE, 'type' => '', @@ -260,6 +265,81 @@ function field_property_list_reverse_lookup() { ); } +/** + * array_filter() callback used to filter out already installed dependencies. + */ +function _groups_filter_dependencies($dependency) { + return !module_exists($dependency); +} + +/** + * Install additional modules. + * + * The groups modules installed from this hook to avoid + * memory exhausted error messages. + * + * l10n_update module move to the end of the queue to + * avoid download of translations during module + * deployment. + */ +function groups_install_additional_modules() { + $modules = array( + 'groups_common', + 'groups_groups', + 'groups_directory', + 'groups_footer', + 'groups_events', + 'groups_homepage', + 'groups_comment', + 'groups_auth', + 'groups_oauth2', + 'groups_oauth2_picture', + 'groups_feeds', + 'groups_events_pages', + 'groups_pages', + 'groups_reports', + 'groups_wikis', + ); + // Resolve the dependencies now, so that module_enable() doesn't need + // to do it later for each individual module (which kills performance). + $files = system_rebuild_module_data(); + + // Add l10n_update module as last one to avoid translation file fetch + // during deployment. + $modules[] = 'l10n_update'; + $files['l10n_update']->sort = -999; + + $modules_sorted = array(); + foreach ($modules as $module) { + if ($files[$module]->requires) { + // Create a list of dependencies that haven't been installed yet. + $dependencies = array_keys($files[$module]->requires); + $dependencies = array_filter($dependencies, '_groups_filter_dependencies'); + // Add them to the module list. + $modules = array_merge($modules, $dependencies); + } + } + $modules = array_unique($modules); + foreach ($modules as $module) { + $modules_sorted[$module] = $files[$module]->sort; + } + arsort($modules_sorted); + + $operations = array(); + // Enable the selected modules. + foreach ($modules_sorted as $module => $weight) { + $operations[] = array('_groups_enable_module', array($module, $files[$module]->info['name'])); + } + + $batch = array( + 'title' => st('Installing additional functionality'), + 'operations' => $operations, + 'file' => drupal_get_path('profile', 'groups') . '/groups.install_callbacks.inc', + ); + + return $batch; +} + /** * Create demo group */ diff --git a/modules/commons/commons_activity_streams/commons_activity_page/commons_activity_page.info b/modules/commons/commons_activity_streams/commons_activity_page/commons_activity_page.info index 20fe828..8d779de 100644 --- a/modules/commons/commons_activity_streams/commons_activity_page/commons_activity_page.info +++ b/modules/commons/commons_activity_streams/commons_activity_page/commons_activity_page.info @@ -1,18 +1,20 @@ name = Commons Activity Page -description = Allows users to view a stream of site-wide and personalized activity. -core = 7.x +description = Provides a landing page which lists site activity. package = Commons - Landing pages +core = 7.x + dependencies[] = commons_activity_streams dependencies[] = commons_featured dependencies[] = ctools dependencies[] = page_manager + features[ctools][] = page_manager:pages_default:1 features[features_api][] = api:2 features[page_manager_pages][] = commons_activity_streams_activity -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_activity_streams/commons_activity_streams.features.inc b/modules/commons/commons_activity_streams/commons_activity_streams.features.inc index 637134b..042bcd8 100644 --- a/modules/commons/commons_activity_streams/commons_activity_streams.features.inc +++ b/modules/commons/commons_activity_streams/commons_activity_streams.features.inc @@ -38,11 +38,7 @@ function commons_activity_streams_default_message_type() { "language" : "", "arguments" : null, "message_text" : { "und" : [ - { - "value" : "[message:user:picture:35x35]", - "format" : "filtered_html", - "safe_value" : "[message:user:picture:35x35]" - }, + { "value" : "[message:user:picture:35x35]", "format" : "filtered_html" }, { "value" : "\\u003Ca href=\\u0022[message:user:url:absolute]\\u0022\\u003E[message:user:name]\\u003C\\/a\\u003E commented on \\u003Ca href=\\u0022[message:field-target-nodes:0:url]\\u0022\\u003E[message:field-target-nodes:0:title_field]\\u003C\\/a\\u003E", "format" : "full_html", @@ -70,11 +66,7 @@ function commons_activity_streams_default_message_type() { "language" : "", "arguments" : null, "message_text" : { "und" : [ - { - "value" : "[message:user:picture:35x35]", - "format" : "filtered_html", - "safe_value" : "[message:user:picture:35x35]" - }, + { "value" : "[message:user:picture:35x35]", "format" : "filtered_html" }, { "value" : "\\u003Ca href=\\u0022[message:user:url:absolute]\\u0022\\u003E[message:user:name]\\u003C\\/a\\u003E created \\u003Ca href=\\u0022[message:field-target-nodes:0:url]\\u0022\\u003E[message:field-target-nodes:0:title_field]\\u003C\\/a\\u003E", "format" : "full_html", @@ -102,11 +94,7 @@ function commons_activity_streams_default_message_type() { "language" : "", "arguments" : null, "message_text" : { "und" : [ - { - "value" : "[message:user:picture:35x35]", - "format" : "filtered_html", - "safe_value" : "[message:user:picture:35x35]" - }, + { "value" : "[message:user:picture:35x35]", "format" : "filtered_html" }, { "value" : "\\u003Ca href=\\u0022[message:user:url:absolute]\\u0022\\u003E[message:user:name]\\u003C\\/a\\u003E has an updated profile", "format" : "full_html", diff --git a/modules/commons/commons_activity_streams/commons_activity_streams.info b/modules/commons/commons_activity_streams/commons_activity_streams.info index 420b162..a861f0c 100644 --- a/modules/commons/commons_activity_streams/commons_activity_streams.info +++ b/modules/commons/commons_activity_streams/commons_activity_streams.info @@ -1,6 +1,8 @@ name = Commons Activity Streams -core = 7.x +description = Displays a listing of site-wide and user-specific site activity. package = Commons - Building blocks +core = 7.x + dependencies[] = commons_follow dependencies[] = ctools dependencies[] = entity @@ -13,6 +15,7 @@ dependencies[] = token dependencies[] = views dependencies[] = views_content dependencies[] = views_load_more + features[ctools][] = strongarm:strongarm:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 @@ -30,6 +33,7 @@ features[variable][] = timeago_comment features[variable][] = timeago_node features[views_view][] = commons_activity_streams_activity features[views_view][] = commons_activity_streams_user_activity + features_exclude[field][message-commons_activity_streams_comment_created-field_target_comments] = message-commons_activity_streams_comment_created-field_target_comments features_exclude[field][message-commons_activity_streams_comment_created-field_target_nodes] = message-commons_activity_streams_comment_created-field_target_nodes features_exclude[field][message-commons_activity_streams_node_created-field_target_nodes] = message-commons_activity_streams_node_created-field_target_nodes @@ -38,9 +42,9 @@ features_exclude[field_base][field_target_nodes] = field_target_nodes features_exclude[field_base][field_target_comments] = field_target_comments features_exclude[views_view][commons_bw_all] = commons_bw_all -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_activity_streams/commons_activity_streams.install b/modules/commons/commons_activity_streams/commons_activity_streams.install index 4bfc7cf..049f592 100644 --- a/modules/commons/commons_activity_streams/commons_activity_streams.install +++ b/modules/commons/commons_activity_streams/commons_activity_streams.install @@ -63,3 +63,14 @@ function commons_activity_streams_update_3106() { features_revert($revert); return array(); } + +/** + * Accommodate changes to message definitions. + */ +function commons_activity_streams_update_3107() { + $revert = array( + 'commons_activity_streams' => array('message_type'), + ); + features_revert($revert); + return array(); +} diff --git a/modules/commons/commons_activity_streams/commons_activity_streams.module b/modules/commons/commons_activity_streams/commons_activity_streams.module index 8765d63..854b4f3 100644 --- a/modules/commons/commons_activity_streams/commons_activity_streams.module +++ b/modules/commons/commons_activity_streams/commons_activity_streams.module @@ -218,14 +218,18 @@ function commons_activity_streams_user_profile_submit($form, &$form_state) { * Implements hook_token_info(). */ function commons_activity_streams_token_info() { - $styles = image_styles(); $tokens = array(); + $styles = image_styles(); + + // Create a token to retrieve the user picture formatted using any of the + // currently defined image styles. foreach ($styles as $style_name => $style) { $tokens['picture:' . $style_name] = array( 'name' => t('Picture: @st image style', array('@st' => $style_name)), 'description' => t('Picture: @st image style', array('@st' => $style_name)), ); } + return array( 'tokens' => array( 'user' => $tokens, @@ -238,42 +242,44 @@ function commons_activity_streams_token_info() { */ function commons_activity_streams_tokens($type, $tokens, array $data = array(), array $options = array()) { $replacements = array(); + if ($type == 'user' && isset($data['user'])) { - $user = $data['user']; - $user_wrapper = entity_metadata_wrapper('user', $user); - $alt = $user->name; - if (isset($user->field_name_first)) { - $alt = $user_wrapper->field_name_first->value(); - if (isset($user->field_name_last)) { - $alt .= " " . $user_wrapper->field_name_last->value(); - } - } - $alt = t("@name's picture", array('@name' => $alt)); + $account = $data['user']; + + // Generate suitable alternative text using the user's username. + $username = format_username($account); + $alt = t("@name's picture", array('@name' => $username)); + foreach ($tokens as $token => $original) { if (strpos($token, 'picture:') !== FALSE) { list( , $style) = explode(':', $token); - $path = variable_get('user_picture_default', '/profiles/commons/images/avatars/user-avatar.png'); - if (!empty($user->picture)) { - $path = image_style_url($style, $user->picture->uri); - } + + // Prefer unique account pictures but fall back to the default user + // picture if necessary. + $path = $account->picture ? $account->picture->uri : variable_get('user_picture_default', '/profiles/commons/images/avatars/user-avatar.png'); + $image_variables = array( - 'path' => $path, + 'path' => image_style_url($style, $path), 'alt' => $alt, 'title' => $alt, 'class' => array('image-style-none'), ); + $image = theme('image', $image_variables); - $user_path = user_uri($user); + $user_path = user_uri($account); + $link_options = array( 'attributes' => array( 'title' => t('View user profile.'), ), 'html' => TRUE, ); + $replacements[$original] = "
" . l($image, $user_path['path'], $link_options) . "
"; } } } + return $replacements; } diff --git a/modules/commons/commons_activity_streams/commons_activity_streams_groups/commons_activity_streams_groups.info b/modules/commons/commons_activity_streams/commons_activity_streams_groups/commons_activity_streams_groups.info index 2ba44f1..11aec4c 100644 --- a/modules/commons/commons_activity_streams/commons_activity_streams_groups/commons_activity_streams_groups.info +++ b/modules/commons/commons_activity_streams/commons_activity_streams_groups/commons_activity_streams_groups.info @@ -1,18 +1,20 @@ name = Commons Activity Streams Groups -description = Contains Organic Groups integration for Commons Activity Streams -core = 7.x +description = Integrates site activity with Organic Groups. package = Commons - Building blocks +core = 7.x + dependencies[] = commons_activity_streams dependencies[] = entity dependencies[] = views dependencies[] = views_content + features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 features[views_view][] = activity_group -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_body/commons_body.features.field_base.inc b/modules/commons/commons_body/commons_body.features.field_base.inc index 08b6813..77f8594 100644 --- a/modules/commons/commons_body/commons_body.features.field_base.inc +++ b/modules/commons/commons_body/commons_body.features.field_base.inc @@ -19,14 +19,6 @@ function commons_body_field_default_field_bases() { 0 => 'node', ), 'field_name' => 'body', - 'foreign keys' => array( - 'format' => array( - 'columns' => array( - 'format' => 'format', - ), - 'table' => 'filter_format', - ), - ), 'indexes' => array( 'format' => array( 0 => 'format', diff --git a/modules/commons/commons_body/commons_body.info b/modules/commons/commons_body/commons_body.info index 17d165c..88440a2 100644 --- a/modules/commons/commons_body/commons_body.info +++ b/modules/commons/commons_body/commons_body.info @@ -1,16 +1,18 @@ name = Commons Body Field -description = Provides a simple body field for re-use by various Commons content types -core = 7.x +description = Provides a simple body field for re-use by various Commons content types. package = Commons - Building blocks +core = 7.x + dependencies[] = features dependencies[] = field_sql_storage dependencies[] = text + features[features_api][] = api:2 features[field_base][] = body -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_bw/commons_bw.features.field_base.inc b/modules/commons/commons_bw/commons_bw.features.field_base.inc index 34f1a3b..ea224f8 100644 --- a/modules/commons/commons_bw/commons_bw.features.field_base.inc +++ b/modules/commons/commons_bw/commons_bw.features.field_base.inc @@ -17,14 +17,6 @@ function commons_bw_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'title_field', - 'foreign keys' => array( - 'format' => array( - 'columns' => array( - 'format' => 'format', - ), - 'table' => 'filter_format', - ), - ), 'indexes' => array( 'format' => array( 0 => 'format', diff --git a/modules/commons/commons_bw/commons_bw.features.field_instance.inc b/modules/commons/commons_bw/commons_bw.features.field_instance.inc index 7189faf..cd917b0 100644 --- a/modules/commons/commons_bw/commons_bw.features.field_instance.inc +++ b/modules/commons/commons_bw/commons_bw.features.field_instance.inc @@ -38,13 +38,13 @@ function commons_bw_field_definition(&$field_instances, $bundle) { 'label' => 'above', 'settings' => array(), 'type' => 'hidden', - 'weight' => 12, + 'weight' => -50, ), 'teaser' => array( 'label' => 'above', 'settings' => array(), 'type' => 'hidden', - 'weight' => 0, + 'weight' => -50, ), ), 'display_in_partial_form' => !empty($display_in_partial_form[$bundle]), @@ -67,7 +67,7 @@ function commons_bw_field_definition(&$field_instances, $bundle) { 'size' => '60', ), 'type' => 'text_textfield', - 'weight' => -5, + 'weight' => -50, ), ); } diff --git a/modules/commons/commons_bw/commons_bw.info b/modules/commons/commons_bw/commons_bw.info index fbeca51..a7845dd 100644 --- a/modules/commons/commons_bw/commons_bw.info +++ b/modules/commons/commons_bw/commons_bw.info @@ -1,20 +1,23 @@ -name = Commons Tabbed Browsing Widget -core = 7.x +name = Commons Browsing Widget +description = Provides a single content area with multiple panels for adding and browsing content by content type. package = Commons - Building blocks +core = 7.x + dependencies[] = commons_groups dependencies[] = features dependencies[] = og dependencies[] = quicktabs dependencies[] = quicktabs_tabstyles dependencies[] = title + features[features_api][] = api:2 features[field_base][] = title_field -files[] = includes/views/handlers/commons_bw_handler_node_partial_form.inc -; Views handlers -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +files[] = includes/views/handlers/commons_bw_handler_node_partial_form.inc + +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_bw/commons_bw.install b/modules/commons/commons_bw/commons_bw.install index a297a0c..18892fd 100644 --- a/modules/commons/commons_bw/commons_bw.install +++ b/modules/commons/commons_bw/commons_bw.install @@ -32,3 +32,14 @@ function commons_bw_update_7302() { drupal_flush_all_caches(); } + +/** + * Standardize browsing widget field weights. + */ +function commons_bw_update_7303() { + $revert = array( + 'commons_bw' => array('field_instance'), + ); + features_revert($revert); + return array(); +} diff --git a/modules/commons/commons_bw/commons_bw.module b/modules/commons/commons_bw/commons_bw.module index a7164ad..0cf267c 100644 --- a/modules/commons/commons_bw/commons_bw.module +++ b/modules/commons/commons_bw/commons_bw.module @@ -28,14 +28,48 @@ function commons_bw_system_info_alter(&$info, $file, $type) { // so that Features is aware of the instance and can successfully revert the // field_instance component back to its default state. if ($file->name == 'commons_bw') { - foreach (node_type_get_types() as $node_type) { - $type = $node_type->type; + foreach (node_type_get_types() as $node_type_object) { + $node_type = $node_type_object->type; - if (commons_bw_node_auto_title_instance($type)) { - $info['features']['field_instance'][] = "node-$type-title_field"; + if (commons_bw_node_auto_title_instance($node_type)) { + $info['features']['field_instance'][] = "node-$node_type-title_field"; } } } + + // Dynamically adding a field to a content type results in features + // automatically detecting Commons BW as a dependency. + // We manually exclude the dependency in order to prevent the content type + // modules from appearing overridden and to allow them to be used + // independently of Commons BW. + $node_types = &drupal_static(__FUNCTION__); + + if (!isset($node_types)) { + foreach (module_implements('node_info') as $module) { + $node_types[$module] = call_user_func($module . '_node_info'); + } + } + + if (isset($node_types[$file->name])) { + foreach ($node_types[$file->name] as $node_type => $node_info) { + if (commons_bw_node_auto_title_instance($node_type)) { + $info['features_exclude']['dependencies']['commons_bw'] = 'commons_bw'; + } + } + } +} + +/** + * Implements hook_modules_enabled(). + */ +function commons_bw_modules_enabled($modules) { + // Ensure that dynamically added title_field fields are in the default state + // when modules that provide content types are enabled. + foreach ($modules as $module) { + if (module_hook($module, 'node_info')) { + features_revert(array('commons_bw' => array('field_instance'))); + } + } } /** @@ -169,7 +203,7 @@ function commons_bw_partial_node_form($form, &$form_state, $bundle, $group_id = // Add a default form title. $form['title'] = array( '#markup' => t('Create content'), - '#weight' => -50, + '#weight' => -100, ); // Display the user's picture. diff --git a/modules/commons/commons_content_moderation/commons_content_moderation.info b/modules/commons/commons_content_moderation/commons_content_moderation.info index 5cb011e..2fb3130 100644 --- a/modules/commons/commons_content_moderation/commons_content_moderation.info +++ b/modules/commons/commons_content_moderation/commons_content_moderation.info @@ -1,12 +1,14 @@ -name = Commons Content moderation -description = Commons Content moderation +name = Commons Content Moderation +description = Provides a content moderator role which allows privileged users to moderate content and users. +package = Commons - Building blocks core = 7.x -package = Commons - Building Blocks + dependencies[] = ctools dependencies[] = flag dependencies[] = flag_abuse dependencies[] = strongarm dependencies[] = views + features[ctools][] = strongarm:strongarm:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 @@ -16,11 +18,12 @@ features[user_role][] = content moderator features[variable][] = flag_abuse_flags features[views_view][] = commons_content_moderation_reported_comments features[views_view][] = commons_content_moderation_reported_nodes + features_exclude[dependencies][features] = features -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_documents/commons_documents.commons.inc b/modules/commons/commons_documents/commons_documents.commons.inc index 9335e6c..c7b2398 100644 --- a/modules/commons/commons_documents/commons_documents.commons.inc +++ b/modules/commons/commons_documents/commons_documents.commons.inc @@ -12,6 +12,8 @@ function commons_documents_commons_entity_integration() { 'node' => array( 'document' => array( 'is_group_content' => TRUE, + 'exclude_rate' => TRUE, + 'exclude_rate_comments' => TRUE, ), ), ); @@ -32,3 +34,21 @@ function commons_documents_commons_bw_group_widget() { ), ); } + +/** + * Implements hook_commons_bw_create_all_widget(). + */ +function commons_documents_commons_bw_create_all_widget($group) { + if (og_user_access('node', $group->nid, 'create document content')) { + $link = l(t('Create a document'),'node/add/document', + array('attributes' => array('class' => 'commons-documents-create'), 'query' => array('og_group_ref' => $group->nid)) + ); + return array( + 'commons_documents' => array( + 'link' => $link, + 'text' => t('Share a document'), + '#weight' => 6, + ), + ); + } +} diff --git a/modules/commons/commons_documents/commons_documents.features.field_base.inc b/modules/commons/commons_documents/commons_documents.features.field_base.inc index 0621f77..f6c93d6 100644 --- a/modules/commons/commons_documents/commons_documents.features.field_base.inc +++ b/modules/commons/commons_documents/commons_documents.features.field_base.inc @@ -17,14 +17,6 @@ function commons_documents_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_document_file', - 'foreign keys' => array( - 'fid' => array( - 'columns' => array( - 'fid' => 'fid', - ), - 'table' => 'file_managed', - ), - ), 'indexes' => array( 'fid' => array( 0 => 'fid', diff --git a/modules/commons/commons_documents/commons_documents.features.field_instance.inc b/modules/commons/commons_documents/commons_documents.features.field_instance.inc index 008013d..b88319b 100644 --- a/modules/commons/commons_documents/commons_documents.features.field_instance.inc +++ b/modules/commons/commons_documents/commons_documents.features.field_instance.inc @@ -22,7 +22,7 @@ function commons_documents_field_default_field_instances() { 'module' => 'text', 'settings' => array(), 'type' => 'text_default', - 'weight' => 2, + 'weight' => -49, ), 'teaser' => array( 'label' => 'hidden', @@ -31,7 +31,7 @@ function commons_documents_field_default_field_instances() { 'trim_length' => 600, ), 'type' => 'text_summary_or_trimmed', - 'weight' => 1, + 'weight' => -49, ), ), 'display_in_partial_form' => 1, @@ -51,7 +51,7 @@ function commons_documents_field_default_field_instances() { 'summary_rows' => 5, ), 'type' => 'text_textarea_with_summary', - 'weight' => 1, + 'weight' => -49, ), ); @@ -66,13 +66,13 @@ function commons_documents_field_default_field_instances() { 'module' => 'file', 'settings' => array(), 'type' => 'file_default', - 'weight' => 4, + 'weight' => -48, ), 'teaser' => array( 'label' => 'above', 'settings' => array(), 'type' => 'hidden', - 'weight' => 0, + 'weight' => -48, ), ), 'display_in_partial_form' => 1, @@ -94,7 +94,7 @@ function commons_documents_field_default_field_instances() { 'progress_indicator' => 'throbber', ), 'type' => 'file_generic', - 'weight' => 2, + 'weight' => -48, ), ); diff --git a/modules/commons/commons_documents/commons_documents.info b/modules/commons/commons_documents/commons_documents.info index 1fcc1e9..673b2cc 100644 --- a/modules/commons/commons_documents/commons_documents.info +++ b/modules/commons/commons_documents/commons_documents.info @@ -1,18 +1,24 @@ name = Commons Documents -core = 7.x +description = Provides a Document content type for sharing files. package = Commons - Content types +core = 7.x + dependencies[] = commons_body -dependencies[] = commons_groups dependencies[] = commons_topics dependencies[] = ctools +dependencies[] = entity dependencies[] = entityreference dependencies[] = features dependencies[] = file +dependencies[] = node dependencies[] = og dependencies[] = og_ui dependencies[] = strongarm +dependencies[] = taxonomy +dependencies[] = text dependencies[] = views dependencies[] = views_litepager + features[ctools][] = strongarm:strongarm:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 @@ -45,9 +51,11 @@ features[variable][] = node_preview_document features[variable][] = node_submitted_document features[views_view][] = commons_bw_documents -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +features_exclude[dependencies][commons_trusted_contacts] = commons_trusted_contacts + +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_documents/commons_documents.install b/modules/commons/commons_documents/commons_documents.install index f2605e8..120946d 100644 --- a/modules/commons/commons_documents/commons_documents.install +++ b/modules/commons/commons_documents/commons_documents.install @@ -1,14 +1,17 @@ array('og_features_permission', 'field_instance', 'field_base', 'variable', 'views_view', 'node'))); + $revert = array( + 'commons_documents' => array('og_features_permission'), + ); + features_revert($revert); $groups = og_get_all_group(); - foreach ($groups as $gid) { + foreach ($groups AS $gid) { commons_groups_features_permission_rebuild('commons_documents', $gid); } } @@ -128,3 +131,14 @@ function commons_documents_update_7009() { return array(); } + +/** + * Standardize browsing widget field weights. + */ +function commons_documents_update_7010() { + $revert = array( + 'commons_documents' => array('field_instance'), + ); + features_revert($revert); + return array(); +} diff --git a/modules/commons/commons_events/commons_events.features.field_base.inc b/modules/commons/commons_events/commons_events.features.field_base.inc index b8a0fa6..47c9471 100644 --- a/modules/commons/commons_events/commons_events.features.field_base.inc +++ b/modules/commons/commons_events/commons_events.features.field_base.inc @@ -17,7 +17,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_date', - 'foreign keys' => array(), 'indexes' => array(), 'locked' => 0, 'module' => 'date', @@ -47,7 +46,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_location', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', @@ -74,14 +72,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_logo', - 'foreign keys' => array( - 'fid' => array( - 'columns' => array( - 'fid' => 'fid', - ), - 'table' => 'file_managed', - ), - ), 'indexes' => array( 'fid' => array( 0 => 'fid', @@ -104,7 +94,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_number_of_attendees', - 'foreign keys' => array(), 'indexes' => array(), 'locked' => 0, 'module' => 'number', @@ -120,14 +109,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_offsite_url', - 'foreign keys' => array( - 'format' => array( - 'columns' => array( - 'format' => 'format', - ), - 'table' => 'filter_format', - ), - ), 'indexes' => array( 'format' => array( 0 => 'format', @@ -149,14 +130,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_organizers', - 'foreign keys' => array( - 'users' => array( - 'columns' => array( - 'target_id' => 'uid', - ), - 'table' => 'users', - ), - ), 'indexes' => array( 'target_id' => array( 0 => 'target_id', @@ -190,14 +163,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_registration', - 'foreign keys' => array( - 'registration_type' => array( - 'columns' => array( - 'registration_type' => 'name', - ), - 'table' => 'registration_type', - ), - ), 'indexes' => array( 'registration_type' => array( 0 => 'registration_type', @@ -217,7 +182,6 @@ function commons_events_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_registration_type', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', diff --git a/modules/commons/commons_events/commons_events.features.field_instance.inc b/modules/commons/commons_events/commons_events.features.field_instance.inc index 9526fd9..b127394 100644 --- a/modules/commons/commons_events/commons_events.features.field_instance.inc +++ b/modules/commons/commons_events/commons_events.features.field_instance.inc @@ -28,7 +28,7 @@ function commons_events_field_default_field_instances() { 'module' => 'text', 'settings' => array(), 'type' => 'text_default', - 'weight' => 5, + 'weight' => -49, ), 'teaser' => array( 'label' => 'hidden', @@ -37,7 +37,7 @@ function commons_events_field_default_field_instances() { 'trim_length' => 600, ), 'type' => 'text_summary_or_trimmed', - 'weight' => 3, + 'weight' => -49, ), ), 'entity_type' => 'node', @@ -57,7 +57,7 @@ function commons_events_field_default_field_instances() { 'summary_rows' => 5, ), 'type' => 'text_textarea_with_summary', - 'weight' => 1, + 'weight' => -49, ), ); diff --git a/modules/commons/commons_events/commons_events.features.menu_links.inc b/modules/commons/commons_events/commons_events.features.menu_links.inc deleted file mode 100644 index 1b1fc2a..0000000 --- a/modules/commons/commons_events/commons_events.features.menu_links.inc +++ /dev/null @@ -1,37 +0,0 @@ - 'main-menu', - 'link_path' => 'events', - 'router_path' => 'events', - 'link_title' => 'Events', - 'options' => array( - 'attributes' => array(), - 'identifier' => 'main-menu:events', - ), - 'module' => 'menu', - 'hidden' => 0, - 'external' => 0, - 'has_children' => 0, - 'expanded' => 0, - 'weight' => 2, - 'customized' => 1, - ); - // Translatables - // Included for use with string extractors like potx. - t('Events'); - - - return $menu_links; -} diff --git a/modules/commons/commons_events/commons_events.info b/modules/commons/commons_events/commons_events.info index 124980b..843cdee 100644 --- a/modules/commons/commons_events/commons_events.info +++ b/modules/commons/commons_events/commons_events.info @@ -1,15 +1,16 @@ name = Commons Events -description = Provides the Event features for Drupal Commons. -core = 7.x +description = Provides an Event content type for hosting events. package = Commons - Content types +core = 7.x + dependencies[] = addressfield dependencies[] = addressfield_tokens dependencies[] = block dependencies[] = commons_body -dependencies[] = commons_follow_node -dependencies[] = commons_groups -dependencies[] = commons_notify dependencies[] = commons_location +; @todo Move message- field instances into another module in order to allow +; Commons Events to function independently of Commons Notify. +dependencies[] = commons_notify dependencies[] = commons_topics dependencies[] = ctools dependencies[] = date @@ -22,7 +23,7 @@ dependencies[] = features dependencies[] = field_sql_storage dependencies[] = image dependencies[] = list -dependencies[] = menu +dependencies[] = message dependencies[] = node dependencies[] = number dependencies[] = og @@ -37,6 +38,7 @@ dependencies[] = text dependencies[] = views dependencies[] = views_content dependencies[] = views_load_more + features[ctools][] = strongarm:strongarm:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 @@ -60,8 +62,8 @@ features[field_instance][] = node-event-field_registration features[field_instance][] = node-event-field_registration_type features[field_instance][] = message-commons_events_event_node_created-field_message_rendered_body features[field_instance][] = message-commons_events_event_node_created-field_message_rendered_subject +features[field_instance][] = message-commons_events_event_node_created-field_target_comments features[field_instance][] = message-commons_events_event_node_created-field_target_nodes -features[menu_links][] = main-menu:events features[message_type][] = commons_events_event_node_created features[node][] = event features[og_features_permission][] = node:group:create event content @@ -70,7 +72,6 @@ features[og_features_permission][] = node:group:delete own event content features[og_features_permission][] = node:group:update any event content features[og_features_permission][] = node:group:update own event content features[registration_type][] = event -features[schemaorg][] = node-event features[user_permission][] = create event content features[user_permission][] = create event registration features[user_permission][] = delete own event content @@ -86,6 +87,7 @@ features[variable][] = comment_event features[variable][] = comment_form_location_event features[variable][] = comment_preview_event features[variable][] = comment_subject_field_event +features[variable][] = field_bundle_settings_message__commons_events_event_node_created features[variable][] = field_bundle_settings_node__event features[variable][] = menu_options_event features[variable][] = menu_parent_event @@ -96,16 +98,17 @@ features[views_view][] = commons_events_event_attendee_list features[views_view][] = commons_events_organizers features[views_view][] = commons_events_upcoming features[views_view][] = commons_events_user_upcoming_events -files[] = commons_events.features.inc -files[] = commons_events.features.field_base.inc -files[] = commons_events.features.field_instance.inc -files[] = commons_events.strongarm.inc -files[] = includes/commons_events.forms.inc -files[] = includes/commons_events.theme.inc -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Manually remove the Commons Follow module as a dependency until +; https://www.drupal.org/node/766264 is fixed. Commons Follow dynamically adds a +; views pane for events the user follows which causes Commons Events to appear +; overridden. +features_exclude[dependencies][commons_follow] = commons_follow +features_exclude[dependencies][commons_trusted_contacts] = commons_trusted_contacts + +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_events/commons_events.install b/modules/commons/commons_events/commons_events.install index c6fba50..9cdcb0a 100644 --- a/modules/commons/commons_events/commons_events.install +++ b/modules/commons/commons_events/commons_events.install @@ -272,3 +272,37 @@ function commons_events_update_7014() { features_revert($revert); return array(); } + +/** + * Ensure that the target comments field instance used for custom event messages + * is detected and fix Commons Events appearing overridden. + */ +function commons_events_update_7015() { + $revert = array( + 'commons_events' => array('field_instance'), + ); + features_revert($revert); + return array(); +} + +/** + * Move event menu item handling from menu links to page manager pages. + */ +function commons_events_update_7016() { + $revert = array( + 'commons_events' => array('page_manager_pages'), + ); + features_revert($revert); + return array(); +} + +/** + * Standardize browsing widget field weights. + */ +function commons_events_update_7017() { + $revert = array( + 'commons_events' => array('field_instance'), + ); + features_revert($revert); + return array(); +} diff --git a/modules/commons/commons_events/commons_events.module b/modules/commons/commons_events/commons_events.module index 317aeae..1bef11b 100644 --- a/modules/commons/commons_events/commons_events.module +++ b/modules/commons/commons_events/commons_events.module @@ -51,7 +51,7 @@ function commons_events_menu_alter(&$items) { * Access callback for showing the Attendees tab. */ function commons_events_attendee_access($event_node) { - if ($event_node->type == 'event') { + if ($event_node->type == 'event' && user_access('view event registration')) { return TRUE; } @@ -229,12 +229,18 @@ function commons_events_entity_view_alter(&$build, $type) { } /** - * Implements hook_form_FORM_ID_alter(). + * Implements hook_form_BASE_FORM_ID_alter(). */ function commons_events_form_node_form_alter(&$form, &$form_state, $form_id) { $node = $form_state['node']; - if ($node->type == 'event') { + list(, , $bundle) = entity_extract_ids('node', $node); + + if ($bundle == 'event' && empty($node->nid)) { + drupal_set_title(t('Create an event')); + } + + if ($bundle == 'event') { // Attach custom CSS and JS to the form. $form['#attached']['css'][] = drupal_get_path('module', 'commons_events') . '/css/commons_events.css'; $form['#attached']['js'][] = drupal_get_path('module', 'commons_events') . '/js/commons_events.js'; @@ -319,11 +325,11 @@ function commons_events_form_node_form_alter(&$form, &$form_state, $form_id) { $form['event_registration_settings']['field_registration'] = $form['field_registration']; // Unset all of the original registration settings. - unset($form['field_organizers']); - unset($form['field_registration_type']); - unset($form['field_status']); - unset($form['field_number_of_attendees']); - unset($form['field_registration']); + hide($form['field_organizers']); + hide($form['field_registration_type']); + hide($form['field_status']); + hide($form['field_number_of_attendees']); + hide($form['field_registration']); // Add additional submission and validation handlers. $form['#validate'][] = 'commons_events_node_form_validate'; @@ -623,7 +629,7 @@ function theme_commons_events_date_display_range_advanced($variables) { } /** - * Implements commons_notify_message_selection_alter(). + * Implements hook_commons_notify_message_selection_alter(). */ function commons_events_commons_notify_message_selection_alter(&$message_type, $hook, $node) { // Provide a special message type that describes the event details diff --git a/modules/commons/commons_events/commons_events.strongarm.inc b/modules/commons/commons_events/commons_events.strongarm.inc index a613917..e31a500 100644 --- a/modules/commons/commons_events/commons_events.strongarm.inc +++ b/modules/commons/commons_events/commons_events.strongarm.inc @@ -59,6 +59,40 @@ function commons_events_strongarm() { $strongarm->value = 1; $export['comment_subject_field_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 = 'field_bundle_settings_message__commons_events_event_node_created'; + $strongarm->value = array( + 'view_modes' => array(), + 'extra_fields' => array( + 'form' => array(), + 'display' => array( + 'message__message_text__0' => array( + 'message_notify_email_subject' => array( + 'visible' => TRUE, + 'weight' => 0, + ), + 'message_notify_email_body' => array( + 'visible' => FALSE, + 'weight' => 0, + ), + ), + 'message__message_text__1' => array( + 'message_notify_email_subject' => array( + 'visible' => FALSE, + 'weight' => 0, + ), + 'message_notify_email_body' => array( + 'visible' => TRUE, + 'weight' => 0, + ), + ), + ), + ), + ); + $export['field_bundle_settings_message__commons_events_event_node_created'] = $strongarm; + $strongarm = new stdClass(); $strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */ $strongarm->api_version = 1; diff --git a/modules/commons/commons_events/commons_events.views_default.inc b/modules/commons/commons_events/commons_events.views_default.inc index 85b752a..b37dc1e 100644 --- a/modules/commons/commons_events/commons_events.views_default.inc +++ b/modules/commons/commons_events/commons_events.views_default.inc @@ -701,68 +701,6 @@ function commons_events_views_default_views() { $handler->display->display_options['arguments']['uid']['summary']['number_of_records'] = '0'; $handler->display->display_options['arguments']['uid']['summary']['format'] = 'default_summary'; $handler->display->display_options['arguments']['uid']['summary_options']['items_per_page'] = '25'; - - /* Display: You follow - pane */ - $handler = $view->new_display('panel_pane', 'You follow - pane', 'panel_pane_3'); - $handler->display->display_options['defaults']['title'] = FALSE; - $handler->display->display_options['title'] = 'You follow'; - $handler->display->display_options['defaults']['hide_admin_links'] = FALSE; - $handler->display->display_options['defaults']['style_plugin'] = FALSE; - $handler->display->display_options['style_plugin'] = 'default'; - $handler->display->display_options['defaults']['style_options'] = FALSE; - $handler->display->display_options['defaults']['row_plugin'] = FALSE; - $handler->display->display_options['row_plugin'] = 'fields'; - $handler->display->display_options['row_options']['inline'] = array( - 'capacity_used' => 'capacity_used', - 'comment_count' => 'comment_count', - ); - $handler->display->display_options['defaults']['row_options'] = FALSE; - $handler->display->display_options['defaults']['empty'] = FALSE; - $handler->display->display_options['defaults']['relationships'] = FALSE; - /* Relationship: Flags: commons_follow_node */ - $handler->display->display_options['relationships']['flag_content_rel']['id'] = 'flag_content_rel'; - $handler->display->display_options['relationships']['flag_content_rel']['table'] = 'node'; - $handler->display->display_options['relationships']['flag_content_rel']['field'] = 'flag_content_rel'; - $handler->display->display_options['relationships']['flag_content_rel']['flag'] = 'commons_follow_node'; - $handler->display->display_options['defaults']['fields'] = FALSE; - /* Field: Content: Title */ - $handler->display->display_options['fields']['title_field']['id'] = 'title_field'; - $handler->display->display_options['fields']['title_field']['table'] = 'field_data_title_field'; - $handler->display->display_options['fields']['title_field']['field'] = 'title_field'; - $handler->display->display_options['fields']['title_field']['label'] = ''; - $handler->display->display_options['fields']['title_field']['link_to_entity'] = 1; - /* Field: Content: Address */ - $handler->display->display_options['fields']['field_address']['id'] = 'field_address'; - $handler->display->display_options['fields']['field_address']['table'] = 'field_data_field_address'; - $handler->display->display_options['fields']['field_address']['field'] = 'field_address'; - $handler->display->display_options['fields']['field_address']['label'] = ''; - $handler->display->display_options['fields']['field_address']['element_label_colon'] = FALSE; - $handler->display->display_options['fields']['field_address']['click_sort_column'] = 'country'; - $handler->display->display_options['fields']['field_address']['settings'] = array( - 'use_widget_handlers' => 1, - 'format_handlers' => array( - 'address' => 'address', - ), - ); - /* Field: Registration Settings: Spaces used */ - $handler->display->display_options['fields']['capacity_used']['id'] = 'capacity_used'; - $handler->display->display_options['fields']['capacity_used']['table'] = 'node'; - $handler->display->display_options['fields']['capacity_used']['field'] = 'capacity_used'; - $handler->display->display_options['fields']['capacity_used']['label'] = ''; - $handler->display->display_options['fields']['capacity_used']['alter']['alter_text'] = TRUE; - $handler->display->display_options['fields']['capacity_used']['alter']['text'] = '[capacity_used] attendees,'; - $handler->display->display_options['fields']['capacity_used']['element_label_colon'] = FALSE; - $handler->display->display_options['fields']['capacity_used']['separator'] = ''; - /* Field: Content: Comment count */ - $handler->display->display_options['fields']['comment_count']['id'] = 'comment_count'; - $handler->display->display_options['fields']['comment_count']['table'] = 'node_comment_statistics'; - $handler->display->display_options['fields']['comment_count']['field'] = 'comment_count'; - $handler->display->display_options['fields']['comment_count']['label'] = ''; - $handler->display->display_options['fields']['comment_count']['alter']['alter_text'] = TRUE; - $handler->display->display_options['fields']['comment_count']['alter']['text'] = '[comment_count] comments'; - $handler->display->display_options['fields']['comment_count']['element_label_colon'] = FALSE; - $handler->display->display_options['fields']['comment_count']['separator'] = ''; - $handler->display->display_options['defaults']['arguments'] = FALSE; $translatables['commons_events_user_upcoming_events'] = array( t('Master'), t('more'), diff --git a/modules/commons/commons_events/includes/commons_events.forms.inc b/modules/commons/commons_events/includes/commons_events.forms.inc index f2614cd..1116047 100644 --- a/modules/commons/commons_events/includes/commons_events.forms.inc +++ b/modules/commons/commons_events/includes/commons_events.forms.inc @@ -30,7 +30,7 @@ function commons_events_attend_event_form($form, &$form_state, $event_node, $reg $form['count'] = array( '#type' => 'textfield', '#default_value' => '0', - '#description' => ' + Guests', + '#description' => t('+ Guests'), '#size' => 2, '#maxlength' => 2, '#required' => false, @@ -94,7 +94,12 @@ function commons_events_attend_event_form_submit($form, $form_state) { $registration->count = $form_state['values']['count']; if (registration_save($registration)) { drupal_set_message(t('Your registration was saved.')); - commons_follow_node_follow_node($registration->entity_id, 'event', $user->uid); + + // Have the user automatically follow the event if Commons Follow (Node) is + // enabled. + if (module_exists('commons_follow_node')) { + commons_follow_node_follow_node($registration->entity_id, 'event', $user->uid); + } } else { drupal_set_message(t('There was an error saving your registration.')); diff --git a/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.info b/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.info index 555386f..0212d92 100644 --- a/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.info +++ b/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.info @@ -1,10 +1,12 @@ name = Commons Events Pages -description = Provides the panelized Event page feature. +description = Enhances the appearance of event nodes by listing the event organizers/attendees and allows them to be customized. core = 7.x package = Commons - Landing pages + dependencies[] = commons_events dependencies[] = panelizer dependencies[] = strongarm + features[ctools][] = panelizer:panelizer:1 features[ctools][] = strongarm:strongarm:1 features[ctools][] = page_manager:pages_default:1 @@ -12,12 +14,10 @@ features[features_api][] = api:2 features[page_manager_pages][] = views_events_landing_page features[panelizer_defaults][] = node:event:default features[variable][] = panelizer_defaults_node_event -files[] = commons_events_pages.features.inc -files[] = commons_events_pages.strongarm.inc -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.pages_default.inc b/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.pages_default.inc index d650ff7..8387104 100644 --- a/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.pages_default.inc +++ b/modules/commons/commons_events/modules/commons_events_pages/commons_events_pages.pages_default.inc @@ -1,13 +1,13 @@ disabled = FALSE; /* Edit this to true to make a default page disabled initially */ $page->api_version = 1; @@ -20,7 +20,18 @@ function commons_events_pages_default_page_manager_pages() { 'type' => 'none', 'settings' => NULL, ); - $page->menu = array(); + $page->menu = array( + 'type' => 'normal', + 'title' => 'Events', + 'weight' => '2', + 'name' => 'main-menu', + 'parent' => array( + 'type' => 'none', + 'title' => '', + 'weight' => 0, + 'name' => 'navigation', + ), + ); $page->arguments = array(); $page->conf = array( 'admin_paths' => FALSE, diff --git a/modules/commons/commons_events/modules/commons_events_solr/commons_events_solr.info b/modules/commons/commons_events/modules/commons_events_solr/commons_events_solr.info index 65c06fe..cfc24bf 100644 --- a/modules/commons/commons_events/modules/commons_events_solr/commons_events_solr.info +++ b/modules/commons/commons_events/modules/commons_events_solr/commons_events_solr.info @@ -1,7 +1,8 @@ -name = Commons Events - Solr -description = Provides the Solr based faceted search for events -core = 7.x +name = Commons Search SOLR Event +description = Adds support for searching events to the Commons Search SOLR module. package = Commons - Search +core = 7.x + dependencies[] = apachesolr_search dependencies[] = commons_events dependencies[] = ctools @@ -9,6 +10,7 @@ dependencies[] = facetapi dependencies[] = page_manager dependencies[] = pm_existing_pages dependencies[] = strongarm + features[apachesolr_search_page][] = solr_events features[ctools][] = apachesolr_search:apachesolr_search_defaults:3 features[ctools][] = facetapi:facetapi_defaults:1 @@ -20,9 +22,9 @@ features[page_manager_existing_pages][] = solr_events_search features[page_manager_handlers][] = pm_existing_pages_solr_events_search_panel_context features[variable][] = pm_existing_pages_disabled_solr_events_search -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_featured/commons_featured.info b/modules/commons/commons_featured/commons_featured.info index 5fb4b9b..12aabc8 100644 --- a/modules/commons/commons_featured/commons_featured.info +++ b/modules/commons/commons_featured/commons_featured.info @@ -1,16 +1,18 @@ name = Commons Featured Content description = Allows community managers to display certain pieces of content more prominently on the site. -core = 7.x package = Commons - Building blocks +core = 7.x + dependencies[] = views dependencies[] = views_content + features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 features[views_view][] = commons_featured -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow.features.field_base.inc b/modules/commons/commons_follow/commons_follow.features.field_base.inc index 3e58098..539d3e0 100644 --- a/modules/commons/commons_follow/commons_follow.features.field_base.inc +++ b/modules/commons/commons_follow/commons_follow.features.field_base.inc @@ -20,14 +20,6 @@ function commons_follow_field_default_field_bases() { 'field_permissions' => array( 'type' => 0, ), - 'foreign keys' => array( - 'comment' => array( - 'columns' => array( - 'target_id' => 'cid', - ), - 'table' => 'comment', - ), - ), 'indexes' => array( 'target_id' => array( 0 => 'target_id', @@ -65,14 +57,6 @@ function commons_follow_field_default_field_bases() { 'field_permissions' => array( 'type' => 0, ), - 'foreign keys' => array( - 'node' => array( - 'columns' => array( - 'target_id' => 'nid', - ), - 'table' => 'node', - ), - ), 'indexes' => array( 'target_id' => array( 0 => 'target_id', @@ -110,14 +94,6 @@ function commons_follow_field_default_field_bases() { 'field_permissions' => array( 'type' => 0, ), - 'foreign keys' => array( - 'users' => array( - 'columns' => array( - 'target_id' => 'uid', - ), - 'table' => 'users', - ), - ), 'indexes' => array( 'target_id' => array( 0 => 'target_id', diff --git a/modules/commons/commons_follow/commons_follow.features.inc b/modules/commons/commons_follow/commons_follow.features.inc index 944fada..d418f51 100644 --- a/modules/commons/commons_follow/commons_follow.features.inc +++ b/modules/commons/commons_follow/commons_follow.features.inc @@ -4,34 +4,6 @@ * commons_follow.features.inc */ -/** - * Implements hook_features_pipe_alter(). - * - */ -function commons_follow_features_pipe_alter(&$pipe, $data, $export) { - $commons_follow_fields = array( - 'field_target_users', 'field_target_nodes', 'field_target_comments', - ); - // Prevent Commons Follow fields from being piped in features - // when a content type includes those fields. - if (!empty($pipe['field_instance'])) { - foreach ($pipe['field_instance'] as $delta => $value) { - $args = explode('-', $value); - $field_name = $args[2]; - if (in_array($field_name, $commons_follow_fields)) { - unset($pipe['field_instance'][$delta]); - } - } - } - if (!empty($pipe['field_base'])) { - foreach ($pipe['field_base'] as $delta => $value) { - if (in_array($delta, $commons_follow_fields)) { - unset($pipe['field_base'][$delta]); - } - } - } -} - /** * Implements hook_ctools_plugin_api(). */ @@ -50,16 +22,8 @@ function commons_follow_image_default_styles() { // Exported image style: 50x50_avatar. $styles['50x50_avatar'] = array( 'label' => '50x50_avatar', - 'name' => '50x50_avatar', 'effects' => array( 3 => array( - 'label' => 'Scale and crop', - 'help' => 'Scale and crop will maintain the aspect-ratio of the original image, then crop the larger dimension. This is most useful for creating perfectly square thumbnails without stretching the image.', - 'effect callback' => 'image_scale_and_crop_effect', - 'dimensions callback' => 'image_resize_dimensions', - 'form callback' => 'image_resize_form', - 'summary theme' => 'image_resize_summary', - 'module' => 'image', 'name' => 'image_scale_and_crop', 'data' => array( 'width' => 50, diff --git a/modules/commons/commons_follow/commons_follow.info b/modules/commons/commons_follow/commons_follow.info index 2f8889c..1315048 100644 --- a/modules/commons/commons_follow/commons_follow.info +++ b/modules/commons/commons_follow/commons_follow.info @@ -1,13 +1,15 @@ name = Commons Follow -description = Views and Field integration for Commons Following functionality. -core = 7.x +description = Provides a framework for allowing users to follow entities. package = Commons - Building blocks +core = 7.x + dependencies[] = ctools dependencies[] = entityreference dependencies[] = features dependencies[] = field_sql_storage dependencies[] = message_subscribe dependencies[] = strongarm + features[ctools][] = strongarm:strongarm:1 features[features_api][] = api:2 features[field_base][] = field_target_comments @@ -15,7 +17,9 @@ features[field_base][] = field_target_nodes features[field_base][] = field_target_users features[image][] = 50x50_avatar features[variable][] = message_subscribe_flag_prefix + features_exclude[dependencies][image] = image + files[] = includes/views/commons_follow.views.inc files[] = includes/views/handlers/commons_follow_handler_filter_follow.inc files[] = includes/views/handlers/commons_follow_plugin_argument_default_node.inc @@ -23,9 +27,10 @@ files[] = includes/views/handlers/commons_follow_plugin_argument_default_message files[] = includes/views/handlers/commons_follow_user_follow_filter.inc files[] = includes/views/handlers/commons_follow_user_follow_filter_message.inc files[] = includes/views/handlers/commons_follow_handler_field_ops.inc -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" + +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow.module b/modules/commons/commons_follow/commons_follow.module index ddc0a94..5fa62f8 100644 --- a/modules/commons/commons_follow/commons_follow.module +++ b/modules/commons/commons_follow/commons_follow.module @@ -25,6 +25,73 @@ function commons_follow_theme() { * Adding the "Following" filter to the group-browsing-widget views. */ function commons_follow_views_default_views_alter(&$views) { + // Add a new views pane for events the user follows. + if (isset($views['commons_events_user_upcoming_events'])) { + $view = $views['commons_events_user_upcoming_events']; + + /* Display: You follow - pane */ + $handler = $view->new_display('panel_pane', 'You follow - pane', 'panel_pane_3'); + $handler->display->display_options['defaults']['title'] = FALSE; + $handler->display->display_options['title'] = 'You follow'; + $handler->display->display_options['defaults']['hide_admin_links'] = FALSE; + $handler->display->display_options['defaults']['style_plugin'] = FALSE; + $handler->display->display_options['style_plugin'] = 'default'; + $handler->display->display_options['defaults']['style_options'] = FALSE; + $handler->display->display_options['defaults']['row_plugin'] = FALSE; + $handler->display->display_options['row_plugin'] = 'fields'; + $handler->display->display_options['row_options']['inline'] = array( + 'capacity_used' => 'capacity_used', + 'comment_count' => 'comment_count', + ); + $handler->display->display_options['defaults']['row_options'] = FALSE; + $handler->display->display_options['defaults']['empty'] = FALSE; + $handler->display->display_options['defaults']['relationships'] = FALSE; + /* Relationship: Flags: commons_follow_node */ + $handler->display->display_options['relationships']['flag_content_rel']['id'] = 'flag_content_rel'; + $handler->display->display_options['relationships']['flag_content_rel']['table'] = 'node'; + $handler->display->display_options['relationships']['flag_content_rel']['field'] = 'flag_content_rel'; + $handler->display->display_options['relationships']['flag_content_rel']['flag'] = 'commons_follow_node'; + $handler->display->display_options['defaults']['fields'] = FALSE; + /* Field: Content: Title */ + $handler->display->display_options['fields']['title_field']['id'] = 'title_field'; + $handler->display->display_options['fields']['title_field']['table'] = 'field_data_title_field'; + $handler->display->display_options['fields']['title_field']['field'] = 'title_field'; + $handler->display->display_options['fields']['title_field']['label'] = ''; + $handler->display->display_options['fields']['title_field']['link_to_entity'] = 1; + /* Field: Content: Address */ + $handler->display->display_options['fields']['field_address']['id'] = 'field_address'; + $handler->display->display_options['fields']['field_address']['table'] = 'field_data_field_address'; + $handler->display->display_options['fields']['field_address']['field'] = 'field_address'; + $handler->display->display_options['fields']['field_address']['label'] = ''; + $handler->display->display_options['fields']['field_address']['element_label_colon'] = FALSE; + $handler->display->display_options['fields']['field_address']['click_sort_column'] = 'country'; + $handler->display->display_options['fields']['field_address']['settings'] = array( + 'use_widget_handlers' => 1, + 'format_handlers' => array( + 'address' => 'address', + ), + ); + /* Field: Registration Settings: Spaces used */ + $handler->display->display_options['fields']['capacity_used']['id'] = 'capacity_used'; + $handler->display->display_options['fields']['capacity_used']['table'] = 'node'; + $handler->display->display_options['fields']['capacity_used']['field'] = 'capacity_used'; + $handler->display->display_options['fields']['capacity_used']['label'] = ''; + $handler->display->display_options['fields']['capacity_used']['alter']['alter_text'] = TRUE; + $handler->display->display_options['fields']['capacity_used']['alter']['text'] = '[capacity_used] attendees,'; + $handler->display->display_options['fields']['capacity_used']['element_label_colon'] = FALSE; + $handler->display->display_options['fields']['capacity_used']['separator'] = ''; + /* Field: Content: Comment count */ + $handler->display->display_options['fields']['comment_count']['id'] = 'comment_count'; + $handler->display->display_options['fields']['comment_count']['table'] = 'node_comment_statistics'; + $handler->display->display_options['fields']['comment_count']['field'] = 'comment_count'; + $handler->display->display_options['fields']['comment_count']['label'] = ''; + $handler->display->display_options['fields']['comment_count']['alter']['alter_text'] = TRUE; + $handler->display->display_options['fields']['comment_count']['alter']['text'] = '[comment_count] comments'; + $handler->display->display_options['fields']['comment_count']['element_label_colon'] = FALSE; + $handler->display->display_options['fields']['comment_count']['separator'] = ''; + $handler->display->display_options['defaults']['arguments'] = FALSE; + } + // Add a "most active" exposed sort to Commons BW views. foreach ($views as $view_id => $view) { if (strpos($view_id, 'commons_bw_') !== 0) { diff --git a/modules/commons/commons_follow/commons_follow_group/commons_follow_group.info b/modules/commons/commons_follow/commons_follow_group/commons_follow_group.info index f821235..cdab940 100644 --- a/modules/commons/commons_follow/commons_follow_group/commons_follow_group.info +++ b/modules/commons/commons_follow/commons_follow_group/commons_follow_group.info @@ -1,20 +1,22 @@ name = Commons Follow (Groups) -description = Lets users follow individual organic groups. -core = 7.x +description = Provides Organic Groups integration for Commons Follow, allowing users to follow individual groups. package = Commons - Building blocks +core = 7.x + dependencies[] = ctools dependencies[] = flag dependencies[] = og dependencies[] = strongarm + features[ctools][] = strongarm:strongarm:1 features[features_api][] = api:2 features[flag][] = commons_follow_group features[flag][] = email_group features[variable][] = message_subscribe_og -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow_node/commons_follow_node.info b/modules/commons/commons_follow/commons_follow_node/commons_follow_node.info index 7153abe..5580b47 100644 --- a/modules/commons/commons_follow/commons_follow_node/commons_follow_node.info +++ b/modules/commons/commons_follow/commons_follow_node/commons_follow_node.info @@ -1,19 +1,22 @@ -name = Commons Follow (Individual nodes) -description = Lets users follow individual nodes. -core = 7.x +name = Commons Follow (Nodes) +description = Provides Node integration for Commons Follow, allowing users to follow individual nodes. package = Commons - Building blocks +core = 7.x + dependencies[] = ctools dependencies[] = flag dependencies[] = views_litepager + features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 features[flag][] = commons_follow_node features[views_view][] = commons_follow_node + features_exclude[dependencies][views] = views -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow_term/commons_follow_term.info b/modules/commons/commons_follow/commons_follow_term/commons_follow_term.info index ab55c93..41692b2 100644 --- a/modules/commons/commons_follow/commons_follow_term/commons_follow_term.info +++ b/modules/commons/commons_follow/commons_follow_term/commons_follow_term.info @@ -1,19 +1,22 @@ -name = Commons Follow (Taxonomy terms) -description = Lets users follow individual taxonomy terms -core = 7.x +name = Commons Follow (Terms) +description = Provides Taxonomy integration for Commons Follow, allowing users to follow individual taxonomy terms. package = Commons - Building blocks +core = 7.x + dependencies[] = flag dependencies[] = views dependencies[] = views_litepager + features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 features[flag][] = commons_follow_term features[views_view][] = commons_follow_taxonomy_term + features_exclude[dependencies][ctools] = ctools -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow_term/commons_follow_term.install b/modules/commons/commons_follow/commons_follow_term/commons_follow_term.install index 77c4c76..c1a42b9 100644 --- a/modules/commons/commons_follow/commons_follow_term/commons_follow_term.install +++ b/modules/commons/commons_follow/commons_follow_term/commons_follow_term.install @@ -26,4 +26,16 @@ function commons_follow_term_update_3501() { ); features_revert($revert); return array(); +} + +/** + * Add a distinct field to the notification view to remove duplicates when + * multiple users have send email clicked. + */ +function commons_follow_term_update_3502() { + $revert = array( + 'commons_follow_term' => array('views_view'), + ); + features_revert($revert); + return array(); } \ No newline at end of file diff --git a/modules/commons/commons_follow/commons_follow_term/commons_follow_term.views_default.inc b/modules/commons/commons_follow/commons_follow_term/commons_follow_term.views_default.inc index 21e785a..24fc59c 100644 --- a/modules/commons/commons_follow/commons_follow_term/commons_follow_term.views_default.inc +++ b/modules/commons/commons_follow/commons_follow_term/commons_follow_term.views_default.inc @@ -27,6 +27,7 @@ function commons_follow_term_views_default_views() { $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['pager']['type'] = 'lite'; $handler->display->display_options['pager']['options']['items_per_page'] = '20'; diff --git a/modules/commons/commons_follow/commons_follow_ui/commons_follow_ui.info b/modules/commons/commons_follow/commons_follow_ui/commons_follow_ui.info index 19ece11..9e02ff8 100644 --- a/modules/commons/commons_follow/commons_follow_ui/commons_follow_ui.info +++ b/modules/commons/commons_follow/commons_follow_ui/commons_follow_ui.info @@ -1,14 +1,15 @@ -name = "Commons Follow UI" -description = "User interface for the Commons Follow functionality" -core = 7.x +name = Commons Follow User Interface +description = Integrates with Message Subscribe UI to provide users with a user interface for managing the entities they follow and associated notification settings. package = Commons - Building blocks +core = 7.x + dependencies[] = commons_follow dependencies[] = message_subscribe_ui dependencies[] = quicktabs -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.features.inc b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.features.inc index 2548e96..79061c5 100644 --- a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.features.inc +++ b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.features.inc @@ -91,11 +91,7 @@ function commons_follow_user_default_message_type() { "language" : "", "arguments" : null, "message_text" : { "und" : [ - { - "value" : "[message:user:picture]", - "format" : "filtered_html", - "safe_value" : "[message:user:picture]" - }, + { "value" : "[message:user:picture]", "format" : "filtered_html" }, { "value" : "\\u003Ca href=\\u0022[message:user:url:absolute]\\u0022\\u003E[message:user:name]\\u003C\\/a\\u003E is now following \\u003Ca href=\\u0022[message:field-target-users:0:url]\\u0022\\u003E[message:field-target-users:0:name]\\u003C\\/a\\u003E", "format" : "full_html", diff --git a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.info b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.info index 72639db..fc8cc14 100644 --- a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.info +++ b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.info @@ -1,27 +1,35 @@ name = Commons Follow (Users) -description = Lets users follow other users. -core = 7.x +description = Provides User integration for Commons Follow, allowing users to follow other users. package = Commons - Building blocks +core = 7.x + dependencies[] = commons_follow +dependencies[] = ctools +dependencies[] = entity dependencies[] = entityreference +dependencies[] = features dependencies[] = flag dependencies[] = message +dependencies[] = strongarm dependencies[] = views dependencies[] = views_content dependencies[] = views_litepager dependencies[] = views_load_more + +features[ctools][] = strongarm:strongarm:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 features[field_instance][] = message-commons_follow_user_user_followed-field_target_users features[flag][] = commons_follow_user features[message_type][] = commons_follow_user_user_followed +features[variable][] = field_bundle_settings_message__commons_follow_user_user_followed features[views_view][] = commons_follow_user features[views_view][] = commons_follow_user_followers features[views_view][] = commons_follow_user_following -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.install b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.install index 2a02786..e59f124 100644 --- a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.install +++ b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.install @@ -37,4 +37,15 @@ function commons_follow_user_update_3502() { ); features_revert($revert); return array(); -} \ No newline at end of file +} + +/** + * Accommodate changes to message definitions. + */ +function commons_follow_user_update_3503() { + $revert = array( + 'commons_follow_user' => array('message_type'), + ); + features_revert($revert); + return array(); +} diff --git a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.module b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.module index 1f8222d..0f4cac6 100644 --- a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.module +++ b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.module @@ -6,8 +6,6 @@ include_once 'commons_follow_user.features.inc'; - - /** * Implements hook_commons_follow_get_nids(). */ @@ -61,22 +59,9 @@ function commons_follow_user_commons_follow_get_nids($account, $options) { } } - return $nids; } -/** -* Implements hook_system_info_alter(). -*/ -function commons_follow_user_system_info_alter(&$info, $file, $type) { - // If Message.module is enabled, we'll define our "User follows another user" - // message type and will need to add to it an instance of field_target_users. - if ($file->name == 'commons_follow_user' && module_exists('message')) { - $info['features']['field_instance'][] = 'message-commons_follow_user_user_followed-field_target_users'; - $info['features']['message_type'][] = 'commons_follow_user_user_followed'; - } -} - /** * Implements hook_flag(). */ @@ -101,9 +86,9 @@ function commons_follow_user_flag($op, $flag, $content_id, $account, $fcid) { } /** -* Indicate whether there is an existing message about a given user following -* a target user. -*/ + * Indicate whether there is an existing message about a given user following + * a target user. + */ function commons_follow_user_existing_follow_message($acting_uid, $target_uids) { $query = new EntityFieldQuery(); $query->entityCondition('entity_type', 'message', '=') @@ -115,10 +100,9 @@ function commons_follow_user_existing_follow_message($acting_uid, $target_uids) return !empty($query->ordered_results); } - /** -* Implements hook_commons_follow_get_message_ids(). -*/ + * Implements hook_commons_follow_get_message_ids(). + */ function commons_follow_user_commons_follow_get_message_ids(&$followed_mids, $followed_content = array()) { // If the user isn't following any other users, we've nothing to do here. if (empty($followed_content['commons_follow_user'])) { @@ -135,4 +119,4 @@ function commons_follow_user_commons_follow_get_message_ids(&$followed_mids, $fo foreach ($result as $this_result) { $followed_mids[] = $this_result->mid; } -} \ No newline at end of file +} diff --git a/modules/commons/commons_follow/commons_follow_user/commons_follow_user.strongarm.inc b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.strongarm.inc new file mode 100644 index 0000000..ccedd99 --- /dev/null +++ b/modules/commons/commons_follow/commons_follow_user/commons_follow_user.strongarm.inc @@ -0,0 +1,48 @@ +disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */ + $strongarm->api_version = 1; + $strongarm->name = 'field_bundle_settings_message__commons_follow_user_user_followed'; + $strongarm->value = array( + 'view_modes' => array(), + 'extra_fields' => array( + 'form' => array(), + 'display' => array( + 'message__message_text__0' => array( + 'message_notify_email_subject' => array( + 'visible' => TRUE, + 'weight' => 0, + ), + 'message_notify_email_body' => array( + 'visible' => FALSE, + 'weight' => 0, + ), + ), + 'message__message_text__1' => array( + 'message_notify_email_subject' => array( + 'visible' => FALSE, + 'weight' => 0, + ), + 'message_notify_email_body' => array( + 'visible' => TRUE, + 'weight' => 0, + ), + ), + ), + ), + ); + $export['field_bundle_settings_message__commons_follow_user_user_followed'] = $strongarm; + + return $export; +} diff --git a/modules/commons/commons_groups/commons_groups.features.field_base.inc b/modules/commons/commons_groups/commons_groups.features.field_base.inc index f60237e..93fb90f 100644 --- a/modules/commons/commons_groups/commons_groups.features.field_base.inc +++ b/modules/commons/commons_groups/commons_groups.features.field_base.inc @@ -17,7 +17,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'group_access', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', @@ -44,7 +43,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'group_content_access', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', @@ -72,7 +70,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'field_og_access_default_value', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', @@ -98,7 +95,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'field_og_subscribe_settings', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', @@ -130,7 +126,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'group_group', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', @@ -157,14 +152,6 @@ function commons_groups_field_default_field_bases() { 'entity_types' => array(), 'description' => 'Separate group names with commas', 'field_name' => 'og_group_ref', - 'foreign keys' => array( - 'node' => array( - 'columns' => array( - 'target_id' => 'nid', - ), - 'table' => 'node', - ), - ), 'indexes' => array( 'target_id' => array( 0 => 'target_id', @@ -207,14 +194,6 @@ function commons_groups_field_default_field_bases() { 0 => 'og_membership', ), 'field_name' => 'og_membership_request', - 'foreign keys' => array( - 'format' => array( - 'columns' => array( - 'format' => 'format', - ), - 'table' => 'filter_format', - ), - ), 'indexes' => array( 'format' => array( 0 => 'format', @@ -234,14 +213,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'field_group_logo', - 'foreign keys' => array( - 'fid' => array( - 'columns' => array( - 'fid' => 'fid', - ), - 'table' => 'file_managed', - ), - ), 'indexes' => array( 'fid' => array( 0 => 'fid', @@ -264,7 +235,6 @@ function commons_groups_field_default_field_bases() { 'deleted' => '0', 'entity_types' => array(), 'field_name' => 'og_roles_permissions', - 'foreign keys' => array(), 'indexes' => array( 'value' => array( 0 => 'value', diff --git a/modules/commons/commons_groups/commons_groups.features.inc b/modules/commons/commons_groups/commons_groups.features.inc index 48e20fd..6915706 100644 --- a/modules/commons/commons_groups/commons_groups.features.inc +++ b/modules/commons/commons_groups/commons_groups.features.inc @@ -55,16 +55,8 @@ function commons_groups_image_default_styles() { // Exported image style: 35x35. $styles['35x35'] = array( 'label' => '35x35', - 'name' => '35x35', 'effects' => array( 1 => array( - 'label' => 'Scale and crop', - 'help' => 'Scale and crop will maintain the aspect-ratio of the original image, then crop the larger dimension. This is most useful for creating perfectly square thumbnails without stretching the image.', - 'effect callback' => 'image_scale_and_crop_effect', - 'dimensions callback' => 'image_resize_dimensions', - 'form callback' => 'image_resize_form', - 'summary theme' => 'image_resize_summary', - 'module' => 'image', 'name' => 'image_scale_and_crop', 'data' => array( 'width' => 35, @@ -78,16 +70,8 @@ function commons_groups_image_default_styles() { // Exported image style: 50x50. $styles['50x50'] = array( 'label' => '50x50', - 'name' => '50x50', 'effects' => array( 2 => array( - 'label' => 'Scale and crop', - 'help' => 'Scale and crop will maintain the aspect-ratio of the original image, then crop the larger dimension. This is most useful for creating perfectly square thumbnails without stretching the image.', - 'effect callback' => 'image_scale_and_crop_effect', - 'dimensions callback' => 'image_resize_dimensions', - 'form callback' => 'image_resize_form', - 'summary theme' => 'image_resize_summary', - 'module' => 'image', 'name' => 'image_scale_and_crop', 'data' => array( 'width' => 50, diff --git a/modules/commons/commons_groups/commons_groups.info b/modules/commons/commons_groups/commons_groups.info index fd467bc..3915320 100644 --- a/modules/commons/commons_groups/commons_groups.info +++ b/modules/commons/commons_groups/commons_groups.info @@ -1,9 +1,9 @@ name = Commons Groups -description = Commons Organic Groups Functionality -core = 7.x +description = Allows content to be organized into groups. package = Commons - Building blocks +core = 7.x + dependencies[] = commons_body -dependencies[] = commons_bw dependencies[] = commons_topics dependencies[] = ctools dependencies[] = date @@ -27,6 +27,7 @@ dependencies[] = views dependencies[] = views_content dependencies[] = views_litepager dependencies[] = views_load_more + features[ctools][] = strongarm:strongarm:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 @@ -39,8 +40,6 @@ features[field_base][] = group_group features[field_base][] = og_group_ref features[field_base][] = og_membership_request features[field_base][] = og_roles_permissions -features[field_instance][] = node-group-body -features[field_instance][] = node-group-group_group features[field_instance][] = og_membership-og_membership_type_default-og_membership_request features[image][] = 35x35 features[image][] = 50x50 @@ -49,20 +48,8 @@ features[og_features_permission][] = user:user:subscribe features[og_features_permission][] = user:user:subscribe without approval features[user_permission][] = create group content features[user_permission][] = edit own group content -features[variable][] = comment_anonymous_group -features[variable][] = comment_default_mode_group -features[variable][] = comment_default_per_page_group -features[variable][] = comment_form_location_group -features[variable][] = comment_group -features[variable][] = comment_preview_group -features[variable][] = comment_subject_field_group -features[variable][] = field_bundle_settings_node__group features[variable][] = menu_options_group features[variable][] = menu_parent_group -features[variable][] = node_options_group -features[variable][] = node_preview_group -features[variable][] = node_submitted_group -features[variable][] = og_group_manager_default_rids_node_group features[variable][] = pathauto_node_group_pattern features[variable][] = pathauto_node_pattern features[views_view][] = commons_bw_all @@ -72,12 +59,10 @@ features[views_view][] = commons_groups_contributors features[views_view][] = commons_groups_directory features[views_view][] = commons_groups_recent_content features[views_view][] = commons_groups_user_groups -features_exclude[field][node-group-group_group] = node-group-group_group -features_exclude[field][node-group-group_access] = node-group-group_access -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_groups/commons_groups.install b/modules/commons/commons_groups/commons_groups.install index e345e8d..f7762d3 100644 --- a/modules/commons/commons_groups/commons_groups.install +++ b/modules/commons/commons_groups/commons_groups.install @@ -253,4 +253,37 @@ function commons_groups_update_3120() { ); features_revert($revert); return array(); +} + +/** + * Fix URL aliases for group references + */ +function commons_groups_update_3121() { + $revert = array( + 'commons_groups' => array('variable'), + ); + features_revert($revert); + return array(); +} + +/** + * Revert the contributors view to hide 'more' link and show a pager. + */ +function commons_groups_update_3122() { + $revert = array( + 'commons_groups' => array('views_view'), + ); + features_revert($revert); + return array(); +} + +/** + * Revert the group view to display a link to the groups a user contributes to. + */ +function commons_groups_update_3170() { + $revert = array( + 'commons_groups' => array('views_view'), + ); + features_revert($revert); + return array(); } \ No newline at end of file diff --git a/modules/commons/commons_groups/commons_groups.module b/modules/commons/commons_groups/commons_groups.module index cf535a3..1866973 100644 --- a/modules/commons/commons_groups/commons_groups.module +++ b/modules/commons/commons_groups/commons_groups.module @@ -444,6 +444,29 @@ function commons_groups_system_info_alter(&$info, $file, $type) { } } } + + // Dynamically adding a field instance to an entity type results in features + // automatically detecting Commons Groups as a dependency. + // We manually exclude the dependency in order to prevent entity type provider + // modules from appearing overridden and to allow them to be used + // independently of Commons Groups. + $commons_entity_integrations = &drupal_static(__FUNCTION__); + + if (!isset($commons_entity_integrations)) { + foreach (module_implements('commons_entity_integration') as $module) { + $commons_entity_integrations[$module] = call_user_func($module . '_commons_entity_integration'); + } + } + + if (isset($commons_entity_integrations[$file->name])) { + foreach ($commons_entity_integrations[$file->name] as $entity_type => $integration) { + foreach ($integration as $bundle => $options) { + if (commons_groups_is_group_content($entity_type, $bundle)) { + $info['features_exclude']['dependencies']['commons_groups'] = 'commons_groups'; + } + } + } + } } /** @@ -506,7 +529,7 @@ function commons_groups_token_info() { ); $tokens['commons-groups']['in-groups-text'] = array( 'name' => t('"In groups" text'), - 'description' => t('The text (starting with "in the groups") indicating which groups a peice of content belongs to.'), + 'description' => t('The text (starting with "in the groups") indicating which groups a piece of content belongs to.'), ); $tokens['node']['commons-groups-first-group'] = array( 'name' => t('First Group'), @@ -522,7 +545,6 @@ function commons_groups_token_info() { ); } - /** * Implements hook_tokens(). */ @@ -566,7 +588,7 @@ function commons_groups_tokens($type, $tokens, $data = array(), $options = array } } } - // If no groups are associated with any of the targett nodes, + // If no groups are associated with any of the target nodes, // then we have no "in the groups" text. if (empty($related_gids)) { $replacements['[commons-groups:in-groups-text]'] = ''; @@ -832,6 +854,24 @@ function commons_groups_set_group_permissions($node) { } } +/** + * Helper function to determine whether an entity bundle is considered group + * content. + * + * @param $entity_type + * The entity type to check group content settings for. + * @param $bundle + * The entity bundle to check group content settings for. + * + * @return boolean + * The value of the group content setting if available, FALSE otherwise. + */ +function commons_groups_is_group_content($entity_type, $bundle) { + $commons_groups_entity_types = commons_groups_get_group_content_entity_types(); + + return isset($commons_groups_entity_types[$entity_type][$bundle]['is_group_content']) ? $commons_groups_entity_types[$entity_type][$bundle]['is_group_content'] : FALSE; +} + /** * Returns an array of entity types that are enabled via Commons Groups. */ @@ -1046,13 +1086,18 @@ function commons_groups_field_formatter_view($entity_type, $entity, $field, $ins return; } if (og_is_member($entity_type, $id, 'user', $account)) { - // The user has an active membership. She can leave the group. - // For groups where anyone can contribute without joining, don't display - // a "Leave" link since users never went through - // the separate step of joining. - if (og_is_member($entity_type, $id, 'user', $account, array(OG_STATE_ACTIVE)) && $entity->field_og_subscribe_settings[LANGUAGE_NONE][0]['value'] != 'anyone') { - $links['title'] = t('Leave group'); - $links['href'] = "group/$entity_type/$id/unsubscribe"; + // The user has an active membership. + if (og_user_access($entity_type, $id, 'unsubscribe', $account)) { + // The user has the permission to unsubscribe himself, + // otherwise don't display a "Leave" link since the user can't leave + // anyways. + // For groups where anyone can contribute without joining, don't display + // a "Leave" link since users never went through + // the separate step of joining. + if (og_is_member($entity_type, $id, 'user', $account, array(OG_STATE_ACTIVE)) && $entity->field_og_subscribe_settings[LANGUAGE_NONE][0]['value'] != 'anyone') { + $links['title'] = t('Leave group'); + $links['href'] = "group/$entity_type/$id/unsubscribe"; + } } } else { @@ -1160,6 +1205,11 @@ function commons_groups_features_permission_rebuild($module, $gid) { module_load_include('features.inc', 'og', '/includes/og_features_role'); if ($defaults = features_get_default('og_features_permission', $module)) { + // Make sure the list of available group types is up to date, especially + // when installing multiple features at once, for example from an install + // profile or via drush. + drupal_static_reset(); + $grant = array(); $revoke = array(); diff --git a/modules/commons/commons_groups/commons_groups.views_default.inc b/modules/commons/commons_groups/commons_groups.views_default.inc index a369882..3555a6c 100644 --- a/modules/commons/commons_groups/commons_groups.views_default.inc +++ b/modules/commons/commons_groups/commons_groups.views_default.inc @@ -170,7 +170,7 @@ function commons_groups_views_default_views() { /* Display: Master */ $handler = $view->new_display('default', 'Master', 'default'); - $handler->display->display_options['title'] = 'Group members'; + $handler->display->display_options['title'] = 'Group contributors'; $handler->display->display_options['use_more'] = TRUE; $handler->display->display_options['use_more_always'] = FALSE; $handler->display->display_options['access']['type'] = 'perm'; @@ -363,6 +363,16 @@ function commons_groups_views_default_views() { $handler->display->display_options['defaults']['title'] = FALSE; $handler->display->display_options['title'] = 'Contributors to %1'; $handler->display->display_options['defaults']['hide_admin_links'] = FALSE; + $handler->display->display_options['defaults']['use_more'] = FALSE; + $handler->display->display_options['defaults']['use_more_always'] = FALSE; + $handler->display->display_options['use_more_always'] = FALSE; + $handler->display->display_options['defaults']['use_more_text'] = FALSE; + $handler->display->display_options['defaults']['pager'] = FALSE; + $handler->display->display_options['pager']['type'] = 'full'; + $handler->display->display_options['pager']['options']['items_per_page'] = '16'; + $handler->display->display_options['pager']['options']['offset'] = '0'; + $handler->display->display_options['pager']['options']['id'] = '0'; + $handler->display->display_options['pager']['options']['quantity'] = '9'; $handler->display->display_options['defaults']['style_plugin'] = FALSE; $handler->display->display_options['style_plugin'] = 'list'; $handler->display->display_options['style_options']['row_class'] = 'profile-badge'; @@ -1391,6 +1401,12 @@ function commons_groups_views_default_views() { $handler->display->display_options['fields']['title_field']['label'] = ''; $handler->display->display_options['fields']['title_field']['element_label_colon'] = FALSE; $handler->display->display_options['fields']['title_field']['link_to_entity'] = 1; + $handler->display->display_options['fields']['title_field']['type'] = 'title_linked'; + $handler->display->display_options['fields']['title_field']['settings'] = array( + 'title_style' => '_none', + 'title_link' => 'content', + 'title_class' => '', + ); /* Field: Field: Group */ $handler->display->display_options['fields']['group_group']['id'] = 'group_group'; $handler->display->display_options['fields']['group_group']['table'] = 'field_data_group_group'; diff --git a/modules/commons/commons_groups/modules/commons_groups_directory/commons_groups_directory.info b/modules/commons/commons_groups/modules/commons_groups_directory/commons_groups_directory.info index f116eaf..52930fe 100644 --- a/modules/commons/commons_groups/modules/commons_groups_directory/commons_groups_directory.info +++ b/modules/commons/commons_groups/modules/commons_groups_directory/commons_groups_directory.info @@ -1,19 +1,21 @@ name = Commons Groups Directory -description = The site-wide directory of groups -core = 7.x +description = Provides a listing of all of the current groups. package = Commons - Landing pages +core = 7.x + dependencies[] = commons_activity_streams_groups dependencies[] = ctools dependencies[] = page_manager dependencies[] = views_content + features[ctools][] = page_manager:pages_default:1 features[ctools][] = views:views_default:3.0 features[features_api][] = api:2 features[page_manager_pages][] = groups_directory -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.info b/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.info index edcd5e1..ab9b833 100644 --- a/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.info +++ b/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.info @@ -1,23 +1,22 @@ -name = Commons Group Homepages -description = Provides a default home page for groups -core = 7.x +name = Commons Group Pages +description = Enhances the appearance of group landing pages and allows them to be customized. package = Commons - Landing pages +core = 7.x + dependencies[] = commons_activity_streams dependencies[] = commons_bw dependencies[] = commons_follow_group dependencies[] = ctools dependencies[] = panelizer dependencies[] = strongarm + features[ctools][] = panelizer:panelizer:1 features[ctools][] = strongarm:strongarm:1 features[features_api][] = api:2 -features[panelizer_defaults][] = node:group:default -features[panelizer_defaults][] = node:group:default:teaser -features[variable][] = panelizer_defaults_node_group -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.panelizer.inc b/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.panelizer.inc index 467227e..b1ef909 100644 --- a/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.panelizer.inc +++ b/modules/commons/commons_groups/modules/commons_groups_pages/commons_groups_pages.panelizer.inc @@ -151,6 +151,36 @@ function commons_groups_pages_panelizer_defaults() { $pane->uuid = 'a7009535-0e2a-2c94-edd2-4ecc953c4ca2'; $display->content['new-a7009535-0e2a-2c94-edd2-4ecc953c4ca2'] = $pane; $display->panels['two_66_33_second'][1] = 'new-a7009535-0e2a-2c94-edd2-4ecc953c4ca2'; + + if (module_exists('commons_radioactivity_groups')) { + $pane = new stdClass(); + $pane->pid = 'new-ba735f2b-4734-7724-098d-1925c6a4bb47'; + $pane->panel = 'two_66_33_second'; + $pane->type = 'views_panes'; + $pane->subtype = 'commons_radioactivity_groups_active_in_group-panel_pane_1'; + $pane->shown = TRUE; + $pane->access = array(); + $pane->configuration = array( + 'arguments' => array( + 'gid' => '%node:nid', + ), + 'context' => array( + 0 => 'panelizer', + ), + ); + $pane->cache = array(); + $pane->style = array( + 'settings' => NULL, + ); + $pane->css = array(); + $pane->extras = array(); + $pane->position = 2; + $pane->locks = array(); + $pane->uuid = 'ba735f2b-4734-7724-098d-1925c6a4bb47'; + $display->content['new-ba735f2b-4734-7724-098d-1925c6a4bb47'] = $pane; + $display->panels['two_66_33_second'][2] = 'new-ba735f2b-4734-7724-098d-1925c6a4bb47'; + } + $pane = new stdClass(); $pane->pid = 'new-52796f83-93dd-2cf4-41aa-33520dc31e5f'; $pane->panel = 'two_66_33_second'; diff --git a/modules/commons/commons_images/commons_images.info b/modules/commons/commons_images/commons_images.info index 774ab75..5f54d84 100644 --- a/modules/commons/commons_images/commons_images.info +++ b/modules/commons/commons_images/commons_images.info @@ -1,14 +1,15 @@ name = Commons Images -description = Image styles used in the Commons distribution -core = 7.x +description = Enhances the display of images by making them responsive and intelligently cropping them where necessary. package = Commons - Building blocks -project = commons_images +core = 7.x + dependencies[] = breakpoints dependencies[] = ctools dependencies[] = file_entity dependencies[] = image dependencies[] = picture dependencies[] = smartcrop + features[breakpoint_group][] = commons_default features[breakpoint_group][] = commons_full features[breakpoint_group][] = commons_origins @@ -44,9 +45,9 @@ features[picture_mapping][] = commons_default features[picture_mapping][] = commons_full features[picture_mapping][] = commons_teaser -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_kissmetrics/commons_kissmetrics.info b/modules/commons/commons_kissmetrics/commons_kissmetrics.info index 8205419..9d9facb 100644 --- a/modules/commons/commons_kissmetrics/commons_kissmetrics.info +++ b/modules/commons/commons_kissmetrics/commons_kissmetrics.info @@ -1,7 +1,8 @@ name = Commons KISSmetrics description = Integrates with KISSmetrics to tracks Commons-specific user metrics and actions. -core = 7.x package = Commons - Building blocks +core = 7.x + dependencies[] = comment dependencies[] = entity dependencies[] = flag @@ -10,6 +11,7 @@ dependencies[] = og dependencies[] = privatemsg_rules dependencies[] = rules dependencies[] = voting_rules + features[features_api][] = api:2 features[rules_config][] = rules_commons_kissmetrics_collect_referenced_groups features[rules_config][] = rules_commons_kissmetrics_user_adds_a_trusted_contact @@ -30,9 +32,9 @@ features[rules_config][] = rules_commons_kissmetrics_user_registers features[rules_config][] = rules_commons_kissmetrics_user_replies_to_private_message_thread features[rules_config][] = rules_commons_kissmetrics_user_starts_new_private_message_thread -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_like/commons_like.features.inc b/modules/commons/commons_like/commons_like.features.inc index 8017877..825adda 100644 --- a/modules/commons/commons_like/commons_like.features.inc +++ b/modules/commons/commons_like/commons_like.features.inc @@ -4,16 +4,6 @@ * commons_like.features.inc */ -/** - * Implements hook_features_export_alter(). - */ -function commons_like_features_export_alter(&$export, $module_name) { - /* don't export strongarm anymore */ - if($module_name == 'commons_like' && isset($export['features']['variable'])) { - unset($export['features']['variable']); - } -} - /** * Implements hook_ctools_plugin_api(). */ diff --git a/modules/commons/commons_like/commons_like.info b/modules/commons/commons_like/commons_like.info index 23b96eb..b101a4d 100644 --- a/modules/commons/commons_like/commons_like.info +++ b/modules/commons/commons_like/commons_like.info @@ -1,21 +1,25 @@ name = Commons Like -description = Community members can indicate that they like content and comments. -core = 7.x +description = Allows users to indicate that they like certain content and comments. package = Commons - Building blocks +core = 7.x + dependencies[] = entityreference dependencies[] = features dependencies[] = message dependencies[] = rate dependencies[] = strongarm dependencies[] = votingapi + features[ctools][] = strongarm:strongarm:1 features[features_api][] = api:2 features[field_instance][] = message-commons_like_user_likes_node-field_target_nodes features[message_type][] = commons_like_user_likes_node +features[variable][] = field_bundle_settings_message__commons_like_user_likes_node features[variable][] = rate_widgets -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" + +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_like/commons_like.strongarm.inc b/modules/commons/commons_like/commons_like.strongarm.inc index 7a98e8b..d44c060 100644 --- a/modules/commons/commons_like/commons_like.strongarm.inc +++ b/modules/commons/commons_like/commons_like.strongarm.inc @@ -10,6 +10,40 @@ function commons_like_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_message__commons_like_user_likes_node'; + $strongarm->value = array( + 'view_modes' => array(), + 'extra_fields' => array( + 'form' => array(), + 'display' => array( + 'message__message_text__0' => array( + 'message_notify_email_subject' => array( + 'visible' => TRUE, + 'weight' => 0, + ), + 'message_notify_email_body' => array( + 'visible' => FALSE, + 'weight' => 0, + ), + ), + 'message__message_text__1' => array( + 'message_notify_email_subject' => array( + 'visible' => FALSE, + 'weight' => 0, + ), + 'message_notify_email_body' => array( + 'visible' => TRUE, + 'weight' => 0, + ), + ), + ), + ), + ); + $export['field_bundle_settings_message__commons_like_user_likes_node'] = $strongarm; + $strongarm = new stdClass(); $strongarm->disabled = FALSE; /* Edit this to true to make a default strongarm disabled initially */ $strongarm->api_version = 1; diff --git a/modules/commons/commons_location/commons_location.features.field_base.inc b/modules/commons/commons_location/commons_location.features.field_base.inc index 565a109..9dd396f 100644 --- a/modules/commons/commons_location/commons_location.features.field_base.inc +++ b/modules/commons/commons_location/commons_location.features.field_base.inc @@ -17,7 +17,6 @@ function commons_location_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_address', - 'foreign keys' => array(), 'indexes' => array(), 'locked' => 0, 'module' => 'addressfield', diff --git a/modules/commons/commons_location/commons_location.info b/modules/commons/commons_location/commons_location.info index b592151..3a8f41b 100644 --- a/modules/commons/commons_location/commons_location.info +++ b/modules/commons/commons_location/commons_location.info @@ -1,16 +1,18 @@ name = Commons Location -description = Provide a field definition for locations. +description = Provides a simple address field for re-use by various Commons content types. +package = Commons - Building blocks core = 7.x -package = Commons - Building Blocks + dependencies[] = addressfield dependencies[] = features dependencies[] = field_sql_storage + features[features_api][] = api:2 features[field_base][] = field_address -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_media/commons_media.default_entity_embed_configurations.inc b/modules/commons/commons_media/commons_media.default_entity_embed_configurations.inc new file mode 100644 index 0000000..b38c53c --- /dev/null +++ b/modules/commons/commons_media/commons_media.default_entity_embed_configurations.inc @@ -0,0 +1,25 @@ +disabled = FALSE; /* Edit this to true to make a default configuration disabled initially */ + $configuration->api_version = 1; + $configuration->admin_title = 'File'; + $configuration->name = 'file'; + $configuration->button_label = 'File'; + $configuration->entity_type = 'file'; + $configuration->button_icon_fid = 0; + $configurations['file'] = $configuration; + + return $configurations; +} diff --git a/modules/commons/commons_media/commons_media.features.field_base.inc b/modules/commons/commons_media/commons_media.features.field_base.inc index 3a93532..640ba49 100644 --- a/modules/commons/commons_media/commons_media.features.field_base.inc +++ b/modules/commons/commons_media/commons_media.features.field_base.inc @@ -17,14 +17,6 @@ function commons_media_field_default_field_bases() { 'deleted' => 0, 'entity_types' => array(), 'field_name' => 'field_media', - 'foreign keys' => array( - 'fid' => array( - 'columns' => array( - 'fid' => 'fid', - ), - 'table' => 'file_managed', - ), - ), 'indexes' => array( 'fid' => array( 0 => 'fid', diff --git a/modules/commons/commons_media/commons_media.features.field_instance.inc b/modules/commons/commons_media/commons_media.features.field_instance.inc index 91e86d0..3605967 100644 --- a/modules/commons/commons_media/commons_media.features.field_instance.inc +++ b/modules/commons/commons_media/commons_media.features.field_instance.inc @@ -10,13 +10,12 @@ function commons_media_field_default_field_instances() { $field_instances = array(); - $commons_groups_entity_types = commons_groups_get_group_content_entity_types(); - if (!empty($commons_groups_entity_types)) { - foreach ($commons_groups_entity_types as $entity_type => $bundles) { - foreach ($bundles as $bundle => $integrations) { - if (!empty($integrations['media'])) { - commons_media_field_definition($field_instances, $entity_type, $bundle); - } + $commons_groups_entity_types = commons_entity_integration_info(); + foreach ($commons_groups_entity_types as $entity_type => $bundles) { + foreach ($bundles as $bundle => $integrations) { + if (isset($integrations['media']) && $integrations['media'] == TRUE + && isset($integrations['is_group_content']) && $integrations['is_group_content'] == TRUE) { + commons_media_field_definition($field_instances, $entity_type, $bundle); } } } @@ -38,7 +37,7 @@ function commons_media_field_definition(&$field_instances, $entity_type, $bundle 'file_view_mode' => 'default', ), 'type' => 'file_rendered', - 'weight' => 0, + 'weight' => -48, ), 'teaser' => array( 'label' => 'hidden', @@ -47,7 +46,7 @@ function commons_media_field_definition(&$field_instances, $entity_type, $bundle 'file_view_mode' => 'teaser', ), 'type' => 'file_rendered', - 'weight' => 0, + 'weight' => -48, ), ), 'display_in_partial_form' => 1, @@ -85,7 +84,7 @@ function commons_media_field_definition(&$field_instances, $entity_type, $bundle 'progress_indicator' => 'throbber', ), 'type' => 'media_generic', - 'weight' => 2, + 'weight' => -48, ), ); diff --git a/modules/commons/commons_media/commons_media.features.inc b/modules/commons/commons_media/commons_media.features.inc index b77b46f..5eb8991 100644 --- a/modules/commons/commons_media/commons_media.features.inc +++ b/modules/commons/commons_media/commons_media.features.inc @@ -8,6 +8,9 @@ * Implements hook_ctools_plugin_api(). */ function commons_media_ctools_plugin_api($module = NULL, $api = NULL) { + if ($module == 'entity_embed' && $api == 'default_entity_embed_configurations') { + return array('version' => 1); + } if ($module == "strongarm" && $api == "strongarm") { return array("version" => "1"); } diff --git a/modules/commons/commons_media/commons_media.info b/modules/commons/commons_media/commons_media.info index cc06d65..6e201d1 100644 --- a/modules/commons/commons_media/commons_media.info +++ b/modules/commons/commons_media/commons_media.info @@ -1,7 +1,8 @@ name = Commons Media description = Provides media handling capabilities. -core = 7.x package = Commons - Building blocks +core = 7.x + dependencies[] = ctools dependencies[] = features dependencies[] = file @@ -10,6 +11,7 @@ dependencies[] = media dependencies[] = media_internet dependencies[] = media_oembed dependencies[] = strongarm + features[ctools][] = strongarm:strongarm:1 features[features_api][] = api:2 features[field_base][] = field_media @@ -23,9 +25,9 @@ features[variable][] = file_entity_file_upload_wizard_skip_file_type features[variable][] = file_entity_file_upload_wizard_skip_scheme features[variable][] = media_dialog_theme -; Information added by Drupal.org packaging script on 2014-06-25 -version = "7.x-3.15" +; Information added by Drupal.org packaging script on 2015-03-18 +version = "7.x-3.23" core = "7.x" project = "commons" -datestamp = "1403672628" +datestamp = "1426714630" diff --git a/modules/commons/commons_media/commons_media.install b/modules/commons/commons_media/commons_media.install index e813ba7..b61fc1e 100644 --- a/modules/commons/commons_media/commons_media.install +++ b/modules/commons/commons_media/commons_media.install @@ -26,3 +26,14 @@ function commons_media_update_7301() { features_revert($revert); return array(); } + +/** + * Standardize browsing widget field weights. + */ +function commons_media_update_7302() { + $revert = array( + 'commons_media' => array('field_instance'), + ); + features_revert($revert); + return array(); +} diff --git a/modules/commons/commons_media/commons_media.module b/modules/commons/commons_media/commons_media.module index 7b7ecf3..cf06213 100644 --- a/modules/commons/commons_media/commons_media.module +++ b/modules/commons/commons_media/commons_media.module @@ -26,6 +26,46 @@ function commons_media_system_info_alter(&$info, $file, $type) { } } } + + // Dynamically adding a field instance to an entity type results in features + // automatically detecting Commons Media as a dependency. + // We manually exclude the dependency in order to prevent entity type provider + // modules from appearing overridden and to allow them to be used + // independently of Commons Media. + $commons_entity_integrations = &drupal_static(__FUNCTION__); + + if (!isset($commons_entity_integrations)) { + foreach (module_implements('commons_entity_integration') as $module) { + $commons_entity_integrations[$module] = call_user_func($module . '_commons_entity_integration'); + } + } + + if (isset($commons_entity_integrations[$file->name])) { + foreach ($commons_entity_integrations[$file->name] as $entity_type => $integration) { + foreach ($integration as $bundle => $options) { + if (commons_media_has_media_integration($entity_type, $bundle)) { + $info['features_exclude']['dependencies']['commons_media'] = 'commons_media'; + } + } + } + } +} + +/** + * Helper function to determine whether an entity bundle has media integration. + * + * @param $entity_type + * The entity type to check media integration for. + * @param $bundle + * The entity bundle to check media integration for. + * + * @return boolean + * The value of the media integration if available, FALSE otherwise. + */ +function commons_media_has_media_integration($entity_type, $bundle) { + $commons_media_entity_types = commons_entity_integration_info(); + + return isset($commons_media_entity_types[$entity_type][$bundle]['media']) ? $commons_media_entity_types[$entity_type][$bundle]['media'] : FALSE; } /** @@ -140,17 +180,38 @@ function commons_media_page_build(&$page) { * Implements hook_filter_default_formats_alter(). */ function commons_media_filter_default_formats_alter(&$formats) { - if (module_exists('media_wysiwyg') && !empty($formats['filtered_html'])) { - // Allow markup from remote media. - $formats['filtered_html']['filters']['filter_html']['settings']['allowed_html'] = '