示例#1
0
 /**
  * Pre-processor for $table->delete($pk)
  *
  * @param   mixed $pk An optional primary key value to delete.  If not set the instance property value is used.
  *
  * @return  void
  *
  * @since   3.1.2
  * @throws  UnexpectedValueException
  */
 public function onAfterDelete($pk)
 {
     $db = $this->table->getDbo();
     $item = new Userideas\Item\Item($db);
     $item->load($this->table->item_id);
     $item->decreaseVote($this->table->votes);
 }