1
0
Fork 1
mirror of https://github.com/mastodon/mastodon.git synced 2024-12-26 18:44:13 +00:00
Commit graph

21 commits

Author SHA1 Message Date
Matt Jankowski 1b0cb3b54d
Announcement reactions query spec improvement and refactor () 2024-01-17 09:18:13 +00:00
Matt Jankowski e677eb164c
Remove unused Announcement#time_range? () 2024-01-08 15:26:30 +00:00
Matt Jankowski 3e43cd095c
Remove unused scope Announcement.without_muted () 2024-01-08 15:26:14 +00:00
Matt Jankowski 1bc5a52139
Extract SQL heredoc method for Announcement scopes () 2024-01-08 11:22:16 +00:00
Matt Jankowski ba5f659bb3
Use shorter attribute query methods in Announcement () 2023-12-29 10:55:50 +00:00
Claire dcc24db793
Fix N+1s because of association preloaders not actually getting called () 2023-12-13 07:47:32 +00:00
Matt Jankowski ce43ed144c
Rails 7.0 update () 2023-07-13 09:36:07 +02:00
Eugen Rochko ba06a2f104
Revert "Rails 7 update" () 2023-07-02 11:14:22 +02:00
Matt Jankowski 50c2a03695
Rails 7 update () 2023-07-02 10:38:53 +02:00
Nick Schonning 9909b4b653
Autofix Rubocop Rails/WhereEquals () 2023-02-21 03:20:56 +09:00
Nick Schonning 2177daeae9
Autofix Rubocop Style/RedundantBegin () 2023-02-19 07:09:40 +09:00
Claire d9d722d74b
Change admin announcement edition interface to use datetime-local ()
* Change admin announcement edition interface to use datetime-local

* Dynamically set announcement stop date as required if start date is set, set minimum date for stop date

* Change `all_day` to not be bound to presence of time-range

* Add pattern and placeholder as minimal fallback for browsers not supporting datetime-local

* Display datetime-local inputs as local time

Co-authored-by: Eugen Rochko <eugen@zeonfederated.com>
2022-10-28 12:56:32 +02:00
Eugen Rochko 0396acf39e
Add audit log entries for user roles ()
* Refactor audit log schema

* Add audit log entries for user roles
2022-08-25 20:39:40 +02:00
ThibG b29defb851
Change order of announcements in admin page to sort them newest-first ()
* Change order of announcements in admin page to sort show newly-created first

Fixes 

* Use reverse-chronological rather than creation date only
2020-11-04 21:15:22 +01:00
Eugen Rochko 5edff32733
Change delivery failure tracking to work with hostnames instead of URLs () 2020-04-15 20:33:24 +02:00
ThibG 89e28c7674
Fix PostgreSQL load when linking in announcements ()
* Fix PostgreSQL load when linking in announcements

Fixes  by caching status lookups

Since statuses are supposed to be known already and we only
need their URLs and a few other things, caching them should
be fine.

Since it's only used by announcements so far, there won't
be much statuses to cache.

* Perform status lookup when saving announcements, not when rendering them

* Change EntityCache#status to fetch URLs instead of looking into the database

* Move announcement link lookup to publishing worker

* Address issues pointed out during review
2020-04-05 12:51:22 +02:00
ThibG aa67036b41
Add support for links to statuses in announcements to be opened in web UI ()
* Add support for links to public statuses in announcements to be opened in WebUI

* Please CodeClimate
2020-03-08 16:10:48 +01:00
Eugen Rochko 663ea84b08
Add publish/unpublish controls to announcements in admin UI () 2020-01-27 11:05:33 +01:00
Eugen Rochko 401f32f9ee
Fix expired announcements being re-published () 2020-01-26 22:43:18 +01:00
Eugen Rochko b9d74d4076
Add streaming API updates for announcements being modified or deleted ()
Change `all_day` to be a visual client-side cue only

Publish immediately if `scheduled_at` is in the past

Add `published_at` and `updated_at` to announcements JSON
2020-01-26 20:07:26 +01:00
Eugen Rochko f52c988e12
Add announcements ()
* Add announcements

Fix 

* Add reactions to announcements

* Add admin UI for announcements

* Add unit tests

* Fix issues

- Add `with_dismissed` param to announcements API
- Fix end date not being formatted when time range is given
- Fix announcement delete causing reactions to send streaming updates
- Fix announcements container growing too wide and mascot too small
- Fix `all_day` being settable when no time range is given
- Change text "Update" to "Announcement"

* Fix scheduler unpublishing announcements before they are due

* Fix filter params not being passed to announcements filter
2020-01-23 22:00:13 +01:00