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


PHP App_Form_Field类代码示例

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


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

示例1: __construct

 public function __construct($app)
 {
     $formfield = new App_Form_Field();
     //           $fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $month = $formfield->field('Select', 'month', '', '', 'mand required', '', true, '', '', '', '', '', 0, 0);
     $this->addElements(array($month));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:7,代码来源:Form.php

示例2: __construct

 public function __construct($accNum)
 {
     parent::__construct($accNum);
     $date = new ZendX_JQuery_Form_Element_DatePicker('date');
     $date->setAttrib('class', 'txt_put');
     $date->setJQueryParam('dateFormat', 'yy-mm-dd');
     $date->setRequired(true);
     $date->setAttrib('size', 12);
     $date1 = new ZendX_JQuery_Form_Element_DatePicker('date1');
     $date1->setAttrib('class', 'txt_put');
     $date1->setJQueryParam('dateFormat', 'yy-mm-dd');
     $date1->setRequired(true);
     $date1->setAttrib('size', 12);
     //$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $formfield = new App_Form_Field();
     $amount = $formfield->field('Text', 'amount', '', '', 'txt_put', '', true, '', '', '', '', '', 0, '');
     $graterthan = new Zend_Validate_GreaterThan(0);
     $amount->setRequired(true)->addValidators(array(array('NotEmpty'), array('Float'), array($graterthan, true)));
     $amount->setAttrib('size', 12);
     $description = $formfield->field('Textarea', 'description', '', '', 'txt_put', '', true, '', '', '', 2, 15, '', 0, '');
     $transactionMode = $formfield->field('Select', 'transactionMode', '', '', 'txt_put', '', true, '', '', '', '', '', 0, '');
     // hidden feilds
     $accNum = $formfield->field('Hidden', 'accNum', '', '', 'txt_put', '', true, '', '', '', '', '', 0, $accNum);
     $sms = new Zend_Form_Element_Checkbox('sms');
     $back = new Zend_Form_Element_Submit('Back');
     $submit = new Zend_Form_Element_Submit('Submit');
     $this->addElements(array($date, $amount, $transactionMode, $description, $submit, $accNum, $back, $sms, $date1));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:28,代码来源:Deposit.php

示例3: __construct

 public function __construct($id, $subId)
 {
     parent::__construct($id);
     //record id
     parent::__construct($subId);
     //module id
     //create a contact details form elements
     $vtype = array('Digits');
     $formfield = new App_Form_Field();
     $contactPerson = $formfield->field('Text', 'contact_person', '', '', 'mand', 'Contact person', true, '', '', '', '', '', 1, 0);
     $contactPerson->setAttrib('maxlength', 30);
     $telephone = $formfield->field('Text', 'telephone', '', '', 'mand', 'Telephone number', true, $vtype, '', '', '', '', 1, 0);
     $telephone->setAttrib('maxlength', 12);
     $mobile = $formfield->field('Text', 'mobile', '', '', 'mand', 'mobile', true, $vtype, 1, 15, '', '', 1, 0);
     $mobile->setAttrib('maxlength', 10);
     $email = $formfield->field('Text', 'email', '', '', 'mand', 'Email', true, '', '', '', '', '', 1, 0);
     $email->addValidator('EmailAddress');
     $email->addErrorMessage('Enter valid email address');
     //hidden feilds
     $id = $formfield->field('Hidden', 'id', '', '', '', '', false, '', '', '', '', '', 0, $id);
     $subId = $formfield->field('Hidden', 'submodule_id', '', '', '', '', false, '', '', '', '', '', 0, $subId);
     $createdBy = $formfield->field('Hidden', 'created_by', '', '', '', '', false, '', '', '', '', '', 0, 1);
     $createdDate = $formfield->field('Hidden', 'created_date', '', '', '', '', false, '', '', '', '', '', 0, date("y/m/d H:i:s"));
     $recordstatusId = $formfield->field('Hidden', 'recordstatus_id', '', '', '', '', false, '', '', '', '', '', 0, 3);
     $this->addElements(array($id, $contactPerson, $telephone, $mobile, $email, $subId, $createdBy, $createdDate));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:26,代码来源:contactdetails.php

示例4: __construct

 public function __construct($id, $subId)
 {
     parent::__construct($id, $subId);
     $formfield = new App_Form_Field();
     $cropId = new Zend_Form_Element_Select('crop_id[]');
     $cropId->setAttrib('class', 'txt_put');
     $cropId->setAttrib('id', 'crop_id[]');
     $season = new Zend_Form_Element_Select('season[]');
     $season->setAttrib('class', 'txt_put');
     $season->setAttrib('id', 'crop_id[]');
     // $cropId = $formfield->field('Select','crop_id[]','','','','',true,'','','','','',0,0);
     $acre = $formfield->field('Text', 'acre[]', '', '', '', '', true, '', '', '', '', '', 0, 0);
     $acre->setAttrib('size', 8);
     $quantity = $formfield->field('Text', 'quantity[]', '', '', '', '', true, '', '', '', '', '', 0, 0);
     $quantity->setAttrib('size', 12);
     $marketed = $formfield->field('Text', 'marketed[]', '', '', '', '', true, '', '', '', '', '', 0, 0);
     $marketed->setAttrib('size', 12);
     $price = $formfield->field('Text', 'price[]', '', '', '', '', true, '', '', '', '', '', 0, 0);
     //hidden feilds
     $id = $formfield->field('Hidden', 'id[]', '', '', '', '', false, '', '', '', '', '', 0, $id);
     $subId = $formfield->field('Hidden', 'submodule_id[]', '', '', '', '', false, '', '', '', '', '', 0, $subId);
     $createdBy = $formfield->field('Hidden', 'created_by[]', '', '', '', '', false, '', '', '', '', '', 0, 1);
     $createdDate = $formfield->field('Hidden', 'created_date[]', '', '', '', '', false, '', '', '', '', '', 0, date("y/m/d H:i:s"));
     $crpid = $formfield->field('Hidden', 'crpid[]', '', '', '', '', '', '', '', '', '', '', 0, 0);
     $this->addElements(array($id, $cropId, $acre, $quantity, $marketed, $price, $subId, $createdBy, $createdDate, $crpid, $season));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:26,代码来源:Crop.php

示例5: init

 public function init()
 {
     $formfield = new App_Form_Field();
     $field1 = new Zend_Form_Element_Select('field1');
     $field1->addMultiOption('', 'Select');
     $field1->setAttrib('size', '12');
     $field2 = new Zend_Form_Element_Text('field2');
     $field2->setAttrib('size', '12');
     $field3 = new Zend_Form_Element_Text('field3');
     $field3->setAttrib('size', '12');
     $field4 = $formfield->field('Text', '$field4', '', '', 'mand digits', '', false, '', '', '', '', '', 0, 0);
     // $field4 = new Zend_Form_Element_Text('field4');
     $field4->setAttrib('size', '12');
     $field5 = new Zend_Form_Element_Select('field5');
     $field5->addMultiOption('', 'Select');
     $field6 = new Zend_Form_Element_Text('field6');
     $field6->setAttrib('size', '12');
     $field7 = new ZendX_JQuery_Form_Element_DatePicker('field7');
     $field7->setAttrib('size', '12');
     $field8 = new ZendX_JQuery_Form_Element_DatePicker('field8');
     $field8->setAttrib('size', '12');
     $field9 = new Zend_Form_Element_Select('field9');
     $field9->addMultiOption('', 'Select');
     $field10 = new Zend_Form_Element_Select('field10');
     $field10->addMultiOption('', 'Select');
     $submit = new Zend_Form_Element_Submit('Search');
     $this->addElements(array($field1, $field2, $field3, $field4, $field5, $field6, $field7, $field8, $submit, $field9, $field10));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:28,代码来源:Search.php

示例6: init

 public function init()
 {
     $formfield = new App_Form_Field();
     $search_meeting_name_att = $formfield->field('Select', 'search_meeting_name_att', '', '', '', '', '', '', '', '', '', '', '', '');
     $search_meeting_date = $formfield->field('Text', 'search_meeting_date', '', '', '', '', '', '', '', '', '', '', '', '');
     $search_meeting_date->setAttrib('autocomplete', 'off');
     $this->addElements(array($search_meeting_name_att, $search_meeting_date));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:8,代码来源:Search.php

示例7: init

 public function init()
 {
     //$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $formfield = new App_Form_Field();
     $membercode = $formfield->field('Text', 'membercode', '', '', 'mand', '', true, '', '', '', '', '', 0, 0);
     $submit = $formfield->field('Submit', 'Submit', '', '', '', '', false, '', '', '', '', '', 0, 0);
     $this->addElements(array($membercode, $submit));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:8,代码来源:Search.php

示例8: init

 public function init()
 {
     // create instance for common form field
     $formfield = new App_Form_Field();
     // send required parameters to get respective form fields ( first parameter is a input type)
     $profession = $formfield->field('MultiCheckbox', 'profession', '', '', 'profid', '', false, '', '', '', '', '', 0, 0);
     $this->addElements(array($profession));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:8,代码来源:Familymembers.php

示例9: __construct

 public function __construct()
 {
     parent::__construct();
     // 	$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $formfield = new App_Form_Field();
     $remarks = $formfield->field('Textarea', 'remarks', '', '', 'mand', '', true, '', '', '', 3, 18, 1, 0);
     $this->addElements(array($remarks));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:8,代码来源:Delete.php

示例10: init

 public function init()
 {
     $vtype = array('Alpha', 'StringLength');
     $formfield = new App_Form_Field();
     // 	$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $name = $formfield->field('Text', 'membercode', '', '', 'mand', '', true, '', '', '', '', '', 0, 0);
     $this->addElements(array($name));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:8,代码来源:Familyform.php

示例11: init

 public function init()
 {
     //$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $formfield = new App_Form_Field();
     $groupcode = $formfield->field('Text', 'groupcode', '', '', 'mand', '', true, '', '', '', '', '', 0, 0);
     $groupcode->addValidator('digits')->addErrorMessage('Enter Numeric data');
     $submit = $formfield->field('Submit', 'Submit', '', '', '', '', false, '', '', '', '', '', 1, 0);
     $this->addElements(array($groupcode, $submit));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:9,代码来源:groupform.php

示例12: __construct

 public function __construct()
 {
     parent::__construct();
     //$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$decorator,$value
     $formfield = new App_Form_Field();
     //$vtype=array('Alpha');
     $datefrom = $formfield->field('Text', 'datefrom', '', '', 'mand', 'From date', true, '', '', '', '', '', 0, '');
     $this->addElements(array($datefrom));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:9,代码来源:Search.php

示例13: __construct

 public function __construct()
 {
     parent::__construct();
     //$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$decorator,$value
     $formfield = new App_Form_Field();
     $datefrom = $formfield->field('Select', 'glsubcode', '', '', 'mand', 'Sub ledger', true, '', '', '', '', '', 0, '');
     //add element to form
     $this->addElements(array($datefrom));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:9,代码来源:Search.php

示例14: init

 public function init()
 {
     $formfield = new App_Form_Field();
     $search_weekdays = $formfield->field('Select', 'search_weekdays', '', '', '', '', '', '', '', '', '', '', '', '');
     $search_meeting_name = $formfield->field('Text', 'search_meeting_name', '', '', '', '', '', '', '', '', '', '', '', '');
     $search_meeting_place = $formfield->field('Text', 'search_meeting_place', '', '', '', '', '', '', '', '', '', '', '', '');
     $search_group_name = $formfield->field('Text', 'search_group_name', '', '', '', '', '', '', '', '', '', '', '', '');
     $this->addElements(array($search_weekdays, $search_meeting_name, $search_meeting_place, $search_group_name));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:9,代码来源:Search.php

示例15: init

 public function init()
 {
     //create a object field
     //$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
     $formfield = new App_Form_Field();
     $gramapanchayat = $formfield->field('Select', 'gramapanchayat', '', '', 'mand', ' ', true, '', '', '', '', '', 0, '');
     $submit = new Zend_Form_Element_Submit('Search');
     //adding form elements
     $this->addElements(array($gramapanchayat, $submit));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:10,代码来源:Search.php


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