Covering OroCRM topics, including community updates and company announcements.  Subscribe

This topic contains 2 replies, has 2 voices, and was last updated by  cardiac 2 years, 6 months ago.

  • Creator
  • #9480



    I created a new workflow where I have EntityA.
    I want to create EntityB fill columna and columnb and set EntityA.

    Error is a DB error:

    message: “Can’t create entity AppBundle\Entity\Entityb. An exception occurred while executing ‘INSERT INTO app_entityb (columna, columnb, createdAt, updatedAt, workflow_item_id, workflow_step_id, entitya_id) VALUES (?, ?, ?, ?, ?, ?, ?, ?)’ with params [null, null, “2015-04-23 10:22:38”, “2015-04-23 10:22:38″, null, null, 4]:↵↵SQLSTATE[23000]: Integrity constraint violation: 1048 Column ‘columna’ cannot be null”




    How to set the values from workflow form to the new Entity?

    Thanks and

    best regards

Viewing 2 replies - 1 through 2 (of 2 total)
  • Author
  • #9485
    Yevhen Shyshkin
    Yevhen Shyshkin
    Oro Core

    Hello, cardiac.

    I see two possible issues here.

    1) In your transition “start_entityb” (transition.yml) you use attributes entityb_columna and entityb_columnb, and in the same time they are not defined in list of attributes (attributes.yml). You have to define attributes first to use them in transition form.

    2) Parameter “data” of “@create_entity” action uses keys as property paths – so, please, make sure that entity AppBundle\Entity\Entityb has fields called columna/columnb or has appropriate setters setColumna/setColumnb.

    To debug this case you can add breakpoint here and check what data is there.

    Also you can check how Qualify transition works in Sales Funnel flow: attribute, transition, transition definition.

    Please, write here results of your investigation.



    Thank you for your help. I had an error in attributes.yml. You are right 😉

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.