testing
This commit is contained in:
@@ -10,6 +10,7 @@ require_once 'Article.php';
|
||||
class LocalArticleManager implements ArticleManagerDAO {
|
||||
|
||||
private $file = '../../data/articles.json';
|
||||
private static $instance = null;
|
||||
|
||||
/**
|
||||
* Gibt die LocalArticleManager-Instanz zurück.
|
||||
@@ -24,11 +25,6 @@ class LocalArticleManager implements ArticleManagerDAO {
|
||||
return self::$instance;
|
||||
}
|
||||
|
||||
public function test()
|
||||
{
|
||||
return "Instanz wird übertragen!";
|
||||
}
|
||||
|
||||
/**
|
||||
* Speichert alle Artikel/Beiträge in der Datei.
|
||||
* @param $articles
|
||||
@@ -51,7 +47,7 @@ class LocalArticleManager implements ArticleManagerDAO {
|
||||
public function addArticle($title, $content, $author, $category, array $tags)
|
||||
{
|
||||
$articles = $this->getAllArticles();
|
||||
/*
|
||||
|
||||
$articles[] = [
|
||||
"id" => count($articles)+1,
|
||||
"title" => $title,
|
||||
@@ -61,7 +57,7 @@ class LocalArticleManager implements ArticleManagerDAO {
|
||||
"tags" => $tags,
|
||||
"creationDate" => date("Y-m-d H:i:s")
|
||||
];
|
||||
*/
|
||||
|
||||
$this->saveArticle($articles);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user