[CORE] Plugin API now extends a new Module API

This commit is contained in:
Diogo Cordeiro
2019-08-12 15:03:30 +01:00
committed by Diogo Peralta Cordeiro
parent 3821d2317e
commit 20a6f1d4f4
397 changed files with 3093 additions and 1450 deletions

View File

@@ -99,7 +99,7 @@ class EventPlugin extends ActivityVerbHandlerPlugin
return true;
}
function onPluginVersion(array &$versions)
public function onPluginVersion(array &$versions): bool
{
$versions[] = array('name' => 'Event',
'version' => self::PLUGIN_VERSION,

View File

@@ -148,13 +148,13 @@ class NeweventAction extends FormAction
/* We don't use these ourselves, but we add them to be nice RSS/XML citizens */
$actobj->extra[] = array('startdate',
array('xmlns' => 'http://purl.org/rss/1.0/modules/event/'),
array('xmlns' => 'http://purl.org/rss/1.0/plugins/event/'),
common_date_iso8601($start_str));
$actobj->extra[] = array('enddate',
array('xmlns' => 'http://purl.org/rss/1.0/modules/event/'),
array('xmlns' => 'http://purl.org/rss/1.0/plugins/event/'),
common_date_iso8601($end_str));
$actobj->extra[] = array('location',
array('xmlns' => 'http://purl.org/rss/1.0/modules/event/'),
array('xmlns' => 'http://purl.org/rss/1.0/plugins/event/'),
$location);
$act->objects = array($actobj);

View File

@@ -259,13 +259,13 @@ class Happening extends Managed_DataObject
/* We don't use these ourselves, but we add them to be nice RSS/XML citizens */
$actobj->extra[] = array('startdate',
array('xmlns' => 'http://purl.org/rss/1.0/modules/event/'),
array('xmlns' => 'http://purl.org/rss/1.0/plugins/event/'),
common_date_iso8601($this->start_time));
$actobj->extra[] = array('enddate',
array('xmlns' => 'http://purl.org/rss/1.0/modules/event/'),
array('xmlns' => 'http://purl.org/rss/1.0/plugins/event/'),
common_date_iso8601($this->end_time));
$actobj->extra[] = array('location',
array('xmlns' => 'http://purl.org/rss/1.0/modules/event/'),
array('xmlns' => 'http://purl.org/rss/1.0/plugins/event/'),
$this->location);
return $actobj;

View File

@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-08-14 14:44+0100\n"
"POT-Creation-Date: 2019-08-14 14:50+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -247,57 +247,6 @@ msgstr ""
msgid "%1$s might attend %2$s."
msgstr ""
#. TRANS: Plugin description.
#: EventPlugin.php:110
msgid "Event invitations and RSVPs."
msgstr ""
#. TRANS: Title for event application.
#: EventPlugin.php:116
msgctxt "TITLE"
msgid "Event"
msgstr ""
#. TRANS: Exception thrown when event plugin comes across a unknown object type.
#: EventPlugin.php:213
msgid "Unknown object type."
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:340
msgid "Time:"
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:357
msgid "Location:"
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:365
msgid "Description:"
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:375
msgid "Attending:"
msgstr ""
#. TRANS: Content for a deleted RSVP list item (RSVP stands for "please respond").
#: EventPlugin.php:418
msgid "Deleted."
msgstr ""
#. TRANS: Menu item in sample plugin.
#: EventPlugin.php:431
msgid "Happenings"
msgstr ""
#. TRANS: Menu item title in sample plugin.
#: EventPlugin.php:433
msgid "A list of your events"
msgstr ""
#. TRANS: Field label on event form.
#: forms/event.php:103
msgctxt "LABEL"
@@ -420,3 +369,54 @@ msgstr ""
msgctxt "BUTTON"
msgid "Maybe"
msgstr ""
#. TRANS: Plugin description.
#: EventPlugin.php:110
msgid "Event invitations and RSVPs."
msgstr ""
#. TRANS: Title for event application.
#: EventPlugin.php:116
msgctxt "TITLE"
msgid "Event"
msgstr ""
#. TRANS: Exception thrown when event plugin comes across a unknown object type.
#: EventPlugin.php:213
msgid "Unknown object type."
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:340
msgid "Time:"
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:357
msgid "Location:"
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:365
msgid "Description:"
msgstr ""
#. TRANS: Field label for event description.
#: EventPlugin.php:375
msgid "Attending:"
msgstr ""
#. TRANS: Content for a deleted RSVP list item (RSVP stands for "please respond").
#: EventPlugin.php:418
msgid "Deleted."
msgstr ""
#. TRANS: Menu item in sample plugin.
#: EventPlugin.php:431
msgid "Happenings"
msgstr ""
#. TRANS: Menu item title in sample plugin.
#: EventPlugin.php:433
msgid "A list of your events"
msgstr ""