Commit Graph

1802 Commits

Author SHA1 Message Date
2850c1b38c Make NotificationSender compatibleWith method static 2015-05-05 14:29:57 +09:30
d13cb03e39 Return the post that was added/changed/deleted 2015-05-05 14:29:07 +09:30
f2056c4acf Clean up post type API 2015-05-05 14:28:40 +09:30
bf593504c7 Clean up event handlers 2015-05-05 14:27:47 +09:30
24481f3f77 Change API for serializer relationships 2015-05-05 14:26:53 +09:30
3726c97d5c Remove old code 2015-05-05 09:17:00 +09:30
f0219de93f Fix admin 2015-05-05 09:16:53 +09:30
56ef42f931 Add concept of "mergeable" activity posts
For example: when you rename a discussion, DiscussionRenamedPost is
created. If you rename it again immediately afterwards, then a new
DiscussionRenamedPost can be merged into the old one. This will either
result in the old one being updated with the new title, or it being
deleted all together if it was renamed back to the old title.
2015-05-04 12:19:25 +09:30
0a2c05379c Update TokenAction for new architecture 2015-05-04 10:30:56 +09:30
9af9dce740 Add ExtensionsServiceProvider to load enabled extensions 2015-05-04 08:56:19 +09:30
67f64b631a Pass action in RenderView event so that handler can access actor 2015-05-04 08:55:44 +09:30
850a49285b Add API to define custom model relationships 2015-05-04 08:55:03 +09:30
f03f046efe Add event to modify user search 2015-05-03 12:07:15 +09:30
d966c9831a Add event for registering user search gambits 2015-05-03 12:06:01 +09:30
b38878da80 Add delete avatar action 2015-05-03 12:05:18 +09:30
29be20c91a Fix incorrect function call 2015-05-03 12:04:57 +09:30
8f29679b46 Convert the rest of the API to new action architecture
Also make some tweaks:
- Merge SerializeAction::$include and
SerializeAction::$includeAvailable into a keyed boolean array
- Set defaults for SerializeAction::$limit and $limitMax
- Rename SerializeAction::$sortAvailable to $sortFields
2015-05-03 12:04:43 +09:30
ecdb2becd4 Assign user input to data property on EditDiscussionCommand 2015-05-02 09:01:27 +09:30
f67f34e287 Add removed posts as an API attribute 2015-05-02 09:00:22 +09:30
8ee9480205 Update discussion/post sort semantics inline with new API actions
Instead of $sort and $order being separate, they are now a single
array, allowing multiple sort criteria: `[‘foo’ => ‘asc', ‘bar’ =>
‘desc’]`
2015-05-02 09:00:07 +09:30
22ff8a203d Make sure serializers work with relations implemented with magic (via __call) 2015-05-02 08:58:28 +09:30
db31d9f772 Making a note that we should not use Actor as a singleton 2015-05-02 08:57:14 +09:30
a426fa6560 Update API action architecture
- An API action handles a Flarum\Api\Request, which is a simple object
containing an array of params, the actor, and optionally an HTTP
request object
- Most API actions use SerializeAction as a base, which parses request
input according to the JSON-API spec (creates a JsonApiRequest object),
runs the child class method to get data, then serializes it and assigns
it to a JsonApiResponse (standard HTTP response with a
Tobscure\JsonApi\Document as content)
- The JSON-API request input parsing is subject to restrictions as
defined by public static properties on the action (i.e. extensible)
- Also the actor is given to the serializer instance now, instead of
being a static property
2015-05-02 08:56:43 +09:30
288fd694a8 Extensibility: data when starting a new discussion 2015-05-02 08:39:44 +09:30
60e69ae7b9 Add an event to register discussion gambits 2015-05-02 08:12:30 +09:30
66b374b1c1 Add API to collect posts that were removed during an action
This is useful for both the Sticky and Categories extensions, where if
you sticky a discussion and then immediately unsticky it, or if you
move it to a category and then immediately move it back, the last
“activity” post will be removed.
2015-05-02 08:12:09 +09:30
a2fd60ed0c Define assets in a more appropriate spot, make extensible 2015-05-02 08:10:06 +09:30
c3aecbceaa Extract config into database 2015-05-02 08:07:51 +09:30
ac269683ed Merge remote-tracking branch 'upstream/master' 2015-04-25 22:45:27 +09:30
52b476dc6b Return more relations when a discussion is created 2015-04-25 22:37:25 +09:30
34d150b24b Fix read discussion command action 2015-04-25 22:37:04 +09:30
0548ebd54c Allow custom relation to be specified as string 2015-04-25 22:36:34 +09:30
8fdc1ba548 Add BootForum event so extensions can add assets 2015-04-25 22:35:41 +09:30
b6613dbdc2 Recompile assets every time a file changes 2015-04-25 22:34:56 +09:30
a57e3fc028 Use Less_Parser cache feature to speed up LESS generation 2015-04-25 22:34:46 +09:30
c6079c53c9 Fix email confirmation route 2015-04-25 22:34:33 +09:30
8491c4cbf8 Rename assets directory 2015-04-25 22:34:26 +09:30
b68a4711dc Replace Ember app with Mithril app 2015-04-25 22:28:39 +09:30
a4ccc020e7 Fix class name conflict. 2015-04-15 13:44:35 +02:00
6f67b8c247 Fix attribute serialisation event mutability 2015-04-03 17:04:59 +10:30
0bcaaaa9b9 Add an event to modify search queries 2015-04-03 17:04:41 +10:30
6898e0acbb Refactor Flarum\Web and Flarum\Admin
- In order to be consistent with the Ember/LESS naming scheme, renamed
Flarum\Web to Flarum\Forum.
- Moved common classes into Flarum\Support so that Flarum\Admin doesn’t
depend on Flarum\Forum. Also moved Actor into Flarum\Support as it
doesn’t belong in the domain.
2015-03-30 16:17:04 +10:30
8e0a27de49 Oops 2015-03-30 12:56:41 +10:30
3b4beaa6ca "See" a user on the initial page load too 2015-03-30 12:55:39 +10:30
a43957e1e2 Don't allow guests into the admin area 2015-03-30 12:43:55 +10:30
7051b608a0 Update administration page title 2015-03-30 10:42:13 +10:30
3886efffef Turns out putting a . there breaks Laravel 2015-03-29 22:27:37 +10:30
40a6d77e74 Big front-end asset/filestructure refactor
- Extract shared Ember components into a “flarum-common” ember-cli
addon. This can be used by both the forum + admin Ember apps, keeping
things DRY
- Move LESS styles into their own top-level directory and do a similar
thing (extract common styles)
- Add LESS/JS compilation and versioning to PHP (AssetManager)
- Set up admin entry point

(Theoretical) upgrade instructions:
- Delete everything in [app_root]/public
- Set up tooling in forum/admin Ember apps (npm install/update, bower
install/update) and then build them (ember build)
- php artisan vendor:publish
- Upgrade flarum/flarum repo (slight change in a config file)
- If you need to trigger a LESS/JS recompile, delete the .css/.js files
in [app_root]/public/flarum. I set up LiveReload to do this for me when
I change files in less/ or ember/

Todo:
- Start writing admin app!
- Remove bootstrap/font-awesome from repo and instead depend on their
composer packages? Maybe? (Bower is not an option here)
2015-03-29 22:13:26 +10:30
950d2f0eb9 Move forum ember app into a subdir, preparing for admin app to exist alongside 2015-03-28 19:10:52 +10:30
52a7b536c4 Fix scope removal of bindings 2015-03-28 16:31:26 +10:30