Hello

How can I configure the admin generator to display an additional "retype 
password"
field and validate it with the already existing password field that's populated
with the database content? The retype password should be discarded afterwards 
and
so that the admin generator only stores the password if it has changed.

I known that showing the sha1 hash in the web interface is not as clean as 
possible
but I could live with that. It's just for the admins after all :)

What I managed so far is displaying the additional field using a 
_retype_password.php
template and the following generator.yml:

generator:
  class: sfDoctrineGenerator
  param:
    model_class:           ManageUsers
    theme:                 admin
    non_verbose_templates: true
    with_show:             false
    singular:              ~
    plural:                ~
    route_prefix:          manage_users
    with_doctrine_route:   true
    actions_base_class:    sfActions

    config:
      actions: ~

      fields:
        password:
          sfStringValidator:
            min: 6
            min_error: password must be at least 6 characters

        new_password:
          name: Erneut Password
          label_for: retype_password

      list:    ~
      filter:  ~
      form:    ~

      edit:
        display:
          "User Details": [username, password, _retype_password, comment, host, 
expire, type]

      new:     ~
bye,

-christian-

-- 
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en.

Reply via email to