@relate signal not being triggered

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • a.slyzhko
    Member
    • Oct 2023
    • 90

    @relate signal not being triggered

    Hi there!

    When I create two entities A and B. A has many B. When I'm on detail record of entity A and try to create new B from relationship panel (with plus button), I can't catch signal @relate.bRelationName on A entity. But when I unlink this newly created entity B, I can catch @unrelate.bRelationName on A entity. Any suggestions?
  • yuri
    Member
    • Mar 2014
    • 8440

    #2
    From the docs, the relate signal is triggered only for many-to-many.
    If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

    Comment


    • a.slyzhko
      a.slyzhko commented
      Editing a comment
      Then, can you please explain, why @unrelate signal worked, however relation is one-to-meny?

    • yuri
      yuri commented
      Editing a comment
      Because unrelate is a separate action internally. When you create one-to-many, there's no linking action.
      Last edited by yuri; 04-26-2024, 01:32 PM.

    • yuri
      yuri commented
      Editing a comment
      @unrelate works for all. unrelate only for many-to-many.
Working...