Ejemplo n.º 1
0
 /**
  * Deletes a row from the wotd table
  * @access protected
  * @return string
  * */
 protected function doDelete()
 {
     $wotd = WordOfTheDay::get_by_id($this->id);
     $wotd->delete();
     $wotdr = WordOfTheDayRel::get_by_wotdId($this->id);
     $wotdr->delete();
     return '';
 }
Ejemplo n.º 2
0
 /**
  * Deletes a row from the wotd table
  * @access protected
  * @return error string (empty for success)
  * */
 protected function doDelete()
 {
     $wotd = WordOfTheDay::get_by_id($this->id);
     if ($wotd) {
         $wotd->delete();
         return '';
     } else {
         return "Înregistrarea de șters nu a fost găsită (id={$this->id})";
     }
 }