Compare commits
3 Commits
20309244f3
...
e17645a8f3
Author | SHA1 | Date |
---|---|---|
Luca | e17645a8f3 | |
Luca | 661fd5d83b | |
Luca | 207d03abeb |
|
@ -95,8 +95,6 @@ class Command(BaseCommand):
|
||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
self.stderr.write()
|
|
||||||
|
|
||||||
all_messages = set(messages)
|
all_messages = set(messages)
|
||||||
sent_messages = set()
|
sent_messages = set()
|
||||||
error = None
|
error = None
|
||||||
|
@ -104,16 +102,16 @@ class Command(BaseCommand):
|
||||||
for message in send(all_messages):
|
for message in send(all_messages):
|
||||||
sent_messages.add(message)
|
sent_messages.add(message)
|
||||||
|
|
||||||
self.stderr.write()
|
|
||||||
self.stderr.write(
|
self.stderr.write(
|
||||||
self.style.SUCCESS(
|
self.style.SUCCESS(
|
||||||
f"\r{str(len(sent_messages)).rjust(len(str(len(all_messages))))} / {len(all_messages)}"
|
f"\r{str(len(sent_messages)).rjust(len(str(len(all_messages))))} / {len(all_messages)}"
|
||||||
|
),
|
||||||
|
ending="",
|
||||||
)
|
)
|
||||||
)
|
|
||||||
self.stderr.write()
|
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
error = e
|
error = e
|
||||||
|
|
||||||
|
self.stderr.write()
|
||||||
self.stderr.write(
|
self.stderr.write(
|
||||||
self.style.WARNING(f"sent {len(sent_messages)} out of {len(all_messages)}")
|
self.style.WARNING(f"sent {len(sent_messages)} out of {len(all_messages)}")
|
||||||
)
|
)
|
||||||
|
|
|
@ -28,7 +28,9 @@ class Receiver(BaseReceiver):
|
||||||
class Sender(BaseSender):
|
class Sender(BaseSender):
|
||||||
def send(self, messages):
|
def send(self, messages):
|
||||||
for message in messages:
|
for message in messages:
|
||||||
logger.info(f"would send sms\nto: {message.recipient}\n\n{message.text}")
|
logger.info(
|
||||||
|
f"\nwould send sms\nto: {message.recipient}\n\n{message.text}\n"
|
||||||
|
)
|
||||||
yield message
|
yield message
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -41,17 +41,21 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{% if shift.event.fallbackassignment_set.count > 0 %}
|
||||||
|
<h5 class="subtitle">Teammitglieder</h5>
|
||||||
|
<div class="columns is-multiline">
|
||||||
|
{% for fallback in shift.event.fallbackassignment_set.all %}
|
||||||
<div class="column is-one-quarter">
|
<div class="column is-one-quarter">
|
||||||
<div class="box">
|
<div class="box{% if fallback.was_full %} has-text-grey" style="text-decoration: line-through;{% endif %}">
|
||||||
<div class="is-flex is-align-items-center is-justify-content-space-between mb-2">
|
{{ fallback.team_member.name }}
|
||||||
Teammitglieder: {%for e in shift.event.fallbackassignment_set.all%}{% if not e.was_full %}{{e.team_member.name}}, {% endif %}{%endfor%}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
|
{% endif %}
|
||||||
<h5 class="subtitle">Helfer*in eintragen</h5>
|
<h5 class="subtitle">Helfer*in eintragen</h5>
|
||||||
<form action="" method="post">
|
<form action="" method="post">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
|
|
Loading…
Reference in New Issue