mirror of
https://github.com/neocities/neocities.git
synced 2025-06-29 07:33:26 +02:00
more work on comments for events
This commit is contained in:
parent
eba4a6e3f5
commit
b96730b83f
17 changed files with 2298 additions and 43 deletions
|
@ -6,6 +6,11 @@ class Event < Sequel::Model
|
|||
one_to_one :site_change
|
||||
many_to_one :profile_comment
|
||||
one_to_many :likes
|
||||
one_to_many :comments
|
||||
|
||||
def add_site_comment(site, message)
|
||||
add_comment actioning_site_id: site.id, message: message
|
||||
end
|
||||
|
||||
def site_likes?(site)
|
||||
likes_dataset.filter(actioning_site_id: site.id).count > 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue