About play.api.data.Form problem when i add more than 4 elements

122 views
Skip to first unread message

Isak Rickyanto

unread,
Nov 16, 2011, 3:59:58 AM11/16/11
to play-fr...@googlegroups.com
Hi,

I am developing using Play 2.0 now, and i have problem with Form:

If i use this code:
 val testingForm = Form(
   of (
      "id" -> text,
      "title" -> requiredText,
      "content" -> requiredText,
      "slug" -> requiredText
      )
  )

Above code works well, but i add new element, it always fail.

Example if i add "test": 

 val testingForm = Form(
   of (
      "id" -> text,
      "title" -> requiredText,
      "content" -> requiredText,
      "slug" -> requiredText,
      "test" -> requiredText
      )
  )

That code cause me got exception message:
...
overloaded method value of with alternatives: [A, B, C, D](a: (String, play.api.data.Mapping[A]), b: (String, play.api.data.Mapping[B]), c: (String, play.api.data.Mapping[C]), d: (String, play.api.data.Mapping[D]))play.api.data.Mapping[(A, B, C, D)] .
I don't really understand well when reading scala play.api docs, but I think the play.api.data.Mapping only accept maximum 4 elements? Is that correct?

Thanks


Best regards,
Isak Rickyanto
----------------------
BeritaTeknologi.com

Guillaume Bort

unread,
Nov 16, 2011, 4:22:21 AM11/16/11
to play-fr...@googlegroups.com
Try the new beta package. It is fixed.

> --
> You received this message because you are subscribed to the Google Groups
> "play-framework" group.
> To post to this group, send email to play-fr...@googlegroups.com.
> To unsubscribe from this group, send email to
> play-framewor...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/play-framework?hl=en.
>

--
Guillaume Bort

Isak Rickyanto

unread,
Nov 16, 2011, 4:35:21 AM11/16/11
to play-fr...@googlegroups.com
Thanks Guillaume for your quick answer, will try ASAP.
Reply all
Reply to author
Forward
0 new messages