Arthri
(Arthri)
Dezembro 17, 2022, 3:30am
1
O TL0 conseguiu enviar uma mensagem para um grupo com “Quem pode enviar mensagens para este grupo?” definido como “Todos” por causa de um recurso implementado aqui
Is there any way to allow TL0 members to start messages to a specific discourse group, but not to other regular members or non staff members? I am currently not finding a way to make this work. When TL0 members write to our helpdeskteam group for help, they get an off putting and confusing error message - see below.
[18%20PM]
The TL0 user is writing to a group with “who can message this member” set to “everyone”. If I make the user TL1 the message is saved with no error.
Everyone in the group…
No entanto, isso não é mais possível por causa de uma atualização no último mês (nossa versão do fórum é 2.9.0.beta14). Acredito que este PR causou a regressão
main ← issue/can-send-pm-check-not-reliant-on-system-user
opened 05:41AM - 01 Nov 22 UTC
Since the system user is a regular user, it can have its `allow_private_messages… ` user option turned off, which with our current `can_send_private_message?(Discourse.system_user)` check inside the CurrentUserSerializer, will prevent any user from sending messages in the UI if the system user is not accepting PMs.
This commit adds a new `can_send_private_messages?` method to the Guardian, which can be used in serializers and not depend on the system user. When the user actually sends a message we still rely on the old `can_send_private_message?(target)` call to see if they are allowed to send the message to the target. The new method is just to say they can "generally" send private messages.
2 curtidas
martin
(Martin Brennan)
Dezembro 20, 2022, 3:11am
3
Obrigado pelo relatório @Arthri , isso foi corrigido aqui:
main ← issue/fix-messageable-everyone-regression-tl0
opened 01:14AM - 20 Dec 22 UTC
The commits https://github.com/discourse/discourse/commit/e62e93f83a77adfa80b38f… bfecf82bbee14e12fe and
https://github.com/discourse/discourse/commit/d6bd4ad7ee1d3bf43ba0a2bb1948f8f306b6177a caused a regression
to the behaviour added for
https://meta.discourse.org/t/allow-tl0-to-write-messages-to-staff-group-not-to-other-members-or-non-staff/124335,
which allowed a user to message a group with the messageable_level
set to Everyone even if they were TL0 (or otherwise did not reach
the appropriate trust level). This commit fixes the issue and adjusts
the spec to reflect the real scenario.
c.f. https://meta.discourse.org/t/tl0-cant-message-groups-with-messageable-level-everyone-recession/249205
2 curtidas
Este tópico foi fechado automaticamente após 25 horas. Novas respostas não são mais permitidas.