Scheduler, Order Events, Path to Product Images

Hi there, 

Hope you are doing well. I followed the steps to install the cron and it even showed in the ‚scheduled_task‘ table in database. when I execute the cron & consumer manually using the CLI it keeps on executing although I have a dump statemenet in my cron but nothing gets printed in the CLI.

Also I have one more issue. I have to work with order events

  1. Order written event (OrderEvents::ORDER_WRITTEN_EVENT)
  2. Order state change event (OrderEvents::ORDER_STATE_WRITTEN_EVENT)
    The first event i found is working perfectly and it dumps the data as expected but the 2nd event doesnt work when I change order_state. Am I using wrong event for Order state Change if not can you tell me what can be wrong with it ?

Last but not least. I need to extract the complete link of the display image of the product description page. I cant find its path in the DataBase tables media, product_media. Where can I find the complete path to the uploaded product image. 

Hey,

I am sorry to not reply to your question, to be honest I am new to Shopware6… 
I am just here to ask you how you did you do to make your first event (OrderEvents::ORDER_WRITTEN_EVENT) work?
Because I have this code and it’s not working, nothing happens when I create a test order in the frontend.
 

    

<?php

  namespace Emakers\TransmissionPlugin\Subscriber;  use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\HttpKernel\Event\ExceptionEvent; use Symfony\Component\HttpKernel\KernelEvents; use Enlight\_Hook\_HookArgs;  class OrderSubscriber implements EventSubscriberInterface  {     public static function getSubscribedEvents()      {          // return the subscribed events, their methods and priorities         return [                     ['OrderEvents::ORDER\_WRITTEN\_EVENT' =\> 'onOrderCheckout'],          ];      }      public function onOrderCheckout(Enlight\_Hook\_HookArgs $args)      {          die('TEST OK');     } }

Hi hope you are doing well. Sorry to say but i still couldnt make the code to work :( 

Hey! I am also sorry, could not find a solution to your problem. 

I have the same problem this event (ORDER_STATE_WRITTEN_EVENT) does not work.

Have you found a solution?

Hi,

 

Hope you are doing well. Sorry but no I didnt find any solution to it as of now.

hi,

even though this thread is a bit older i’m actually facing the same issue right now and was hoping anybody had any idea for this…

Hi,
have the same problem! Still no solution for this one?

Hi :slight_smile:

OrderEvents::ORDER_STATE_WRITTEN_EVENT is not implemented.

I recommend use state_machine.order.state_changed event instead.