Merge branch 'cc-5709-airtime-analyzer-buy-now' into cc-5709-airtime-analyzer-buy-now-saas
This commit is contained in:
commit
51b7fe9adf
|
@ -174,6 +174,10 @@ class BillingController extends Zend_Controller_Action {
|
||||||
|
|
||||||
public function clientAction()
|
public function clientAction()
|
||||||
{
|
{
|
||||||
|
$CC_CONFIG = Config::getConfig();
|
||||||
|
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||||
|
$this->view->headLink()->appendStylesheet($baseUrl.'css/billing.css?'.$CC_CONFIG['airtime_version']);
|
||||||
|
|
||||||
$request = $this->getRequest();
|
$request = $this->getRequest();
|
||||||
$form = new Application_Form_BillingClient();
|
$form = new Application_Form_BillingClient();
|
||||||
BillingController::ensureClientIdIsValid();
|
BillingController::ensureClientIdIsValid();
|
||||||
|
@ -220,6 +224,10 @@ class BillingController extends Zend_Controller_Action {
|
||||||
|
|
||||||
public function invoicesAction()
|
public function invoicesAction()
|
||||||
{
|
{
|
||||||
|
$CC_CONFIG = Config::getConfig();
|
||||||
|
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||||
|
$this->view->headLink()->appendStylesheet($baseUrl.'css/billing.css?'.$CC_CONFIG['airtime_version']);
|
||||||
|
|
||||||
BillingController::ensureClientIdIsValid();
|
BillingController::ensureClientIdIsValid();
|
||||||
$credentials = self::getAPICredentials();
|
$credentials = self::getAPICredentials();
|
||||||
|
|
||||||
|
|
|
@ -8,6 +8,7 @@ class Application_Form_BillingClient extends Zend_Form
|
||||||
/*$this->setDecorators(array(
|
/*$this->setDecorators(array(
|
||||||
array('ViewScript', array('viewScript' => 'form/billing-purchase.phtml'))));*/
|
array('ViewScript', array('viewScript' => 'form/billing-purchase.phtml'))));*/
|
||||||
$client = BillingController::getClientDetails();
|
$client = BillingController::getClientDetails();
|
||||||
|
$this->setAttrib("id", "clientdetails_form");
|
||||||
|
|
||||||
$notEmptyValidator = Application_Form_Helper_ValidationTypes::overrideNotEmptyValidator();
|
$notEmptyValidator = Application_Form_Helper_ValidationTypes::overrideNotEmptyValidator();
|
||||||
$emailValidator = Application_Form_Helper_ValidationTypes::overrideEmailAddressValidator();
|
$emailValidator = Application_Form_Helper_ValidationTypes::overrideEmailAddressValidator();
|
||||||
|
|
|
@ -1,5 +1,10 @@
|
||||||
<div class="ui-widget ui-widget-content block-shadow clearfix padded-strong">
|
<?php
|
||||||
<H2>Account Details</H2>
|
$this->form->getElement("submit")->setAttrib("class", "right-align");
|
||||||
|
$this->form->getElement("country")->setAttrib("class", "right-align");
|
||||||
|
$this->form->getElement("securityqid")->setAttrib("class", "right-align");
|
||||||
|
?>
|
||||||
|
<div class="ui-widget ui-widget-content block-shadow clearfix padded-strong billing-panel">
|
||||||
|
<H2>Billing Account Details</H2>
|
||||||
<?php if (isset($this->errorMessage)) {?>
|
<?php if (isset($this->errorMessage)) {?>
|
||||||
<div class="errors"><?php echo $this->errorMessage ?></div>
|
<div class="errors"><?php echo $this->errorMessage ?></div>
|
||||||
<?php } else if (isset($this->successMessage)) {?>
|
<?php } else if (isset($this->successMessage)) {?>
|
||||||
|
|
|
@ -1,9 +1,22 @@
|
||||||
<div class="ui-widget ui-widget-content block-shadow clearfix padded-strong">
|
<div class="ui-widget ui-widget-content block-shadow clearfix padded-strong billing-panel">
|
||||||
|
<H2>Invoices</H2>
|
||||||
|
<p style="text-align: center;"><?=_("Tip: To pay an invoice, click \"View Invoice\"<br> and look for the \"Checkout\" button.")?></p>
|
||||||
|
<table id="invoices_table">
|
||||||
|
<tr class="header">
|
||||||
|
<th>Date Issued</th>
|
||||||
|
<th>Due Date</th>
|
||||||
|
<th>Link</th>
|
||||||
|
<th>Status</th>
|
||||||
|
</tr>
|
||||||
<?php
|
<?php
|
||||||
foreach ($this->invoices as $invoice) {?>
|
foreach ($this->invoices as $invoice) {?>
|
||||||
<div>
|
<tr>
|
||||||
<a href="invoice?invoiceid=<?php echo $invoice["id"]?>">View Invoice</a>
|
<td><?php echo $invoice["date"]?></td>
|
||||||
</div>
|
<td><?php echo $invoice["duedate"]?></td>
|
||||||
|
<td><a href="invoice?invoiceid=<?php echo $invoice["id"]?>">View Invoice</a></td>
|
||||||
|
<td class="<?=$invoice["status"]==="Unpaid" ? "unpaid" : "";?>"><?php echo $invoice["status"]?></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
<?php }?>
|
<?php };?>
|
||||||
|
</table>
|
||||||
</div>
|
</div>
|
|
@ -135,4 +135,55 @@
|
||||||
#upgrade-downgrade input[type=submit]
|
#upgrade-downgrade input[type=submit]
|
||||||
{
|
{
|
||||||
float: right;
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
#invoices_table
|
||||||
|
{
|
||||||
|
margin: 0 auto;
|
||||||
|
border-spacing: 0px;
|
||||||
|
border-collapse: separate;
|
||||||
|
border: 1px solid #777;
|
||||||
|
/*background-color: #555;*/
|
||||||
|
table-layout: fixed;
|
||||||
|
margin-top: 20px;
|
||||||
|
margin-bottom: 35px;
|
||||||
|
background: #ccc;
|
||||||
|
}
|
||||||
|
|
||||||
|
#invoices_table tbody tr th
|
||||||
|
{
|
||||||
|
border: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#invoices_table .header
|
||||||
|
{
|
||||||
|
box-shadow: 0px 2px 2px rgba(0,0,0,0.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
#invoices_table tr
|
||||||
|
{
|
||||||
|
border: 1px solid #555;
|
||||||
|
}
|
||||||
|
|
||||||
|
#invoices_table .unpaid
|
||||||
|
{
|
||||||
|
color: #ff0000;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** This form is the separate one on the Billing Account Details page (BillingClient.php) */
|
||||||
|
#clientdetails_form dt {
|
||||||
|
float: left;
|
||||||
|
clear: both;
|
||||||
|
width: 50%;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
#clientdetails_form dd {
|
||||||
|
float: left;
|
||||||
|
margin-left: 0px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
#clientdetails_form .right-align
|
||||||
|
{
|
||||||
|
/*text-align: right;*/
|
||||||
|
width: 100%;
|
||||||
}
|
}
|
Loading…
Reference in New Issue