当前位置: 首页>>代码示例>>PHP>>正文


PHP PersonPeer::getForSelectParent方法代码示例

本文整理汇总了PHP中PersonPeer::getForSelectParent方法的典型用法代码示例。如果您正苦于以下问题:PHP PersonPeer::getForSelectParent方法的具体用法?PHP PersonPeer::getForSelectParent怎么用?PHP PersonPeer::getForSelectParent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PersonPeer的用法示例。


在下文中一共展示了PersonPeer::getForSelectParent方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: configure

 public function configure()
 {
     unset($this['id'], $this['date_added'], $this['date_updated']);
     $affiliations = AffiliationPeer::getForSelectParent();
     $companies = CompanyPeer::getForSelectParent();
     $persons = PersonPeer::getForSelectParent();
     # Fields
     $this->widgetSchema['co_donor_id'] = new sfWidgetFormInput(array(), array('class' => 'text narrow'));
     $this->widgetSchema['affiliation_id'] = new sfWidgetFormChoice(array('choices' => $affiliations));
     $this->widgetSchema['block_mailings'] = new sfWidgetFormInputCheckbox(array(), array('value' => 1));
     $this->widgetSchema['prospect_comment'] = new sfWidgetFormTextarea(array(), array('class' => 'text'));
     $this->widgetSchema['salutation'] = new sfWidgetFormInput(array(), array('class' => 'text'));
     $this->widgetSchema['company_id'] = new sfWidgetFormChoice(array('choices' => $companies));
     $this->widgetSchema['position'] = new sfWidgetFormInput(array(), array('class' => 'text'));
     $this->widgetSchema['donor_potential'] = new sfWidgetFormInput(array(), array('class' => 'text'));
     $this->widgetSchema['person_id'] = new sfWidgetFormChoice(array('choices' => $persons));
     $this->widgetSchema->setLabels(array('co_donor_id' => 'Co Donor Id'));
     $this->widgetSchema->setLabels(array('affiliation_id' => 'Affiliation Id'));
     $this->widgetSchema->setLabels(array('block_mailings' => 'Block mailings'));
     $this->widgetSchema->setLabels(array('prospect_comment' => 'Prospect comment'));
     $this->widgetSchema->setLabels(array('salutation' => 'Salutation'));
     $this->widgetSchema->setLabels(array('company_id' => 'Company'));
     $this->widgetSchema->setLabels(array('position' => 'Position'));
     $this->widgetSchema->setLabels(array('donor_potential' => 'Donor potential'));
     $this->widgetSchema->setLabels(array('person_id' => 'Person'));
     $this->validatorSchema['co_donor_id'] = new sfValidatorInteger(array('required' => false), array('invalid' => 'Co donor id must be in number format !'));
     $this->validatorSchema['affiliation_id'] = new sfValidatorInteger(array('required' => false));
     $this->validatorSchema['block_mailings'] = new sfValidatorInteger(array('required' => false));
     $this->validatorSchema['prospect_comment'] = new sfValidatorString(array('required' => false));
     $this->validatorSchema['salutation'] = new sfValidatorString(array('required' => false));
     $this->validatorSchema['company_id'] = new sfValidatorInteger(array('required' => false));
     $this->validatorSchema['position'] = new sfValidatorString(array('required' => false));
     $this->validatorSchema['donor_potential'] = new sfValidatorInteger(array('required' => false), array('invalid' => 'Donor porential must be in number format !'));
     $this->validatorSchema['person_id'] = new sfValidatorInteger(array('required' => false));
     $this->widgetSchema->setNameFormat('donor[%s]');
 }
开发者ID:yasirgit,项目名称:afids,代码行数:36,代码来源:DonorForm.class.php


注:本文中的PersonPeer::getForSelectParent方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。