BaseLinksTableForm.class.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. /**
  3. * LinksTable form base class.
  4. *
  5. * @package usic
  6. * @subpackage form
  7. * @author Your name here
  8. * @version SVN: $Id: sfPropelFormGeneratedTemplate.php 15484 2009-02-13 13:13:51Z fabien $
  9. */
  10. class BaseLinksTableForm extends BaseFormPropel
  11. {
  12. public function setup()
  13. {
  14. $this->setWidgets(array(
  15. 'id' => new sfWidgetFormInputHidden(),
  16. 'module_name' => new sfWidgetFormTextarea(),
  17. 'action_name' => new sfWidgetFormTextarea(),
  18. 'name' => new sfWidgetFormTextarea(),
  19. 'created_at' => new sfWidgetFormDateTime(),
  20. ));
  21. $this->setValidators(array(
  22. 'id' => new sfValidatorPropelChoice(array('model' => 'LinksTable', 'column' => 'id', 'required' => false)),
  23. 'module_name' => new sfValidatorString(),
  24. 'action_name' => new sfValidatorString(),
  25. 'name' => new sfValidatorString(),
  26. 'created_at' => new sfValidatorDateTime(),
  27. ));
  28. $this->widgetSchema->setNameFormat('links_table[%s]');
  29. $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);
  30. parent::setup();
  31. }
  32. public function getModelName()
  33. {
  34. return 'LinksTable';
  35. }
  36. }