Select current plan and show that correctly

This commit is contained in:
Albert Santoni 2014-06-27 15:50:05 -04:00
parent 2504a34818
commit 3357c1f032
4 changed files with 73 additions and 55 deletions

View file

@ -17,14 +17,16 @@ class Application_Form_BillingUpgradeDowngrade extends Zend_Form
$pid->setLabel(_('Plan type:'))
->setMultiOptions($productTypes)
->setRequired(true)
->setValue(26);
->setValue(BillingController::getClientCurrentAirtimeProduct()["pid"]);
$this->addElement($pid);
Logging::info(BillingController::getClientCurrentAirtimeProduct());
$billingcycle = new Zend_Form_Element_Radio('newproductbillingcycle');
$billingcycle->setLabel(_('Billing cycle:'))
->setMultiOptions(array('monthly' => 'Monthly', 'annually' => 'Annually'))
->setRequired(true)
->setValue('monthly');
->setValue(BillingController::getClientCurrentAirtimeProduct()["billingcycle"]);
$this->addElement($billingcycle);
$paymentmethod = new Zend_Form_Element_Radio('paymentmethod');