Commit Graph

385 Commits

Author SHA1 Message Date
Gerhard Schlager d47fa6653b do not notify staged users about posts withing mailinglist mirror category 2017-11-17 15:29:14 +01:00
Robin Ward 971e302ff2 FEATURE: Support an end date for user silencing 2017-11-14 13:20:19 -05:00
Robin Ward 1f14350220 Rename "Blocked" to "Silenced" 2017-11-10 14:10:27 -05:00
Gerhard Schlager 0ccefb0365 make RuboCop happy 2017-11-10 17:57:28 +01:00
Gerhard Schlager 31e2385316 FEATURE: do not send notification emails to users who are included in the To and CC header of an incoming email 2017-11-10 17:44:20 +01:00
Neil Lalonde 18d65fe7e5 FIX: post counts in user stats when changing post owner 2017-11-02 18:05:23 -04:00
Guo Xiang Tan e91a631978 REFACTOR: DRY up code and add better test coverage. 2017-10-23 11:16:14 +08:00
Guo Xiang Tan 79de10b212 FEATURE: Allow users to disable new PMs.
https://meta.discourse.org/t/is-it-possible-to-disable-private-messaging-for-a-specific-user/46391
2017-10-19 12:32:55 +08:00
Gerhard Schlager c0bb97b5cb FIX: delete staged users when the incoming email is rejected 2017-10-11 16:17:01 +02:00
Robin Ward 41c3941c4c FEATURE: Support regular expressions for watched words 2017-09-27 15:48:57 -04:00
Robin Ward 7578d8fc44 Add a `DiscourseEvent` for when a topic is closed 2017-09-27 14:00:53 -04:00
Guo Xiang Tan 4e5e7dc736 FIX: Fix ActiveRecord API that was removed in Rails 5.1. 2017-09-25 16:16:37 +08:00
Guo Xiang Tan 77d4c4d8dc Fix all the errors to get our tests green on Rails 5.1. 2017-09-25 13:48:58 +08:00
Gerhard Schlager 87b4246c14 FIX: notify about whispered reply 2017-09-19 15:51:10 +02:00
Sam 50203794e6 FIX: staged users should get emails on must_approve_users sites 2017-08-28 17:32:07 -04:00
Bianca Nenciu 6bc74ceb50 Split alias levels in mentionable and messageable levels. (#5065)
* Split alias levels in mentionable and messageable levels.

* Fixed some tests.

* Set messageable level to everyone by default.

* By defaults, groups are not mentionable or messageable.

* Made staff groups messageable by the system.
2017-08-28 12:32:08 -04:00
Erick Guan 6e59149a77 FIX: rebuild index when engine replaced (#5021) 2017-08-16 07:38:34 -04:00
Guo Xiang Tan b77aa29e71 Merge pull request #5013 from LeoMcA/alternate-emails-phase-1.5
FIX: add additional email to tests and clean up resulting mess
2017-08-16 16:19:28 +09:00
Bianca Nenciu 117417848e Remove like on change of ownership. (#5038) 2017-08-11 09:55:00 +02:00
Leo McArdle 836dee1120 FIX: add additional email to tests and clean up resulting mess 2017-07-31 22:27:29 +00:00
Guo Xiang Tan 4620dfe92d FEATURE: Add group settngs to allow users to leave a group freely.
https://meta.discourse.org/t/split-join-leave-freely-setting-on-groups/65565
2017-07-28 15:00:25 +09:00
Guo Xiang Tan 5012d46cbd Add rubocop to our build. (#5004) 2017-07-28 10:20:09 +09:00
Neil Lalonde 24cb950432 FEATURE: Watched Words: when posts contain words, do one of flag, require approval, censor, or block 2017-07-26 11:01:09 -04:00
Régis Hanol d67fe4c674 FIX: block all emails associated to a user when destroying their record 2017-07-25 17:44:46 +02:00
Sam Saffron 045a2abcec FEATURE: remove the timecop gem
We should only have one way of mocking time, misuse of timecop
was causing build stability issues
2017-07-24 12:11:10 -04:00
Guo Xiang Tan c12edda766 Use `Timecop.freeze` instead of `Timecop.travel`. 2017-07-24 15:40:57 +09:00
Guo Xiang Tan 86dbd76191 Fix random spec failure due to ordering. 2017-07-24 15:25:07 +09:00
Leo McArdle ddc0134b48 add DiscourseEvent triggers necessary to update a user's permissions before they're notified 2017-07-21 11:03:54 -04:00
Leo McArdle d0b027d88d FEATURE: phase 1 of supporting multiple email addresses 2017-07-20 11:22:27 +09:00
Guo Xiang Tan 13f3de4bf6 Nuke all `SiteSetting.stubs` from our codebase. 2017-07-07 15:09:14 +09:00
Guo Xiang Tan d82dbd565b FIX: Remove dependency on `rest-client`. 2017-06-16 09:42:41 +09:00
Guo Xiang Tan b5ec241716 FIX: Validate interpolation keys used in translation overrides.
https://meta.discourse.org/t/discobot-translation-missing-error/64429/6?u=tgxworld
2017-06-16 08:54:48 +09:00
Guo Xiang Tan 238a156300 FIX: `TopicTimestampChanger` should not allow timestamps in the future. 2017-05-22 16:03:49 +08:00
Guo Xiang Tan 4382a0bb07 Rename `PostTimestampChanger` -> `TopicTimestampChanger`. 2017-05-22 15:01:33 +08:00
Sam e1dd543a93 FEATURE: allow users to select theme on single device 2017-05-15 12:48:16 -04:00
Neil Lalonde 55b61e9bea rename topic_status_update to topic_timer 2017-05-11 18:27:53 -04:00
Sam 946f25098f Refactor theme fields so they support custom theme defined vars
This paves the way to allowing themes to specify uploads and so on.
2017-05-02 16:02:14 -04:00
Sam a3e8c3cd7b FEATURE: Native theme support
This feature introduces the concept of themes. Themes are an evolution
of site customizations.

Themes introduce two very big conceptual changes:

- A theme may include other "child themes", children can include grand
children and so on.

- A theme may specify a color scheme

The change does away with the idea of "enabled" color schemes.

It also adds a bunch of big niceties like

- You can source a theme from a git repo

- History for themes is much improved

- You can only have a single enabled theme. Themes can be selected by
    users, if you opt for it.

On a technical level this change comes with a whole bunch of goodies

- All CSS is now compiled using a custom pipeline that uses libsass
    see /lib/stylesheet

- There is a single pipeline for css compilation (in the past we used
    one for customizations and another one for the rest of the app

- The stylesheet pipeline is now divorced of sprockets, there is no
   reliance on sprockets for CSS bundling

- CSS is generated with source maps everywhere (including themes) this
    makes debugging much easier

- Our "live reloader" is smarter and avoid a flash of unstyled content
   we run a file watcher in "puma" in dev so you no longer need to run
   rake autospec to watch for CSS changes
2017-04-12 10:53:49 -04:00
Robin Ward 40cee37bcc FIX: Don't insert topic status messages unless the status changes 2017-04-07 17:10:43 -04:00
Sam Saffron 48d9c69117 remove confusing comment 2017-04-05 08:46:35 -04:00
Sam Saffron cd39049262 SECURITY: do not send push notifications to suspended users 2017-04-05 08:28:24 -04:00
Robin Ward a649014adf Add spec for validation on group mention updater 2017-04-04 11:22:39 -04:00
Guo Xiang Tan 34b7bee568 FEATURE: Allow admin to auto reopen at topic.
* This commit also introduces a `TopicStatusUpdate`
  model to support other forms of deferred topic
  status update in the future.
2017-03-31 11:14:18 +08:00
Sam 74dbe877d8 test for side effect without mock 2017-03-20 16:15:23 -04:00
Arpit Jalan d5bcc70e9c FIX: grant trust level when bulk adding users to group 2017-03-06 14:39:53 +05:30
Arpit Jalan e27b1b98d1 FIX: handle new user when logging name change 2017-03-01 13:43:57 +05:30
Arpit Jalan 6661cebff8 FIX: do not log duplicate username changes 2017-02-28 01:32:00 +05:30
Arpit Jalan b32d3d66e5 FEATURE: log all username and name changes 2017-02-28 00:23:27 +05:30
Sam 783bac9ff7 less stubbing for better clarity and robustness 2017-02-13 14:34:15 -05:00
Sam ff49f72ad9 FEATURE: per client user tokens
Revamped system for managing authentication tokens.

- Every user has 1 token per client (web browser)
- Tokens are rotated every 10 minutes

New system migrates the old tokens to "legacy" tokens,
so users still remain logged on.

Also introduces weekly job to expire old auth tokens.
2017-02-07 09:22:16 -05:00
Robin Ward 496682c442 Merge pull request #4662 from tgxworld/fix_localized_group_name_change
Fix localized group name change
2017-01-26 10:50:00 -05:00
Neil Lalonde 6b93b09404 FIX: when blocking a user results in hiding their posts, only hide posts made in the last 24 hours 2017-01-19 15:56:22 -05:00
Guo Xiang Tan 706b4f6b9f FEATURE: Remap group mentions when group name has been changed. 2017-01-18 13:39:34 +08:00
Robin Ward 86c52c72f6 FIX: Deleting a user was not deleting their directory items 2017-01-16 11:46:52 -05:00
Guo Xiang Tan e3b6f9b8ae FIX: Do not update user stats like counts for private messages. 2017-01-16 11:07:53 +08:00
Guo Xiang Tan 38496985ef Fix syntax error. 2017-01-12 10:03:37 +08:00
Guo Xiang Tan 23d4435af1 Oops. 2017-01-12 09:56:20 +08:00
Guo Xiang Tan 515f50e42e FEATURE: Log admin action when readonly mode is changed. 2017-01-12 09:41:02 +08:00
Neil Lalonde b177827841 more specs for staff action logging 2017-01-11 11:41:21 -05:00
Guo Xiang Tan d10fe51b72 Fix broken specs since all urls will be oneboxed. 2017-01-06 10:05:51 +08:00
Guo Xiang Tan f1beef43a8 Merge pull request #4618 from tgxworld/fix_invalid_emails
FIX: Don't allow invalid email to be saved.
2016-12-30 07:11:48 +08:00
Sam d28d8a1f85 FIX: order by op_likes leads to broken browsing 2016-12-27 19:08:54 +11:00
Sam c531f4ded5 remove rails-observers
Rails yanked out observers many many years ago, instead the functionality
was yanked out to a gem that is very lightly maintained.

For example: if we want to upgrade to rails 5 there is no published gem

Internally the usage of observers had quite a few problem.

The series of refactors renamed a bunch of classes to give us more clarity
and removed some magic.
2016-12-22 16:46:53 +11:00
Sam 019f1a1d06 UserEmailObserver is now removed
no big surprises here was pretty straightforward

after_commit semantics sure are weird though
2016-12-22 16:46:53 +11:00
Sam 2f6a4cc6de remove UserActionObserver, replace with after_save and service
interestingly there was some left over dead code from when stars
existed in the topic_users table
2016-12-22 16:46:53 +11:00
Sam 0a78ae739d Remove SearchObserver, aim is to remove all observers
rails-observers gem is mostly unmaintained and is a pain to carry forward
new implementation contains significantly less magic as a bonus
2016-12-22 13:13:14 +11:00
Guo Xiang Tan 13c6191e89 FIX: Don't allow invalid email to be saved. 2016-12-21 17:47:11 +08:00
Guo Xiang Tan 05f55dbc10 FEATURE: Group logs. 2016-12-12 17:29:54 +08:00
Régis Hanol 6edd3c347c FIX: automatically disable digests when enabling mailing list mode 2016-11-28 15:52:35 +01:00
Guo Xiang Tan f824afb4d3 FEATURE: Allow date_of_field column to be updated. 2016-11-17 15:16:58 +08:00
Sam aaf947356b correct regression where notifications scope is not pushing to push server 2016-10-14 22:52:39 +11:00
Sam f4f5524190 FEATURE: user API now contains scopes so permission is granular
previously we supported blanket read and write for user API, this
change amends it so we can define more limited scopes. A scope only
covers a few routes. You can not grant access to part of the site and
leave a large amount of the information hidden to API consumer.
2016-10-14 16:05:42 +11:00
Sam 3ad8616f44 Merge pull request #4476 from xfalcox/localize-badge-notifications
FIX: Properly localize badge notification on batch grant
2016-10-12 15:16:35 +11:00
Rafael dos Santos Silva 48fa1f141f Add specs for localized notifications on backfilled badges 2016-10-11 19:15:36 -03:00
Sam 89daa43754 FEATURE: remap emojis back for push notifications and desktop alerts 2016-10-11 13:03:48 +11:00
cpradio 6f1c31d777 Add notification level user preference when replying to a topic 2016-09-30 14:58:07 -04:00
Robin Ward c94e6f1b96 Add locale step 2016-09-22 09:52:19 -04:00
Neil Lalonde 06eb256d0a FIX: blocking users should never hide all posts if they are trust level 1 or higher 2016-09-12 11:58:10 -04:00
Sam 340874d345 FIX: post notifications in JSON so we properly support arrays and so on 2016-09-04 15:51:16 +10:00
Sam 4fe52c8cbe FEATURE: backend support for pushing notifications to clients 2016-08-26 12:47:10 +10:00
Arpit Jalan 4a2f0e772c add specs for post ownership change without revision 2016-08-20 01:27:48 +05:30
Robin Ward 4061725a95 FIX: Don't ever grant badges when they're disabled 2016-08-19 15:16:37 -04:00
Robin Ward 3d62e5dd98 SECURITY: XSS issue on Admin users list 2016-08-05 12:01:16 -04:00
Sam 9018de39ed FEATURE: allow shipping bio markdown via SSO
- Also adds site setting for sso_overrides_bio to disable bio editing by end users
2016-08-01 15:29:28 +10:00
Robin Ward c279889191 FIX: Watching First Post in groups was working incorrectly 2016-07-21 15:05:10 -04:00
Robin Ward 09be741820 FIX: Don't alert on new posts in a topic unless it's a new record 2016-07-19 15:57:05 -04:00
Guo Xiang Tan d55da4fe1b Revert "Revert "Update rails.""
This reverts commit 4d27d7e1d3.
2016-07-18 11:00:23 +08:00
Robin Ward 4d27d7e1d3 Revert "Update rails."
This reverts commit 898ec43989.
2016-07-15 16:35:57 -04:00
Guo Xiang Tan 898ec43989 Update rails. 2016-07-15 13:18:30 +08:00
Sam 4161ee210a FEATURE: improved tag and category watching and tracking
- present tags watched on the user prefs page
- automatically watch or unwatch old topics based on watch status

New watching and tracking logic takes care of handling old topics
(either with or without read state)

When you watch a topic you now watch historically

Also removes confusing warnings from user.
2016-07-08 12:58:30 +10:00
Robin Ward 2005565c9c Server side code for Watching First Post Only 2016-07-07 11:21:50 -04:00
Robin Ward 83e46cc302 FIX: Restrict changing ownership to one topic 2016-06-17 14:20:14 -04:00
Neil Lalonde d62f2b4d67 UX: rename setting num_flags_to_block_new_user to num_spam_flags_to_block_new_user 2016-06-15 13:19:06 -04:00
Neil Lalonde 1c9519636c FEATURE: new users can be blocked from posting if enough TL3 users flag their posts 2016-06-15 10:51:34 -04:00
Robin Ward 0396b14b70
FEATURE: New "First Onebox" badge 2016-04-12 15:31:14 -04:00
Sam 72849e65de FIX: when granting old badges that are bronze, do not notify 2016-04-12 22:08:38 +10:00
Sam a130cb8305 FEATURE: move more urgent emails notifications to critical queue
Move signup, admin login and password change email notifications
to critical queue
2016-04-07 14:39:01 +10:00
Sam f9e5c49350 FIX: blue notification instead of green for replies/mentions in PMs 2016-03-22 14:28:14 +11:00
Régis Hanol f15d463eb8 FIX: user 'UserBlocker' when blocking a new user 2016-03-18 12:16:37 +01:00
Sam c2fa314684 test username actually changes 2016-03-18 12:32:09 +11:00
jeremylan 1c7a0cb514 Updated test to check for Site Setting full_name_required
Added context and new test to check for correct user anonymizing depending on full_name_required Site Setting
2016-03-18 09:43:48 +11:00
Sam Saffron e947c3b9ec correct for earlier versions of ruby 2016-03-17 09:25:48 +11:00
Sam Saffron 8577b7e2cc FIX: setting owner on topic should not bump topic 2016-03-17 08:32:56 +11:00
Sam Saffron b300d60086 FIX: when changing owner of last post user list on topic incorrect 2016-03-16 23:49:54 +11:00
Régis Hanol 2747e14b4c FEATURE: hide elided part of incoming emails behind a [details] tag 2016-03-09 18:51:54 +01:00
Neil Lalonde 091e7ef3ca FIX: when a post is edited by someone other than the original author and a mention is added, the mention notification is from the person who edited 2016-03-08 15:26:12 -05:00
Sam af577a5854 FEATURE: like notification frequency of never 2016-03-06 09:12:59 +11:00
Sam Saffron 8b1772ac0f FIX: if user undos like, and relikes notify
FEATURE: roll up likes for notify on all likes
2016-03-04 22:56:27 +11:00
Sam 5a6c34fb8a regression, unable to edit posts 2016-03-03 16:00:14 +11:00
Guo Xiang Tan 9d24a00f2e Merge pull request #4055 from tgxworld/fix_topic_view_not_working_in_redis_readonly
FIX: Topic view not working when Redis is readonly.
2016-03-03 08:48:31 +08:00
Guo Xiang Tan 5f8e20aa1d FIX: Topic view not working when Redis is readonly. 2016-03-03 08:26:45 +08:00
Neil Lalonde c1aea91d63 FEATURE: More digest email frequency options. Digests can be sent as often as every 30 minutes. 2016-03-02 15:43:47 -05:00
Sam Saffron 5f4075a6cf FEATURE: users can select how frequently they are notified on likes
- first time
- first time and daily (default)
- always
2016-03-02 23:16:52 +11:00
Sam Saffron 820a435af8 FEATURE: add "email in-reply-to user option"
We no longer include previous replies as "context", instead
we include and excerpt of the post being replied to at the bottom
of notifications, this information was previously missing.

Users may opt in to emailing previous replies if they wish
or opt out of "in-reply-to" which makes sense in some email clients that
are smarter about displaying a tree of replies.
2016-02-26 00:05:59 +11:00
Guo Xiang Tan e7cfbfeabb FIX: `Array#first` with block will return the first element if nothing matches. 2016-02-24 22:34:40 +08:00
Robert Riemann 9c39647cd2 fix: support for hyphens in group name
The group mention @ORG-team triggers notifications for the group @ORG. This fix changes the RegExp, so that the group name is correctly extracted.

see: https://meta.discourse.org/t/group-mentions-that-begin-with-the-same-characters-may-be-incorrect/39892/12?u=rriemann
2016-02-23 23:55:31 +01:00
Régis Hanol 8d1da9cedd FEATURE: keep original title when sending email notifications about a PM 2016-02-23 01:34:16 +01:00
Sam f0e942f647 PERF: move 3 more option columns out of the user table 2016-02-18 16:57:22 +11:00
Sam 3829c78526 PERF: shift most user options out of the user table
As it stands we load up user records quite frequently on the topic pages,
this in turn pulls all the columns for the users being selected, just to
discard them after they are loaded

New structure keeps all options in a discrete table, this is better organised
and allows us to easily add more column without worrying about bloating the
user table
2016-02-17 18:08:25 +11:00
Sam Saffron 4099823efe FIX: batch badge assigner was not including full info in notification
(missing drilldown link in notification)
2016-02-01 18:27:07 +11:00
Arpit Jalan cf1bd35fc6 FIX: while changing site text, old and new values can be nil 2016-01-18 20:56:14 +05:30
Sam cba76db53b FIX: if people link own post, watchers not notified 2015-12-31 10:51:58 +11:00
Arpit Jalan 4c967d11b4 FEATURE: log site text changes 2015-12-18 19:42:06 +05:30
Guo Xiang Tan 8b6b3cf858 FIX: Admin logging should not log permissions if none has been set. 2015-12-06 15:29:13 +08:00
Andy Waite 3e50313fdc Prepare for separation of RSpec helper files
Since rspec-rails 3, the default installation creates two helper files:
* `spec_helper.rb`
* `rails_helper.rb`

`spec_helper.rb` is intended as a way of running specs that do not
require Rails, whereas `rails_helper.rb` loads Rails (as Discourse's
current `spec_helper.rb` does).

For more information:

https://www.relishapp.com/rspec/rspec-rails/docs/upgrade#default-helper-files

In this commit, I've simply replaced all instances of `spec_helper` with
`rails_helper`, and renamed the original `spec_helper.rb`.

This brings the Discourse project closer to the standard usage of RSpec
in a Rails app.

At present, every spec relies on loading Rails, but there are likely
many that don't need to. In a future pull request, I hope to introduce a
separate, minimal `spec_helper.rb` which can be used in tests which
don't rely on Rails.
2015-12-01 20:39:42 +00:00
Sam d1a5d8ea62 FEATURE: show group mentions and topics in groups page 2015-12-01 16:52:43 +11:00
Sam ad3dd161e7 FEATURE: first class group mentions built in
If you allow a group to be mentioned it can be mentioned with the @ symbol.

Keep in mind as a safety mechanism max_users_notified_per_group_mention is set to 100
2015-11-30 17:08:43 +11:00
Neil Lalonde 84342ecdef FIX: anonymized user's preferences should have system assigned avatar chosen 2015-11-27 14:37:30 -05:00
Robin Ward d65ec1af2e Rename `ninja_edit_window` to `editing_grace_period` :'( 2015-11-24 14:28:42 -05:00
Guo Xiang Tan d9fe78da20 FIX: Topic#last_posted_at was not being set when changing topic timestamp. 2015-10-20 10:12:52 +08:00
Robin Ward eacd75bcf8 SECURITY: Unread post notifications should respect whispers 2015-10-19 16:32:10 -04:00
Guo Xiang Tan f39b9124b6 FEATURE: Log staff actions for Category changes. 2015-09-18 10:53:08 +08:00
Neil Lalonde 354a3f9638 add test for auth_token being cleared by user anonymizer, which it already does 2015-09-10 11:17:48 -04:00
Sam 262f561a87 FEATURE: relax username rules to allow - and . and leading _
This relaxes our very strict username rules to allow for some long asked for requests

- leading _ is now allowed
- . is allowed except for trailing char and confusing extensions like .gif .json
- dash (-) is now permitted
2015-09-02 12:13:44 +10:00
Arpit Jalan 10b8e43a92 FIX: send new email activation token if the original token expired 2015-08-24 12:00:00 +05:30
Sam 94f05a40de FIX: when destroying users we were leaving drafts behind 2015-08-24 16:05:08 +10:00
Guo Xiang Tan 89f4ebfb36 Fix timestamp comparison in tests.
Follow up to 58190c92e9.
2015-08-22 10:12:02 +08:00
Guo Xiang Tan c7a21b7c23 FEATURE: Allow admin to change timestamp of topic. 2015-08-17 00:00:05 +08:00
Sam 5ee4d3ba8c FIX: log post deletion even if user is deleted. 2015-08-14 13:57:02 +10:00
Sam 5ab7f7e88d FIX: double like notification
If you got a like -> edit/quote/etc -> like you would get a
double notification
2015-06-19 12:31:36 +10:00
Neil Lalonde 3a67c02c7a FIX: change topic creator wasn't removing the topic from the previous creator's activity stream 2015-05-29 17:39:36 -04:00
Sam 1e4c7dfbe7 FIX: invalid plan generation when % in query on badge definition UI 2015-05-28 16:06:22 +10:00
Régis Hanol d4974b7093 FIX: anonymous mode don't work when names are required 2015-05-15 14:20:15 +02:00
Arthur Neves b8cbe51026
Convert specs to RSpec 2.99.2 syntax with Transpec
This conversion is done by Transpec 3.1.0 with the following command:
    transpec

* 424 conversions
    from: obj.should
      to: expect(obj).to

* 325 conversions
    from: == expected
      to: eq(expected)

* 38 conversions
    from: obj.should_not
      to: expect(obj).not_to

* 15 conversions
    from: =~ /pattern/
      to: match(/pattern/)

* 9 conversions
    from: it { should ... }
      to: it { is_expected.to ... }

* 5 conversions
    from: lambda { }.should_not
      to: expect { }.not_to

* 4 conversions
    from: lambda { }.should
      to: expect { }.to

* 2 conversions
    from: -> { }.should
      to: expect { }.to

* 2 conversions
    from: -> { }.should_not
      to: expect { }.not_to

* 1 conversion
    from: === expected
      to: be === expected

* 1 conversion
    from: =~ [1, 2]
      to: match_array([1, 2])

For more details: https://github.com/yujinakayama/transpec#supported-conversions
2015-04-25 11:18:35 -04:00
Robin Ward 151b559e4c FIX: If you delete a user, delete their queued posts as well. 2015-04-24 16:04:44 -04:00
Sam 4bfca12b11 FEATURE: anonymous_account_duration_minutes , cycle anon accounts after N minutes from last post
fixes it so anon users can not like stuff
2015-04-08 12:30:02 +10:00
Sam f5d89169e2 FEATURE: initial implemenation of anonymous posting mode 2015-04-07 18:05:31 +10:00
Sam 14741b5dac FIX: only ONE user on site could have a list of muted users 2015-03-31 10:16:23 +11:00
Sam 92e371f0b3 FEATURE: civilized mute
Allow user to mute all notifications generated by specific users
2015-03-24 11:55:22 +11:00
Neil Lalonde 2585962552 fix spec that can fail when comparing timestamps. I only care that it isn't null. 2015-03-11 16:51:29 -04:00
Neil Lalonde dece5a351a more fixes for post ownership change and user deletion 2015-03-11 15:54:20 -04:00
Neil Lalonde 608647d02f FEATURE: Anonymize User. A way to remove a user but keep their topics and posts. 2015-03-10 11:59:08 -04:00
Neil Lalonde 35c58c1b00 FIX: after changing post owner, profile pages still showed previous owner and incorrect topic and post counts 2015-03-03 14:15:11 -05:00
Neil Lalonde 1bf4f34049 FIX: topic and post counts are not updated when ownership of a post is changed 2015-03-02 12:13:21 -05:00
Sam b760d22460 PERF: avoid expensive order by random for suggested topics 2015-02-25 17:19:12 +11:00
Robin Ward 4e64d16a47 FEATURE: Allow plugins to log staff actions 2015-02-05 15:26:34 -05:00
Robin Ward b2e2a99898 FIX: Don't raise an error when trying to log nothing 2014-12-15 14:14:12 -05:00
Robin Ward cb0e7a5724 For performance reasons, use `delete_all` when removing a user's email logs 2014-11-28 14:20:43 -05:00
Régis Hanol 4e735e8aab FIX: roll up staff action wasn't working 2014-11-27 01:12:56 +01:00
David McClure efc4109902 update specs to remove deprecation warnings 2014-11-07 06:05:44 -08:00
Régis Hanol e7f251c105 LOTS of changes to properly handle post/topic revisions
FIX: history revision can now properly be hidden
FIX: PostRevision serializer is now entirely dynamic to properly handle
hidden revisions
FIX: default history modal to "side by side" view on mobile
FIX: properly hiden which revision has been hidden
UX: inline category/user/wiki/post_type changes with the revision
details
FEATURE: new '/posts/:post_id/revisions/latest' endpoint to retrieve
latest revision
UX: do not show the hide/show revision button on mobile (no room for
them)
UX: remove CSS transitions on the buttons in the history modal
FIX: PostRevisor now handles all the changes that might create new
revisions
FIX: PostRevision.ensure_consistency! was wrong due to off by 1
mistake...
refactored topic's callbacks for better readability
extracted 'PostRevisionGuardian'
2014-10-27 22:06:43 +01:00
Régis Hanol 10094a0bcd FIX: resolve flags as good when deleting a spam user 2014-10-20 16:59:06 +02:00
Sam f834a5fe4e correct spec 2014-10-09 22:27:34 +11:00
Sam 0e7be81e60 FIX: badge granted titles were not being revoked when badge was revoked 2014-10-08 10:26:18 +11:00
Régis Hanol 98b6b9821a FEATURE: log topic/post deletions from staff members 2014-10-01 17:40:13 +02:00
Régis Hanol de76b512c1 fix most deprecations in the specs (still some left) 2014-09-25 17:44:48 +02:00
Neil Lalonde d6a562658a FIX: update user preferences was failing if custom_fields is blank string 2014-09-17 13:09:39 -04:00
Sam 7f3797b635 FEATURE: Nice Topic, Good Topic and Great Topic badges
Note we will revoke all old badges post badges that went to post #1
and instead get topic badges
2014-09-11 12:36:37 +10:00
Sam 59d04c0695 Internal renaming of elder,leader,regular,basic to numbers
Changed internals so trust levels are referred to with

TrustLevel[1], TrustLevel[2] etc.

This gives us much better flexibility naming trust levels, these names
are meant to be controlled by various communities.
2014-09-05 15:20:52 +10:00
Neil Lalonde d273374f1a FIX: before nuking a user, do a real count of posts instead of relying on user_stat record 2014-08-18 12:07:29 -04:00
Sam 1baa55fe45 FIX: preview bust when no params 2014-08-13 12:25:56 +10:00
Sam 22cd259687 FIX: remove faulty "ensure consistency" badge job 2014-08-11 09:21:06 +10:00
Sam f20c5a02c7 amend test 2014-08-08 10:02:43 +10:00
Sam 5d9eefbfed FIX: don't notify on link reflections 2014-07-29 15:40:05 +10:00
Régis Hanol bddffa7f9a FEATURE: flag dispositions normalization
All flags should end up in one of the three dispositions
  - Agree
  - Disagree
  - Defer

In the administration area, the *active* flags section displays 4 buttons
  - Agree (hide post + send PM)
  - Disagree
  - Defer
  - Delete

Clicking "Delete" will open a modal that offer to
  - Delete Post & Defer Flags
  - Delete Post & Agree with Flags
  - Delete Spammer (if available)

When the flag has a list associated, the list will now display 1
response and 1 reply and a "show more..." link if there are more in the
conversation. Replying to the conversation will NOT give a disposition.
Moderators must click the buttons that does that.

If someone clicks one buttons, this will add a default moderator message
from that moderator saying what happened.

The *old* flags section now displays the proper dispositions and is
super duper fast (no more N+9999 queries).

FIX: the old list includes deleted topics
FIX: the lists now properly display the topic states (deleted, closed,
archived, hidden, PM)
FIX: flagging a topic that you've already flagged the first post
2014-07-28 19:28:07 +02:00
Sam 0f9678fe49 FIX: faster update of all badges
Introduced badge triggers, introduced concept of badge that happens due to a post but has the post hidden

Delta badge grant happens once a minute, backed by redis
2014-07-23 11:46:07 +10:00
Neil Lalonde 939e8505a9 Remove hub username integration 2014-07-16 12:25:24 -04:00
Sam e32e96dabb FEATURE: new badges
- Pay it forward renamed to first like
- First flag
- First share
2014-07-09 12:17:39 +10:00
Sam 81682b74b7 Feature: Paying it forward badge 2014-07-08 14:26:53 +10:00
Sam 0f25bbeaf7 FEATURE: Editor badge 2014-07-07 17:55:40 +10:00
Sam 4a25c86d61 FIX: correct duplicate granting 2014-07-05 18:32:06 +10:00
Sam 9a9ad9bda8 FEATURE: Badge progress
- Refactor model so it stores backfill query
- Implement autobiographer
- Remove sample badge
- Correct featured badges to only include a badge once
2014-07-03 17:29:44 +10:00
Sam bc44bfcdf2 Work in progress backfill for like badges 2014-07-01 22:01:15 +10:00
Vikhyat Korrapati 23983efeea Don't grant multiple_grant badges multiple times for the same post. 2014-06-28 00:32:09 +05:30
Vikhyat Korrapati 3ba65af19e Add like-based system badges. 2014-06-19 17:10:43 +05:30
Sam 56dcd00570 BUGFIX: trust_level_0 group not including trust_level_1
BUGFIX: manual trust level change not adding user to groups
BUGFIX: system not in correct trust level groups
2014-06-17 10:52:02 +10:00
Andrew Bezzub 9ffd173873 move bio to UserProfile from User 2014-06-13 14:55:32 -04:00
Andrew Bezzub 7db31adf35 move website from User to UserProfile 2014-06-06 21:54:32 -07:00
Vikhyat Korrapati 8c2ec4c52a Get rid of update_badges mocks. 2014-05-15 23:13:04 +05:30
Vikhyat Korrapati c07244a4e6 Refactor BadgeGranter.update_trust_level_badges! -> update_badges. 2014-05-14 21:01:41 +05:30
Vikhyat Korrapati b144b75565 Add automatically assigned trust level badges. 2014-05-14 20:47:21 +05:30
Neil Lalonde c4d3aa3d47 Theming: a UI to choose some base colors that are applied to all the site css. CSS compiled outside of asset pipeline. 2014-05-14 10:18:12 -04:00
Louis Rose 1574485443 Perform the where(...).first to find_by(...) refactoring.
This refactoring was automated using the command: bundle exec "ruby refactorings/where_dot_first_to_find_by/app.rb"
2014-05-06 14:41:59 +01:00
Neil Lalonde f61f29439e Track the ip address where user was registered 2014-04-29 14:37:56 -04:00
Neil Lalonde feaaf55a0c Theming: color scheme editing. Unfinished! Doesn't have any effect on css files yet. 2014-04-24 16:49:12 -04:00
Vikhyat Korrapati 8113e8d897 Basic UI for selecting gold/silver badges as titles. 2014-04-18 09:20:51 +05:30
Vikhyat Korrapati 89f45901bc Create notification when badge is granted. 2014-04-17 01:58:01 +05:30
Régis Hanol 2505d18aa9 FEATURE: support email attachments 2014-04-14 22:55:57 +02:00
Neil Lalonde 379f4a87d5 FIX: remove likes and other post actions before nuking a user 2014-03-31 14:06:35 -04:00
Vikhyat Korrapati dcaa069bb5 Log badge grant/revoke to the staff actions log. 2014-03-21 11:10:07 +05:30