Fix for billing downgrade with no new invoice created
This commit is contained in:
parent
5530142174
commit
8a52178765
|
@ -165,7 +165,13 @@ class BillingController extends Zend_Controller_Action {
|
||||||
Billing::addVatToInvoice($result["invoiceid"]);
|
Billing::addVatToInvoice($result["invoiceid"]);
|
||||||
}
|
}
|
||||||
|
|
||||||
self::viewInvoice($result["invoiceid"]);
|
// there may not be an invoice created if the client is downgrading
|
||||||
|
if (!empty($result["invoiceid"])) {
|
||||||
|
self::viewInvoice($result["invoiceid"]);
|
||||||
|
} else {
|
||||||
|
$this->_redirect('billing/invoices?planupdated');
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->view->form = $form;
|
$this->view->form = $form;
|
||||||
|
|
Loading…
Reference in New Issue