Commit Graph

78 Commits

Author SHA1 Message Date
Kfir Hadas d7181cf6a1 PEP8 2017-05-25 22:19:42 +03:00
Anna-Maria Meriniemi 0394639954 Calculate comment age clientside, show timestamp in mouseover title (#191)
Resolves outdated comment ages thanks to caching and will show timestamps in local time.
2017-05-25 21:13:35 +03:00
TheAMM bb30f6e3d2 Scroll user to their new comment after submission 2017-05-25 21:11:55 +03:00
TheAMM 1ab3d6e3eb Add cachebuster helper function for static css/js 2017-05-25 20:11:37 +03:00
TheAMM b09c61980c Add new route for torrent download, fix Content-Disposition
New route is `/download/<torrent_id>.torrent`, which will help people using tools that do not consider headers.
Old torrent download route still works.
Updated one remaining link to use url_for.

Added plain `filename="..."` to `Content-Disposition`, since it is still the most common standard with percent encoded UTF-8.
Fixes part 2 of #45
2017-05-25 11:15:45 +03:00
Kfir Hadas ebcf1dc836 PEP8 2017-05-25 09:08:18 +03:00
TheAMM 3a4280ccc5 Redirect searches with an info hash to torrent if found
Redirect will not happen on RSS or user page views (/searches).
Adds a helper to models.Torrent to search with a hex hash
Reformats "special search logic"
2017-05-24 17:34:36 +03:00
TheAMM aeef80edaa Clean up user search suggestion 2017-05-24 13:34:33 +03:00
ReimuHakurei 363203dfe0 Fix error on search for non-Unicode. 2017-05-24 10:14:03 +00:00
ReimuHakurei f215f0803c Add per-user filter on search page based on query. 2017-05-24 08:33:32 +00:00
nyaadev 020a0871bd fix #173 and add avatar to mod user info
add rank color to username everywhere
some other minor changes
2017-05-24 00:28:17 +02:00
katnyaa ba7e0a7c2e routes: Fix invalid call from previous merge 2017-05-23 13:47:47 +01:00
katnyaa 48df88ce71 Merge pull request #140 from FallenWarrior2k/master
Changed RSS feed to conform to RSS standards and added a namespace
2017-05-23 12:44:03 +00:00
nyaadev af61e5b1e9 some html + css changes around comments 2017-05-23 02:47:20 +02:00
nyaadev 3fc347d049 Move posting comments to view_torrent to fix displaying form errors. 2017-05-23 00:04:27 +02:00
nyaadev b7144f80f9 Make comments great again. 2017-05-22 23:38:06 +02:00
nyaadev fee55c1792 comments can be added+removed. gravatar for user avatar 2017-05-22 23:20:49 +02:00
Sn0wCrack fe6abf33c1 Added ability for users to leave anonymous comments 2017-05-22 23:19:36 +02:00
Sn0wCrack 1a9ebc19ed Added hard delete functionality 2017-05-22 23:19:36 +02:00
Sn0wCrack 6d608ab2f4 Added comments 2017-05-22 23:19:23 +02:00
TheAMM f04c3e1cf3 Remove v1 upload api and update notice 2017-05-22 22:57:37 +03:00
A nyaa developer b241dd5508 Don't generate empty torrent file for torrents without info dict (has_torrent). 2017-05-22 20:08:41 +02:00
katnyaa 159d5a5d9e Fix lint errors 2017-05-22 15:12:17 +01:00
nyaadev a4c7dd7912 Add ReCaptcha to upload page if user is not logged in.
Bring back CSRF to upload form (Use the upload API)
2017-05-21 19:29:21 +02:00
nyaadev 9af778217b DB CHANGE: Add uploader ip address to torrent column and show on torrent view page for superadmins.
Added migration script!: remove sukebei_ lines if your local db does not have those.
Show users ip address on user page for superadmins.
Rename Admin to Moderator internally.
Moderators can now change user level to trusted.
Superadmins can make users moderator.
Improve changing user level.
2017-05-21 19:12:15 +02:00
TheAMM af0cca2f8c Display full category names on upload/edit category lists 2017-05-20 22:50:40 +03:00
TheAMM b9d88e8960 Restructure upload.html and edit.html as well as route logic
Rename variables and reformats user/admin logic
Add an is_trusted field to upload and edit forms

Restructure fields on upload and edit pages
Add simple styling for checkboxes
Add titles (mouseover) for checkboxes with crude explanations
Show Anonymous checkbox during upload and check & disable it for guests
Show Trusted checkbox for users at or above Trusted level
Adjust description field rendering to show field label above it

Add title (mouseover) for edit icon on torrent page
Show uploader for admins on anonymous torrents
Show uploader for admins when editing others' torrents
2017-05-20 22:00:45 +03:00
Simon Veit Engmann cc957ccc96 Changed RSS feed to conform to RSS standards and added a namespace 2017-05-20 01:13:04 +02:00
TheAMM 358c75036b Fix RSS link generation on user pages
Also removes a debug print (oops #2)
2017-05-19 23:20:15 +03:00
TheAMM 68b5bc045b Add "magnets" parameter for RSS, slightly clean up home and view_user 2017-05-19 20:11:20 +03:00
TheAMM daef4a9c6a Finalize RSS ES fix 2017-05-19 19:25:48 +03:00
TheAMM e7614bcef1 Merge branch 'update-rss-template' of https://github.com/sharkykh/nyaa into sharkykh-update-rss-template 2017-05-19 18:31:10 +03:00
nyaadev 2a1f8fab87 pep8 2017-05-19 14:36:33 +02:00
TheAMM e554f9ae97 Fix category name on icon titletext, fixes #131
Also reformats the cat_id if-logic
2017-05-19 15:24:09 +03:00
TheAMM 18ebf201b8 Add a function for getting a id->category name map
Redo _create_upload_category_choices to use new function
Also removes (renames) by_id from models.SubCategory (we use composite key)
2017-05-19 15:21:20 +03:00
Mart 02fa705330 Merge pull request #107 from UnKnoWn-Consortium/patch-2
Make profile page more profile
2017-05-19 00:20:41 -04:00
TheAMM e5fce168a0 Upload API V2 2017-05-18 16:46:07 +03:00
kyamiko 746ea8b63d Comment debug print 2017-05-18 00:06:53 -04:00
kyamiko 785a8db0c8 Updated api/upload 2017-05-17 23:56:36 -04:00
UnKnoWn 2ef053dec8 Update routes.py 2017-05-18 04:37:22 +08:00
martstern 04047a5712 make admin unable to set own user class, fix missing post method 2017-05-17 09:17:08 -04:00
martstern 931b2b0b83 added user class display and editing 2017-05-17 06:02:15 -04:00
aldacron 40c311f80a fix registration 2017-05-17 02:36:27 -07:00
aldacron a2ca6eb2ac changed cache control from 1 hr to 5 mins 2017-05-17 01:05:55 -07:00
aldacron 5a1e44faff added success message after torrent edit 2017-05-17 00:56:51 -07:00
aldacron 8ffcbca4d5 improved profile page user flow. clears data on success and shows current email. also, flashes success message if successful 2017-05-17 00:53:07 -07:00
Johnny Ding ad17558ec3 Merge pull request #53 from sharkykh/pep8
Fix PEP8 errors and warnings
2017-05-17 00:08:42 -07:00
UnKnoWn cfb3fafd64 Merge remote-tracking branch 'refs/remotes/nyaadevs/master' 2017-05-17 14:51:47 +08:00
UnKnoWn 1fb249be35 Enforce password check on email change
Updated route handler to enforce current password check on all account details.
2017-05-17 05:10:25 +08:00
Johnny Ding 033e83562f Merge pull request #79 from nyaadevs/legacy-args
Support legacy arguments in search route
2017-05-16 13:04:52 -07:00