Commit Graph

31 Commits

Author SHA1 Message Date
Hugo Sales 483983790a
[CORE][Router] Rename \App\Core\Router\Router to \App\Core\Router and merge \App\Core\Router\RouteLoader with \App\Core\Router 2022-03-28 20:59:15 +01:00
Hugo Sales abe35428da
[CORE][DB] Rename App\Core\DB\DB to App\Core\DB 2022-03-28 20:59:14 +01:00
Hugo Sales 6cd7be6abc
[UI][CONTROLLER][ENTITY][DOCS] Refactor term 'timeline' into 'feed' 2021-11-26 13:05:23 +00:00
Hugo Sales 9109c61af5
[TOOLS][CS-FIXER] Run new PHP CS Fixer config. Notably, adds strict_types 2021-10-27 04:19:28 +01:00
Diogo Peralta Cordeiro 67d62cf37b
[TWIG] Remove kludge event TwigPopulateVars 2021-09-18 07:27:35 +01:00
Diogo Peralta Cordeiro 941cbe6599
[Actor] Refactor GSActor into Actor 2021-09-18 05:12:17 +01:00
Hugo Sales eb833b62e2
[TOOLS] Fix all level 0 errors found by PHPStan and move constant definition to bootstrap file 2021-09-14 13:13:42 +01:00
Hugo Sales 811caaadf9
[MODULES][PLUGINS] Move noteActionHandle utility to NoteHandlerPlugin which plugins which handle actions on notes should extend 2021-09-14 13:13:34 +01:00
Hugo Sales aeabf64051
[PLUGIN] Change base class from Module to Plugin for all plugins 2021-09-14 13:12:23 +01:00
Diogo Peralta Cordeiro ccf3aa990a
[MODULES] Introduce the concept of abstract modules to V3
Introduce placeholder for abstract upload and thumb modules
Temporarily supress some bugs
2021-09-14 13:11:45 +01:00
Pastilhas 2c3599721e
[DOCKER][MAIL] Removed unused config files and scripts
Now user is created on setup and dockerfile
2021-09-14 13:10:14 +01:00
Daniel 1747e14824
[Poll] Removed/refactored unnecessary files, changed redirect to default parameters in new poll route 2021-09-14 13:10:13 +01:00
Daniel c0d363e317
[Poll] Restructured templates, added misssing poll related css 2021-09-14 13:10:13 +01:00
Daniel 7a299162e1
[Poll] Polls now have an associated note, poll templates, start_show_styles event, started css 2021-09-14 13:10:13 +01:00
Daniel 090c593a61
[Poll] Started testing with note integration 2021-09-14 13:10:13 +01:00
Daniel 50ec306243
[Poll] Added file headers 2021-09-14 13:10:12 +01:00
Daniel ffb4b9df23
[Poll] Added modified param for Poll/Poll response, added PollTest 2021-09-14 13:10:12 +01:00
Mikael Nordfeldth de55d8f83b plugins onAutoload now only overloads if necessary (extlibs etc.)
lib/plugin.php now has a parent onAutoload function that finds most common
files that are used in plugins (actions, dataobjects, forms, libs etc.) if
they are put in the standardised directories ('actions', 'classes', 'forms',
'lib' and perhaps some others in the future).
2013-08-28 16:10:30 +02:00
Mikael Nordfeldth 861e838add pkeyGet is now static and more similar to getKV
Memcached_DataObject now defines
   * pkeyGetClass to avoid collision with Managed_DataObject pkeyGet
   * getClassKV to avoid collision with Managed_DataObject getKV
