create and review the creation of a person

This commit is contained in:
2013-12-03 17:12:56 +01:00
parent 44d8236f21
commit 5750c73574
6 changed files with 258 additions and 7 deletions

View File

@@ -16,6 +16,18 @@ chill_person_general_update:
pattern: /view/{id}/update
defaults: {_controller: CLChillPersonBundle:Person:update }
chill_person_new:
pattern: /new
defaults: {_controller: CLChillPersonBundle:Person:new }
chill_person_review:
pattern: /review
defaults: {_controller: CLChillPersonBundle:Person:review }
chill_person_create:
pattern: /create
defaults: {_controller: CLChillPersonBundle:Person:create }
chill_person_search:
pattern: /search

View File

@@ -7,17 +7,17 @@ CL\Chill\PersonBundle\Entity\Person:
groups: [general]
name:
- NotBlank:
groups: [general]
groups: [general, creation]
- Length:
min: 2
max: 255
minMessage: validation.Person.constraint.name_min
maxMessage: validation.Person.constraint.name_max
groups: [general]
groups: [general, creation]
surname:
- NotBlank:
groups: [general]
groups: [general, creation]
- Length:
min: 2
max: 255
@@ -26,7 +26,8 @@ CL\Chill\PersonBundle\Entity\Person:
groups: [general]
dateOfBirth:
- Date:
groups: [general]
message: validation.Person.constraint.dateOfBirth.not_valid
groups: [general, creation]
nbOfChild:
- Range:
min: 0
@@ -48,11 +49,15 @@ CL\Chill\PersonBundle\Entity\Person:
CL\Chill\PersonBundle\Entity\PersonHistoryFile:
properties:
date_opening:
- Date: ~
- NotNull: ~
- Date:
message: validation.history.date_opening.not_valid
- NotNull:
message: validation.history.date_opening.not_null
date_closing:
- Date: ~
- Date:
message: validation.history.date_closing.not_valid
- NotNull:
message: validation.history.date_closing.not_null
groups: [closed]
constraints:
- Callback: