Create workflow based on call Count

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Falerci
    Junior Member
    • Apr 2019
    • 24

    Create workflow based on call Count

    HI there,

    My idea is: if I have 10 calls related with the account send an email to the Account Email.

    I was thinking to do it with a workflow, but I have no clue about how count the account related calls. Do you have an idea how to handle this scenario?

    I thinks that the workflow shoud be based on the Call, as soon as I have 10 calls with the same account, send the email. Workflow Conditions does not offer the possibility to per a specific value.

    Thanks
  • AlexAv
    EspoCRM Team
    • May 2014
    • 124

    #2
    You can try to implement this:

    Steps:

    1. Create a Report;
    2. Create a Scheduled Workflow.

    https://docs.espocrm.com/administration/workflows/#scheduled

    Comment

    • Falerci
      Junior Member
      • Apr 2019
      • 24

      #3
      Thanks AlexAv for your solution. I need that the count immediately so schedule a workflow is not the better option for my case.

      I solved using a workflow with the function: record\count. https://docs.espocrm.com/administrat...a/#recordcount

      Comment

      • yuri
        Member
        • Mar 2014
        • 8483

        #4
        Hi,

        You can create a workflow rule for a Call entity with 'after-record-created' trigger with a formula condition checking the number of records. Use record\count function https://docs.espocrm.com/administrat...a/#recordcount.

        Code:
        record\count('Call', 'accountId=', accountId) == 10

        This workflow can either do some actions or trigger another workflow rule with a target record changed to a related account.
        Last edited by yuri; 07-31-2020, 11:17 AM.
        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

        Working...