Forums OroPlatform OroPlatform – Programming Questions Configuring Workflows

This topic contains 1 reply, has 2 voices, and was last updated by  Yevhen Shyshkin 2 years, 3 months ago.

  • Creator
  • #28493

    Nicolas Rangeon

    Hello to all!

    I’m currently trying to configure Workflows.

    I saw here this kind of configuration :

    Let’s have a look on the last line:

    I guess the attribute $call_timeout has to be re-computed and updated each day, for each entity. This may probably need a daily cron.
    Is there a simpler way to do that? Something that would look like :

Viewing 1 replies (of 1 total)
  • Author
  • #28494

    Yevhen Shyshkin

    Hello, Nicolas.

    In fact this specific workflow is just an example of how workflow should look like, so this is not real workflow for some entity.

    If you need to calculate time interval from some specific date to now, you can calculate if with diff function – e.g. you can create “now” object with create_datetime action, then call diff using call_method action, and then extract it from DateInterval object. Of course, instead of all that you can register your own action (like calculate_diff_until_now) and encapsulate all this logic inside.

Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.