|
|
@ -164,7 +164,14 @@ class HelperDetail(FormMixin, LoginRequiredMixin, DetailView):
|
|
|
|
|
|
|
|
|
|
|
|
form = self.get_form()
|
|
|
|
form = self.get_form()
|
|
|
|
if form.is_valid():
|
|
|
|
if form.is_valid():
|
|
|
|
Message(text=form.cleaned_data["message"], to=self.object).save()
|
|
|
|
IncomingMessage.objects.filter(sender=self.object.phone).update(read=True)
|
|
|
|
|
|
|
|
Message(
|
|
|
|
|
|
|
|
text=form.cleaned_data["message"].replace(
|
|
|
|
|
|
|
|
"$token",
|
|
|
|
|
|
|
|
f"https://helfen.kntkt.de{self.object.logintoken_set.first().get_absolute_url()}",
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
to=self.object,
|
|
|
|
|
|
|
|
).save()
|
|
|
|
|
|
|
|
|
|
|
|
return self.render_to_response(self.get_context_data(form=form))
|
|
|
|
return self.render_to_response(self.get_context_data(form=form))
|
|
|
|
|
|
|
|
|
|
|
|