aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perllib/FixMyStreet/Cobrand/ZeroTB.pm13
-rw-r--r--templates/email/zerotb/alert-update.txt9
2 files changed, 22 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/Cobrand/ZeroTB.pm b/perllib/FixMyStreet/Cobrand/ZeroTB.pm
index c774610c4..32d14d0f6 100644
--- a/perllib/FixMyStreet/Cobrand/ZeroTB.pm
+++ b/perllib/FixMyStreet/Cobrand/ZeroTB.pm
@@ -29,6 +29,7 @@ sub allow_photo_upload{ return 0; }
sub send_questionnaires { return 0; }
sub on_map_default_max_pin_age { return 0; }
sub never_confirm_updates { 1; }
+sub include_time_in_update_alerts { 1; }
sub get_clinic_list {
my $self = shift;
@@ -36,5 +37,17 @@ sub get_clinic_list {
return $self->problems->search({ state => 'confirmed' }, { order_by => 'title' });
}
+sub prettify_dt {
+ my ( $self, $dt, $type ) = @_;
+ $type ||= '';
+
+ if ( $type eq 'alert' ) {
+ return $dt->strftime('%H:%M %Y-%m-%d');
+ } else {
+ return Utils::prettify_dt( $dt, $type );
+ }
+
+}
+
1;
diff --git a/templates/email/zerotb/alert-update.txt b/templates/email/zerotb/alert-update.txt
new file mode 100644
index 000000000..ee32524f9
--- /dev/null
+++ b/templates/email/zerotb/alert-update.txt
@@ -0,0 +1,9 @@
+Subject: New stockout report for Clinic - '<?=$values['title']?>'
+
+The following stockouts have been reported for this clinic:
+
+<?=$values['data']?>
+
+You cannot contact anyone by replying to this email.
+
+<?=$values['signature']?>