Is launching a BPM when a relation has changed possible? Advanced pack

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • abisbe
    Member
    • May 2021
    • 60

    Is launching a BPM when a relation has changed possible? Advanced pack

    Hi all,

    I am trying to launch a flowchart process when a relationship has changed, but it doesn't seem to work. I have an entity Application, and an entity Selection, Application is related many to many with Selection with the relation selections, what I need is that when I add a course to this relation, or unlink one to be able to launch this flowchart process.
    To achieve this I have tried to add as a start conditional something like Selections changed, in hopes that when that relation array changes, it'll launch the process, but this doesn't seem to work.
    Click image for larger version

Name:	image.png
Views:	98
Size:	10.6 KB
ID:	110348
    Any suggestions on how to address this?
    I am not on the latest updates, I'm using 7.3.4 and Advanced pack 2.15.5 I know there might be some fixes already to this, but I'm in the middle of some campaigns and can't risk upgrading now.

    Thank you!

    PS: This post might be better in the Extensions area, but I couldn't decide which place was best, please move it if you think that it's better at the other place.
  • lazovic
    Super Moderator
    • Jan 2022
    • 810

    #2
    Hi abisbe,

    In your case, it is better to use Signal Start Event with @relate.selections and/or @unrelate.selections signals: https://docs.espocrm.com/administrat...als/#default_1

    Comment

    • rabii
      Active Community Member
      • Jun 2016
      • 1250

      #3
      Hey,

      Not sure about the version you have but i think you can still use Signal event instead of conditional event even better you can use two signal events on the flowchart one for @relate.selections and another @unrelate.selections

      so when a new selection is related to the application you can execute certain task and second signal when a selection is unrelated from the application you can execute a different task / logic etc.

      Check this in the documentation


      This is what you need to make it work.
      Rabii
      Web Dev

      Comment

      • abisbe
        Member
        • May 2021
        • 60

        #4
        Of course! How did I miss that! I'll make it happen and post the result, thank you both!

        Comment

        • abisbe
          Member
          • May 2021
          • 60

          #5
          rabii I am a little confused because the signals you are talking about are found in the intermediate signal event, which as I understand it will not start a workflow right? and the on the start signal I cannot add @relate...

          Comment

          • rabii
            Active Community Member
            • Jun 2016
            • 1250

            #6
            Hey,

            Object signals
            • Broadcasted along with the entity (record).
            • Prefixed with @ character.
            • Can be used only to initiate a new process or workflow rule.
            • Can't be caught within a running process.
            • Can be broadcasted by a running process.
            As you can see in documentation they can be used to initiate a new process, i understand you can't find them there but you can just type them @relate.selections and that should work fine. ​
            Rabii
            Web Dev

            Comment

            Working...