Replace '$token' with login token in bulk messages
This commit is contained in:
parent
920de57f2b
commit
964de92b9d
|
@ -87,7 +87,13 @@ def bulk_message(request):
|
||||||
try:
|
try:
|
||||||
Message.objects.bulk_create(
|
Message.objects.bulk_create(
|
||||||
(
|
(
|
||||||
Message(text=form.cleaned_data["message"], to=helper)
|
Message(
|
||||||
|
text=form.cleaned_data["message"].replace(
|
||||||
|
"$token",
|
||||||
|
f"https://kontakt.rocks{helper.logintoken_set.first().get_absolute_url()}",
|
||||||
|
),
|
||||||
|
to=helper,
|
||||||
|
)
|
||||||
for helper in Helper.objects.filter(number_validated=True)
|
for helper in Helper.objects.filter(number_validated=True)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue