Announcement

Collapse
No announcement yet.

How to check if custom workflow action is actually invoked ?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to check if custom workflow action is actually invoked ?

    Hello EspoCRM developers,

    I am totaly new to the EspoCRM source code and PHP in general. I managed to configure a custom workflow action ( As I can see it in the workflow editor).
    I added a log statement similar to one that I found in the code
    class AppProject extends \Espo\Core\Templates\Services\BasePlus { public function appCreateAction($workflowId, Entity $entity, $additionalParameters = null) { $GLOBALS['log']->info('hello world'); } } I do not see this in the log file data/logs/espo-....log I set the log level to DEBUG in the config.php but there a no log entries except [2018-11-16 10:24:01] Espo.DEBUG: BPM: processPendingFlows [] [] I would expect much more debug output. Am I missing something ? Any help appreceated. Dirk

  • #2
    Hello,
    can you find your entityDefs Workflow definition in data/cache/application/metadat.php? What if instead of log, throw an error?

    Comment


    • #3
      Yes the action is in the metadata.php. If I throw an Exception I get an error when I try to save the entity that is associated with my custom workflow action - this is one step forward
      But I would like it better to see some log output. If I on purpose make some syntax error in my Service Action I do not see this anywhere.

      Comment


      • #4
        check access to log file.
        If you use different user for web and for crontab, you can have problem with access to log file. (depends on who was first today and who created this file)

        also you can try higher log level for message, like error(). Only for test. But DEBUG level covers info() messages, as I know

        Comment


        • #5
          removed all log files and set Level to 'ALL'. Now I can see the log messages ;-)

          Comment

          Working...
          X