Skip to content

Commit

Permalink
Merge pull request #4821 from trydofor/master
Browse files Browse the repository at this point in the history
fill  the original tempty template
  • Loading branch information
marcospereira committed Jul 30, 2015
2 parents af62ebb + ff4c5ef commit 7b4f5ab
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 2 deletions.
Expand Up @@ -5,3 +5,5 @@ GET /contacts/:id controllers.Application.showContact(id:Int)
POST /user controllers.Application.userPost

POST /submit controllers.Application.submit

POST /contact/save controllers.Application.saveContact
@@ -1,3 +1,20 @@
@(contactForm: Form[Contact])
@(contactForm: Form[Contact])(implicit messages: Messages)

@import scalaguide.forms.scalaforms.controllers.routes

@helper.form(action = routes.Application.saveContact) {

@helper.inputText(contactForm("firstname"))
@helper.inputText(contactForm("lastname"))
@helper.inputText(contactForm("company"))

@helper.repeat(contactForm("informations")) { info =>
@helper.inputText(info("label"))
@helper.inputText(info("email"))
@helper.repeat(info("phones")) { phone =>
@helper.inputText(phone)
}
}

<input type="submit" id="submit" value="@routes.Application.saveContact">
}
Expand Up @@ -92,7 +92,7 @@ In the code samples below, we’ll use the following JSON:
"key2" : {
"key21" : 123,
"key22" : true,
"key23" : [ "alpha", "beta", "gamma"]
"key23" : [ "alpha", "beta", "gamma"],
"key24" : {
"key241" : 234.123,
"key242" : "value242"
Expand Down

0 comments on commit 7b4f5ab

Please sign in to comment.