public function _buildSchema(Schema $schema) { $schema->addField('nome', 'string'); $schema->addField('email', 'string'); $schema->addField('mensagem', 'text'); return $schema; }
public static function getForm(string $tabId = null) : Form { $schema = new Schema(); $settings = self::getSettings($tabId); /** @var $v \ThreeCMS\Core\Settings\Setting **/ foreach ($settings as $v) { $schema->addField($v->getKey(), ['type' => 'text']); } $form = new Form(); $form->validator(self::getValidator($tabId)); $form->schema($schema); return $form; }
/** * Build form schema * * @param \Cake\Form\Schema $schema Schema * @return \Cake\Form\Schema */ protected function _buildSchema(Schema $schema) { return $schema->addField('current_password', ['type' => 'password'])->addField('new_password', ['type' => 'password'])->addField('confirm_new_password', ['type' => 'password']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('osm_section', 'int'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('scoutgroup', 'integer')->addField('email', 'varchar'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('cubs', 'integer')->addField('yls', 'integer')->addField('leaders', 'integer'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('email', ['type' => 'string']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('searchWhat', ['type' => 'string'])->addField('searchField', ['type' => 'string']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('assunto', 'string')->addField('corpo', ['type' => 'text']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('newpw', ['type' => 'string'])->addField('confirm', ['type' => 'string'])->addField('postcode', ['type' => 'string']); }
/** * test __debugInfo * * @return void */ public function testDebugInfo() { $schema = new Schema(); $schema->addField('name', 'string')->addField('numbery', ['type' => 'decimal', 'required' => true]); $result = $schema->__debugInfo(); $expected = ['_fields' => ['name' => ['type' => 'string', 'length' => null, 'precision' => null], 'numbery' => ['type' => 'decimal', 'length' => null, 'precision' => null]]]; $this->assertEquals($expected, $result); }
protected function _buildSchema(Schema $schema) { return $schema->addField('firstname', 'string')->addField('lastname', 'string')->addField('email', ['type' => 'email'])->addField('website', ['type' => 'string'])->addField('phone', ['type' => 'tel']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('osm_email', 'string')->addField('osm_password', 'string'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('name', 'string')->addField('description', ['type' => 'string']); }
/** * test fieldType * * @return void */ public function testFieldType() { $schema = new Schema(); $schema->addField('name', 'string')->addField('numbery', ['type' => 'decimal', 'required' => true]); $this->assertEquals('string', $schema->fieldType('name')); $this->assertEquals('decimal', $schema->fieldType('numbery')); $this->assertNull($schema->fieldType('nope')); }
protected function _buildSchema(Schema $schema) { return $schema->addField('id', 'integer')->addField('qte', ['type' => 'integer']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('agree1', 'boolean')->addField('agree2', 'boolean'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('link', 'string'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('name', ['type' => 'string', 'length' => 40])->addField('email', ['type' => 'string', 'length' => 50])->addField('subject', ['type' => 'string', 'length' => 60])->addField('body', ['type' => 'text']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('id', 'int'); return $schema->addField('controller', 'int'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('firstname', 'string')->addField('lastname', 'string')->addField('position', 'string')->addField('company', 'string')->addField('email', ['type' => 'email'])->addField('phone', ['type' => 'tel'])->addField('info', ['type' => 'select'])->addField('message', ['type' => 'text']); }
/** * Defines virtual schema for model-less form fields. * * @param Cake\Form\Schema $schema Instance of Schema * @return Cake\Form\Schema */ protected function _buildSchema(Schema $schema) { return $schema->addField('url', 'string')->addField('webroot', ['type' => 'string'])->addField('force', ['type' => 'boolean']); }
/** * The schema definition for the fields of this form. * * @param Schema $schema The schema to customize. * @return $this */ protected function _buildSchema(Schema $schema) { return $schema->addField('name', 'string')->addField('email', 'string')->addField('subject', 'string')->addField('message', 'text'); }
protected function _buildSchema(Schema $schema) { return $schema->addField('name', 'string')->addField('email', ['type' => 'string'])->addField('body', ['type' => 'text']); }
protected function _buildSchema(Schema $schema) { return $schema->addField('nom', 'string')->addField('prenom', 'string')->addField('email', 'string')->addField('telephone', 'string')->addField('adresse', 'string')->addField('codePostal', 'string')->addField('ville', 'string')->addField('adresseChantier', 'string')->addField('commentaire', 'text'); }