Commit graph

235 commits

Author SHA1 Message Date
Anna Buianova
e9f0891577
Improved the podcasts seeds (#6565) 2020-03-10 14:23:48 -04:00
Ben Halpern
0817e2ac9e
Create implicit experience level rating vote upon creating of readinglist reaction (#6522) [deploy]
* Do not render or link to empty rss feeds

* s

* Move calculation to worker

* remove xit test

* Also allow implicit rating votes in comments

* Fix alignment issue

* Remove comment logic
2020-03-10 10:59:49 -04:00
rhymes
d73d0c34ab
Add CodeNewbie podcast to seeds (#6527) 2020-03-09 08:34:25 +01:00
Alex
35651b26e5
Remove Algolia from Comments (#6464) [deploy]
* Remove Algolia from comments

* Remove more references to ordered_comments index

* Remove more references to Comments Algolia index

* Fix index_worker_spec
2020-03-05 11:30:25 -08:00
Molly Struve
039ac2e856
Remove Shipping Fields from Users (#6477) [deploy] 2020-03-05 13:41:09 -05:00
Molly Struve
699820e5e3
install Blazer for querying the database (#6459) [deploy] 2020-03-05 08:07:58 -05:00
Alex
07d3991bc8
Remove Algolia for ClassifiedListings (#6435) [deploy] 2020-03-04 08:36:14 -05:00
Ben Halpern
1dc1723709
Add field test gem to establish a/b testing (#6283) [deploy]
* Initial field test spec work

* Clean up specs

* Fix codeclimage

* Cleanups

* Update names

* Rename and remove need to pass logged in status

* Leadup to prod: two experiments

* Move test logic to controller and add tests

Co-authored-by: Josh Puetz <josh@grorichpuetz.com>
2020-03-03 10:21:29 -05:00
Andy Zhao
a3728cfa4c
[deploy] Add EmailAuthorization model (#6335)
* Add EmailAuthorization model

* Add model file oops

* Add comment for uuid type

Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2020-03-02 12:14:24 -05:00
Anna Buianova
df93e8d41e
Custom social preview template for tags (#6290) [deploy]
* Custom social preview template for tags

* Added index on tags social_preview_template + small refactoring

* Add checks if index exists to tags migration
2020-02-27 17:56:21 -05:00
Vaidehi Joshi
422cebf87e
Remove sent attribute from broadcasts table (#6350) [deploy]
Now that 6318 and 6319 have been merged, we no longer need the `sent` attribute on the Broadcast model.
2020-02-27 17:36:26 -05:00
Vaidehi Joshi
3bc0f49861
Only send notifications that belong to an active broadcast (#6319) [deploy]
* Use active in place of sent on internal broadcast routes

* Add and use active scope on broadcasts

* Update seeds + specs to use active broadcasts

* Add note about active broadcasts to /internal/broadcasts page
2020-02-27 08:02:45 -08:00
Vaidehi Joshi
81e2a5efc3
Add active attribute to Broadcasts (#6318) [deploy]
* Add active attribute to Broadcasts

* Backfill active attribute on Broadcasts
2020-02-26 16:44:27 -05:00
rhymes
fc09716709
Use builtin Rails index_exists? for indices (#6293) 2020-02-26 11:05:23 -05:00
rhymes
33a11adca8
Various optimizations (#6249) [deploy]
* Pluck over map
* Explain why map makes sense there
* Refactor reactions controller a bit and iterate only once
* Use group by instead of N counting queries
* More positive
* Simplify BufferedArticlesController
* Less queries for MailchimpBot
* Use Rails instead of SQL
* Build comment_ids only when needed
2020-02-25 13:42:24 -05:00
Molly Struve
607d8d71de
Add index missing check to podcast migration (#6292) [deploy] 2020-02-25 12:29:19 -05:00
rhymes
956334cf1f
Add indexes to PodcastEpisode.title and .website_url (#6280) [deploy] 2020-02-25 08:36:05 -05:00
rhymes
a5588ae430
Enable strong-migrations in all environments (#6279) [deploy]
* Enable strong-migrations in production
* Disable environment checks in initializers
* Remove misleading description
2020-02-24 11:12:49 -05:00
Molly Struve
fad4a1172d
remove reference to strong migrations from migration that will run in prod (#6277) [deploy] 2020-02-24 09:29:29 -05:00
rhymes
7744973dd9
Remove User.organization_id (#6242) 2020-02-24 08:34:17 -05:00
Nick Schwaderer
a6d9390948
Ensure seeds.rb does not fail validation (#6210) 2020-02-21 09:03:29 -05:00
Zachary Dixon
cf2af6c2dc
Add dropdown menu to listings (#4184) [deploy]
* Resolves 2826, add dropdown menu to listings

* Fixed dropdown position

* Refactored single listing

* Revert schema.rb to master

* Fixed tests
2020-02-18 18:08:39 -05:00
rhymes
f3c2adfa45
Routine rubocop fixes (#6138) 2020-02-18 11:21:42 -05:00
Andy Zhao
acd3b92b32
Add sink user service and specs for mass vomits (#6006)
* Add sink user service and specs for mass vomits

* Use new score calculation

* Lower articles' scores instead and make async

* Add lower score functionality to controllers

* Remove unused variable

* Use correct var and add missing arg

* Remove unused status

* Add composite index for reactable_type and ID

* Use alias instead of additional boolean

* Use medium priority for sink worker

* Log to honeybadger and not logs

* Log the error and not a string
2020-02-17 10:29:50 -05:00
Vaidehi Joshi
76fe99b76a
Add Broadcast seeds + generator service to set up for welcome notifications (#6080)
* Add more Broadcasts to seeds for welcome notification flow

* Remove unnecessary welcoming_user_id from development config

* Add basic service class for generating appropriate broadcast per user

Eventually, this should be called from a rake task that will rely on this service to determine which broadcast, if any, is the appropriate one to send to newly signed-up users, and will enqueue a worker to create/send a welcome notification when appropriate.

* Add a few TODOs, plus some general cleanup

* Add some skipped tests for WelcomeNotification::Generator
2020-02-14 12:30:25 -08:00
Alex
b81c2e8df3
Remove delayed_job (#6071) [deploy]
* Update adapter to sidekiq

* Remove delayed_jobs routes

* Remove delayd_jobs initializer and references

* Remove delayed_job_spec

* Remove bin/delayed_job

* Remove app/jobs/

* Migration to drop delayed_jobs table

* Remove delayed_job_web & delayed_job_active_record

* Update docs

* Remove reference to delayed_job dashboard

* Remove delayed_job settings from initializers

* Add delayed_job_admin back to reserved words list
2020-02-14 10:00:26 -08:00
rhymes
59eb367f2c
Fix uniqueness generator when too much data is seeded (#6058) 2020-02-13 12:39:48 -05:00
Molly Struve
0bfbd9bb1f
Set Up Framework For Running Data Update Scripts (#6025) [deploy] 2020-02-13 10:48:23 -05:00
rhymes
085c0d1e01
Add multiplier for seeds and use it for articles and users (#6003)
* Add seeds multiplier and use it for articles and users

* Update DB documentation
2020-02-10 16:06:58 -05:00
Molly Struve
0dfabf4324
Remove indexing from ChatChannel model in seed script (#6001) 2020-02-10 11:30:08 -05:00
Ben Halpern
f3c86c6377
Add mod channel automation to tags (#5731) [deploy]
* Add mod channel automation to tags

* Change mod_relations to mod_relations_admin

* Run migration properly

* Make queries consistent and fix test
2020-02-06 16:27:12 -05:00
Alex
231e8d49b2
Add index to notifications to optimize query (#5921) [deploy]
- Index notifications on notifiable_id, notifiable_type, and action
2020-02-06 08:49:25 -08:00
rhymes
a1835ae5b9
User counters using PostgreSQL JSON (#5373) [deploy]
Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2020-02-03 10:35:08 -05:00
Sebastien
a25446b1d4 Add organizations to user profile (#5583) [deploy]
* Add organizations to user profile

* Add user organization info updated at column and cache key

* Remove default value for users organization_info_updated_at column

* Update organization_memberships factory

* Remove schema organization_info_updated_at default value

Co-authored-by: rhymes <rhymesete@gmail.com>
2020-01-27 13:31:27 -05:00
Michael Kohl
5b35370db8 Introduce BanishedUser table (#5589) [deploy] 2020-01-21 17:15:58 -05:00
Ben Halpern
9fa5d3156a
Add article.comment_score metric calc and tracking (#5560) [deploy]
* Add article.comment_score metric calc and tracking

* Change from gauge to count

* Adjust key and tags
2020-01-19 15:21:19 -05:00
Lucas Hiago
9ed6a5add0 Fix hex color in seeds (#5452) 2020-01-11 11:24:08 -05:00
Anna Buianova
e09e46ec99 Creating podcasts by users (#3730) [deploy]
* Create podcast as a user [WIP]

* Sample css for podcast form

* Nicer podcasts suggesting form

* Validate podcast feed_url

* Validate podcast main_color_hex

* Fix podcasts specs

* Fix form appearance

* Placeholder for podcast main_color_hex

* Provide a link to suggest a podcast

* Add a checkbox and a role for when a podcast is added by an owner

* Prettier checkbox in the podcasts form

* Added creator to podcasts

* Set the podcast creator

* Fix the /pod spec

* Added creator information to the internal podcast page

* Added cta class to the podcasts submit button

* Global notice when a podcast was suggested

Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2020-01-08 16:14:25 -05:00
rhymes
09e5ad5c0c Remove PushNotificationSubscription (#5258) [deploy] 2019-12-27 13:45:38 -06:00
rhymes
d015fb7c85 Remove search keywords (#5259) [deploy] 2019-12-27 12:40:20 -05:00
Molly Struve
1ac9a2d7bd
add index to created_at for notifications (#5251) [deploy] 2019-12-27 08:57:40 -06:00
Ben Halpern
03c2404b13
Redo /mod for performance and usability (#5230) [deploy] 2019-12-23 18:10:25 -05:00
Sarthak Sharma
b602b7b91f 🚀Feature/ability to edit messages (#5139) [deploy]
* Feature 🚀 : Ability to delete messages in chat channels

- Sending message ID to frontend
- Deleting Message
- Use pusher to delete message realtime

* Minor Bug 🐞: Show message action only for current user

- User can delete or edit their own messages

* Test cases added

* Bug 🐞: Update message id for receiver

Message id was not sent to receiver by pusher

* Refactoring🛠: Message controller refactoring

* Test Cases📝 : Specs for Delete message added

* Feature 🚀 : Ability to edit messages

* Test Cases📝 : Specs for Edit message added

* Refactoring🔩: Refactoring for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Test Cases📝 : Test Cases for edit message added

* Minor Bug 🐞: Show message action only for current user

- User can delete or edit their own messages

* Test cases added

* Bug 🐞: Update message id for receiver

Message id was not sent to receiver by pusher

* Feature 🚀 : Ability to edit messages

* Test Cases📝 : Specs for Edit message added

* Refactoring🔩: Refactoring for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Refactoring🔩: Refactoring:2 for edit messages

* Bug Fix 🐞: Added space between edited and timestamp

Co-authored-by: Ben Halpern <bendhalpern@gmail.com>
2019-12-20 10:19:00 -05:00
Keith Bennett
70e1ffbbc3 Fix rubocop Rails.root.path complaints (#5114) 2019-12-16 12:13:15 -05:00
Jacob Herrington
6877534cce Add abuse report seed data (#5113) 2019-12-16 08:09:52 -05:00
Andy Zhao
71157c993e Hide comment feature (#4944)
* Add MVP of hide comment feature

* Slight copy adjustments

* Remove unused file oops

* Fix strange styling issues

* Add hide/unhide comment specs

* Authenticate user for hide/unhide

* Add tests for hide/unhide functionality

* Remove opacity CSS for hidden comments

* Fix hidden comment explanation logic

* Fix some styling issues

* Fix hiding top level comment logic

* Show only hidden comments in permalink and not thread

* Hide subtree properly if hidden comment

* Fix weird CSS issue

* Properly hide comments for permalink view

* Show children comments in permalink view

* Add tests for comment hiding visibility

* Remove superfluous code and adjust copy

* Remove some more logical duplication

* Add dedicated article column for any comments hidden

* Add reload in test
2019-12-10 15:09:47 -05:00
rhymes
62edf443f3 Add FKs to notifications_subscriptions, page_views and users_roles (#4999) [deploy] 2019-12-04 10:14:57 -06:00
rhymes
e62f5ada21 Add missing fks to api_secrets, listings and identities (#4997) [deploy] 2019-12-03 10:59:13 -06:00
rhymes
1c0a9f8198 Add missing foreign keys to tag_adjustments (#4994) [deploy] 2019-12-03 09:48:43 -06:00
leewynne
5b50d52b5f Replaced hard coded AWS region in carrierwave.rb and sitemaps.rb. Updated legacy migration files to include pre rails 5 version (this resolved new instances on Heroku) (#4874) [deploy]
* missing rails version 4.2 added to pre 5 migrations

* updated carrierwave.rb and sitemap.rb with AWS_DEFAULT_REGION
2019-11-22 09:07:59 -05:00