diff --git a/profiles/wcm_base/CHANGELOG.txt b/profiles/wcm_base/CHANGELOG.txt index 37c8e7065ce2ce2d57b8274125661c5739b919c8..41dfc2e09e71a700bdc0b94de0b12a4b27957a14 100644 --- a/profiles/wcm_base/CHANGELOG.txt +++ b/profiles/wcm_base/CHANGELOG.txt @@ -1,6 +1,6 @@ WCM Base 7.x-1.x, 2017-02-17 ---------------------------- -- WCM Base: Updated contrib modules fieldable_panels_panes, media, redis, smtp, token. +- WCM Base: Updated contrib modules media, redis, smtp, token. - WCM Media Gallery: Updated colorbox contrib module to 2.12. - WMM Omega: Merged commits to fix search buttons, tile pane resizing, misc form fixes. - WCM Search: Updated search_api_attachments contrib module to 1.10. diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/CHANGELOG.txt b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/CHANGELOG.txt index 438bfca1675f91e45e692b68bb62cb272db585af..7f2c9b51fdeaff16c38d7559d76890693a73cf84 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/CHANGELOG.txt +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/CHANGELOG.txt @@ -1,29 +1,3 @@ -Fieldable Panels Panes 7.x-1.11, 2016-11-05 -------------------------------------------- -#2688577 by rigoucr: Wrong function name for update 7114. -#2778265 by DamienMcKenna: Fixed tests due to permission changes in core. -#2233363 by DamienMcKenna: Removed some legacy paths that were causing problems - on some sites. -#2798963 by tbfisher: Typo on Migrate integration could lead to dataloss. -#2798965 by tbfisher: Migrate class for use as a data source. -#2730465 by joelpittet: Fixed integration with Panel Nodes. -#2548883 by Ahmad Abbad: Title field was shown twice in certain circumstances. -#2637740 by joelstein, Chris Burge: Add the entity's bundle name, to make some - of the hooks easier to work with. -#2494733 by DamienMcKenna: Added a test dependency on Pathauto. -#2494733 by DamienMcKenna: Added a test for path handling when Pathauto is - installed. -#2801605 by scuba_fly, DamienMcKenna, mrmikedewolf: Allow 'reuseable' option to - be changed after initial FPP creation. -#2814117 by cboyden, lucas.constantino, dsnopek: Added - hook_fieldable_panels_panes_access() to allow other modules to control access - to Fieldable Panels Pane objects. -#2801353 by ChaseOnTheWeb, DamienMcKenna: Duplicate logic of update_7112 and - update_7113 for when using UUID. -#2723655 by DamienMcKenna: Fixed usage of POSITION() in update_7112 and - update_7113. - - Fieldable Panels Panes 7.x-1.10, 2016-05-04 ------------------------------------------- By cboyden, DamienMcKenna, dsnopek: Admin title formatting. diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.api.php b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.api.php index a8f0b810d796ee09c2bbe47e2bbce0cfb789c926..2e1057f9ddd0e4e7e34846dace9824924ae6f4ae 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.api.php +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.api.php @@ -106,30 +106,6 @@ function hook_fieldable_panels_panes_content_types_alter(&$types, $bundle, $enti } } -/** - * Allow other modules to control access to Fieldable Panels Pane objects. - * - * @param string $op - * The operation to be performed. - * @param $entity - * The fieldable panels pane that is being accessed. - * @param $account - * The user account whose access should be checked. - * - * @return TRUE|FALSE|NULL - * Returns TRUE to allow access, FALSE to deny, or NULL to pass the access - * decision off to the next hook or the module itself. - * - * @ingroup fieldable_panels_pane_api_hooks - */ -function hook_fieldable_panels_panes_access($op, $entity = NULL, $account = NULL) { - // Example implementation which restricts access to edit reusable panes. - if ($op == 'update' && !empty($entity) && $entity->reusable && !user_access('administer fieldable panels panes')) { - return FALSE; - } - return NULL; -} - /** * @} End of "addtogroup hooks". */ diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.info b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.info index b9d3520ba42b748d22090cef4ebf34e8c0709dba..7313e8b357deefcb5c4cb8b46d81d33cec9e32d0 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.info +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.info @@ -56,17 +56,13 @@ files[] = tests/fpp.with_panels_and_entity.test test_dependencies[] = panelizer files[] = tests/fpp.with_panelizer.test -; Test the interaction with the Pathauto module. -test_dependencies[] = pathauto -files[] = tests/fpp.with_pathauto.test - ; Test the node revisions workflow with Revisioning module. test_dependencies[] = revisioning files[] = tests/fpp.with_revisioning.test -; Information added by Drupal.org packaging script on 2016-11-05 -version = "7.x-1.11" +; Information added by Drupal.org packaging script on 2016-05-04 +version = "7.x-1.10" core = "7.x" project = "fieldable_panels_panes" -datestamp = "1478371741" +datestamp = "1462374853" diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.install b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.install index efe1ea943e309f18a35205158d0d1f87772fd69f..37b18e4555650d556ebe79f81993e10e5418f269 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.install +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.install @@ -31,7 +31,6 @@ function fieldable_panels_panes_uninstall() { // Variables. variable_del('fieldable_panels_panes_skip_default_type'); - variable_del('fpp_allow_reusable_access'); variable_del('fpp_blocks_expose'); variable_del('fpp_hide_contextual_links'); variable_del('fpp_revision_locking'); @@ -518,7 +517,7 @@ function fieldable_panels_panes_update_7112(&$sandbox) { $sandbox['max'] = db_query("SELECT DISTINCT fpp.fpid as fpid, fpp.vid as vid FROM {fieldable_panels_panes} fpp INNER JOIN {panels_pane} pp - ON fpp.fpid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) + ON fpp.fpid = SUBSTRING_INDEX(pp.subtype, ':', -1) INNER JOIN {panelizer_entity} pe ON pe.did = pp.did WHERE (pp.subtype LIKE 'fpid:%' OR pp.subtype LIKE 'current:%') @@ -538,7 +537,7 @@ function fieldable_panels_panes_update_7112(&$sandbox) { $results = db_query_range("SELECT DISTINCT fpp.fpid as fpid, fpp.vid as vid FROM {fieldable_panels_panes} fpp INNER JOIN {panels_pane} pp - ON fpp.fpid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) + ON fpp.fpid = SUBSTRING_INDEX(pp.subtype, ':', -1) INNER JOIN {panelizer_entity} pe ON pe.did = pp.did WHERE (pp.subtype LIKE 'fpid:%' OR pp.subtype LIKE 'current:%') @@ -644,7 +643,7 @@ function fieldable_panels_panes_update_7113() { $sandbox['max'] = db_query("SELECT DISTINCT fpp.fpid as fpid, fpp.vid as vid FROM {fieldable_panels_panes} fpp INNER JOIN {panels_pane} pp - ON fpp.fpid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) + ON fpp.fpid = SUBSTRING_INDEX(pp.subtype, ':', -1) INNER JOIN {panels_node} pn ON pn.did = pp.did WHERE (pp.subtype LIKE 'fpid:%' OR pp.subtype LIKE 'current:%') @@ -664,7 +663,7 @@ function fieldable_panels_panes_update_7113() { $results = db_query_range("SELECT DISTINCT fpp.fpid as fpid, fpp.vid as vid FROM {fieldable_panels_panes} fpp INNER JOIN {panels_pane} pp - ON fpp.fpid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) + ON fpp.fpid = SUBSTRING_INDEX(pp.subtype, ':', -1) INNER JOIN {panels_node} pn ON pn.did = pp.did WHERE (pp.subtype LIKE 'fpid:%' OR pp.subtype LIKE 'current:%') @@ -700,11 +699,11 @@ function fieldable_panels_panes_update_7113() { /** * Restore the default FPP bundle that may have been purged in update 7108. */ -function fieldable_panels_panes_update_7114() { +function incae_custom_panes_update_7114() { if (!variable_get('fieldable_panels_panes_skip_default_type', FALSE)) { // Check if the FPP type exists. $found = db_select('fieldable_panels_pane_type', 'fppt') - ->fields('fppt', array('name')) + ->fields('fppt', 'name') ->condition('name', 'fieldable_panels_pane') ->execute() ->fetchField(); @@ -718,257 +717,3 @@ function fieldable_panels_panes_update_7114() { } } } - -/** - * Update all Panelizer displays to point non-reusable FPPs to the vuuid instead - * of the uuid. - */ -function fieldable_panels_panes_update_7115(&$sandbox) { - if (!module_exists('panelizer')) { - return t('Panelizer is not installed, so nothing to do.'); - } - - // This won't as-is work for many sites because the 'fpp_revision_locking' - // variable won't be defined before it's checked for. The simplest approach - // is to manually rerun the updates. - // - // /** - // * Enable the FPP revision locking feature. - // */ - // function MYMODULE_update_7100() { - // variable_set('fpp_revision_locking', 'lock'); - // } - // - // /** - // * Rerun Fieldable Panels Panes update 7115. - // */ - // function MYMODULE_update_7101(&$sandbox) { - // return fieldable_panels_panes_update_7115($sandbox); - // } - // - // - // A more correct approach is to use hook_update_dependencies to ensure that - // the updates happen in the correct order. This may not work because if the - // hook implementation is newly added to the module it won't be recognized - // until the caches are cleared, which may not happen until after the updates - // are ran, thus the updates not running in the correct order. - // - // /** - // * Implements hook_update_dependencies(). - // */ - // function MYMODULE_update_dependencies() { - // // Make sure that update 7100 below runs *after* Fieldable Panels Pane - // // update 7111 and *before* Fieldable Panels Pane update 7112, that way - // // the FPP 'lock' option will be enabled when the Panelizer updates are - // // started. - // $dependencies['MYMODULE'][7100] = array( - // 'fieldable_panels_panes' => 7111, - // ); - // $dependencies['fieldable_panels_panes'][7115] = array( - // 'MYMODULE' => 7100, - // ); - // return $dependencies; - // } - // - // /** - // * Enable the FPP revision locking feature. - // */ - // function MYMODULE_update_7100() { - // variable_set('fpp_revision_locking', 'lock'); - // } - // - // - // An alternative solution would be to rerun the updates. - - if (variable_get('fpp_revision_locking', 'lock') != 'lock') { - return t('Pane locking is not enabled, so nothing to do.'); - } - - // Update all Panelizer displays. - - // The first time through, work out how many records need to be updated. - if (!isset($sandbox['progress'])) { - $sandbox['progress'] = 0; - - // Total records that must be processed. - $sandbox['max'] = db_query("SELECT DISTINCT fpp.uuid as uuid, fppr.vuuid as vuuid - FROM {fieldable_panels_panes} fpp - INNER JOIN {fieldable_panels_panes_revision} fppr - ON fpp.vid = fppr.vid - INNER JOIN {panels_pane} pp - ON fpp.uuid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) - INNER JOIN {panelizer_entity} pe - ON pe.did = pp.did - WHERE (pp.subtype LIKE 'uuid:%') - AND fpp.reusable != 1 - ORDER BY fpp.uuid")->rowCount(); - - // If there's nothing to do, bail early. - if (empty($sandbox['max'])) { - return t('No panels needed to be updated.'); - } - } - - // Do the updates in small batches. - $limit = 10; - - // Get a list of all UUIDs for Panelizer displays. - $results = db_query_range("SELECT DISTINCT fpp.uuid as uuid, fppr.vuuid as vuuid - FROM {fieldable_panels_panes} fpp - INNER JOIN {fieldable_panels_panes_revision} fppr - ON fpp.vid = fppr.vid - INNER JOIN {panels_pane} pp - ON fpp.uuid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) - INNER JOIN {panelizer_entity} pe - ON pe.did = pp.did - WHERE (pp.subtype LIKE 'uuid:%') - AND fpp.reusable != 1 - ORDER BY fpp.uuid", 0, $limit); - - // Loop through the FPPs. - foreach ($results as $record) { - // Update the 'uuid:' records to use 'vuuid:'; don't bother checking if the - // record exists first because there's no down side to running this query - // immediately. - $query = db_update('panels_pane') - ->fields(array('subtype' => 'vuuid:' . $record->vuuid)) - ->condition('subtype', 'uuid:' . $record->uuid) - ->execute(); - - // Increment the progress counter. - $sandbox['progress']++; - } - - // Done yet? - $sandbox['#finished'] = empty($sandbox['max']) ? TRUE : ($sandbox['progress'] / $sandbox['max']); - - if ($sandbox['#finished'] === TRUE) { - return t('Updated @count record(s) to use the new locking system.', array('@count' => $sandbox['max'])); - } -} - -/** - * Update all Panel Nodes displays to point non-reusable FPPs to the vuuid - * instead of the uuid. - */ -function fieldable_panels_panes_update_7116(&$sandbox) { - if (!module_exists('panels_node')) { - return t('Panel Nodes is not installed, so nothing to do.'); - } - - // This won't as-is work for many sites because the 'fpp_revision_locking' - // variable won't be defined before it's checked for. The simplest approach - // is to manually rerun the updates. - // - // /** - // * Enable the FPP revision locking feature. - // */ - // function MYMODULE_update_7100() { - // variable_set('fpp_revision_locking', 'lock'); - // } - // - // /** - // * Rerun Fieldable Panels Panes update 7116. - // */ - // function MYMODULE_update_7101(&$sandbox) { - // return fieldable_panels_panes_update_7116($sandbox); - // } - // - // - // A more correct approach is to use hook_update_dependencies to ensure that - // the updates happen in the correct order. This may not work because if the - // hook implementation is newly added to the module it won't be recognized - // until the caches are cleared, which may not happen until after the updates - // are ran, thus the updates not running in the correct order. - // - // /** - // * Implements hook_update_dependencies(). - // */ - // function MYMODULE_update_dependencies() { - // // Make sure that update 7100 below runs *after* Fieldable Panels Pane - // // update 7111 and *before* Fieldable Panels Pane update 7112, that way - // // the FPP 'lock' option will be enabled when the Panel Nodes updates are - // // started. - // $dependencies['MYMODULE'][7100] = array( - // 'fieldable_panels_panes' => 7111, - // ); - // $dependencies['fieldable_panels_panes'][7116] = array( - // 'MYMODULE' => 7100, - // ); - // return $dependencies; - // } - // - // /** - // * Enable the FPP revision locking feature. - // */ - // function MYMODULE_update_7100() { - // variable_set('fpp_revision_locking', 'lock'); - // } - // - // - // An alternative solution would be to rerun the updates. - - if (variable_get('fpp_revision_locking', 'lock') != 'lock') { - return t('Pane locking is not enabled, so nothing to do.'); - } - - // The first time through, work out how many records need to be updated. - if (!isset($sandbox['progress'])) { - $sandbox['progress'] = 0; - - // Total records that must be processed. - $sandbox['max'] = db_query("SELECT DISTINCT fpp.uuid as uuid, fppr.vuuid as vuuid - FROM {fieldable_panels_panes} fpp - INNER JOIN {fieldable_panels_panes_revision} fppr - ON fpp.vid = fppr.vid - INNER JOIN {panels_pane} pp - ON fpp.uuid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) - INNER JOIN {panels_node} pn - ON pn.did = pp.did - WHERE (pp.subtype LIKE 'uuid:%') - AND fpp.reusable != 1 - ORDER BY fpp.uuid")->rowCount(); - - // If there's nothing to do, bail early. - if (empty($sandbox['max'])) { - return t('No panels needed to be updated.'); - } - } - - // Do the updates in small batches. - $limit = 10; - - // Get a list of all UUIDs for Panel Nodes displays. - $results = db_query_range("SELECT DISTINCT fpp.uuid as uuid, fppr.vuuid as vuuid - FROM {fieldable_panels_panes} fpp - INNER JOIN {fieldable_panels_panes_revision} fppr - ON fpp.vid = fppr.vid - INNER JOIN {panels_pane} pp - ON fpp.uuid = SUBSTRING(pp.subtype FROM (POSITION(':' IN pp.subtype) + 1)) - INNER JOIN {panels_node} pn - ON pn.did = pp.did - WHERE (pp.subtype LIKE 'uuid:%') - AND fpp.reusable != 1 - ORDER BY fpp.uuid", 0, $limit); - - // Loop through the FPPs. - foreach ($results as $record) { - // Update the 'uuid:' records to use 'vuuid:'; don't bother checking if the - // record exists first because there's no down side to running this query - // immediately. - $query = db_update('panels_pane') - ->fields(array('subtype' => 'vuuid:' . $record->vuuid)) - ->condition('subtype', 'uuid:' . $record->uuid) - ->execute(); - - // Increment the progress counter. - $sandbox['progress']++; - } - - // Done yet? - $sandbox['#finished'] = empty($sandbox['max']) ? TRUE : ($sandbox['progress'] / $sandbox['max']); - - if ($sandbox['#finished'] === TRUE) { - return t('Updated @count record(s) to use the new locking system.', array('@count' => $sandbox['max'])); - } -} diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.module b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.module index 8f190adecf9e36a330db124fb76f770b8abe7a64..6c2f9b7e46fbb1c8701e79ef38ac3a9c48f98c23 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.module +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/fieldable_panels_panes.module @@ -73,7 +73,7 @@ function fieldable_panels_panes_entity_info() { 'save callback' => 'fieldable_panels_panes_save', 'deletion callback' => 'fieldable_panels_panes_delete', - // Entity translation support. + // Entity translation support 'translation' => array( 'entity_translation' => array( 'class' => 'EntityTranslationFieldablePanelsPaneHandler', @@ -83,7 +83,7 @@ function fieldable_panels_panes_entity_info() { ), ), - // Title module support. + // Title module support 'field replacement' => array( 'title' => array( 'field' => array( @@ -224,8 +224,7 @@ function fieldable_panels_panes_menu() { 'file' => 'includes/admin.inc', ); - // Legacy paths to support the old method of providing bundles via - // entity_hook_info(). + // Legacy paths to support the old method of providing bundles via entity_hook_info(). $items['admin/structure/fieldable-panels-panes/view/%fieldable_panels_panes'] = array( 'title callback' => 'fieldable_panels_panes_entity_title', 'title arguments' => array(4), @@ -256,7 +255,7 @@ function fieldable_panels_panes_menu() { 'weight' => -9, ) + $base; - // Access control. + // Access control $items['admin/structure/fieldable-panels-panes/view/%fieldable_panels_panes/access'] = array( 'title' => 'Access control', 'type' => MENU_LOCAL_TASK, @@ -392,20 +391,27 @@ function fieldable_panels_panes_menu() { ); } - $items['admin/structure/fieldable-panels-panes/%fieldable_panels_pane_type'] = array( + $items['admin/structure/fieldable-panels-panes/manage/%fieldable_panels_pane_type'] = array( 'title callback' => 'fieldable_panels_panes_entities_title', - 'title arguments' => array(3), + 'title arguments' => array(4), 'page callback' => 'fieldable_panels_panes_entities_list_page', - 'page arguments' => array(3), + 'page arguments' => array(4), ) + $base; - $items['admin/structure/fieldable-panels-panes/%fieldable_panels_pane_type/add'] = array( - 'title' => 'Add fieldable panels pane', + $items['admin/structure/fieldable-panels-panes/manage/%fieldable_panels_pane_type/list'] = array( + 'title' => 'List', + 'type' => MENU_LOCAL_TASK, + 'context' => MENU_CONTEXT_PAGE | MENU_CONTEXT_INLINE, + 'weight' => -10, + ); + + $items['admin/structure/fieldable-panels-panes/manage/%fieldable_panels_pane_type/add'] = array( + 'title' => 'Add fieldable panel pane', 'page callback' => 'fieldable_panels_panes_entities_add_page', - 'page arguments' => array(3), + 'page arguments' => array(4), 'access callback' => 'fieldable_panels_panes_access', - 'access arguments' => array('create', 3), - 'type' => MENU_LOCAL_ACTION, + 'access arguments' => array('create', 4), + 'type' => MENU_LOCAL_TASK, 'context' => MENU_CONTEXT_PAGE | MENU_CONTEXT_INLINE, ) + $base; @@ -415,11 +421,20 @@ function fieldable_panels_panes_menu() { 'page arguments' => array(3), 'access callback' => 'fieldable_panels_panes_access_callback', 'access arguments' => array(), - 'type' => MENU_DEFAULT_LOCAL_TASK, + 'type' => MENU_LOCAL_TASK, 'context' => MENU_CONTEXT_PAGE | MENU_CONTEXT_INLINE, 'weight' => -10, ) + $base; + $items['admin/structure/fieldable-panels-panes/%fieldable_panels_pane_type/add'] = array( + 'title' => 'Add', + 'page callback' => 'fieldable_panels_panes_entities_add_page', + 'page arguments' => array(3), + 'access callback' => 'fieldable_panels_panes_access', + 'access arguments' => array('create', 3), + 'type' => MENU_LOCAL_TASK, + 'context' => MENU_CONTEXT_PAGE | MENU_CONTEXT_INLINE, + ) + $base; // Settings. $items['admin/structure/fieldable-panels-panes/settings'] = array( @@ -617,19 +632,6 @@ function fieldable_panels_pane_type_load($type) { if (isset($entity_info['bundles'][$type])) { return $type; } - else { - // Special handling for two legacy paths: - // * admin/structure/fieldable-panels-panes/manage/FPPTYPE/fields - // * admin/structure/fieldable-panels-panes/manage/FPPTYPE/display - // Redirect these paths as appropriate. - if ($type == 'manage' && (arg(5) == 'fields' || arg(5) == 'display')) { - drupal_goto('admin/structure/fieldable-panels-panes/' . arg(4) . '/' . arg(5)); - } - - // If nothing else was found, redirect to the main FPP admin page. - drupal_set_message(t('Unable to load the "@type" Fieldable Panels Pane type.', array('@type' => $type))); - drupal_goto('admin/structure/fieldable-panels-panes'); - } } /** @@ -991,7 +993,7 @@ function fieldable_panels_panes_load_from_subtype($subtype_name) { $subtype_info = ctools_content_get_subtype($plugin, $subtype_name); // This means we're probably in the process of creating a new one. - if (!isset($subtype_info['entity_id'])) { + if (isset($subtype_info['bundle'])) { return fieldable_panels_panes_create(array('bundle' => $subtype_info['bundle'])); } @@ -1418,14 +1420,6 @@ function fieldable_panels_panes_entity_edit_form($form, &$form_state) { ), ); - // Override reusable pane settings to be changed after the pane is created. - if (variable_get('fpp_allow_reusable_access', FALSE)) { - // Reset field access. - unset($form['reusable']['#access']); - $form['reusable']['reusable']['#description'] = t('A reusable pane may be used multiple times on the same page or on other pages. A non-reusable pane may not be added to another page once it is created and added to this page. Once this option has been checked it cannot be turned off.'); - $form['reusable']['reusable']['#disabled'] = !empty($form_state['entity']->reusable); - } - $language = NULL; if (function_exists('entity_language')) { // entity_language() was added in Drupal 7.15. diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/PanelsPaneController.class.php b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/PanelsPaneController.class.php index e1c034ac2560fa59a8283c20c8840cb255c7d7b5..6c7f1ea817a722c6752a2bbbac0ce8dd8aedf4ea 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/PanelsPaneController.class.php +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/PanelsPaneController.class.php @@ -70,13 +70,6 @@ class PanelsPaneController extends DrupalDefaultEntityController { return TRUE; } - // On the first FALSE we return, otherwise we use our own access check. - foreach (module_invoke_all('fieldable_panels_panes_access', $op, $entity, $account) as $result) { - if ($result === FALSE) { - return $result; - } - } - $bundle = is_string($entity) ? $entity : $entity->bundle; if ($op == 'create') { diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/admin.inc b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/admin.inc index 7986502c663bed4585bb26d4ffb04c4ec4f2bea4..234f8a2c46cef21ca4b4d3e0a980e65cd50b0b93 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/admin.inc +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/admin.inc @@ -36,14 +36,6 @@ function fieldable_panels_panes_settings() { '#description' => t('Fieldable panels panes that are reusable will be made available as blocks.'), '#default_value' => variable_get('fpp_blocks_expose', FALSE), ); - - $form['fpp_allow_reusable_access'] = array( - '#type' => 'checkbox', - '#title' => t('Allow access to the "reusable" option on the pane edit form after initial creation'), - '#description' => t('This only allows the pane te be made reusable. Reusable panes cannot be changed back to non reusable panes.<br />Warning: enabling this option could break the editorial workflows using e.g. the Workbench Moderation or Revisioning modules, and could cause other problems too.'), - '#default_value' => variable_get('fpp_allow_reusable_access', FALSE), - ); - $form['bundles'] = array( '#type' => 'fieldset', '#title' => t('FPP Types Exposed as Blocks'), diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/fieldable_panels_pane.migrate.inc b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/fieldable_panels_pane.migrate.inc index 57052bcd93b03614ca2ff29623cc22f606d7c6d4..a7c9682503d66b65936f7d40b52d3466ae88e090 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/fieldable_panels_pane.migrate.inc +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/includes/fieldable_panels_pane.migrate.inc @@ -144,7 +144,7 @@ class MigrateDestinationFieldablePanelsPanes extends MigrateDestinationEntity { if (!isset($fieldable_panels_pane->fpid)) { throw new MigrateException(t('System-of-record is DESTINATION, but no destination fpid provided')); } - $old_fieldable_panels_panes = entity_load_single('fieldable_panels_pane', $fieldable_panels_pane->fpid); + $old_fieldable_panels_panes = entity_load_single('fieldable_panels_panes', $fieldable_panels_pane->fpid); if (empty($old_fieldable_panels_panes)) { throw new MigrateException(t('System-of-record is DESTINATION, but fieldable panels pane !fpid does not exist', array('!fpid' => $fieldable_panels_pane->fpid))); @@ -258,190 +258,3 @@ class MigrateDestinationFieldablePanelsPanes extends MigrateDestinationEntity { return $return; } } - -/** - * Handling specific to a Drupal 7 source for Fieldable Panels Panes. - */ -class DrupalFieldablePanelsPanesMigration extends DrupalMigration { - - /** - * The source and destination content types (bundles) we're dealing with. - */ - protected $destinationType; - - /** - * Default language to apply to the node and it's body field. - * - * @var string - */ - protected $defaultLanguage = LANGUAGE_NONE; - - /** - * {@inheritdoc} - */ - public function __construct(array $arguments) { - $this->destinationType = $arguments['destination_type']; - $this->sourceType = $arguments['source_type']; - if (!empty($arguments['default_language'])) { - $this->defaultLanguage = $arguments['default_language']; - } - $arguments['source_version'] = 7; - parent::__construct($arguments); - - // Document known core fields. - $this->sourceFields += array( - 'fpid' => t('The primary identifier for the entity.'), - 'vid' => t('The current version in use for this entity.'), - 'bundle' => t('The bundle of the entity.'), - 'title' => t('The title of the entity.'), - 'link' => t('Whether or not this entity title will link to another page.'), - 'path' => t('The path the title should link to.'), - 'reusable' => t('Whether or not this entity will appear in the Add Content dialog.'), - 'admin_title' => t('The title it will appear in the Add Content dialog as.'), - 'admin_description' => t('The description it will appear in the Add Content dialog with.'), - 'category' => t('The category it will appear in the Add Content dialog under.'), - 'view_access' => t('Access rules to describe if the user has view access to this entity.'), - 'edit_access' => t('Access rules to describe if the user has view access to this entity.'), - 'created' => t('The Unix timestamp when the entity was created.'), - 'changed' => t('The Unix timestamp when the entity was most recently saved.'), - 'uuid' => t('The Universally Unique Identifier.'), - 'language' => t('The languages.language of this entity.'), - 'uid' => t('The users.uid of the current revision.'), - 'log' => t('The log message of the current revision.'), - 'vuuid' => t('The Universally Unique Identifier of the current revision.'), - ); - - $this->sourceFields += $this->version->getSourceFields('fieldable_panels_pane', $this->sourceType); - - $this->source = new MigrateSourceSQL($this->query(), $this->sourceFields, NULL, $this->sourceOptions); - - $this->destination = new MigrateDestinationFieldablePanelsPanes($this->destinationType); - - $this->map = new MigrateSQLMap($this->machineName, - array( - 'fpid' => array( - 'type' => 'int', - 'unsigned' => TRUE, - 'not null' => TRUE, - 'description' => 'Source entity ID', - 'alias' => 'fpp', - ), - ), - MigrateDestinationNode::getKeySchema(), - $this->mapConnection - ); - - if (!$this->newOnly) { - $this->highwaterField = array( - 'name' => 'changed', - 'alias' => 'fpp', - 'type' => 'int', - ); - } - - // Setup common mappings. - $this->addSimpleMappings(array( - 'title', - 'link', - 'path', - 'reusable', - 'admin_title', - 'admin_description', - 'category', - 'view_access', - 'edit_access', - 'created', - 'changed', - 'uuid', - 'language', - )); - - $this->addUnmigratedSources(array('vid')); - $this->addUnmigratedDestinations(array()); - - if (isset($arguments['default_uid'])) { - $default_uid = $arguments['default_uid']; - } - else { - $default_uid = 1; - } - /* - if (isset($user_migration)) { - $this->addFieldMapping('uid', 'uid') - ->sourceMigration($user_migration) - ->defaultValue($default_uid); - } - else { - $this->addFieldMapping('uid', NULL, FALSE) - ->defaultValue($default_uid); - } - */ - } - - /** - * {@inheritdoc} - */ - protected function query() { - $query = Database::getConnection('default', $this->sourceConnection) - ->select('fieldable_panels_panes', 'fpp') - ->fields('fpp', array( - 'fpid', - 'vid', - 'title', - 'link', - 'path', - 'reusable', - 'admin_title', - 'admin_description', - 'category', - 'view_access', - 'edit_access', - 'created', - 'changed', - 'uuid', - 'language', - )); - $query->join('fieldable_panels_panes_revision', 'fppv', - 'fppv.fpid = fpp.fpid and fppv.vid = fpp.vid'); - $query->fields('fppv', array( - 'uid', - 'log', - 'vuuid', - )); - $query->condition('fpp.bundle', $this->sourceType); - $query->orderBy($this->newOnly ? 'fpp.fpid' : 'fpp.changed'); - return $query; - } - - /** - * {@inheritdoc} - */ - public function prepareRow($row) { - if (parent::prepareRow($row) === FALSE) { - return FALSE; - } - - $this->version->getSourceValues($row, $row->fpid); - - return TRUE; - } - - /** - * Implementation of Migration::createStub(). - */ - protected function createStub($migration) { - migrate_instrument_start('DrupalNodeMigration::createStub'); - $entity = new stdClass(); - $entity->title = t('Stub'); - $entity->type = $this->destination->getBundle(); - fieldable_panels_panes_save($entity); - migrate_instrument_stop('DrupalFieldablePanelsPanesMigration::createStub'); - if (isset($entity->fpid)) { - return array($entity->fpid); - } - else { - return FALSE; - } - } - -} diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/content_types/fieldable_panels_pane.inc b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/content_types/fieldable_panels_pane.inc index 174f290536cc247db6195f6781be121b75b0bda1..ee10fd630df7ba81742697acb59a4306dc021d4b 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/content_types/fieldable_panels_pane.inc +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/content_types/fieldable_panels_pane.inc @@ -104,9 +104,9 @@ function fieldable_panels_panes_fieldable_panels_pane_content_type_content_types // The current function is called as part of the standard panel pane rendering // pipeline. To prevent a full list of FPP entities from being generated every // time that a panel is rendered, generate the list only when a request is - // made from an administrative URL or Panel Nodes pages. + // made from an administrative URL. // @see https://www.drupal.org/node/2374577 - if (path_is_admin(current_path()) || preg_match('#(panels|panel_content$)#i', current_path())) { + if (path_is_admin(current_path()) || preg_match('/panels/i', current_path())) { $fpp_info = entity_get_info('fieldable_panels_pane'); foreach ($fpp_info['bundles'] as $bundle_name => $bundle) { $ids = db_query('SELECT fpid FROM {fieldable_panels_panes} WHERE reusable = 1 AND bundle = :bundle', array(':bundle' => $bundle_name))->fetchCol(); @@ -179,16 +179,14 @@ function fieldable_panels_panes_fieldable_panels_pane_content_type_render($subty // Is this view mode configured? $is_view_mode_set = isset($settings['extra_fields']['display']['title'][$view_mode]['visible']); - // Should the default view mode show the title? - $show_default_title = !empty($settings['extra_fields']['display']['title']['default']['visible']); - // Is the title configured for this view mode? $show_view_mode_title = ($is_view_mode_set && $settings['extra_fields']['display']['title'][$view_mode]['visible']); + // Should the default view mode show the title? + $show_default_title = !empty($settings['extra_fields']['display']['title']['default']['visible']); + // Combine all of the above logic. - if (empty($settings['extra_fields']['display']) - || (!$is_view_mode_set && $show_default_title) - || !$show_view_mode_title) { + if (empty($settings['extra_fields']['display']) || (!$is_view_mode_set && $show_default_title) || $show_view_mode_title) { $block->title = filter_xss_admin($entity->title); } } @@ -438,7 +436,6 @@ function _fieldable_panels_panes_custom_content_type($entity) { } $info['entity_id'] = $info['name']; - $info['bundle'] = $entity->bundle; return $info; } diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/export_ui/fieldable_panels_pane.class.php b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/export_ui/fieldable_panels_pane.class.php index b7b1ec0e440ec022c1bb9fd3c7c9aa54af307b30..2e7907624d2175fd4dedc32c0b54319828d32c6f 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/export_ui/fieldable_panels_pane.class.php +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/plugins/export_ui/fieldable_panels_pane.class.php @@ -178,13 +178,13 @@ class fieldable_panels_pane extends ctools_export_ui { if (user_access('administer fieldable panels panes') || user_access('access fieldable panels panes master list')) { $operations['list'] = array( 'title' => t('list'), - 'href' => 'admin/structure/fieldable-panels-panes/' . $bundle, + 'href' => 'admin/structure/fieldable-panels-panes/manage/' . $bundle, ); } if (user_access('administer fieldable panels panes')) { $operations['add'] = array( 'title' => t('add'), - 'href' => 'admin/structure/fieldable-panels-panes/' . $bundle . '/add', + 'href' => 'admin/structure/fieldable-panels-panes/manage/' . $bundle . '/add', ); $operations['edit'] = array( 'title' => t('edit'), diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.entity_form.test b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.entity_form.test index 6270420e739b8966e55f77eefbf46f096847631b..79970c7ad5114e839da22dafebd80267a7031d12 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.entity_form.test +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.entity_form.test @@ -169,52 +169,4 @@ class FppEntityFormTest extends FppTestHelper { $this->assertFieldByName('log'); } - /** - * Confirm that the edit form has the correct fields for non-reusable FPPs - * when the allow_reusable_access is enabled. - */ - function testAllowReusableAccessOption() { - // Create a user with the admin permission. - $this->adminUser = $this->createAdminUser(); - - $this->drupalLogin($this->adminUser); - - // Create a non-reusable FPP. - $fpp = new StdClass(); - $fpp->bundle = $this->bundle; - $fpp->title = $this->title; - $fpp->reusable = 0; - $saved_fpp = fieldable_panels_panes_save($fpp); - - // Load the fpp-add form. - $this->drupalGet('admin/structure/fieldable-panels-panes/view/' . $fpp->fpid . '/edit'); - $this->assertResponse(200); - - // The 'reusable' option is not changable after the FPP's initial creation, - // and these fields will be hidden for non-reusable FPPs. - $this->assertNoFieldByName('reusable'); - $this->assertNoFieldByName('category'); - - // When editing a non-reusable FPP the revision option may not be disabled - // but the log field will be available. - $this->assertNoFieldByName('revision'); - $this->assertFieldByName('log'); - - // Change the 'allow_reusable_access' option. - variable_set('fpp_allow_reusable_access', TRUE); - - // Load the fpp-add form. - $this->drupalGet('admin/structure/fieldable-panels-panes/view/' . $fpp->fpid . '/edit'); - $this->assertResponse(200); - - // The 'reusable' option is now changable again because the - // "allow_reusable_access" option has been enabled. - $this->assertFieldByName('reusable'); - $this->assertFieldByName('category'); - - // The revision fields should be visible when editing a reusable FPP. - $this->assertFieldByName('revision'); - $this->assertFieldByName('log'); - } - } diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.helper.test b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.helper.test index aac9489461e483bb2441ed105589b07ab5336414..53013570589be51006c6cf7c5b27bac6384694ea 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.helper.test +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.helper.test @@ -4,7 +4,7 @@ * A base class for the Fieldable Panels Panes tests, provides shared methods. */ -abstract class FppTestHelper extends DrupalWebTestCase { +class FppTestHelper extends DrupalWebTestCase { /** * Admin user. @@ -24,42 +24,21 @@ abstract class FppTestHelper extends DrupalWebTestCase { /** * Create an admin-level user. * - * @param array $perms - * Any permissions to be added to the user. - * * @return object * A standard Drupal user object. */ - function createAdminUser(array $perms = array()) { + function createAdminUser() { // Create a user with the admin permission. $permissions = array( - // The master permission for FPP. 'administer fieldable panels panes', - - // Required for Drupal core 7.50+, otherwise the user won't have access to - // the field settings. - 'administer fields', ); - return $this->createUser(array_merge($permissions, $perms)); - } - - /** - * Create a new user account with limited permissions. - * - * @param array $perms - * Any permissions to be added to the user. - * - * @return object - * A standard Drupal user object. - */ - function createUser(array $perms = array()) { // Reset the static variable used to identify permissions, otherwise it's // possible the permissions check in drupalCreateUser will fail. $this->checkPermissions(array(), TRUE); cache_clear_all(); - return $this->drupalCreateUser($perms); + return $this->drupalCreateUser($permissions); } /** diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.permissions.test b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.permissions.test index 7e502e5683fd849fa5288a15ffbcc04ab30ddf5e..3dad9d11b702fc8da199c28e9a78bdda42ea2149 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.permissions.test +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.permissions.test @@ -33,7 +33,16 @@ class FppPermissionsTest extends FppTestHelper { */ function testAdminPermission() { // Create a user with the admin permission. - $this->adminUser = $this->createAdminUser(); + $permissions = array( + 'administer fieldable panels panes', + ); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); $this->drupalLogin($this->adminUser); @@ -77,13 +86,14 @@ class FppPermissionsTest extends FppTestHelper { $this->assertResponse(200, 'Loaded the Manage Display page for the default FPP type.'); $this->assertText(t('Use custom display settings for the following view modes')); - // These two legacy paths should redirect to the correct paths. + // These two paths don't exist. $this->drupalGet('admin/structure/fieldable-panels-panes/manage/' . $this->bundle . '/fields'); $this->assertResponse(200); - $this->assertEqual($this->getUrl(), url('admin/structure/fieldable-panels-panes/' . $this->bundle . '/fields', array('absolute' => TRUE))); + $this->assertText(t('There are currently no entities of this type.'), 'The old(?) FPP manage fields URL no longer works.'); + $this->drupalGet('admin/structure/fieldable-panels-panes/manage/' . $this->bundle . '/display'); $this->assertResponse(200); - $this->assertEqual($this->getUrl(), url('admin/structure/fieldable-panels-panes/' . $this->bundle . '/display', array('absolute' => TRUE))); + $this->assertText(t('There are currently no entities of this type.'), 'The old(?) FPP manage display URL no longer works.'); } /** @@ -94,8 +104,15 @@ class FppPermissionsTest extends FppTestHelper { $permissions = array( 'access fieldable panels panes master list', ); - $this->user = $this->createUser($permissions); - $this->drupalLogin($this->user); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); + + $this->drupalLogin($this->adminUser); // Load the 'list' page. $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle . '/list'); @@ -109,10 +126,17 @@ class FppPermissionsTest extends FppTestHelper { function testCreateBundlePermission() { // Create a user with the admin permission. $permissions = array( - "create fieldable {$this->bundle}", + 'create fieldable ' . $this->bundle, ); - $this->user = $this->createUser($permissions); - $this->drupalLogin($this->user); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); + + $this->drupalLogin($this->adminUser); // Load the 'add' page. $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle . '/add'); @@ -149,10 +173,17 @@ class FppPermissionsTest extends FppTestHelper { function testEditBundlePermission() { // Create a user with edit permission. $permissions = array( - "edit fieldable {$this->bundle}", + 'edit fieldable ' . $this->bundle, ); - $this->user = $this->createUser($permissions); - $this->drupalLogin($this->user); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); + + $this->drupalLogin($this->adminUser); // Load the 'add' page. $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle . '/add'); @@ -165,11 +196,18 @@ class FppPermissionsTest extends FppTestHelper { function testCreateEditBundlePermission() { // Create a user with create & edit permission. $permissions = array( - "create fieldable {$this->bundle}", - "edit fieldable {$this->bundle}", + 'create fieldable ' . $this->bundle, + 'edit fieldable ' . $this->bundle, ); - $this->user = $this->createUser($permissions); - $this->drupalLogin($this->user); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); + + $this->drupalLogin($this->adminUser); // Load the 'add' page. $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle . '/add'); @@ -199,11 +237,18 @@ class FppPermissionsTest extends FppTestHelper { function testDeleteBundlePermission() { // Create a user with the admin permission. $permissions = array( - "create fieldable {$this->bundle}", - "delete fieldable {$this->bundle}", + 'create fieldable ' . $this->bundle, + 'delete fieldable ' . $this->bundle, ); - $this->user = $this->createUser($permissions); - $this->drupalLogin($this->user); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); + + $this->drupalLogin($this->adminUser); // Load the 'add' page. $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle . '/add'); diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_panels.test b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_panels.test index 126fcbc0c39d4aab8946a5e6e8061eb1ad82e34c..0bf39969161e1ec5c2a0828008fc35c756c57bca 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_panels.test +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_panels.test @@ -33,11 +33,19 @@ class FppWithPanelsTest extends FppTestHelper { // Create a user with all the permissions $permissions = array( + 'administer fieldable panels panes', + // Needed for Page Manager. 'administer page manager', 'use page manager', ); - $this->adminUser = $this->createAdminUser($permissions); + + // Reset the static variable used to identify permissions, otherwise it's + // possible the permissions check in drupalCreateUser will fail. + $this->checkPermissions(array(), TRUE); + cache_clear_all(); + + $this->adminUser = $this->drupalCreateUser($permissions); $this->drupalLogin($this->adminUser); } diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_pathauto.test b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_pathauto.test deleted file mode 100644 index 626355d101bdd16d6e1bdceb1e093ade4b392e1c..0000000000000000000000000000000000000000 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp.with_pathauto.test +++ /dev/null @@ -1,75 +0,0 @@ -<?php -/** - * @file - * Tests for the Fieldable Panels Panes module with Pathauto. - */ - -class FppWithPathautoTest extends FppTestHelper { - /** - * {@inheritdoc} - */ - public static function getInfo() { - return array( - 'name' => 'FPP tests for Pathauto', - 'description' => 'Confirm that FPP does not break when using Pathauto.', - 'group' => 'FPP', - ); - } - - /** - * {@inheritdoc} - */ - function setUp(array $modules = array()) { - $modules[] = 'fieldable_panels_panes'; - - // - $modules[] = 'pathauto'; - - parent::setUp($modules); - - // Some default values to work with. - $this->bundle = 'fieldable_panels_pane'; - } - - function testPathauto() { - // Create a test node. - $node = $this->drupalCreateNode(); - - // Create a user with the admin permission. - $permissions = array( - "create fieldable {$this->bundle}", - 'view the administration theme', - ); - $this->user = $this->createUser($permissions); - $this->drupalLogin($this->user); - - // Load the 'add' page. - $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle . '/add'); - $this->assertResponse(200, 'Loaded the Add page for the default FPP type.'); - - // Save the record with a path that points to the node. - $args = array( - 'title' => t('Test'), - 'link' => TRUE, - 'path' => 'node/1', - ); - $this->drupalPost(NULL, $args, t('Save')); - $this->assertResponse(200); - $this->assertText(t('The entity has been saved.')); - - // Confirm the record was saved. - $this->drupalGet('admin/structure/fieldable-panels-panes/' . $this->bundle); - $this->assertNoText(t('There are currently no entities of this type.')); - - // Try loading it. - $this->drupalGet('admin/structure/fieldable-panels-panes/view/1'); - $this->assertResponse(200, 'Loaded the FPP object.'); - - // Load the FPP. - $fpp = fieldable_panels_panes_load(1); - - // Confirm there's a link with the FPP's title and the node's URL. - $this->assertRaw(l($fpp->title, 'node/' . $node->nid)); - } - -} diff --git a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp_with_panels_test.info b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp_with_panels_test.info index 02383526ced0724617d4b3d150b0467631e3895e..0dc5dadf14aca1d30daaab854cbf99679cc92025 100644 --- a/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp_with_panels_test.info +++ b/profiles/wcm_base/modules/contrib/fieldable_panels_panes/tests/fpp_with_panels_test.info @@ -9,9 +9,9 @@ dependencies[] = ctools dependencies[] = page_manager dependencies[] = fieldable_panels_panes -; Information added by Drupal.org packaging script on 2016-11-05 -version = "7.x-1.11" +; Information added by Drupal.org packaging script on 2016-05-04 +version = "7.x-1.10" core = "7.x" project = "fieldable_panels_panes" -datestamp = "1478371741" +datestamp = "1462374853" diff --git a/profiles/wcm_base/wcm_base.make b/profiles/wcm_base/wcm_base.make index d192f7eadbbe9acf4242dfc00de6e3b3ddb2be99..fff7cbfb5b47d3957c9a1bc092fd4fc840727d91 100644 --- a/profiles/wcm_base/wcm_base.make +++ b/profiles/wcm_base/wcm_base.make @@ -48,7 +48,7 @@ projects[field_group][version] = 1.5 projects[field_group][subdir] = contrib projects[field_group][patch][1670136] = http://drupal.org/files/issues/1670136-export-ctools-plugin-info-21.patch -projects[fieldable_panels_panes][version] = 1.11 +projects[fieldable_panels_panes][version] = 1.10 projects[fieldable_panels_panes][subdir] = contrib projects[file_entity][version] = 2.0-beta3