* * @return mixed Int (No. of rows affected) on success, false on failure, 0 on no data affected
*/
public function delete($useWhere = FALSE) {
+ $preEvent = new \Civi\Core\DAO\Event\PreDelete($this);
+ \Civi::service('dispatcher')->dispatch("civi.dao.preDelete", $preEvent);
+
$result = parent::delete($useWhere);
$event = new \Civi\Core\DAO\Event\PostDelete($this, $result);
public static function buildOptions($fieldName, $context = NULL, $props = array()) {
// If a given bao does not override this function
$baoName = get_called_class();
- return CRM_Core_PseudoConstant::get($baoName, $fieldName, array(), $context);
+ return CRM_Core_PseudoConstant::get($baoName, $fieldName, $props, $context);
}
/**