CC-2718: Changes to the support page
- stroing and retreving new value "privact" to DB - Displaying "Terms and Condition" link when user agrees it
This commit is contained in:
parent
6c2f94dec7
commit
3e3391dfba
8 changed files with 86 additions and 44 deletions
|
@ -5,8 +5,8 @@ class Application_Form_SupportSettings extends Zend_Form
|
|||
|
||||
public function init()
|
||||
{
|
||||
$country_list = Application_Model_Preference::GetCountryList();
|
||||
|
||||
$country_list = Application_Model_Preference::GetCountryList();
|
||||
|
||||
$this->setDecorators(array(
|
||||
array('ViewScript', array('viewScript' => 'form/support-setting.phtml')),
|
||||
array('File', array('viewScript' => 'form/support-setting.phtml', 'placement' => false)))
|
||||
|
@ -161,10 +161,12 @@ class Application_Form_SupportSettings extends Zend_Form
|
|||
public function isValid ($data)
|
||||
{
|
||||
$isValid = parent::isValid($data);
|
||||
$checkPrivacy = $this->getElement('Privacy');
|
||||
if($data["SupportFeedback"] == "1" && $data["Privacy"] != "1"){
|
||||
$checkPrivacy->addError("You have to agree to privacy policy.");
|
||||
$isValid = false;
|
||||
if(isset($data["Privacy"])){
|
||||
$checkPrivacy = $this->getElement('Privacy');
|
||||
if($data["SupportFeedback"] == "1" && $data["Privacy"] != "1"){
|
||||
$checkPrivacy->addError("You have to agree to privacy policy.");
|
||||
$isValid = false;
|
||||
}
|
||||
}
|
||||
return $isValid;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue