Projet

Général

Profil

Révision e4c061ad

Ajouté par Assos Assos il y a plus de 9 ans

Weekly update of contrib modules

Voir les différences:

drupal7/sites/all/modules/ctools/plugins/export_ui/ctools_export_ui.class.php
121 121

  
122 122
    switch ($op) {
123 123
      case 'import':
124
        return user_access('use PHP for settings');
124
        return user_access('use ctools import');
125 125
      case 'revert':
126 126
        return ($item->export_type & EXPORT_IN_DATABASE) && ($item->export_type & EXPORT_IN_CODE);
127 127
      case 'delete':
......
639 639
  }
640 640

  
641 641
  function add_page($js, $input, $step = NULL) {
642
    drupal_set_title($this->get_page_title('add'));
642
    drupal_set_title($this->get_page_title('add'), PASS_THROUGH);
643 643

  
644 644
    // If a step not set, they are trying to create a new item. If a step
645 645
    // is set, they're in the process of creating an item.
......
676 676
   * Main entry point to edit an item.
677 677
   */
678 678
  function edit_page($js, $input, $item, $step = NULL) {
679
    drupal_set_title($this->get_page_title('edit', $item));
679
    drupal_set_title($this->get_page_title('edit', $item), PASS_THROUGH);
680 680

  
681 681
    // Check to see if there is a cached item to get if we're using the wizard.
682 682
    if (!empty($this->plugin['use wizard'])) {
......
712 712
   * Main entry point to clone an item.
713 713
   */
714 714
  function clone_page($js, $input, $original, $step = NULL) {
715
    drupal_set_title($this->get_page_title('clone', $original));
715
    drupal_set_title($this->get_page_title('clone', $original), PASS_THROUGH);
716 716

  
717 717
    // If a step not set, they are trying to create a new clone. If a step
718 718
    // is set, they're in the process of cloning an item.
......
1218 1218
   * Page callback to display export information for an exportable item.
1219 1219
   */
1220 1220
  function export_page($js, $input, $item) {
1221
    drupal_set_title($this->get_page_title('export', $item));
1221
    drupal_set_title($this->get_page_title('export', $item), PASS_THROUGH);
1222 1222
    return drupal_get_form('ctools_export_form', ctools_export_crud_export($this->plugin['schema'], $item), t('Export'));
1223 1223
  }
1224 1224

  
......
1226 1226
   * Page callback to import information for an exportable item.
1227 1227
   */
1228 1228
  function import_page($js, $input, $step = NULL) {
1229
    drupal_set_title($this->get_page_title('import'));
1229
    drupal_set_title($this->get_page_title('import'), PASS_THROUGH);
1230 1230
    // Import is basically a multi step wizard form, so let's go ahead and
1231 1231
    // use CTools' wizard.inc for it.
1232 1232

  
......
1339 1339
 *
1340 1340
 * This simply loads the object defined in the plugin and hands it off.
1341 1341
 */
1342
function ctools_export_ui_list_form($form, $form_state) {
1342
function ctools_export_ui_list_form($form, &$form_state) {
1343 1343
  $form_state['object']->list_form($form, $form_state);
1344 1344
  return $form;
1345 1345
}

Formats disponibles : Unified diff