Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-9250

It's possible to add an object more than once to a node

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Medium Medium
    • 3.8.7, 3.9.0rc1
    • 3.8.2, 3.8.3, 3.8.4, 3.9.0alpha1
    • None
    • Operating System: Linux (Debian i386 etch)
      PHP Version: 4.4.2
      Database and version: mysql 5.0.24

    Description

      In /kernel/content/action.php for "CurrentAction" == AddAssignment the array "$assignedIDArray" is filled with the wrong nodes.

      Currently this array contains the nodeIDs of the nodes of the object already has. This is wrong as it should contain the nodeIDs the current object is already placed on.

      This is easy to resolve by just changing this line in /kernel/content/action.php

      $assignedNodeID = $assignedNode->attribute( 'node_id' );
      

      to this:

      $assignedNodeID = $assignedNode->attribute( 'parent_node_id' );
      

      In current trunk rev. 17263 the affected line# is 705.

      Steps to reproduce

      Simply try to add an object in the admin interface twice to a new node. This will lead to something like you can see in the attached screenshot.

      Attachments

        Activity

          People

            vp vp
            dabe dabe
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: