Commit Graph

35 Commits

Author SHA1 Message Date
Andreas Nedbal b4cfc95c83 Adjust accessors to pull values from attributes if they exist
This has to be done because using multiple queries in a select statement does not automatically map into an ActiveRecord model and the values we want wait in the `self.attributes` hash.
2024-03-19 22:45:19 +01:00
Andreas Nedbal 06b2421f2c Rename all occurences of `Inbox` class to `InboxEntry` 2024-01-27 19:21:07 +01:00
Andreas Nedbal d303b5b18e Use `attr_accessor` for `Answer` object properties 2024-01-19 22:06:27 +01:00
Karina Kwiatek 539868173c Fix `has_reacted` and `is_subscribed` not being set 2023-12-19 13:45:25 +01:00
Karina Kwiatek 13d69cfd43 Fix render error on answer create 2023-12-09 18:05:50 +01:00
Karina Kwiatek 8facb44af7 Fix lint errors 2023-11-27 22:14:21 +01:00
Karina Kwiatek b55e6da9a5 Use subqueries to check reaction/subscription state 2023-11-26 19:32:50 +01:00
Andreas Nedbal 1e29d3f86f Rename `Appendable::Reaction` to `Reaction` 2023-10-28 02:44:48 +02:00
Karina Kwiatek 54ac832c91 Ensure inbox caching timestamp gets updated when answering questions and returning to inbox 2023-08-16 21:57:31 +02:00
Karina Kwiatek 8cbfd273bc Refactor counters to use `counter_cache` 2023-02-24 23:31:38 +01:00
Karina Kwiatek c2baa86c09 Add `pinned_at` to answers 2023-02-12 20:19:50 +01:00
Andreas Nedbal b66c2b1f36 add `long?` method and constant to Answer model 2023-01-12 21:03:44 +01:00
Andreas Nedbal 9b5470cfd3 Appease the dog overlords 2023-01-01 22:43:24 +01:00
Andreas Nedbal 7b0a615193 Validate uniqueness of answers for questions 2023-01-01 22:43:24 +01:00
Karina Kwiatek f475cd0a0b Make notifications relation polymorphic 2022-07-22 16:52:42 +02:00
Karina Kwiatek 4f88b82361 Use null-safe navigation for `denotify` 2022-07-17 21:21:37 +02:00
Karina Kwiatek 8a6a9c21ec Appease the dog overlords
These counters are legacy and will later be removed.
2022-07-06 20:58:53 +02:00
Karina Kwiatek 539505eccd Ensure counters only get updated if the record exists 2022-07-06 20:58:53 +02:00
Karina Kwiatek 5f0a546353 Refactor smiling answers to using reactions 2022-07-05 23:23:37 +02:00
Georg Gadinger 101b3b68d3 Use cursored pagination, remove WillPaginate 2020-04-20 23:13:24 +02:00
Georg Gadinger 3e7497a144 Upgrade to Rails 5 2020-04-19 00:59:22 +02:00
Yuki 8b88827a00 Fix retrospring/bugs#43 2015-05-05 02:36:57 +05:30
Yuki 1c80c70dd9 Derp x2 (Retrospring/bugs#41) 2015-04-30 05:52:24 +05:30
Yuki 563293be44 Derp (Caused Retrospring/bugs#41) 2015-04-30 05:34:43 +05:30
Yuki cc16afe49b Users get notified by anonymous questions they asked. Fixes Retrospring/bugs#21 2015-04-23 02:07:50 +05:30
Georg G 6be70374c8 fixes Retrospring/bugs#5 2015-04-21 16:53:59 +02:00
Yuki 1c485b20e9 Subscribe asker to the answer 2015-04-21 06:58:35 +05:30
Yuki ecffd07344 Support for post subscriptions 2015-04-21 06:42:11 +05:30
nilsding aec3e1c800 if a question was answered, all occurrences of it in the inbox are now gone 2015-01-03 19:02:56 +01:00
nilsding 8aee9bd69e added User#answer, moved some code from inbox.rb to answer.rb 2015-01-03 18:09:56 +01:00
nilsding fec91eeb5b before_destroy 2014-12-28 21:34:42 +01:00
nilsding b6c0b1864a moved some code 2014-12-28 21:20:07 +01:00
nilsding ab9347f053 notifications work now! 2014-12-14 14:34:51 +01:00
nilsding 027f2629b1 added smile model 2014-11-30 19:43:22 +01:00
nilsding ae66877cde changed a few things 2014-10-28 06:36:38 +01:00