mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-29 23:36:22 +00:00
Merge branch 'issue-15109-1' of https://0xacab.org/sutty/sutty into production.panel.sutty.nl
This commit is contained in:
commit
8a8c1b7d81
6 changed files with 24 additions and 20 deletions
|
@ -20,6 +20,8 @@ class ActivityPub
|
|||
has_one :object, through: :activity_pub
|
||||
|
||||
validates :activity_pub_id, presence: true
|
||||
# Las actividades son únicas con respecto a su estado
|
||||
validates :uri, presence: true, uniqueness: { scope: :activity_pub_id, message: 'estado duplicado' }
|
||||
|
||||
# Siempre en orden descendiente para saber el último estado
|
||||
default_scope -> { order(created_at: :desc) }
|
||||
|
|
|
@ -15,6 +15,9 @@ class ActivityPub
|
|||
has_many :activities
|
||||
has_many :remote_flags
|
||||
|
||||
# Les actores son únicxs a toda la base de datos
|
||||
validates :uri, presence: true, uniqueness: true
|
||||
|
||||
# Obtiene el nombre de la Actor como mención, solo si obtuvimos el
|
||||
# contenido de antemano.
|
||||
#
|
||||
|
|
|
@ -6,8 +6,6 @@ class ActivityPub
|
|||
extend ActiveSupport::Concern
|
||||
|
||||
included do
|
||||
validates :uri, presence: true, uniqueness: true
|
||||
|
||||
# Cuando asignamos contenido, obtener la URI si no lo hicimos ya
|
||||
before_save :uri_from_content!, unless: :uri?
|
||||
|
||||
|
|
|
@ -5,6 +5,9 @@ class ActivityPub
|
|||
class Object < ApplicationRecord
|
||||
include ActivityPub::Concerns::JsonLdConcern
|
||||
|
||||
# Los objetos son únicos a toda la base de datos
|
||||
validates :uri, presence: true, uniqueness: true
|
||||
|
||||
has_many :activity_pubs, as: :object
|
||||
|
||||
# Encontrar le Actor por su relación con el objeto
|
||||
|
|
|
@ -50,6 +50,14 @@ en:
|
|||
pm: pm
|
||||
format: '%-I:%M %p'
|
||||
components:
|
||||
actor:
|
||||
user: Username
|
||||
profile: Profile
|
||||
profile_name: Profile name
|
||||
preferred_name: Name in Fediverse
|
||||
profile_id: ID
|
||||
profile_published: Published
|
||||
profile_summary: Summary
|
||||
block_list:
|
||||
know_more: Know more
|
||||
instances_blocked: Instances blocked
|
||||
|
@ -107,15 +115,6 @@ en:
|
|||
text_allow: Always approve
|
||||
text_block: Block
|
||||
text_report: Report
|
||||
actor_moderations:
|
||||
show:
|
||||
user: Username
|
||||
profile: Profile
|
||||
profile_name: Profile name
|
||||
preferred_name: Name in Fediverse
|
||||
profile_id: ID
|
||||
profile_published: Published
|
||||
profile_summary: Summary
|
||||
remote_flags:
|
||||
report_message: "Hi! Someone using Sutty CMS reported this account on your instance. We don't have support for customized report messages yet, but we will soon. You can reach us at %{panel_actor_mention}."
|
||||
moderation_queue:
|
||||
|
|
|
@ -50,6 +50,14 @@ es:
|
|||
pm: pm
|
||||
format: '%-H:%M'
|
||||
components:
|
||||
actor:
|
||||
user: Nombre de usuarie
|
||||
profile: Cuenta de Origen
|
||||
profile_name: Nombre de la cuenta
|
||||
preferred_name: Nombre en el Fediverso
|
||||
profile_id: ID
|
||||
profile_published: Publicada
|
||||
profile_summary: Presentación
|
||||
block_list:
|
||||
know_more: Saber más (en inglés)
|
||||
instances_blocked: Instancias bloqueadas
|
||||
|
@ -106,15 +114,6 @@ es:
|
|||
text_allow: Aprobar siempre
|
||||
text_block: Bloquear
|
||||
text_report: Reportar
|
||||
actor_moderations:
|
||||
show:
|
||||
user: Nombre de usuarie
|
||||
profile: Cuenta de Origen
|
||||
profile_name: Nombre de la cuenta
|
||||
preferred_name: Nombre en el Fediverso
|
||||
profile_id: ID
|
||||
profile_published: Publicada
|
||||
profile_summary: Presentación
|
||||
remote_flags:
|
||||
report_message: "¡Hola! Une usuarie de Sutty CMS reportó esta cuenta en tu instancia. Todavía no tenemos soporte para mensajes personalizados. Podés contactarnos en %{panel_actor_mention}."
|
||||
moderation_queue:
|
||||
|
|
Loading…
Reference in a new issue