Projects
Kolab:16:Enterprise
kolab-hkccp
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 14
View file
kolab-hkccp.spec
Changed
@@ -3,7 +3,7 @@ %endif Name: kolab-hkccp -Version: 0.7.23 +Version: 0.7.24 Release: 1%{?dist} Summary: Hosted Kolab Customer Control Panel License: AGPLv3+ @@ -104,6 +104,9 @@ %attr(0770,apache,apache) %{_var}/log/%{name} %changelog +* Wed Apr 17 2019 Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> - 0.7.24-1 +- Release of version 0.7.24 + * Fri Oct 5 2018 Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> - 0.7.23-1 - Release of version 0.7.23
View file
kolab-hkccp-0.7.23.tar.gz/composer.phar -> kolab-hkccp-0.7.24.tar.gz/composer.phar
Changed
View file
kolab-hkccp-0.7.23.tar.gz/lib/Kolab/Hosted/Controller/BackendController.php -> kolab-hkccp-0.7.24.tar.gz/lib/Kolab/Hosted/Controller/BackendController.php
Changed
@@ -201,6 +201,7 @@ // replacement variables for mail texts $replace = array( + 'invoiceno' => $invoice->invoiceno, // some localization labels use 'no', some 'invoiceno' variable 'no' => $invoice->invoiceno, 'total' => $this->currency($invoice->totalgross), 'domain' => $user->domain, @@ -1062,6 +1063,12 @@ return true; } + // Encode subject, it might be non-ascii when localizaed + $orig_subject = $headers['Subject']; + if (preg_match('/[^\x20-\x7F]/', $orig_subject)) { + $headers['Subject'] = '=?UTF-8?B?' . base64_encode($orig_subject) . '?='; + } + Log::trace("Sending mail to $mailto", $body); $mail = \Mail::factory($this->config->get('mail.driver', 'mail')); @@ -1078,6 +1085,7 @@ if (!empty($user_id)) { $log = $headers; + $log['Subject'] = $orig_subject; $log['BODY'] = $body; $log['SUCCESS'] = $success;
View file
kolab-hkccp-0.7.23.tar.gz/lib/Kolab/Hosted/Controller/FrontendController.php -> kolab-hkccp-0.7.24.tar.gz/lib/Kolab/Hosted/Controller/FrontendController.php
Changed
@@ -362,6 +362,12 @@ return true; } + // Encode subject, it might be non-ascii when localizaed + $orig_subject = $headers['Subject']; + if (preg_match('/[^\x20-\x7F]/', $orig_subject)) { + $headers['Subject'] = '=?UTF-8?B?' . base64_encode($orig_subject) . '?='; + } + Log::trace("Sending mail to $mailto", $body); $mail = \Mail::factory($this->config->get('mail.driver', 'mail')); @@ -377,7 +383,8 @@ } $log = $headers; - $log['BODY'] = $body; + $log['Subject'] = $orig_subject; + $log['BODY'] = $body; $log['SUCCESS'] = $success; Audit::log($this->user->ID, $mailto, 'sendmail', $log);
View file
kolab-hkccp-0.7.23.tar.gz/lib/Kolab/Hosted/Model/Invoice.php -> kolab-hkccp-0.7.24.tar.gz/lib/Kolab/Hosted/Model/Invoice.php
Changed
@@ -244,10 +244,12 @@ } $item_ids = $result['items']; + $periodic = $result['refundable_count'] > 0; unset($result['items']); + unset($result['refundable_count']); // get last (periodic) invoice - if ($result['refundable_total'] > 0) { + if ($periodic) { $lastinvoice = new Invoice(array( 'status !=' => Invoice::STATUS_CANCELLED, 'account' => $account->ID, @@ -255,6 +257,21 @@ 'ORDER BY ID DESC LIMIT 1' )); + if (!$lastinvoice->count()) { + // use account creation date for first invoicing period + $period_start = clone $account->created; + + // For "free" accounts (discount=100%) we have to make sure + // there's no existing "periodic" invoice, if there is we'll + // use proper period start + $lastinvoice = new Invoice(array( + 'status' => Invoice::STATUS_PAID, + 'account' => $account->ID, + "AND period_start <> period_end", + "ORDER BY ID DESC LIMIT 1" + )); + } + if ($lastinvoice->count()) { $period_start = new \DateTime('now'); if ($lastinvoice->period_end < $period_start) { @@ -262,10 +279,6 @@ $period_start->add(new \DateInterval('P1D')); } } - else { - // use account creation date for first invoicing period - $period_start = clone $account->created; - } $interval = new \DateInterval('P'. intval($paymentplan['factor'] ?: 1) . 'M'); $period_end = clone $period_start; @@ -416,7 +429,7 @@ */ public static function calculate_items($items, $account, $paymentplan) { - $o_total = $r_total = $c_total = 0; + $o_total = $r_total = $c_total = $r_count = 0; $last_created = null; $discount_records = array(); $item_ids = array(); @@ -482,13 +495,15 @@ } $r_total += $item->amount; + $r_count++; } else { $o_total += $item->amount; } - if (!$last_created || $item->created < $last_created) + if (!$last_created || $item->created < $last_created) { $last_created = clone $item->created; + } } } @@ -614,6 +629,7 @@ 'totalgross' => $totalgross, 'vat' => $vat, 'refundable_total' => $r_total, + 'refundable_count' => $r_count, ); }
View file
kolab-hkccp-0.7.23.tar.gz/public_html/skins/ilovefs/templates/billing.print.html -> kolab-hkccp-0.7.24.tar.gz/public_html/skins/ilovefs/templates/billing.print.html
Changed
@@ -269,11 +269,11 @@ {% endif %} <footer> - Kolab Now, a service by Kolab Systems AG, Weinmanngasse 88, 8700 Küsnacht ZH, Switzerland | + Kolab Now, a service by Kolab Systems AG, Schulhausstrasse 47, 8703 Erlenbach ZH, Switzerland | <a href="mailto:contact@kolabnow.com">contact@kolabnow.com</a> <br> Trade Register No: CH-020.3.034.895-4 | VAT No: 748 699 {% if user.attribute('paymentplan') == 'annual' %} | IBAN: {{ config.payment.banktransfer.iban }} {% endif %} </footer> </body> -</html> \ No newline at end of file +</html>
View file
kolab-hkccp-0.7.23.tar.gz/public_html/skins/ilovefs/templates/layout.html -> kolab-hkccp-0.7.24.tar.gz/public_html/skins/ilovefs/templates/layout.html
Changed
@@ -191,7 +191,7 @@ <div id="copyright-block" class="block block-block"> <div class="block-content"> <div> - Kolab Systems AG, Weinmanngasse 88, 8700 Kuesnacht ZH, Switzerland.<br/>Trade register no: CH-020.3.034.895-4. VAT no: 748 699 + Kolab Systems AG, Schulhausstrasse 47, 8703 Erlenbach ZH, Switzerland.<br/>Trade register no: CH-020.3.034.895-4. VAT no: 748 699 </div> </div> </div><!-- /.block -->
View file
kolab-hkccp-0.7.23.tar.gz/public_html/skins/kolabnow/templates/billing.print.html -> kolab-hkccp-0.7.24.tar.gz/public_html/skins/kolabnow/templates/billing.print.html
Changed
@@ -269,11 +269,11 @@ {% endif %} <footer> - Kolab Now, a service by Kolab Systems AG, Weinmanngasse 88, 8700 Küsnacht ZH, Switzerland | + Kolab Now, a service by Kolab Systems AG, Schulhausstrasse 47, 8703 Erlenbach ZH, Switzerland | <a href="mailto:contact@kolabnow.com">contact@kolabnow.com</a> <br> Trade Register No: CH-020.3.034.895-4 | VAT No: 748 699 {% if user.attribute('paymentplan') == 'annual' %} | IBAN: {{ config.payment.banktransfer.iban }} {% endif %} </footer> </body> -</html> \ No newline at end of file +</html>
View file
kolab-hkccp-0.7.23.tar.gz/public_html/skins/kolabnow/templates/layout.html -> kolab-hkccp-0.7.24.tar.gz/public_html/skins/kolabnow/templates/layout.html
Changed
@@ -191,7 +191,7 @@ <div id="copyright-block" class="block block-block"> <div class="block-content"> <div> - Kolab Systems AG, Weinmanngasse 88, 8700 Kuesnacht ZH, Switzerland.<br/>Trade register no: CH-020.3.034.895-4. VAT no: 748 699 + Kolab Systems AG, Schulhausstrasse 47, 8703 Erlenbach ZH, Switzerland.<br/>Trade register no: CH-020.3.034.895-4. VAT no: 748 699 </div> </div> </div><!-- /.block -->
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.