Example #1
0
 public function getListeners()
 {
     $ret = parent::getListeners();
     $factoryId = $this->_getModel()->getProxyModel()->getFactoryId();
     $ret[] = array('class' => $factoryId, 'event' => 'Kwf_Events_Event_Row_Deleted', 'callback' => 'onRowEvent');
     $ret[] = array('class' => $factoryId, 'event' => 'Kwf_Events_Event_Row_Updated', 'callback' => 'onRowEvent');
     $ret[] = array('class' => $factoryId, 'event' => 'Kwf_Events_Event_Model_Updated', 'callback' => 'onModelEvent');
     return $ret;
 }
Example #2
0
 public function getListeners()
 {
     $ret = parent::getListeners();
     foreach ($this->_getModel()->getUnionModels() as $k => $sourceModel) {
         $sourceModelId = $sourceModel->getFactoryId();
         $ret[] = array('class' => $sourceModelId, 'event' => 'Kwf_Events_Event_Row_Inserted', 'callback' => 'onRowEvent');
         $ret[] = array('class' => $sourceModelId, 'event' => 'Kwf_Events_Event_Row_Deleted', 'callback' => 'onRowEvent');
         $ret[] = array('class' => $sourceModelId, 'event' => 'Kwf_Events_Event_Row_Updated', 'callback' => 'onRowEvent');
         $ret[] = array('class' => $sourceModelId, 'event' => 'Kwf_Events_Event_Model_Updated', 'callback' => 'onModelEvent');
     }
     return $ret;
 }
 public function getListeners()
 {
     $ret = parent::getListeners();
     $ret[] = array('class' => null, 'event' => 'Kwf_Model_Events_Basic_TestEvent', 'callback' => 'onTestEvent');
     return $ret;
 }