deleteByDataObjectId($article->getId()); // insert article tombstone $section = $sectionDao->getById($article->getSectionId()); $setSpec = urlencode($journal->getPath()) . ':' . urlencode($section->getLocalizedAbbrev()); $oaiIdentifier = 'oai:' . Config::getVar('oai', 'repository_id') . ':' . 'article/' . $article->getId(); $OAISetObjectsIds = array( ASSOC_TYPE_JOURNAL => $journal->getId(), ASSOC_TYPE_SECTION => $section->getId(), ); $articleTombstone = $tombstoneDao->newDataObject(); $articleTombstone->setDataObjectId($article->getId()); $articleTombstone->stampDateDeleted(); $articleTombstone->setSetSpec($setSpec); $articleTombstone->setSetName($section->getLocalizedTitle()); $articleTombstone->setOAIIdentifier($oaiIdentifier); $articleTombstone->setOAISetObjectsIds($OAISetObjectsIds); $tombstoneDao->insertObject($articleTombstone); if (HookRegistry::call('ArticleTombstoneManager::insertArticleTombstone', array(&$articleTombstone, &$article, &$journal))) return; } } ?>