From 793b0e31beb22fe33402c8a9ceebf47a5a950635 Mon Sep 17 00:00:00 2001 From: Kevin Chabowski Date: Sun, 20 May 2012 13:00:31 +0200 Subject: Plugins can now hook into the Article editor. * Plugins can display additional fields in the article editor. * Plugins can perform actions when saving an article and even veto the saving. * Plugins can get their ArticleExtradata objects. --- ratatoeskr/sys/models.php | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'ratatoeskr/sys/models.php') diff --git a/ratatoeskr/sys/models.php b/ratatoeskr/sys/models.php index 9f3a96a..3cda168 100644 --- a/ratatoeskr/sys/models.php +++ b/ratatoeskr/sys/models.php @@ -2605,6 +2605,21 @@ WHERE " . implode(" AND ", $subqueries) . " $sorting"); $this->section_obj = $section; } + /* + * Function: get_extradata + * Get the extradata for this article and the given plugin. + * + * Parameters: + * $plugin_id - The ID of the plugin. + * + * Returns: + * An object. + */ + public function get_extradata($plugin_id) + { + return new ArticleExtradata($this->id, $plugin_id); + } + /* * Function: save */ -- cgit v1.2.3-70-g09d2