<?php
/**
  * Ahead WebSoft Technologies Pvt Ltd.
  * @copyright  Copyright 2006-2026 Ahead WebSoft Technologies Pvt Ltd.
  * @license    https://www.socialengine.com/policies
*/
class User_Form_Settings_Delete extends Engine_Form
{
  public function init()
  {
    $this
      ->setTitle('Delete Account')
      ->setDescription('Are you sure you want to delete your account? Any content '.
        'you\'ve uploaded in the past will be permanently deleted. You will be '.
        'immediately signed out and will no longer be able to sign in with this account.')
      ->setAction(Zend_Controller_Front::getInstance()->getRouter()->assemble(array()))
      ;

    // Element: token
    $this->addElement('Hash', 'token');
    
    // Init submit
    $this->addElement('Button', 'execute', array(
      'label' => 'Yes, Delete My Account',
      'type' => 'submit',
      'ignore' => true,
      // 'data-bs-target' => "#user_signup_email",
      // 'data-bs-toggle' => 'modal',
      'decorators' => array(
        'ViewHelper',
      ),
    ));

    // Element: cancel
    $this->addElement('Cancel', 'cancel', array(
      'label' => 'cancel',
      'link' => true,
      'prependText' => ' or ',
      'decorators' => array(
        'ViewHelper',
      ),
    ));
    
    // DisplayGroup: buttons
    $this->addDisplayGroup(array(
      'execute',
      'cancel',
    ), 'buttons');
    
    $this->addElement('Button', 'submit_signup', array(
      'label' => 'Continue',
      'type' => 'submit',
      'ignore' => true,
    ));
    return $this;
  }
}
