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 6227313
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T09:11:32+00:00 2026-05-24T09:11:32+00:00

In my Grails 1.3.7 project I have a domain class like this: class User

  • 0

In my Grails 1.3.7 project I have a domain class like this:

class User {

String login
String password
String name
String passwordConfirmation

static constraints = {
    login       unique:true, blank:false, maxSize:45
    password    password:true, blank:false, size:8..45, 
                matches: /(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?!.*\s).*/
    name        blank:false, maxSize:45
    passwordConfirmation display:true, password:true, validator: { val, obj ->
        if (!obj.properties['password'].equals(val)) {
            return ['password.mismatch']
        }}
}

static transients = ['passwordConfirmation']

String toString() {
    name
}

}

And I’m using scaffold for the corresponding create/edit actions.

My problem is that even if I marked passwordConfirmation constraint to be displayed, it isn’t shown at the scaffold views. Is there something that I’m missing to make transient properties to be displayed? Is it possible?

Thanks

  • 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-24T09:11:33+00:00Added an answer on May 24, 2026 at 9:11 am

    By default grails doesn’t create the fields in views for transient properties. You could manually add them on each view or if you have a lot of them and are using the scaffolded views you could do the following:

    Install the view templates:

    grails InstallTemplates
    

    Then open the relevant templates in src/templates/scaffolding

    and modify the line that reads:

    persistentPropNames = domainClass.persistentProperties*.name
    

    to

    persistentPropNames = domainClass.properties*.name
    

    for each of the templates. This is a bit of a bodge, but it should work and you can further edit the template to include/exclude any properties you like.

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

Sidebar

Related Questions

I'm working on a grails legacy project. A domain class called User exists. It
I have the following domain class in my grails project: class Vacation { Date
I am a newbie in grails and groovy. I have a Project domain-class with
I have a gant script in my grails project. I would like to do
i have a grails project Customer customer = Customer.get(params.id) where customer is a domain
In a grails project, some of the domain classes have a region field (not
I have a class in src/groovy in my grails project. How do i make
I have a grails project that contains a few domain objects. I am using
I'm working now together with others in a grails project. I have to write
I'm considering using Grails for my current project. I have a couple of requirements

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.