summaryrefslogtreecommitdiffstats
path: root/apps/admin/modules/user/config/generator.yml
blob: 4764f5b348cfb7f906db54d6bbe26d762ac4bced (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
generator:
  class:              sfPropelAdminGenerator
  param:
    model_class:      User
    theme:            mailadmin

    fields:
      nickname:              { name: Nickname }
      full_name:             { name: Name }
      email:                 { name: E-Mail }
      last_login:            { name: Last Login }
    
    list:
      peer_method:           doSelectJoinRole
      title:                 List of Administrators
      display:               [=nickname, _role_id, _domain_permissions, full_name, email, _last_login]
      filters:               [nickname, role_id, email, parent_user_id, last_login, created_at]
      max_per_page:          '$this->getUser()->getResultsPerPage("pager")'
      sort:                  [nickname, asc]
      fields:
        domain_permissions:  { name: Associated Domains, params: align=left }
        nickname:            { params: align=left }
        role_id:             { params: align=left }
        full_name:           { params: align=left }
        email:               { params: align=left }
        last_login:          { params: align=right }
      object_actions:
        edit:                { name: Edit, action: edit, icon: edit.gif }
        delete:              { name: Delete, action: delete, icon: trash.gif, params: confirm=Are you sure? }
      actions:               {}

    create:
      title:                 Create New Administrator
      
    edit:
      title:                 'Editing Administrator %%nickname%%'
      display:
        'General Settings':  [nickname, first_name, last_name, email, parent_user_id]
        'Password Settings': [_password, _password2]
        'Permissions':       [role_id, domain_permission]
      fields:
        domain_permission:   { name: Assign Domains, type: admin_double_list, params: through_class=DomainPermission, help: Assign which domains the user is allowed to see (Ignored for superadmins) }
        parent_user_id:      { name: Parent User, only_for: edit }
        nickname:            { name: Nickname, params: size=50 }
        first_name:          { name: First Name, params: size=50 }
        last_name:           { name: Last Name, params: size=50 }
        email:               { name: E-Mail, params: size=50, help: Used for password requests or notifications }
        role_id:             { name: Role }
        password:            { name: Desired Password }
        password2:           { name: Re-Type New Password, only_for: edit, help: Leave blank if you do not want to change the password }
      actions:               
        _save_and_list:      { name: Save }
        _save_and_add:       { name: 'Save, then create new one' }
        _list:               { name: Cancel }