push_type icon indicating copy to clipboard operation
push_type copied to clipboard

Matrix field that has a :relation type that is multiple does not save properly

Open kwyoung11 opened this issue 5 years ago • 0 comments

Matrix fields with relation sub fields that allow multiple values do not seem to be working properly.

Create a Relation, for e.g.

class Note < PushType::Node
  has_child_nodes :false

  field :content, :wysiwyg
end
class Klass < PushType::Node
  has_child_nodes :false

  field :notes, :matrix do
    field :note_ids, :relation, multiple: true
  end
end

STR:

  1. Go to CMS.
  2. Create multiple different Note objects and give them whatever content you like
  3. Create a new Klass object
  4. Add a Note object to the first row in the matrix
  5. Click "+Add row" to add a new row to the matrix
  6. Add another Note object to the newly added row (the second row)
  7. Publish the Node

Expected behavior: Note objects remain in their prescribed rows in the matrix

Actual behavior: The second note object from the second row moves up to the first row, and the second row in the matrix becomes blank

kwyoung11 avatar Mar 14 '19 23:03 kwyoung11