You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 satır
464B

  1. <?php
  2. namespace domain\User\UserProducer\Event;
  3. use justcoded\yii2\eventlistener\observers\ActiveRecordObserver;
  4. use domain\User\UserProducer\UserProducerModule;
  5. use yii\db\AfterSaveEvent;
  6. class PaymentObserver extends ActiveRecordObserver
  7. {
  8. public function inserted(AfterSaveEvent $event)
  9. {
  10. $payment = $event->sender;
  11. $userProducerModule = UserProducerModule::getInstance();
  12. $userProducerModule->updateCredit($payment);
  13. }
  14. }