4
* agGeo form base class.
6
* @method agGeo getObject() Returns the current form's model object
11
* @version SVN: $Id: sfDoctrineFormGeneratedTemplate.php 29553 2010-05-20 14:33:00Z Kris.Wallsmith $
13
abstract class BaseagGeoForm extends BaseFormDoctrine
15
public function setup()
17
$this->setWidgets(array(
18
'id' => new sfWidgetFormInputHidden(),
19
'geo_type_id' => new sfWidgetFormDoctrineChoice(array('model' => $this->getRelatedModelName('agGeoType'), 'add_empty' => false)),
20
'geo_source_id' => new sfWidgetFormDoctrineChoice(array('model' => $this->getRelatedModelName('agGeoSource'), 'add_empty' => false)),
21
'created_at' => new sfWidgetFormDateTime(),
22
'updated_at' => new sfWidgetFormDateTime(),
25
$this->setValidators(array(
26
'id' => new sfValidatorChoice(array('choices' => array($this->getObject()->get('id')), 'empty_value' => $this->getObject()->get('id'), 'required' => false)),
27
'geo_type_id' => new sfValidatorDoctrineChoice(array('model' => $this->getRelatedModelName('agGeoType'))),
28
'geo_source_id' => new sfValidatorDoctrineChoice(array('model' => $this->getRelatedModelName('agGeoSource'))),
29
'created_at' => new sfValidatorDateTime(),
30
'updated_at' => new sfValidatorDateTime(),
33
$this->widgetSchema->setNameFormat('ag_geo[%s]');
35
$this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);
37
$this->setupInheritance();
42
public function getModelName()
b'\\ No newline at end of file'