Skip to content

Commit

Permalink
Merge pull request #1 from winzou/company
Browse files Browse the repository at this point in the history
Add company form field
  • Loading branch information
jjanvier committed May 23, 2013
2 parents 3ccde3a + cdc8321 commit 184a6b6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions Form/Type/AddressType.php
Expand Up @@ -55,6 +55,10 @@ public function buildForm(FormBuilderInterface $builder, array $options)
->add('lastName', 'text', array(
'label' => 'sylius.form.address.last_name'
))
->add('company', 'text', array(
'required' => false,
'label' => 'sylius.form.address.company'
))
->add('country', 'sylius_country_choice', array(
'label' => 'sylius.form.address.country',
'empty_value' => 'sylius.form.country.select'
Expand Down
2 changes: 1 addition & 1 deletion Resources/config/doctrine/Address.orm.xml
Expand Up @@ -24,7 +24,7 @@
<join-column name="province_id" referenced-column-name="id" />
</many-to-one>
<field name="street" column="street" type="string" />
<field name="company" column="company" type="string" />
<field name="company" column="company" type="string" nullable="true" />
<field name="city" column="city" type="string" />
<field name="postcode" column="postcode" type="string" />
<field name="createdAt" column="created_at" type="datetime">
Expand Down

0 comments on commit 184a6b6

Please sign in to comment.