Made internal billing report email compatible with Openproject
This commit is contained in:
@@ -12,14 +12,20 @@
|
||||
$billing_start = strtotime("+".$op->billing_delay." months");
|
||||
}
|
||||
|
||||
|
||||
|
||||
$subject = "";
|
||||
if($order->upgrade) {
|
||||
$subject .= "[UPGRADE] ";
|
||||
}
|
||||
$subject .= $order->terminations[0]->building->network->name." - "
|
||||
/*$subject .= $order->terminations[0]->building->network->name." - "
|
||||
."Verr. ab ".date("m", $billing_start)."/".date("Y", $billing_start)." - "
|
||||
.$order->owner->customer_number." - "
|
||||
.str_replace("\n", "", str_replace("\r\n", " ", $order->owner->getCompanyOrName()));
|
||||
*/
|
||||
$subject .= "Verr. ab ".date("m/Y", $billing_start)." - "
|
||||
.$order->owner->customer_number." - "
|
||||
.str_replace("\n", "", str_replace("\r\n", " ", $order->owner->getCompanyOrName()));
|
||||
|
||||
$this->setReturnValue([
|
||||
'subject' => $subject,
|
||||
@@ -34,13 +40,24 @@
|
||||
Achtung: UPGRADE
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
project: verrechnung
|
||||
type: Verrechnung
|
||||
status: Neu
|
||||
priority: Standard
|
||||
start date: <?=date("Y-m-01", $billing_start)?>
|
||||
|
||||
due date: <?=date("Y-m-01", $billing_start)?>
|
||||
|
||||
Kundennummer: <?=$order->owner->customer_number?>
|
||||
|
||||
Kundenname: <?=str_replace("\n", "", str_replace("\r\n", " ", $order->owner->getCompanyOrName()))?>
|
||||
|
||||
Telefon: <?=$order->owner->phone?>
|
||||
|
||||
Netzgebiet: <?=$order->terminations[0]->building->network->name?>
|
||||
|
||||
Bauabschnitt: <?=(($order->terminations[0]->building->networksection_id) ? $order->terminations[0]->building->networksection->name : "<kein Bauabschnitt>")?>
|
||||
|
||||
Kundennummer: <?=$order->owner->customer_number?>
|
||||
|
||||
Kunde: <?=str_replace("\n", "", str_replace("\r\n", " ", $order->owner->getCompanyOrName()))?>
|
||||
|
||||
Verrechungsstart: <?=date("m", $billing_start)?>/<?=date("Y", $billing_start)?>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user