2013-08-18 15:42:51 +02:00
Mikael Nordfeldth 2a4dc77a63 The overloaded DB_DataObject function staticGet is now called getKV
I used this hacky sed-command (run it from your GNU Social root, or change the first grep's path to where it actually lies) to do a rough fix on all ::staticGet calls and rename them to ::getKV

   sed -i -s -e '/DataObject::staticGet/I!s/::staticGet/::getKV/Ig' $(grep -R ::staticGet `pwd`/* | grep -v -e '^extlib' | grep -v DataObject:: |grep -v "function staticGet"|cut -d: -f1 |sort |uniq)

If you're applying this, remember to change the Managed_DataObject and Memcached_DataObject function definitions of staticGet to getKV!

This might of course take some getting used to, or modification fo StatusNet plugins, but the result is that all the static calls (to staticGet) are now properly made without breaking PHP Strict Standards. Standards are there to be followed (and they caused some very bad confusion when used with get_called_class)

Reasonably any plugin or code that tests for the definition of 'GNUSOCIAL' or similar will take this change into consideration.
2013-08-18 13:13:56 +02:00
Mikael Nordfeldth c36608b233 Some statically called functions in plugins now declared statically 2013-08-18 11:18:45 +02:00
Mikael Nordfeldth 6c4c4319ef Plugins with classes that extend Managed_DataObject get better code reuse
The switch to having a function in Managed_DataObject is now being applied
to plugins which can use this as well.

There are some plugins that still use Memcached_DataObject, but these will
be taken care of later.
2013-08-12 20:00:01 +02:00
Evan Prodromou 44753d64ea use Poll_response::pkeyGet() in Poll::getResponse() 2011-07-04 15:47:36 -04:00
Siebrand Mazeland 558a512ac7 Update translator documentation.
Update L10n.
Update whitespace.
2011-04-29 19:22:44 +02:00
Siebrand Mazeland 843ace580d i18n/L10n updates
Translator documentation added
2011-03-11 19:05:28 +01:00
Siebrand Mazeland 76bffe1a64 * Superfluous whitespace removed
* Small L10n updates
2011-03-11 18:31:22 +01:00
Brion Vibber d6c8c61076 AS output/input for poll responses 2011-03-10 13:41:23 -08:00
Brion Vibber e085ef5ef5 Work on turning poll responses into activities so we can send them over ostatus bridge. Not yet bridging. 2011-03-10 12:38:25 -08:00
Brion Vibber d990357be9 fix off-by-one error in poll results display 2011-03-08 15:44:51 -08:00
Brion Vibber cbf16a4974 Bookmark and poll plugins' custom notice forms now do AJAX submit, with the resulting notice appearing in the timeline.
FormNoticeXHR now is triggered on any form labeled with class 'ajax-notice', so those other than the traditional notice form should work as long as they handle the AJAX submission and return a properly formatted notice.

Things to watch out for:
* to determine whether the resulting notice should show on the current timeline, the JS code needs to be able to check the author and such. Keeping the existing vcard bits helps for this!
* the notice form submission stuff clears out inputs from your form -- test to make sure this behaves correctly
* error messages returned from the thingy _should_ come through, but this needs more testing for consistency
* while form components that aren't in a custom form should just be ignored, this should be tested more. (eg there's no location or attachment box for poll or bookmark plugins)
* NoticeListItem isn't currently reachable via autoloader -- touch NoticeList explicitly before calling into it for now.
2011-03-08 15:10:30 -08:00
Brion Vibber 3438a78c02 Initial checkin of Poll plugin: micro-app to post mini polls/surveys from the notice form.
This version is fairly basic; votes do not (yet) show a reply, they just got in the table. No pretty graphs for the results yet, just text.
The ActivityStream output is temporary and probably should be replaced; the current structures for adding custom data aren't really ready yet (especially since we need to cover JSON and Atom formats, probably pretty differently)

Uses similar system as Bookmark for attaching to notices -- saves a custom URI for an alternate action, which we can then pass in and hook back up to our poll object. This can probably do with a little more simplification in the parent MicroAppPlugin class.

Currently adds two tables:
- poll holds the main poll info: id and URI to associate with the notice, then the question and a text blob with the options.
- poll_response records the selections picked by our nice fellows.

Hopefully no off-by-one bugs left in the selection, but I give no guarantees. ;)
Some todo notes in the README and in doc comments.
2011-03-07 21:28:36 -08:00