Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7630369
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T06:05:05+00:00 2026-05-31T06:05:05+00:00

In Groovy/Grails 2.0 I’ve got a domain with Float variable ( Float weight =

  • 0

In Groovy/Grails 2.0 I’ve got a domain with Float variable ( Float weight = 25.28 for example ). When Grails generates form with corresponding number input field, validation complains about the 25.28 value and will only accept an int value. Could someone illuminate what’s going on with that?
Thanks in advance.

EDIT:
In Gails domain object(Double and BigDecimal for the sake of argument):

   Double weight = 350.26;
   BigDecimal width = 86.1;

Generated html:

<input id="weight" type="number" value="350.26" required="" name="weight">
<input id="width" type="number" value="86.1" required="" name="width">

… turns our FF 7 is fine with those numeric values and Chrome gives me “Invalid Value” and only accepts integers.
Any idea on what I’m missing?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T06:05:06+00:00Added an answer on May 31, 2026 at 6:05 am

    If you’re using ‘grails generate-all’ _form.gsp files then update the generated _form.gsp input element to add step=”0.001″ or step=”0.1″ or step=”any” or the like.

    http://code.google.com/p/chromium/issues/detail?id=44116

    One approach to get this update into all generated _form.gsp files is to run ‘grails install-templates’ then edit src/templates/scaffolding/renderEditor.template renderNumberEditor method and add step=”any” to each

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm doing a groovy/grails form file-upload operation, as is described here http://www.grails.org/File+Upload I'd like
I'm just getting started with Groovy/Grails. I added a new domain controller to my
Is there a way to make a domain class name human readable in Groovy/Grails?
I have a groovy/grails application that needs to serve images It works fine on
Is there a good development IDE for Groovy/Grails code completion under Linux?
From the book Groovy and Grails recipes I'm using the following code snippet: String
I'm currently working with Groovy and Grails. While Groovy is pretty straight-forward since it's
Besides the sample applications featured in the books Beginning Groovy and Grails and The
Recently I've been playing a bit with Groovy and Grails and I have to
How to read and import .csv file in groovy on grails. I have .csv

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.