Commit Graph
100 Commits
Author SHA1 Message Date
evazion 7d8150ae2d /post_versions, /artist_versions: fix missing spaces between tags/names. 2017-05-31 19:48:42 -05:00
evazion 88d14b30ed mass updates: log modaction after update successfully completes. 2017-05-28 11:56:44 -05:00
evazion c1a8800bf8 mass updates: fix exception when moving saved searches. 2017-05-28 11:55:05 -05:00
evazion 31b58e17b1 pools: lock pool when adding/removing posts (fixes #3091).
Adding a post id to a pool's post_ids string is non-atomic, hence we
must lock the pool to avoid a race condition.

Adding a pool to a post's pool_string is likewise non-atomic, hence we
must lock the post as well.
2017-05-26 18:35:33 -05:00
evazion a401b1f570 posts: fix nil source tests; fix source:none metatag. 2017-05-26 15:12:39 -05:00
evazion 8f98e8e03c posts: redefine source column to be non-NULL (fixes #3090). 2017-05-26 13:54:17 -05:00
evazion 3ecee91861 Fix #3061: Add "General" button for related tags on new/edit posts. 2017-05-26 12:49:59 -05:00
evazion 991d5cbf6d related tags: optimize calculate_from_sample.
calculate_from_sample is called when clicking the General / Artist /
Copyright / Characters buttons during tag editing. Currently it's slow
because it counts up the tags in ruby, and because it makes repeated
calls to memcache in the inner loop when filtering tags by category.

This changes it to do the counting and filtering entirely in SQL using a
GROUP BY tag / COUNT(*) aggregation. This is faster and makes larger
sample sizes more feasible.
2017-05-26 12:41:48 -05:00
evazion 1b03832b26 /forum_topics/$id: fix atom feed discovery link.
> Found an issue with the forum topic ATOM discovery link. Currently the
> link is visible to feed detectors, but they are unable to add it since
> the link provided is invalid.
>
> <link rel="alternate" type="application/atom+xml" title="Artist tagging
> help" href="http://danbooru.donmai.us/forum_topics.8199" />
2017-05-24 16:11:00 -05:00
evazion ea80d51ecf /posts/$id: add feed discovery link for comments on post. 2017-05-24 16:10:56 -05:00
evazion 1a52f9db2b wiki pages: add wildcard support to "other names" search. 2017-05-24 14:59:00 -05:00
evazion 614bf44086 /bulk_update_requests: add search form. 2017-05-23 17:23:32 -05:00
evazion 02b3622f12 api: allow search[*_id] params to accept lists of ids in more places. 2017-05-23 15:45:40 -05:00
evazion 8988f9cde8 /forum_topics.json: add search[id]=<ids> param. 2017-05-23 15:27:15 -05:00
evazion 3aa405eac1 Post#favorited_by?: fix to cast to a boolean. 2017-05-23 13:12:10 -05:00
evazion 05c6716def Fix date:, age: metatags to use the index. (fix #672). 2017-05-23 12:59:08 -05:00
evazion 4c61e547b9 posts: add data-is-favorited attribute to thumbnails. 2017-05-23 11:53:04 -05:00
evazion c5de983f61 Post#favorited_by?: fix to return a boolean. 2017-05-23 11:53:03 -05:00
evazion 9cf2c60c09 /wiki_page_versions: add #p-global-listing, #p-page-listing ids.
Split the wiki page versions template into two partials,
_global_listing.html.erb and _page_listing.html.erb, to avoid the nested
conditionals that arise from combining these two pages into one template.

Add html IDs to distinguish between these two partials.
2017-05-22 14:05:30 -05:00
evazion 5ff4f12329 /moderator/ip_addrs: add #p-ip-listing, #p-user-listing ids. 2017-05-22 13:25:36 -05:00
evazion 52e289e990 /static/terms_of_service: fix page wrapper ids. 2017-05-22 13:19:18 -05:00
evazion 8bf03e596d /user_reverts/new: fix page wrapper id. 2017-05-22 13:09:52 -05:00
evazion 060375dce7 /bans/new: fix page wrapper ids. 2017-05-22 13:09:36 -05:00
evazion d5b9b7162c /user_upgrades/new: fix page wrapper id.
* Move related css to user_upgrades.scss.
* Delete users/upgrade_information.html.erb as it is unused.
2017-05-22 13:07:31 -05:00
evazion c31d11b095 bans: fix case sensitivity bug in ban reason search. 2017-05-21 20:13:43 -05:00
evazion 3f760069b3 dmails: fix case sensitivity bug in dmail title search. 2017-05-21 13:52:56 -05:00
evazion 9b613157ae Add data attributes for CurrentUser's privileges to <body> tag (fix #3073). 2017-05-21 12:31:28 -05:00
evazion f1f6e5ccc9 anonymous_user.rb: generate is_<role>? methods from User::Roles. 2017-05-21 12:27:39 -05:00
evazion 76b50c31bf /forum_topics/$id.atom: fix ordering (fix #3069). 2017-05-21 10:31:21 -05:00
evazion 223e600eb0 /explore/posts/{popular,searches,missed_searches}: fix page wrapper ids. 2017-05-21 10:26:03 -05:00
evazion 86b1298662 /reports/upload_tags: change page wrapper id to #c-upload-tags-report. 2017-05-20 12:09:37 -05:00
evazion 9bf85ee2b3 Factor out <ins>/<del> css from #c-post-versions to .diff-list. 2017-05-20 12:07:47 -05:00
evazion 6475b98c46 /posts/$id/events: change page wrapper id to #c-post-events. 2017-05-20 08:09:54 -05:00
evazion fad4d48b1c search: fix order:note, order:comment_bumped to use indexes. 2017-05-19 18:19:05 -05:00
evazion d74eda2b96 search: readd posts.id secondary sort to order: metatags. 2017-05-19 18:19:04 -05:00
evazion a8c1b0bc62 structure.sql: add forum topics (is_sticky, updated_at) index. 2017-05-19 18:19:04 -05:00
evazion 2259506bc2 flags: disallow flagging pending posts. 2017-05-19 14:37:38 -05:00
evazion 0e26d0e77e /pool_versions: change page wrapper id to #c-pool-versions. 2017-05-19 13:55:30 -05:00
evazion d46aa89159 /wiki_page_versions: change page wrapper id to #c-wiki-page-versions.
Changes the wrapper id to #c-wiki-page-versions and moves the
corresponding css from wiki_pages.scss to wiki_page_versions.scss.
2017-05-19 13:40:24 -05:00
evazion 3570ace017 flags: ignore flagging rate-limits when deleting posts. 2017-05-17 23:48:37 -05:00
evazion 565945ab7b flags: move flagging inside Post#delete! 2017-05-17 23:48:37 -05:00
evazion 9f1096e67f post replacement: rescale notes. 2017-05-17 00:14:41 -05:00
evazion 302bc52bf8 post replacement: take guidelines from help:replacement_notice. 2017-05-17 00:14:41 -05:00
evazion 402caf6168 post replacement: don't send @mention dmails to replacer. 2017-05-17 00:14:41 -05:00
evazion a3db5ba346 post replacement: move presenter methods to post_replacement.rb. 2017-05-17 00:14:41 -05:00
evazion cd3914f17c post replacement: move tests to post_replacement_test.rb. 2017-05-17 00:14:41 -05:00
evazion eac827973b Normalize pixiv artist urls to pixiv member page (fix #3048). 2017-05-15 14:12:08 -05:00
evazion 6ee3b2635a Fix returning incorrect pixiv profile url (fixes #3054). 2017-05-14 22:00:06 -05:00
evazion 9b73823ccd Add post replacement create action test. 2017-05-14 21:31:12 -05:00
evazion 648cc9ecb7 Move post replacement create action to post replacements controller. 2017-05-14 21:31:01 -05:00
evazion cb09b6661d Add /post_replacements.json, /posts/1234/replacements.json. 2017-05-14 18:49:57 -05:00
evazion a6737dfc14 daily_maintenance.rb: don't prune file deletion delayed jobs. 2017-05-14 12:49:11 -05:00
evazion 91a97e37cb Fix #3051: disable S3 proxy by default. 2017-05-14 10:40:15 -05:00
evazion 2c29a7ac19 /artists: only include domains in /artists/1234.json, not /artists.json. 2017-05-14 10:38:26 -05:00
evazion 087ce001e7 user name changes: don't force new name to lowercase. 2017-05-14 09:53:49 -05:00
evazion 61a37a09cc Fix translated tags for pixiv (fix #3046).
Translated tags expects `tags` to be an array of `[tag_name, search_link]` pairs.
2017-05-13 19:17:33 -05:00
evazion 71a19c28f1 forum topics: don't record a topic visit for api requests. 2017-05-13 13:50:20 -05:00
evazion 8c88e87710 /forum_topics.atom: add atom feed for forum topics. 2017-05-13 10:37:59 -05:00
evazion e68946e95d /comments.atom: add atom feed for comments. 2017-05-13 10:37:58 -05:00
evazion c68e68f3c2 /uploads/new: add show/hide commentary toggle button. 2017-05-13 00:18:52 -05:00
evazion 757a7da49b fixup! /source.json: don't encode '&' as '&amp;' in commentaries. 2017-05-10 21:03:29 -05:00
evazion 7a656f790d /uploads/new: autopopulate commentary from /source.json. 2017-05-10 18:01:52 -05:00
evazion a2a6a0ce27 /source.json: don't encode '&' as '&amp;' in commentaries. 2017-05-10 18:01:52 -05:00
evazion 8015d62b46 /source.json: strip html tags from artist commentary. 2017-05-10 18:01:51 -05:00
evazion b2f62482a1 Remove artist commentary handling from download rewrite strategies. 2017-05-10 18:01:51 -05:00
evazion a3a9a78015 /comments.json: default to id_desc order instead undefined order. 2017-05-09 18:12:37 -05:00
evazion 19e91f438b bans: add test for logging in with expired ban. 2017-05-07 12:13:25 -05:00
evazion fd291c8b42 bans: fix exception when user with expired ban logs in.
`ban.destroy` fails because users have many `bans`, not a single `ban`.
Destroying the expired ban isn't necessary anyway.
2017-05-07 12:13:19 -05:00
evazion fb7e6c7e8e backups: default to s3 backup for production. 2017-05-05 22:54:39 -05:00
evazion 7db40fe69f backups: add amazon s3 backup service. 2017-05-05 22:18:28 -05:00
evazion 30a1f204e9 backups: add stub backup service. 2017-05-05 22:18:28 -05:00
evazion d40da8c5c9 post replacement: leave a system comment after replacement. 2017-05-05 16:10:43 -05:00
evazion 1a058ebe9a delayed jobs: don't delete failed jobs. 2017-05-05 11:33:11 -05:00
evazion b17d564e9b /delayed_jobs: order by next-to-run first. 2017-05-05 11:33:11 -05:00
evazion 9c9bf28db4 /delayed_jobs: add run, cancel, retry, delete actions. 2017-05-05 11:33:10 -05:00
evazion 9404eeafa1 /delayed_jobs: reorganize columns; fix column sizes. 2017-05-05 11:33:10 -05:00
evazion cbb15b3e81 /delayed_jobs: add '#c-delayed-jobs #a-index' wrapper divs. 2017-05-05 11:33:10 -05:00
evazion 666381a582 time_ago_in_words_tagged: handle times set in the future. 2017-05-05 11:33:10 -05:00
evazion c1fa656bd2 posts: change flag borders from red to blue for non-approvers. 2017-05-04 17:40:17 -05:00
evazion 31a38ea39a flags: add flag cooldown test. 2017-05-04 17:37:59 -05:00
evazion 3b37bb6142 flags: add 3 day flagging cooldown period. 2017-05-04 16:51:49 -05:00
evazion 8638b7527b flags: don't set is_flagged twice.
PostFlag#update_post already sets is_flagged when the flag is created.
No need to set it again.
2017-05-04 16:51:49 -05:00
evazion 9f64857719 flags: move status locked check to post_flag.rb. 2017-05-04 16:51:49 -05:00
evazion 43ad3258e5 API: fix api limits being lowered when user doesn't have api key. 2017-05-04 12:57:20 -05:00
evazion 038e40ec98 post replacement: increase grace period to 30 days. 2017-05-04 12:30:27 -05:00
evazion 7b5ae5f8e0 Fix #3024: strip '?' from API attributes. 2017-05-04 12:19:51 -05:00
evazion 7ade3b6831 Fix #2352: return raw usernames in API instead of pretty names. 2017-05-03 22:16:38 -05:00
evazion db1fa60a43 Set pawoo sources to html page after upload. 2017-05-03 00:09:51 -05:00
evazion d6ca040198 /super_voters: remove in favor of /users?search[is_super_voter]=true search. 2017-05-02 23:15:19 -05:00
evazion 1dba314eda /users: add search options for approvers/super voters/contributors. 2017-05-02 23:15:19 -05:00
evazion 44b1a8dbf6 /users: convert search form to simple form. 2017-05-02 22:53:33 -05:00
evazion 002d54921e responsive layout: fix "More »" link from line-wrapping. 2017-05-02 22:30:56 -05:00
evazion 85f6590b1a responsive layout: fix <input> sizes and styling. 2017-05-02 22:30:56 -05:00
evazion 352a3e065f responsive layout: fix dropdown nav menu overlapping main content.
The culprit is `float: right;` but none of this other stuff is needed.
2017-05-02 22:30:56 -05:00
evazion 5f2219a005 post replacement: add tests. 2017-05-02 20:42:41 -05:00
evazion 4e841c4ea5 post replacement: add "Replace Image" dialog to post sidebar. 2017-05-02 20:41:19 -05:00
evazion df7cd67a7d post replacement: add POST /moderator/post/posts/replace endpoint. 2017-05-02 20:41:18 -05:00
evazion dd920b3ffc post replacement: disallow unhandled cases. 2017-05-02 20:41:18 -05:00
evazion ca01539c4b post replacement: delete old files after image is replaced. 2017-05-02 20:41:18 -05:00
evazion e2b988a562 post replacement: add Post#replace! method. 2017-05-02 20:41:18 -05:00