I cloned a panel properly, I changed name, title, path and now I have two similar panels.
But then I change panel content in a one panel, it changes also in the other.

Comments

moonray’s picture

Having the same issue here.

Anonymous’s picture

merlinofchaos’s picture

Status: Active » Fixed

This should now be fixed in -beta4. However, any existing panel with this problem will likely continue to have this problem. Your best bet will be to export all pages that show this problem, delete them, and then re-import. That should clear up any duplication.

Anonymous’s picture

Great, thanks Merlin!

ari-meetai’s picture

Title: Panel page cloning » Panels and cloning
Version: 6.x-3.0-beta2 » 6.x-3.0-beta4
Status: Fixed » Active

- Changed the title to better reflect these related issue. I'm using -beta4

I'm trying to clone a Variant from the new "Pages" page. The clone seems to function properly, but when I edit a value on the newly created cloned Variant, it changes on the original one (and backwards). On save, only one is shown, instead of the original and the cloned one.

When I try to Export and Import a Variant to try and obtain the wanted result, I get the error:

"An error occurred while attempting to process /admin/build/pages/ajax/operation/node_view/actions/import/form"

I edited the exported code to give the panel a new name, in 'title' => 'new_title'

Also checked: http://drupal.org/node/363624

merlinofchaos’s picture

Status: Active » Fixed

Doh. Wow, in the clone routine I apparently forgot to actually clone the handler. So it just added it back. :P

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

dafeder’s picture

Version: 6.x-3.0-beta4 » 6.x-3.0-rc1
Status: Closed (fixed) » Active

I still get "An error occurred while attempting to process /admin/build/pages/ajax/operation/node_view/actions/import/form" when I try to import a variant into an existing page.

dafeder’s picture

FYI have verified this on several different browsers and with different pages and variants. Is anyone able to import variants on RC1? I AM able to import entire pages, but for in-code pages (node, user) this doesn't work and I need to import variants.

Mike_Waters’s picture

same here.

jrabeemer’s picture

I get this JS error "An error occurred while attempting to process /admin/build/pages/ajax/operation/user_view/actions/import/form" when attempting to import my variant into /user/%user system view.

jrabeemer’s picture

Version: 6.x-3.0-rc1 » 6.x-3.0

Rebasing..

jenlampton’s picture

Yep same error here:

An error occurred while attempting to process /admin/build/pages/ajax/operation/search_view-user/actions/import/form

I'm trying to import a variant for the user_view handler. Here is my import code:

$handler = new stdClass;
$handler->disabled = FALSE; /* Edit this to true to make a default handler disabled initially */
$handler->api_version = 1;
$handler->name = 'user_view_panel_context';
$handler->task = 'user_view';
$handler->subtask = '';
$handler->handler = 'panel_context';
$handler->weight = 0;
$handler->conf = array(
  'title' => 'User Profile',
  'no_blocks' => FALSE,
  'css_id' => '',
  'css' => '',
  'contexts' => array(),
  'relationships' => array(),
);
$display = new panels_display;
$display->layout = 'left_sidebar';
$display->layout_settings = array();
$display->panel_settings = array();
$display->cache = array();
$display->title = '%user:name';
$display->hide_title = FALSE;
$display->content = array();
$display->panels = array();
  $pane = new stdClass;
  $pane->pid = 'new-1';
  $pane->panel = 'left';
  $pane->type = 'profile_image_view';
  $pane->subtype = 'profile_image_view';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array();
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 0;
  $display->content['new-1'] = $pane;
  $display->panels['left'][0] = 'new-1';
  $pane = new stdClass;
  $pane->pid = 'new-2';
  $pane->panel = 'left';
  $pane->type = 'profile_action_links';
  $pane->subtype = 'profile_action_links';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array();
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 1;
  $display->content['new-2'] = $pane;
  $display->panels['left'][1] = 'new-2';
  $pane = new stdClass;
  $pane->pid = 'new-3';
  $pane->panel = 'left';
  $pane->type = 'profile_linkedin_view';
  $pane->subtype = 'profile_linkedin_view';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array();
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 2;
  $display->content['new-3'] = $pane;
  $display->panels['left'][2] = 'new-3';
  $pane = new stdClass;
  $pane->pid = 'new-4';
  $pane->panel = 'main';
  $pane->type = 'profile_view';
  $pane->subtype = 'profile_view';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array();
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 0;
  $display->content['new-4'] = $pane;
  $display->panels['main'][0] = 'new-4';
$handler->conf['display'] = $display;

jenlampton’s picture

Title: Panels and cloning » error when exporting / importing a page handler varient

more useful title

jenlampton’s picture

Title: error when exporting / importing a page handler varient » error when exporting / importing a page handler variant

would help if i could spell :-)

Update, same issue happens for me on node_view handler import.
Here's the error:

An error occurred while attempting to process /admin/build/pages/ajax/operation/node_view/actions/import/form

Here's the code I'm using for that:

