public function delete() { $mds = ModelDescription::get_by_modelId($this->id); foreach ($mds as $md) { $md->delete(); } if ($this->modelType == 'V') { $pm = ParticipleModel::loadByVerbModel($this->number); $pm->delete(); } parent::delete(); }
public function delete() { WikiKeyword::deleteByWikiArticleId($this->id); parent::delete(); }
public function delete($connection = null) { if (!isset($connection)) { $connection = QubitTransactionFilter::getConnection(QubitObject::DATABASE_NAME); } $statement = $connection->prepare(' DELETE FROM ' . QubitSlug::TABLE_NAME . ' WHERE ' . QubitSlug::OBJECT_ID . ' = ?'); $statement->execute(array($this->id)); // Delete other names if (0 < count($this->otherNames)) { foreach ($this->otherNames as $otherName) { $otherName->delete(); } } parent::delete($connection); }
function delete() { // TODO: Delete thumbnail and its directory (if it becomes empty) VisualTag::delete_all_by_imageId($this->id); return parent::delete(); }
public function delete() { db_execute("update Inflection set rank = rank - 1 where modelType = '{$this->modelType}' and rank > {$this->rank}"); parent::delete(); }
public function delete() { if ($this->id) { if ($this->hasModelType('VT')) { $this->deleteParticiple(); } if ($this->hasModelType('VT') || $this->hasModelType('V')) { $this->deleteLongInfinitive(); } LexemDefinitionMap::deleteByLexemId($this->id); Meaning::delete_all_by_lexemId($this->id); Relation::delete_all_by_lexemId($this->id); LexemModel::delete_all_by_lexemId($this->id); } // Clear the variantOfId field for lexems having $this as main. $lexemsToClear = Lexem::get_all_by_variantOfId($this->id); foreach ($lexemsToClear as $l) { $l->variantOfId = null; $l->save(); } parent::delete(); }
function delete() { InflectedForm::delete_all_by_lexemModelId($this->id); LexemSource::delete_all_by_lexemModelId($this->id); // delete_all_by_lexemModelId doesn't work for FullTextIndex because it doesn't have an ID column Model::factory('FullTextIndex')->where('lexemModelId', $this->id)->delete_many(); parent::delete(); }
public function delete() { MeaningSource::deleteByMeaningId($this->id); MeaningTagMap::deleteByMeaningId($this->id); Relation::delete_all_by_meaningId($this->id); parent::delete(); }
public function delete() { if ($this->id) { if ($this->modelType == 'VT') { $this->deleteParticiple($this->modelNumber); } if ($this->modelType == 'VT' || $this->modelType == 'V') { $this->deleteLongInfinitive(); } LexemDefinitionMap::deleteByLexemId($this->id); InflectedForm::deleteByLexemId($this->id); } parent::delete(); }