Hi Guys, i would love to have cloning feature as i will be adding 900 products ahead of me. Just installed cloning and found its throwing these 11 errors. Please help. Is there is any special way i can install cloning to make it work???? Thanks in advance.
Notice: Undefined index: mlid in _menu_parent_depth_limit() (line 592 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: mlid in menu_form_node_form_alter() (line 630 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: mlid in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: module in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: hidden in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: has_children in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: customized in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: options in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: expanded in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: hidden in menu_form_node_form_alter() (line 644 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Notice: Undefined index: mlid in menu_form_node_form_alter() (line 661 of /home/thehighb/public_html/carnity.com/carnity/modules/menu/menu.module).
Comment | File | Size | Author |
---|---|---|---|
#10 | 1325028-10.patch | 1.14 KB | pwolanin |
#3 | node_clone_menuclone.diff | 759 bytes | ipaq3870 |
Comments
Comment #1
pwolanin CreditAttribution: pwolanin commentedThose are notices, not errors. Did the cloning fail for you?
They are coming from the menu module, so possible we need to set some more default values when cloning menu links
Comment #2
carnity CreditAttribution: carnity commentedNo it did not cloned the node (product) that i wanted and displayed following errors.
I am using corporate clean template theme, in case that help in fixing the dropdown type menu glitch (if any).
Comment #3
ipaq3870 CreditAttribution: ipaq3870 commentedA quick and dirty fix to add back those missing fields expected by menu.
Comment #4
pwolanin CreditAttribution: pwolanin commentedThis looks wrong - should probably be NULL?
Comment #5
KarenS CreditAttribution: KarenS commentedEven if you fix those values this doesn't work when prepopulating a node. The menu option is not chosen in the form so you won't see any preset value. You can change the menu before you save the node, but there is nothing 'cloned' about that process. I tried various things, like saving the menu link before displaying the form so that the menu already exists, and that makes the menu options work, but then you end up with two menu items, one pointing to the old node and one to the new one. I can't find any way to get the module to clone menu links in the prepopulate method.
Comment #6
Taxoman CreditAttribution: Taxoman commentedComment #7
jkristos CreditAttribution: jkristos commentedFor me it not only throws those errors, but won't save (and throws the error below) if I choose to "provide a menu link" because there seems to be no value for hidden, not sure if these are related to the missing default values or not....
PDOException: SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'hidden' cannot be null: INSERT INTO {menu_links} (menu_name, plid, link_path, hidden, external, has_children, expanded, weight, module, link_title, options, customized, updated) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8, :db_insert_placeholder_9, :db_insert_placeholder_10, :db_insert_placeholder_11, :db_insert_placeholder_12); Array ( [:db_insert_placeholder_0] => menu-careers [:db_insert_placeholder_1] => 0 [:db_insert_placeholder_2] => node/141 [:db_insert_placeholder_3] => [:db_insert_placeholder_4] => 0 [:db_insert_placeholder_5] => [:db_insert_placeholder_6] => [:db_insert_placeholder_7] => -45 [:db_insert_placeholder_8] => menu [:db_insert_placeholder_9] => Clone of Test Page [:db_insert_placeholder_10] => N; [:db_insert_placeholder_11] => [:db_insert_placeholder_12] => 0 ) in menu_link_save() (line 3111 of /opt/testsite/www/includes/menu.inc).
Comment #8
BrightBoldAgreed, this doesn't work. I got the following error:
Notice: Undefined index: language in clone_node_clone_menu_link() (line 141 of /srv/bindings/27b55f9b711141b793a3739da88cbe29/code/sites/all/modules/contrib/node_clone/clone.pages.inc).
and no clone of the menu item. Rats — this would be great functionality.
Comment #9
hexabinaerConfirm.
PDOException and some 14 "undefined index" notices for mlid like given above while "Save" results in an error page and does not clone the given node.
Workaround
* Uncheck "provide a menu link"
* Save
* Set the menu link after cloning.
Comment #10
pwolanin CreditAttribution: pwolanin as a volunteer and at Acquia commentedPatch was out of date. I see why -1 for mlid is useful.
This is working better for both cloning methods.
Need tests for this whole module, obviously.
Comment #11
pwolanin CreditAttribution: pwolanin as a volunteer and at Acquia commentedcommitted my last patch