$handler = new stdClass;
$handler->disabled = FALSE; /* Edit this to true to make a default handler disabled initially */
$handler->api_version = 1;
$handler->name = 'node_view_panel_context';
$handler->task = 'node_view';
$handler->subtask = '';
$handler->handler = 'panel_context';
$handler->weight = 0;
$handler->conf = array(
  'title' => 'Groups',
  'no_blocks' => 0,
  'css_id' => 'group',
  'css' => '',
  'contexts' => array(),
  'relationships' => array(),
  'access' => array(
    'logic' => 'and',
    'plugins' => array(
      '0' => array(
        'name' => 'node_type',
        'settings' => array(
          'type' => array(
            'group' => 'group',
          ),
        ),
        'context' => 'argument_nid_1',
      ),
    ),
  ),
);
$display = new panels_display;
$display->layout = 'stacked_left_sidebar_bricks';
$display->layout_settings = array();
$display->panel_settings = array(
  'main_row3' => array(
    'style' => 'tabs',
  ),
  'style_settings' => array(
    'main_row3' => array(
      'filling_tabs' => 'disabled',
    ),
  ),
);
$display->cache = array();
$display->title = '';
$display->hide_title = FALSE;
$display->content = array();
$display->panels = array();
  $pane = new stdClass;
  $pane->pid = 'new-1';
  $pane->panel = 'left';
  $pane->type = 'group_details';
  $pane->subtype = 'group_details';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array();
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array(
    'css_id' => '',
    'css_class' => 'group-details-pane',
  );
  $pane->extras = array();
  $pane->position = 0;
  $display->content['new-1'] = $pane;
  $display->panels['left'][0] = 'new-1';
  $pane = new stdClass;
  $pane->pid = 'new-2';
  $pane->panel = 'left';
  $pane->type = 'content_type_image';
  $pane->subtype = 'content_type_image';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array(
    'content_type_image_fid' => '13',
    'content_type_image_title' => 'Advertisement',
    'content_type_image_link' => 'http://www.e.com',
    'content_type_image_caption' => '',
  );
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array(
    'css_id' => '',
    'css_class' => 'advertisement-pane',
  );
  $pane->extras = array();
  $pane->position = 1;
  $display->content['new-2'] = $pane;
  $display->panels['left'][1] = 'new-2';
  $pane = new stdClass;
  $pane->pid = 'new-3';
  $pane->panel = 'left';
  $pane->type = 'views_panes';
  $pane->subtype = 'inceptum_profiles-panel_pane_1';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array(
    'context' => array(
      '0' => 'argument_nid_1',
    ),
  );
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 2;
  $display->content['new-3'] = $pane;
  $display->panels['left'][2] = 'new-3';
  $pane = new stdClass;
  $pane->pid = 'new-4';
  $pane->panel = 'main_row1';
  $pane->type = 'group_description';
  $pane->subtype = 'group_description';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array();
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array(
    'css_id' => 'group-header',
    'css_class' => '',
  );
  $pane->extras = array();
  $pane->position = 0;
  $display->content['new-4'] = $pane;
  $display->panels['main_row1'][0] = 'new-4';
  $pane = new stdClass;
  $pane->pid = 'new-5';
  $pane->panel = 'main_row3';
  $pane->type = 'views_panes';
  $pane->subtype = 'inceptum_discussions-panel_pane_2';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array(
    'context' => array(
      '0' => 'argument_nid_1',
    ),
  );
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 0;
  $display->content['new-5'] = $pane;
  $display->panels['main_row3'][0] = 'new-5';
  $pane = new stdClass;
  $pane->pid = 'new-6';
  $pane->panel = 'main_row3';
  $pane->type = 'views_panes';
  $pane->subtype = 'inceptum_profiles_groups-panel_pane_2';
  $pane->shown = TRUE;
  $pane->access = array();
  $pane->configuration = array(
    'context' => array(
      '0' => 'argument_nid_1',
    ),
  );
  $pane->cache = array();
  $pane->style = array();
  $pane->css = array();
  $pane->extras = array();
  $pane->position = 1;
  $display->content['new-6'] = $pane;
  $display->panels['main_row3'][1] = 'new-6';
$handler->conf['display'] = $display;
dawehner’s picture

Just to give more informations:

<br />
<b>Fatal error</b>:  __clone method called on non-object in <b>includes/common.inc</b> on line <b>1692</b><br />
dawehner’s picture

So it seams that page_manager_export_task_handler is called when importing.

Currently $handler is there a string, so it is clear, that drupal_clone fails.

merlinofchaos’s picture

Title: error when exporting / importing a page handler variant » Panels cloned improperly
Status: Active » Closed (fixed)

Ack. #8 repurposed this issue from one thing into something else. That sucks. That really should have been a new issue.

Anyone who had anything useful after #8, please file a new issue. Reverting this to its original state.

dafeder, *wrist smack* for repurposing an unrelated issue. To everyone else: *wrist smack* for not noticing that he did that and running with it.

dafeder’s picture

Ouch! Sorry Merlin, you are of course right.

I'm on deadline with some newer projects now and don't really have time to go back and test this, so I'll hold off on creating a new issue for the moment. If no one follows up I'll try to find some time in the next few days.